Instrument Control (GPIB, Serial, VISA, IVI)

cancel
Showing results for 
Search instead for 
Did you mean: 

error 1073807302 with a USB device

I have been trying to communicate to a USB device, a Gigahertz-Optik Optometer. I have Windows 2000, VISA 4.0 and Labview 7.1 installed on my PC.

I am successfully able to Open the device, however while using Bulk in or Bulk out operations, I get an error 1073807302. The code is attachd below, actually USB RAW BULK example from NI website. The device seems to use a 32 bit Int datatype. But whatever bytes u try in the Bulk-in session generates the same error. What could be the issue? Is it a version problem?

I have read all the discussions on simillar error, unfortnately none was helpful. I have also attached a Spy file generated while the program was being run, in case it is helpful.

Regards
RK


Download All
0 Kudos
Message 1 of 22
(6,724 Views)
Hey,
I think your device supports USBTMC protocol, this link will shows how you can talk to your USB instrument.
Good luck with everything.
Regards
Nikhil A

0 Kudos
Message 2 of 22
(6,703 Views)

http://www.gigahertz-optik.de/database_de/html/produkte/optometer/

According to Gigahertz-Optik optometer web page, there are two models that have USB interface - X1 and HCT-99.  Assuming one of them is used, the product cataloges say the USB protocol is both HID. 

 

0 Kudos
Message 3 of 22
(6,699 Views)
Thanks for the reply.
The USB protocol  for the X11 Optometer that I am using, supports both HID. Moreover, there is no problem in detecting the device as MAX detects it as a USB device and  I can open it using VisaOpen. However, VisaRead or VisaWrite gives me the error 1073807302 (at HEX0x0BFFF003A). If I need to retrive the output of the optometer, I should be able to send in the commands set by the manufacturer. VisaRead/write is not working, I can't do that.

VisaRead needs just 2 inputs. A VISA resource-name (Which is correct as VISAOpen returns no error with the same name) and byte count. Now, this is 12bit ADC device, and the accompanying header file for the dll states it to use a 32 bit data type. ANy number in byte count doesn't seem to work.

Moreover, if I try to communicate to the device using a Call Library Function Node (manufacturer has provided a dll), I get the message that the exception has occured at the external. This I believe is the direct consequence of improper VisaRead/Write.

Any help is appreciated.

Regards,
0 Kudos
Message 4 of 22
(6,686 Views)
Never mix up calls via visa and the dll.
You should probably only use the dll calls, visa does not make life easier for you.
The dll knows how to handle usb already, or do you need visa for something else?

greetings from the Netherlands
0 Kudos
Message 5 of 22
(6,683 Views)
I was already trying to communicate using VISA, when I actually got hold of the dll from the manufacturer. But Call library node function returns error to even the easiest commands defined in the header file. It returns the message that the exception has occured at the external code, and program crashes. What could be the mistake in such as small cade (Given below). I have also added the header file, if you might need.


Regards,
Download All
0 Kudos
Message 6 of 22
(6,682 Views)
I don't quite understand how the device even shows up in MAX if it's HID. Only USBTMC devices or devices you create an inf file with the VISA Driver Development Wizard should be listed. If you did use the wizard, that was a mistake and you should remove the inf and pnf files that were created by the wizard.
0 Kudos
Message 7 of 22
(6,680 Views)
OK. I had created the inf files, as tried to use it as a USB RAW dvice. I removed the the inf files. However, MAX still seems to detect it as a USB device under Devices and Interfaces.
0 Kudos
Message 8 of 22
(6,673 Views)
Dlete the device in max and eventually in the windows device manager.
The original software will take over

greetings from the Netherlands
0 Kudos
Message 9 of 22
(6,671 Views)
I can't delete the device form MAX as delete button for the device in MAX is disabled. Device Uage enable button is checked, but disabled and hence can't change its state. If I remove its driver from the device manager, it get re-installed for the same USB device. The alias is also not getting deleted as the option is also disabled.

Should I completely remove VISA itself?
0 Kudos
Message 10 of 22
(6,669 Views)