views:

202

answers:

2

ni-daqmx has a "simulated driver" feature. In the case of an AI, the returned signal is a noisy sine. Is it possible somehow to change this behavior in order to have anytype of signal?

if not, is there some alternatives to simulate hardware?

+2  A: 

I do not think it is possible to control the signal returned on a simulated device. A DAQmx simulated device is intended to allow you to check your data acquisition code works without having to have the actual hardware present as part of the development process.

If you need to provide a simulation of hardware with real data then using LabVIEW you could provide a vi that calculates (or load in) the required signal and passes this out to the main program. I have used this approach to provide a repeatable test for debugging by running the actual hardware and logging real data to a file then re-running the test with real data.

Swinders
I like this approach. Do you know any document or tutorial that could help me. I am new to the DAQmx world. thanks
luc
I do not know of any tutorials demonstrating this but I may be able to come up with an example of how I have done this in LabVIEW
Swinders
A: 

The simulated devices output a sine wave with a frequency proportional to the sample rate specified. I believe the amplitude is also set to the range of the input voltage specified in the task.

If you want to input an arbitrary signal and make sure it is receive correctly through DaqMx then you could always use the Analog Out function of your hardware to generate a signal, then hook that output to the input you wish to test.

This has the added benefit of getting to test the DaqMx interface rather than just testing the data processing in your application.

Fuzz