06-10-2020 08:14 AM
Hi all,
I'm using an NI9262 output to generate a voltage if a condition is satisfied such high temperature or high vibration RMS. The issue is that i get 1V in the output or i should get 10V as i scaled in the CDAQ. Someone has a clue ??
Thanks.
Solved! Go to Solution.
06-10-2020 08:27 AM
No idea. There really isn't enough information in your post.
Where is your VI?
What value did you write to the DAQmx Write function?
06-10-2020 08:41 AM
Here they are
06-10-2020 08:57 AM
By VI, I meant attach a VI, not a picture of your screen. That way I can see what is going on behind the scenes in those express VI's.
The issue you have is being caused by the Express VI's and the dreaded Dynamic Datatype wire. It hides what data is actually flowing on the wire.
The first blue wire coming out of the DAQ assistant contains a scalar (or perhaps an array depending on how the DAQ assistant is configured). That scalar is a double precision.
Then you compare it to 30. A value goes out on a second blue wire. Because the comparison outputs a boolean. A boolean is hidden within that second blue wire. (Or it could be an array of booleans if the first wire was hiding an array of scalars.)
When the second blue wire reaches that DAQ Assistant for output, it expects an analog value, but instead is getting a boolean. So there is a coercion going on behind the scenes of the blue wires and blue Express VI's. A false in the comparison becomes a zero. A true in the comparison becomes a one.
Your comparison should drive a Select structure to output either a 10 or a 0 (assuming you are looking for 10V output like your original questions suggests.)
Ideally, you get rid of the DAQ Assistants, use regular DAQmx functions from the palette to read and write, and thus eliminate all blue wires.
06-10-2020 09:07 AM
Thanks a lot very accurate answer the problem is solved.