05-12-2023 09:54 AM
I know that MAX allows the creation of simulated DAQmx devices.
And I know that they have some limitations, listed here.
I use some DAQmx analog input devices in a cDAQ chassis and I need to create their "digital twins".
With this term I mean a "fully programmable simulated device" (i.e., a simulated device that I can control completely, deciding which waveform should be returned).
Since I need to control which signal is returned, I know that I must write this "digital twin" by myself.
I need to know if there is some library/driver from NI that can be used for this purpose.
Maybe in Python?
05-12-2023 12:13 PM
@vix wrote:With this term I mean a "fully programmable simulated device" (i.e., a simulated device that I can control completely, deciding which waveform should be returned).
I am not aware of the existence of this feature. There is no API in DAQmx driver for us to specify the waveform for the input task in the first place because we won't know what data will be returned. If you want to overwrite the default behavior, you need to write your own code to replace the DAQmx Read VI.
07-10-2023 01:09 AM
Hi @ZYOng
thank yoy for your answer, and sorry for my late replay.
The idea that I hav ein my mind is that the for the "digital twin" of a cDAQ AI card you must specify a .tdms file that either:
The digital twin would tream back the given data.
This is a powerful way to handle the need IMHO.
For the end-to-end test of my application I really need to leave the executable as it is (and so I cannot replace the DAQmx Read VI), and use simulated hardware instead of real hardware.
I hope that there could be a way
07-10-2023 02:29 PM
@vix wrote:
Hi @ZYOng
thank yoy for your answer, and sorry for my late replay.
The idea that I hav ein my mind is that the for the "digital twin" of a cDAQ AI card you must specify a .tdms file that either:
- you had acquired in advance from a real device
- you had generated in some way
The digital twin would tream back the given data.
This is a powerful way to handle the need IMHO.
For the end-to-end test of my application I really need to leave the executable as it is (and so I cannot replace the DAQmx Read VI), and use simulated hardware instead of real hardware.
I hope that there could be a way
Many posts on this forum resonate your requirement, but had to limit to specific application by creating a HAL. It is substantial work for NI to develop an pseudo-emulated device (device twin) for every DAQ and many of the customers may not be interested to pay a premium for that feature.
07-11-2023 03:42 AM
The additional API to allow this for analog, digital and counter IO would be likely similar in complexity than the already existing API. With a substantially less complex implementation it would have all kinds of limitations that make it barely better than what the current simulated devices offer. The effort would be enormous and nobody is willing to pay extra bucks for it and 1000 bucks a license would never pay for the effort.
And the complexity would make most anyhow not use it. 95% of the DAQmx users use about 5% of what DAQmx can do. Such a feature would only make this ratio even more extreme.
04-25-2024 02:39 AM
How To Implement Digital Twin in LabVIEW any toolkit we have to use?