AnsweredAssumed Answered

FETCH command and 34972A switch unit

Question asked by nigelstevens on Nov 8, 2013
Latest reply on May 12, 2015 by adaware
I'm programming a 33522A waveform generator and a 34972A switch unit using C++ Builder XE. The 34972A has one 40 channel mux (34908A) and two 20 channel mux cards (34901A) fitted.
I've configured all the channels I want to read (frequency, volts ac and volts dc), setup the format (reading, channel and time all ON), and issued the scan command :
:ROUT:SCAN (@101:140,201:220,301:317)
then an INIT command
The scan runs, then after a delay, I use the following in my C code :
viQueryf(Agilent_34972A, ":FETC?\n", "%#T", &readings_size, readings);

readings is just an array of chars, reading_size is an int, which I've tried setting to several different values.

What I want to know is :
1/. What should readings_size be set to (is it the number of readings I'm expecting ?)
2/. Why do I only get readings back up to (and including) channel 309, when the channel list goes up to 317 ?

The data I get back seems to be about 2560 characters. Is this the size of the "output buffer" ?

When I use the front panel green **** on the 34972A to step through the channels, it shows FREQ, VAC or VDC for all channels as expected, including channels 310-317 which don't get returned by the vQueryf FETC statement.

Edited by: NigelStevens on Nov 8, 2013 2:59 PM