07-01-2012 08:16 PM
I am trying to connect 2 Kvaser (USB) dongles to my computer using LabVIEW simultaneously...
They are connected to the computer with a USB Hub but that shouldn't make any difference.
I have: CANKing CAN bus monitor program and the Kvaser SDK and their LabVIEW library also - all installed.
When I run CANKing, the program can detect both USB devices and also the 2 virtual channels - 4 in all.
When I call the CanGetNumberOfChannels.vi the value returned is 3 - but should be 4.
I am assuming that the CANKing program uses the same API calls.
Any ideas, why the second device is not recognised??
Solved! Go to Solution.
07-03-2012 12:55 PM
If you use the devices one at a time, does the CanGetNumberOfChannels.vi return the proper value?
07-03-2012 02:03 PM
I have seen this behaviour before, it is nearly impossible to cleanly unload the Kvaser dll when it is misbehaving. Re-starting LabVIEW may help. If the Kvaser hardware configuration tool shows 4 channels, then the CanGetNumberOfChannels dll call should reflect this. It is not a good idea to add or remove a device with the driver loaded.
All the best,
07-03-2012 06:33 PM
I was playing around with it further again yesterday and just calling a dll directly without using the VI (which is basically the same thing).
Results have been inconsistent although I was able to get the dll to recognise four channels at one point.
08-30-2012 05:09 AM
Just came across your question here. An answer to your question is on our website at:
As the FAQ at the link states, the problem arises due to when the DLL is unloaded.