05-01-2024 05:00 PM
I am trying to get a Vi to function that is running off a EVAL - CN0359 unit. The unit measures conductivity and temperature and is RS485.
I have an RS485 to USB converter, and when I prompt the EVAL with the correct command in tera term, I get a full response.
- The baud rate is set correctly with the EVAL - 115200
- I am using 8N2 for the rest of the settings, I believe the stop bits for this unit are 2 but I'm not entirely sure. I've been having a hard time finding that information.
- The vi runs through everything but then gets to VISA READ and gives me the error- it looks like the program is looking for a response but is getting nothing back, so it times out.
- I tested it on the VISA test panel, and I can write information with no error, but when I click read, i only get a short snippet of information back, even if I set bytes to read to some ridiculous number like 10000.
Does anyone have any general guidance on what to change from a RS232 serial to get a RS485 serial vi to run properly? I am familiar with RS232 serial coms.
Any input/direction or guidance is appreciated!!!
05-02-2024 06:22 AM
Why not to post the whole vi? (preferably in a LV version <= 2021) It's difficult to debug pictures. However, a few quick remarks:
- it's unlikely you need to set flow control other than 0 = none; probably your converter does an automatic send/receive management - but please check the device documentation
- if you are using \n as termination character, you don't need to wait between write and read
- I would clear the input buffer before writing
05-02-2024 06:37 AM - edited 05-02-2024 06:43 AM
Make sure that you are send a correct new line.
Your current image does not show the correct information.
Make sure that the display code for your string is in the correct format when you enter \n or \r
05-02-2024 03:47 PM
Most serial communication issues can be solved by watching this video: VIWeek 2020/Proper way to communicate over serial
05-03-2024 06:09 AM