Not sure I can get to a working Amiga to make this for you, but the RKMs have a demo of talking to the parallel port that should help you out. For what you are trying to do, I would use a command variable input which would allow you to put 00 through FF as the input, convert it to binary and sent the byte out the port. The advantage of that is you can use it from a script or from Arexx with the tool itself being pretty simple.
-Tig