LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Is it possible/advisable to make Agilent 34401 drivers reentrant?

Hi all, I use two Agilent 34401 multimeters from LabVIEW for concurrent data acquisition (connected through GPIB).
I noticed that, contrary for example to DAQmx drivers, all the Agilent 34401 drivers are not reentrant by default.
This gives me a problem when using for instance two concurrent "read" subvi, so that the second block waits the first one to end execution before commanding the multimeter (each measurements from the multimeter takes about 2 seconds).
I'd like to ask if there is some reason to leave the instrument dirvers non reentrant, or if I can set all my Agilent 34401 subVI to reentrant (I noticed that for instance all DAQmx subVI are reentrant by default).
I also would like to ask if it is possible to set the Agilent subVIs reentrant only for my application, while leaving the default settings unchanged on the main installation so that other applications running on the same PC are not affected.

Thank you very much for your help,
Luca
0 Kudos
Message 1 of 3
(2,713 Views)
There's not much reason to make the driver functions reentrant. I suppose you want to do this because you think that will make them work in parallel but the GPIB bus does not (with few exceptions), support parallel operations. You can however, optimize your program to minimize the waits. For example, you can set both instruments for software trigger and start the measurements at the same time. You can also configure the instruments to assert an SRQ when it's measurement is complete so that you can poll them and as soon as detected, read the data. If the instrument takes 1 second for the measurement, you will still have to wait that amount of time but you should be able to immediately read the second instrument after the first.
0 Kudos
Message 2 of 3
(2,698 Views)
Thank you very much for your reply. In fact I've solved my problems using the low level blocks ("configure trigger" + "initiate measurement" + "fetch measurement").
The problem I had was because I used the "read (single point)" vi.  Inside it also uses the configure trigger + initiate measurement + fetch measurement, but the strange thing is that  also if I configured it as reentrant it didn't allow me to acquire "simultaneously" from the two instruments. Then I understood the problem was because of the "query questionable data register" and "error query" blocks which are also inside the "read (single point)". You need to put them out of the acquiring cycle or each instrument will wait the end of the other before starting the measurement. I didn't really understand the reason, but that's it, putting them out of the measuring cycle solves the problem.

Thank you again,
Luca
0 Kudos
Message 3 of 3
(2,688 Views)