Multifunction DAQ

cancel
Showing results for 
Search instead for 
Did you mean: 

DAQmxBaseWriteAnalogF64 bug

I am trying the example ao/voltUpdate.c that ships with NI-DAQmx Base reveals what I consider a bug. The example sets min and max in the call to DAQmxBaseCreateAOVoltageChan() to 0 and 5, respectively. It then uses DAQmxBaseWriteAnalogF64() to set the output voltage to 3.25V. On my PCI-6014 this results in an output of about -8V!

Using -10 and 10 for min and max gives the correct output.

I can understand if the board doesn't support min and max with these settings. But DAQmx Base doesn't issue an error, it creates bad output.

At the very least, the documentation for DAQmxBaseCreateAOVoltageChan() should state that this is a problem. Since the documentation for min and max says, "The minimum value, in volts, that you expect to generate", this seems to imply that I can put anything there and DAQmx Base will select appropriate settings.

I have submitted this to NI support. I am posting this in response to the automated reply that says, "Next time, consider posting your question to the Developer Exchange discussion forums for immediate access to engineers and developers around the world. NI Applications Engineers monitor the forums to ensure all support questions are answered." So, is a posting here the best way to submit bug reports?

Platform: Macintosh OS X 10.3.7 using Xcode 1.5
DAQ board: PCI-6014
NI-DAQmx Base version: 1.4.0f2
John Weeks

WaveMetrics, Inc.
Phone (503) 620-3001
Fax (503) 620-6754
www.wavemetrics.com
0 Kudos
Message 1 of 3
(2,761 Views)
Just got a nice answer from NI Engineer Alan Armstead:

Thank you for contacting National Instruments. I have also duplicated the
issue that you described with a PCI-6014 on a Windows machine. I will file
a CAR (Corrective Action Request) about this immediately. You are
absolutely correct that this is certainly not how the driver should act in
this situation. There should be an error message, and then NOT update the
voltage (at least not to the wrong value!!). I will assign this a high
priority as this could potentially lead to some very bad situations. Thank
you very much for pointing this out. In the mean time I suggest (as you
have probably already done) to implement some software checks to make sure
the min and max values get set to the appropriate values. Thanks again for
pointing this out. Have a wonderful day!

Pretty good response time- less than two hours!
John Weeks

WaveMetrics, Inc.
Phone (503) 620-3001
Fax (503) 620-6754
www.wavemetrics.com
0 Kudos
Message 2 of 3
(2,755 Views)
This issue should be fixe in NI-DAQmx Base 1.5
0 Kudos
Message 3 of 3
(2,717 Views)