NI產品與技術 討論區

取消
顯示結果 
搜尋替代 
您的意思是: 

USB HID compliant device

我需要和Mastervolt 的MasterBus - USB设备通信,该设备属于USB HID compliant device。我通过NI-VISA Driver Wizard制作了一个USB VISA接口,但无论怎样都不能成功的实现通信。报告错误的内容较多,比如"visa: (hex 0xbfff003a)"等。 在制作USB VISA之前,bus hound能监测到该设备的通信。在制作USB VISA之后就检测不到了。这是为什么?有其他的办法实现吗?

0 積分
1 條訊息(共 2 條)
2,113 檢視

You should not use VISA USB Raw to try to talk to a USB HID device. VISA does not know anything about USB HID. The USB Raw mode is the lowest level USB protocol level, comparable to the IP level in TCP/IP and you don't want to communicate on IP level to implement a higher level protocol like SNMP.

 

Instead you should try to get drivers for your instrument in form of a DLL and access this DLL. In the worst case you should interface to the Windows HID API, but for that you need to know the actual data format that the HID messages should contain. This is something the device manufacturer has to provide to do, and in many cases they can't or don't want to do that. Also the Windows HID API is absolutely not LabVIEW friendly and writing an intermediate DLL in C/C++ that translates between the Windows HID API and a more friendly LabVIEW interface is definitely advisable.

 

But a manufacturer really should provide a DLL for his own devices!!!! This you can then fairly easily call from LabVIEW using the Call Library Node.

Rolf Kalbermatter
My Blog
0 積分
2 條訊息(共 2 條)
2,082 檢視