0
\$\begingroup\$

I have a sensor connected to a simple unity gain buffer with its output connected to an Arduino analog pin.

I'm trying to work out if there's a way I can stop the Arduino reading jumping around when there is no real voltage being fed into the unity gain buffer circuit, such as when the sensor is not connected.

Kinda the way a pull-down/up resistor works. Is this sort of thing possible?

\$\endgroup\$
4
\$\begingroup\$

Adding a pullup or pulldown between the Arduino and the buffer won't do you any good (assuming the buffer is actually doing its job).

I assume your buffer has a CMOS input stage. That means its input resistance is so high that miniscule currents, especially when exacerbated by dirty power, cause voltage swings and oscillations. This is where to put your pullup or pulldown, on the buffer's input. Even a huge resistor (hundreds of K or even megs) should work.

If the signal you're measuring is so weak that no pullup or pulldown can be used (say, the output from a load cell), you'll need to find a more stable amplifier, possibly one with a bipolar input stage.

If you're interested, read up on op amps and input resistance.

\$\endgroup\$
0
\$\begingroup\$

Fluctuating voltage on the analog input by itself is not a problem**. If you know that the sensor isn't connected, you can ignore the fluctuating value in the software.

** As long as absolute maximum values aren't exceeded, of course.

The O.P. doesn't say what type or model is the sensor (?). Nevertheless, it does say that the sensor output is voltage**. In this case, a pull-down resistor in front of the unity gain buffer would work without affecting the signal.

** I'll make the assumption that the sensor has voltage output and low output impedance. This rules out resistance sensors such as thermistors.

A pull-up resistor might be a more useful option. It may allow you to detect if the sensor is present or not. If the sensor is not present, the pull-up resistor would drive the analog line to a high voltage, which would correspond to a condition which you know can not occur. For example, suppose that the sensor is sensing water temperature. In the absence of the sensor, the pull-up resistor would generate a voltage corresponding to 300°C. You know that that can not occur, therefore you can infer that the sensor is not connected.

To test the effects of the pull-up or -down, measure the signal from your sensor first with the pull- resistor. Then remove the resistor. The signal shouldn't change.

\$\endgroup\$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.