07-28-2025 03:20 PM
Hey all, not sure if I'm posting this on the right board. pretty new here so feel free to direct me to where this would be more appropriate.
I develop programs that rely on the NI Driver stack to communicate with third-party hardware such as Keysight, Fluke, etc. The drivers are specifically NI-488.2 and NI Visa. The hardware is costly and rarely available for development. I'd like to be able to create scripts that would receive the GPIB commands from my programs and somehow respond with appropriate responses to virtually simulate the physical hardware.
Is it possible to write a program that interacts with either driver in C#, LabView or (ideally) Python to receive commands from the drivers and respond as if they were devices on the GPIB bus? My hope is to be able to develop something that could show up in NI Max and act as a bridge between the drivers and my scripts that would define the logic for the responses.
Hopefully what I am asking is clear. I keep looking online for it and am shocked there isn't an obvious answer as I'm sure many other people have had this problem at some point
07-29-2025 02:08 AM
Yes, this is possible, but not simple, as you need the simulator to know the list of commands, validate, and respond appropriately as per the instrument specifications.
You can create a TCP application that simulates the instrument behavior, then add a networked VISA device to show up in NI MAX.
Luckily, NI did this effort for their instrumentation, including simulation capability within their drivers. Now, since the other manufacturers did not create an instrument simulator, you're forced to develop your own despite paying them for the hardware.
07-29-2025 03:15 AM
Once you have the device simulated in MAX , you can use it pretty much just like a physical device. Go to the Example Finder in LabVIEW (Help>Find Examples) and then browse to the DAQmx examples for different task types. I usually recommend using the API to programmatically create tasks rather than use tasks in MAX or the DAQ Assistant.
07-29-2025 03:31 AM