3.2.3 Signal Conditioning using OPA as ADC Internal Channel
The signal condition circuit, an integral part of the sensor node, comprises OPA as its building block. The analog sensor may have a dynamic output range in millivolts or milliamperes. Depending on the operating environment in which the sensor is mounted, the sensor measurement might be affected by noise induced onto the system. Hence, the resultant sensor output signal might be noisy. Therefore, an analog sensor may require a signal conditioning circuit that converts sensor output to the required voltage range or frequency. The signal conditioning circuit, an integral part of a sensor node, comprises OPA as its building block.
The output of the signal conditioning circuit can be converted to digital form using ADCC for further processing in real-time monitoring and control applications. The PIC16F17146 family of microcontrollers has an inbuilt OPA with an internal resistor ladder and the option to connect external resistors for gain setting. This OPA has a provision to connect its output internally to the ADCC input channel. For more details on using combinations of analog peripherals in sensing and measurement applications, refer to the Getting Started with Integrated Analog Peripherals of PIC® Microcontroller technical brief.
Figure 3-6 illustrates how to interface a passive infrared (PIR) sensor using a PIC microcontroller's ADCC, OPA, DAC, FVR, and Timer Peripherals.
- PIR sensor low output signal is fed to OPA
- OPA with Internal resistor ladder is used to provide gain (x16)
- OPA output is connected internally to the ADCC
- ADCC is used in Low-Pass Filter mode along with threshold comparison
- DAC is used to compensate the offset voltage of the PIR sensor
The application can detect movement even when the CPU is in Sleep mode. When the OPA output goes above the configured ADCC threshold, an interrupt is generated. It wakes the CPU up and indicates the movement detected by blinking the LED.
3.1.1 AC Voltage Measurement Using Differential ADC and 3.1.2 Differential Output Sensor Interface application use cases illustrate the usage of OPA for filtering and amplification of analog signals along with ADC in sensing and measurement applications.