04-19-2021 10:14 AM
Hi,
Could anyone recommend how to connect a 10k linear potentiometer to a NI 9215 with the DAQ Express software and have it read the resistance of the potentiometer throughout its full range fairly accurately. I currently have 5V running across the connection with the current parameter at 1mA. I'm try to use the linear pot as a rough measure of distance. The output signal does not read out linearly as the resistance goes from 0 to 10K. As expected it reads fairly accurately around 5k, then it spikes up or down from there.
Thx,
Mark
04-29-2021 02:54 AM - edited 04-29-2021 03:07 AM
Some points come into my mind:
potentiometer linearity:
For a common pot in the 1% to >5% range depending on type, so a calibration would make sense. If not build for angular or length sensing, the end points can be very nonlinear .. one idea would be to use a 10 turn precision potentiometer, even if you only use a fraction of it, the linearity is usually speced (and better) and I assume the resolution is limited by mechanics anyway 😉 (hysteresis, friction)
input impedance of the 9215:
if you habe the BNC version the input impedance is 200k Ohm, that influences your measurement.
Spikes:
Dust on pot and/or wiper lift-off (speed and dust) ? Or spikes on the 5V ?
Depending on the dynamics of your measurement, filter can help, I would try a median filter against spikes and a mean filter over at least one line frequency periode if possible.
So an individual calibration would be recommended, depending on the result, make a fit with an apropriate polynom or a lookup table with interpolation.
I have never seen a non broken/abused/burned/dirty potentiometer with a non monotone output. Keep in mind that potentiometer are build for quite rare use. Industrial potentiometer sensors have a price for a reason 😄
Finally, since you measure a voltage ratio, it's alway a good idea to measure both voltages ; ) so if you have a spare channel, measure pot supply and wiper output.