09-29-2009 08:15 PM
Hi, I am planning to write a labview program that can communicate with 3 RS 232 devices and 3 RS 485 devices. Could you please tell me the effiecient way to write such a program.
Thank you!
Solved! Go to Solution.
09-29-2009 09:44 PM
Start by looking at the Serial examples in the Example Finder.
For the 3 RS-485 devices, are they all sharing the same serial port? Or do they have separate serial ports?
I would use an architecture that has a separate while loop for each serial port in use, that way any delays or problems with communications in one doesn't conflict with the others. If all 3 RS-485 devices share the same serial port, then their communication should be combined into one loop, that way you don't have any conflicts with multiple parts of your code trying to use the same serial port at once.
Look at a producer/consumer architecture for getting the data from your serial communication loops to the other parts of your code.