Peja,
Each HEX characters is only a nibble (4 bits), thus you need to combine 2 into a byte.
Assuming that the 4 high-order bits are false, you can simply shift the first nibble by 4, then OR it with the second nibble. etc.
I have attached a quick modification to show the procedure.
Some issues:
Do you need to terminate the command with /r/n? Your "ideal" command does not contain it. Add them back if needed.
I recommend a button switch set to latch for the action keys. a latching toggle switch is not natural.
If you make your digits U8, you can typecast them. No need for complex case structures.
You don't need a timeout event. Nothing needs to be done in the empty case. (However, you need a stop event so the VI can be stopped).
You don't need the big case structure. The event structure alone does just fine.
🙂Message Edited by altenbach on 03-16-2005 04:00 PM