Instrument Control (GPIB, Serial, VISA, IVI)

cancel
Showing results for 
Search instead for 
Did you mean: 

Reading Spectrum Analyzer trace data accurately into waveform

Hi,

 

I'm trying to read the trace data from an HP8594A Spectrum Analyzer so that it is replicated into a waveform using LabVIEW 6.1. The attachment shows that I'm able to obtain amplitudes over the spectrum 200 to 1GHz. The spectrum analyser has more information such as limit lines, a grid, scales, freq ranges etc. How can I retrieve ALL the display data and place it onto the waveform? I have tried changing trace data formats from real number to binary to measurement data format. Only binary seems to work properly as this is what's displayed. From here, will it be rather simple to convert the waveform to a JPG image? Any help is much appreciated.

 

Matt

0 Kudos
Message 1 of 4
(5,402 Views)

Hello ms1,

       I recommend that you look through the other VIs in the instrument driver and see if any of them implement the functionality that you seek.  If they don't, then I recommend that you get the programming manual for the instrument (sometimes the programmable commands are in the user manual), and develop VIs that do what you need.  If you are just looking for a screenshot of the SpecAn, there might be a command in the instrument's command set that will do exactly that.

 

Cheers,

 

NathanT

 

p.s.  It is probably a good idea to save a copy of the current driver somewhere safe before you start modifying it

0 Kudos
Message 2 of 4
(5,393 Views)

Thanks for the advice but I have already tried these. The VI uses the tdf b script which sends the display data in binary format. The manual has a screenshot using the tdf m (measurement format) script using HP Basic. I changed the VI from tdf b to tdf m but the image wasn't the same as appeared in the manual. The script for setting up a basic measurement sweep as per the manual is:

 

10 INTEGER A(1:401)                                                      Dimension array A.

30 OUTPUT 718;"IP;CF 300MZ;SP 20MZ;SNGLS;TS;"       Take a measurement sweep.

40 OUTPUT 718;"TDF M; TRA?;"                                      Send trace A data in M format.

50 ENTER 718;A(*)                                                          The computer receives the trace data.

60 PRINT A(*)                                                                  Print trace data.

70 END

 

As far as the manual states, this prints a near replica of the display.

 

The innards of the Read Wvfm to Array Ascii.vi is attached. There is another similar vi included in the driver which yields the same results. It may look as though I'm asking you to produce complete solutions but I merely want suggestions on how to proceed. Thanks

 

0 Kudos
Message 3 of 4
(5,371 Views)

Hello ms1,

       Most likely, the instrument would send image data back in a very different format than it would send trace data.  Just changing the command that is sent to the instrument will probably not have the desired effect.  You should also figure out how much image data is being returned by the instrument, and determine how to parse the data.  A great resource for this information would be the instrument vendor.

 

Cheers,

 

NathanT

0 Kudos
Message 4 of 4
(5,349 Views)