From Friday, April 19th (11:00 PM CDT) through Saturday, April 20th (2:00 PM CDT), 2024, ni.com will undergo system upgrades that may result in temporary service interruption.

We appreciate your patience as we improve our online experience.

LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

advanced scan vi agilent used for continous measurement

I have been using ez temp vi to measure continous temperature mesurments using agilent 34901A.However the speeds are are not fast.

I am trying to read atleast 60 channel readings/sec.BUt as of now I am able to do only 2-3 readings per sec.

 

 

LAter I learnt form some discussiond here that use of advanced scan vi might help.

 

 

So I tried using advanced scan vi .But it worked in debug mode but not in the actual run mode.

Then I learnt from this forum below. that there needs to be a delay timer before configure and trigger vis.

 

 http://forums.ni.com/ni/board/message?board.id=170&message.id=249889&query.id=726386#M249889

 

After doing so  it works.

 

But I want fast measurment rates and a continous measurment. can these delays not be avoided.?

So with out having a while loop if continous measurment is required how is it done?

 

 

0 Kudos
Message 1 of 89
(3,915 Views)
 me can somebody help me solve this problem?
0 Kudos
Message 2 of 89
(3,888 Views)

Hello Siva,

May I know what is the hardware setup that you have from your PC to your agilent 34901A until your sensor?

 

The time delay from the other forum that you have posted seems to be a necessary delay for serial communication which is a waiting time necessary for the data to go to the instruments and for the instruments to send the data back to the computer.

 

Regards,

 

James

- Meadow -
LabVIEW 7.0 - 2011, Vision, RT, FPGA
TestStand 3.0 - 4.5
0 Kudos
Message 3 of 89
(3,878 Views)

I am using a USb to Rs232 to connect to my computer and then the rs232 to rs232 to connect to my agilent 34907A and then the sensor is a T type thermocouple connected to 34901A module card inside the 34907A.

 

The card specs state that 30 channels per second can be read.

 

Also in Rs232 baud rate is set to 9600 currently.So how many readings per sec does this 9600 convert to?

0 Kudos
Message 4 of 89
(3,876 Views)

Siva,

I don't think that the problem here is the baud rate but it is more how do you get the data from your agilent device.

How many ms of time delay that you put between sending message and read message that in the program?

 

There is a minimum amount of time delay but the time delay must be there to give time for the agilent devices to respond to the inquiry message to get the data. This time delay will definitely play a role in how many times you can get data from your devices. (If delay = 100ms, your maximum sampling speed would be <=10 times/second)

 

So one thing that you might want to look into would be on the Agilent 34907A programmable interface whether you would be allowed to take measurement data of all channels together and then transfer the data to the computer in one command. When you might have to inscrease the delay, this would enable you to take data from all channels instead of just one channel at a time.

 

Does the Agilent 34970  have such an instruction set?


James

- Meadow -
LabVIEW 7.0 - 2011, Vision, RT, FPGA
TestStand 3.0 - 4.5
0 Kudos
Message 5 of 89
(3,867 Views)

Yes presently the agilent vi takes an array of channel scan list and returns an array of data which can be sent to the computer.

 

1.BUt I am wondering how can the example vi that comes with drivers not work as expected and needs extra delays to be inserted?

 

2.Moreover I have read in some threads in this forum that for continously reading data one need not use a while loop with the eZ temperature vi instead in advanced Scan vi one can measure and read data  continously.

I am wondering how the same can be done without a while loop.

Advanced scan seems to be much slower than Ez vi's.

 

3.Also will increasing the baud rate not help in getting more channels/sec.

if so how is the baud rate connected to no of reading/sec.

 

4.Also how does Rs232 ,GpiB and USb compare with each other in speeds?

GPIB is 1Mbps Rs232 is 128000 bits /sec as maximum.

So how much bytes are transferred for each reading is it only the reading or there are some internal communication too.?

 

 

0 Kudos
Message 6 of 89
(3,862 Views)
users using advanced scan vi for agilent can share their experiences to overcome this problem!
0 Kudos
Message 7 of 89
(3,854 Views)

In a nutshell using the advanced agilent vi's takes two steps.

 

First you must configure a "scan" that is configure the function of the channel(s) you want to measure.

 

Second trigger a "scan", this will read the channel(s) you have configured and return their values in an array.

 

You can obviously only read a single channel as fast as you can transfer the data. GPIB is fastest or use a "real" serial cable that has all the handshaking lines (Tx, Rx, RTS, CTS, Gnd) and set the agilent to use RTS/CTS flow control. Then higher baud rates can be obtained without errors. The agilent supplied serial cable only has Tx, Rx, and Gnd lines and in my experience only supports Xon/Xoff flow control and (if you are lucky) 19200 baud max without errors. 

 

 

========================
=== Engineer Ambiguously ===
========================
0 Kudos
Message 8 of 89
(3,850 Views)

But is a while loop required to read data continously .If so what vi's need to be inside while loop the trigger and read or the read vi alone.

Moreover how is the timeinterval between two readings controlled. I see there is an option in trigger vi.

BUt is an external wait timer required in the loop?

 

can anyone post an example of the continous advanced scan vi  they have used .Thanks

0 Kudos
Message 9 of 89
(3,840 Views)
can someone answer my queries please
0 Kudos
Message 10 of 89
(3,825 Views)