LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Fast communication with a number of identical devices through a single RS232

Hello Everyone,

I am using an altered version of the driver for my instrument that I got from NI website. I have a serial connection that is made between the devices (output of 1st goes to input of the 2nd and so on) and only one SR232 connection is made to the computer. Each device has a unique address that will allow me to address it individually. I edited the example file in the driver that I downloaded and basically duplicated the interface where I would have several instance of the subVIs but only one initialize VI to open the VISA resoruce. The only difference between the input into the subVIs are the address and the data for each specific device.

 

My trouble is that LabVIEW is slow is passing from one subVI to the other (even before I made any edition or with only one deivce). This is contrary to MATLAB, where for example an ASCII command get passed to the device is less than a second! I am looking to achieve something similar if possible.

As well, can someone please set me straight as to whether I should have used several instances of the subVIs or should I have done anything else?

To summarize, I can control my devices but the process is slow.

 

Sorry the long post.

Thanks for helping,

Aym

0 Kudos
Message 1 of 3
(2,370 Views)

Hi Aym,

 

Thanks for posting.  There may be a number of factors we need to consider.  First of all, how exactly are you benchmarking between the two programs?

 

Can you maybe post your code?  I know many instrument drivers will have a wait function between read and writes.  And also the instrument drivers that manufacturers have will usually have many layers so the subVI that you are calling may have several other subVI's which will increase your execution time. 

 

 

Tejinder Gill
National Instruments
Applications Engineer
Visit ni.com/gettingstarted for step-by-step help in setting up your system.
0 Kudos
Message 2 of 3
(2,338 Views)