|
Circuit #1 : Analog Input Buffer
Some sensors just can’t drive a lot of current, and trying to measure the sensor’s output voltage using an A/D converter gives distorted readings because the A/D converter draws current from the sensor. For those who understand what output resistance is, the AVR’s A/D converters recommend that sensors have an output resistance of no more than . The circuit below can be used to “buffer” the sensor such that very little current is drawn from it. An optional RC low-pass filter (see discussion below) can be used to smooth out noisy sensor readings.
The TLV2371 is a rail-to-rail op-amp (operational amplifier) that allows the output going to the board to range from 0V to 5V. More traditional op-amps such as the LM741 should not be used because they do not allow the output to go all the way down to 0V or all the way up to 5V.
The RC (resistor-capacitor) filter formed by R1 and C1 is an (optional) simple way to smooth out sensor noise. The cutoff frequency of this filter is:

For example, with and the cutoff frequency is 15.9Hz. Slowly-varying sensors such as temperature sensors and humidity sensors are good candidates for filtering at this low frequency. Sensors such as accelerometers which vary quickly should be filtered at a much higher frequency -- consult your sensor’s data sheet for guidance. The higher the filter’s cutoff frequency, however, the more noise will pass through.
|