Instrument Control (GPIB, Serial, VISA, IVI)

cancel
Showing results for 
Search instead for 
Did you mean: 

Visa write and read from two com ports simultanously

How can I read and write up to 8 (PCI485) com ports at the same time. When I use while loops for every com ports. How can I determine that every while loop whith its own com port runs independantly ?
0 Kudos
Message 1 of 3
(3,484 Views)
You can do VISA communication with multiple com ports at once. You should make sure that your serial vi's are re-entrant. There is a Knowledge Base that discusses the use of multiple serial ports at once (link below). You should also make sure that there is no data dependence from one loop to the next. Since LabVIEW is data dependent, once it has all necessary data, the loop will run. To determine if your loops are running independently, you can turn on "Highlight Execution" mode and see what order things occur in.

http://ae.natinst.com/operations/ae/public.nsf/fca7838c4500dc10862567a100753500/59458684cf7861cc862565410061db3b?OpenDocument

If you are not using LabVIEW, make sure that your application is multi-threaded.

Kim L.
Applications Engineer
National Instrumen
ts
0 Kudos
Message 2 of 3
(3,484 Views)
An updated link to the KnowledgeBase mentioned in the answer is:

http://digital.ni.com/public.nsf/websearch/59458684CF7861CC862565410061DB3B?OpenDocument

Molly K.
National Instruments
Molly K.
Web Support & Operations Manager
National Instruments
0 Kudos
Message 3 of 3
(3,484 Views)