I am new to LabView and GPIB so I apologize if this is something trivial but I could not find anything related...I am not sure if this is realted to my device, my VI, GPIB or a combination of such.
I am using a Labview 2009, I am using the Basic GPIB Read/Write VI to command and query my device which is connected via a GPIB-USB interface. I am confident that the VI works, I can command my device to set certain parameters and I can query those parameters to ensure they accepted by the device. So, let's say I send a command to route my RF power to be measured on the top port, I then send a query to see how much power is at the top port. My device reports 21.5dbm (Current), 22.6 (Max) and 21.3 (Minimum).
My problem starts when I send the next query, let's say I query the frequency. I am expecting my device to report 1030.1MHz (Current), 1030.7 (Max) and 1030.0 (Minimum) but my VI is reporting the data from the original query, 21.5dbm (Current), 22.6 (Max) and 21.3 (Minimum). After I run the VI several times the correct data is received. I would really only like to run the VI one time and have the correct data appear.
I am not sure if this is coincidental or part of my problem...First, I ran my VI 15 times before the "Frequency Query" reported correctly. I then sent another query and I had to run the VI 33-35 times before the correct data displayed; I then had a hunch and sent another query, this time it took approximately 64-65 times to run the VI before the correct data was captured.
Any help would be appreciated.
(I needed to edit this post because it was written as if I wrote the VI...I did not; I downloaded it.)
Thanks,
jb