Multifunction DAQ

cancel
Showing results for 
Search instead for 
Did you mean: 

How to set AI gain on DAQpad-6070E?

This is a really simple question, but after pouring through the documentation for an hour I still can't find a definitive answer.
 
I'm using LabWindows/CVI 7.1 and Traditional NI-DAQ to control a DAQpad-6070E.
 
I would like to set and verify the gain settings for the analog input channels.  The documentation talks about setting the gains and things to consider, but not how to actually do it.  The Measurement & Automation application can set the polarity, but I don't see anything regarding gain.
 
There is a function called nidaqAIConfigChannelLimits. Does this set the actual gains or does it do something else?
 
Any help is appreciated,
 
Thanks,
 
Scott T.
0 Kudos
Message 1 of 4
(3,180 Views)
Hi Scott,
 
The function that you are looking for is AI_Setup. More information about this function can be found in the Traditional NI-DAQ Function Reference Help.
 
Regards,
Hal L.
0 Kudos
Message 2 of 4
(3,161 Views)

Thanks Hal,

I tried AI_Setup as well as AI_Configure.  Both compiled and ran OK, but still didn't change the gain of the DAQpad-6070E.  I had used NI's ai_samp example as a guideline which uses easyio.h.  Any known conflicts with easyio.h and dataacq.h functions?  I tried AI_Setup at initial startup and before and after the nidaqAICreateTask function, but no difference. Are there any function order requirements?

I was able use Measurement and Instrument Explorer to change from +/-10 volts to a unipolar 0 to 10 volts. This improved the resolution from 5 mV to 2.5 mV which at least makes our system usable. I'd still like to figure out the gain problem.

After pouring through all the documentation, I couldn't find an exact definition of what the function "nidaqAIConfigChannelLimits" does. Is it possible it's doing an actual gain setting and therefore overriding any previously set gains? However, I did try AI_Setup before and after with no luck.

Any thoughts or ideas are welcome.

Scott T.

 

0 Kudos
Message 3 of 4
(3,134 Views)

Scott T,

On any of our boards, you can change the AI gain by changing the max and min values of the nidaqAIConfigChannelLimits.  Here's what happens when you change those limits: the driver will figure out the appropriate gain then PGIA (programmable gain instrumentation amplifier) on the 6070E will apply that particular gain in hardware.  The data gets digitized but then the driver scales back the data to what it originally should have been.

For example, if you are trying to read 0.05V, the 6070E will apply the max gain available to it (x10) and in hardware, it will become 0.5V but the driver scales it back to 0.05V.  Trust me!  🙂

Hany A.

0 Kudos
Message 4 of 4
(3,120 Views)