Instrument Control (GPIB, Serial, VISA, IVI)

cancel
Showing results for 
Search instead for 
Did you mean: 

faster read and write

hello,

 

I've written a program to control an old spectrum analyzer (OSA) throught a GPIB device.

 

the program is written as an infinie while loop with varioud buttons which respond to changes in the button value.

 

the only think that is constantly done is to read data from the OSA. The OSA constantly sweep over the measurement ragne and store the data - 800 points;

 

I read it in my while loop and output it to waveform chart.

 

When I wrote (it was my first program in ;LabView) I read a lot of tutrials and used a standard scheme that was working for me: send read command, some delay and read data from the instrument. without the delay time between read and write (send read command) it did not work. I tried other configuration like waiting for status byte without success.

 

any how - this method is working but kind of slow...for example if the OSA sweep the entire range at 50 msec, when working through the computer it's down to about 1 Hz.

 

Is there any way to make it faster?

0 Kudos
Message 1 of 14
(5,368 Views)

Can you post your vi or screen shot?

0 Kudos
Message 2 of 14
(5,365 Views)

read data.png

 

attached.

0 Kudos
Message 3 of 14
(5,357 Views)

What is the baud rate that you have set? you dont need to use a flat sequence to create delay between write and read. Please close your session

0 Kudos
Message 4 of 14
(5,354 Views)
What's the make and model? Is there an option to send the trace data as binary instead of ASCII text.
0 Kudos
Message 5 of 14
(5,343 Views)

 

The data are 800 points of numbers (like -62.45).

 

This is what the TRA? command output. I don't know if it can be output binary and if so, how to show it in a graph.

 

I do not save the data to file but input it to a waveform graph

0 Kudos
Message 6 of 14
(5,338 Views)
Why won't you provide the male and model? Have you read the manual?
0 Kudos
Message 7 of 14
(5,332 Views)

hello,

 

sorry for the late respones. I had to check the manual again as I worked on this program long time ago.

 

it is possible to read the data as binary (one or two bytes)...

 

but how do I present them on a waveform chart? (currently I present data on chart as x0, dx, number of points)

0 Kudos
Message 8 of 14
(5,274 Views)

it is an old optical spectrum analyzer model: HP 71450B

0 Kudos
Message 9 of 14
(5,273 Views)
There will be conversion instructions in the manual. Other drivers for analyzers and scope will almost always use binary transfers so you can get some ideas from them.
0 Kudos
Message 10 of 14
(5,266 Views)