I have been trying to understand on how to use the nidaqmxconfig ---export but I really don't get it, what alias should be used?
And what actual procedure shoud I follow?
If you could please detail this on my example I would be grateful.
I have installed a virtual windows machine to try NI Labview there, and I can acquire a first burst of samples (and they look gorgeous) but then the communication with the device drops out and goes into time out every time. The Device can do a self test and seems to work, excpet the DAQ assitant doesn't wnat to acquire anymore
The alias name is what can be passed instead of a device path to open communication to a DAQmx device. This has the advantage that you can reuse existing code across different systems with modules installed in different slots as long as they have the same device alias name. Here is a quick roundup of the steps involved to change the device alias name on Linux. You might have to run these commands with root privileges.
1) In a terminal, execute nidaqmxconfig --export ~/daqmx_export.txt to export the current config to a text file in the current user's home directory.
2) Using a text editor, edit the entries in the first column to set the alias names, i.e. change
PXI1Slot4 PXIe 0x12345678 0x87654321 PXIe-XXXX to My_PXIe_XXXX PXIe 0x12345678 0x87654321 PXIe-XXXX to rename your device alias from "PXI1Slot4" to "My_PXIe_XXXX".
3) Read the configuration data in with nidaqmxconfig --import ~/daqmx_export.txt --replace
Regarding your second question with the device dropping out:
When using a VM with hardware passthrough, numerous problems might occur depending on the way the virtualization software realizes this. I strongly recommend to proceed troubleshooting on the main system to avoid additional potential points of failure. Nevertheless, one possible explanation would be to miss closing the device handle at the end of your code. Remember to also handle errors to gracefully close open device handles.
Please let us know if that worked for you. Good luck!
Ok my config file doesn't have entries similar to the one you have written in the example.
Check out my daqmx_export attached.
Now I'm confused: Where did you install the DAQmx drivers from? Did you download the repo .deb from NI.com, apt update and then apt install ni-daqmx?
If not, please try removing any existing ni-daqmx software with apt autoremove ni-daqmx and retry with the official NI deb repo from Download and Install NI Driver Software on Linux Desktop .
It seems that the kernel module for your USB-DAQ has not been loaded.
I actually installed the same way but now I did it again follwing the exact procedure you mention. Here are the new logs.
daqmx export stays the same.
NI-DAQmx 20.0 and 20.1 do not support USB M or X Series devices on Linux. The only USB DAQ devices that are presently supported by NI-DAQmx on Linux are CompactDAQ. The readme could probably be improved here; some of the language in it is a holdover from when no USB DAQ devices were supported.