10-29-2009 04:11 PM
Hi everyone,
I have a problem....
One of my device (PXI-6682) is unable to register in DAQmx (for some reason)
So I am stuck using VISA...
The question is:
In C++ is there an equivalent to the DAQmx "DAQmxGetDevProductCategory" call?
I can get the physical slot...but that's a bit too restrictive....and the name is also too restrictive....
I need a sure way to know if a device is a timing card.
Thank you,
Seb
10-30-2009 01:27 PM
Hi, Seb.
The reason that you are unable to detect the PXI-6682 is because the NI-SYNC driver has not been installed. VISA will not interface with the 6682. You can find the NI-SYNC driver here. Select the appropriate NI-SYNC driver that is compatible with your operating system.
Let me know if you need any more information. I hope you're having a great day!
10-30-2009 01:44 PM
This is not exactly what I meant...
My PXI-6682 shows up in MAX...
The problem is that it doesn't show up in the lkist of devices when I call:
DAQmxGetSysDevNames
So I have to use VISA to get the device in run time...now the problem is that in Daqmx I can use:
DAQmxGetDevProductCategory
to know if the device I'm reading is a timing card....
But in Visa...is there an equivalent?
For now my only USEFUL data that I can find on VISA is the card's chassis slot...which is not really what I want.
I mean what I could do is:
DAQmxGetSysDevNames
then pin point if a device shows up in slot 2 (star)
'if it doesn't I call VISA
if a ::INSTR shows up in slot 2 I ASSUME it's a timing card...
That is an horrible solution, any ways to do better?
Thank you,
Seb
10-30-2009 02:44 PM
Sebastien,
To answer your question, VISA does not have a function to retrieve the device's product category. The DAQmx notion of product category does not apply to VISA. All PCI/PXI devices are treated the same by VISA. Once you bind VISA as a driver to a PCI/PXI device, all you can do is peek/poke the on-board registers. Unless you know how the hardware is designed, it's very unlikely that you can actually use VISA to do anything useful with the device. That's why Sara recommended you to use the NI-Sync driver. It provides an API for you to interact with the device. NI-Sync is not my expertise, but just looking at its API, I don't see a way to programmatically get all the available resources. If anybody else knows a way, feel free to chime in.