LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

UDP communication between two computers

I'm using UDP to send a message to a computer and I'm having trouble with my packaging. The code will listen and recieve messages fine, but I need to send specific hex codes and that is where the problem arises. I prompt the user for a command and if the command is on the .csv command list, the program sends the HEX code to the computer. My problem is the hex code is being changed into hex code again. 

Example: 

CB00 0000 0000 0000 0000 0000 0000 0000 3A63 6F6C 6C69 7369 6F6E 2061 6374 696F....

4342 3030 2030 3030 3020 3030 3030 2030 3030 3020 3030 3030 2030 3030 3020 3030 3030 ....

 

I want it where it will read the .csv file, match the command, and the send the Hex code in the corresponding row. I attached the command list and the UDP. The section I need help in is located to the far left of the screen

 

Thanks for the help

Download All
0 Kudos
Message 1 of 2
(2,376 Views)

Right now, you are writing a string to the UDP output so the string is automatically converted to its ascii values.  To get around this, you should first convert the string to an array of integers then write those integers to the UDP output.

-Jim B
Applications Engineer, National Instruments
CLD, CTD
0 Kudos
Message 2 of 2
(2,328 Views)