Instrument Control (GPIB, Serial, VISA, IVI)

cancel
Showing results for 
Search instead for 
Did you mean: 

tkafg3k VISA: (HEX 0xBFFFOOOE) The given session or object reference is invalid

Hello. Using Labview 8.6 with the tkafg3k (built for Labview 8.2.1) driver for a Tektronix AFG 3022B arbitrary function generator connected via USB.

 

I had the everything working well earlier today, and all the example's in the driver were doing what they were supposed to on the device. After working for a while, I now get this error "VISA: (HEX 0xBFFFOOOE) The given session or object reference is invalid" during the initialize.vi included in the tkafg3k llb.

 

I've restarted the computer, unplugged the usb's, restarted the device... nothing seems to allow it to work again. Using the measurement and automation explorer, I can see the AFG, so the computer knows it's connected.

 

Does anyone have advice about what to try to get this working again or what could be causing the error.

 

Thanks,

 

-Abe

0 Kudos
Message 1 of 6
(4,063 Views)

What firmware version do you have?  I tried the different examples with the USB with the 3.2 version of firmware and did not see any issues.

Are you running the examples as they are or did you make any modifications?  You might try using also try VISA Interactive Control to verify there is not an issue with the instrument.

0 Kudos
Message 2 of 6
(4,055 Views)

I have version 3.2 firmware.

 

Attached is my code llb (requires having the tkafg3k vi's on your computer). I'm only intermittently getting the above error now. I'm mainly getting a timeout error.

 

Any ideas? There seems to be some problem at the VISA reading from the AFG3022b, as evidenced in the .spy file, also attached.

 

Thanks,

-Abe

Download All
0 Kudos
Message 3 of 6
(4,048 Views)

So here's the hack I've applied as a solution. I had to get rid of the Error Query in all of my VI's, as that read-function to the Tektronix AFG3022b was what was giving the problems (see above .spy file).Unfortunately, I now do not have error checking abilities... but I can see that the waveforms are being written correctly to the Tektronix AFG.

 

Thus, it does seem to be a problem with the "tkafg3k Error Query.vi". I'm tempted to chalk this up as an error in the tkafg3k driver (I'm using the Labview 8.2 version); but I may somehow be using it incorrectly. If anyone has suggestions or ways they've found the Error Query to work correctly, I'd be interested in hearing it.

 

-Abe

0 Kudos
Message 4 of 6
(4,032 Views)

Can you include the missing VIs AFG_offsetAndVpp(SubVI)?  To see the exact code you are using, then I'll try to reproduce the behavior you are seeing.

0 Kudos
Message 5 of 6
(3,998 Views)

Ah, I did miss one. Attached now.

 

Any suggestions?

0 Kudos
Message 6 of 6
(3,989 Views)