Capacitive sensing offers an intuitive and robust interface that increases product reliability by eliminating mechanical parts in many appliances (also called "white goods") and instrumentation. Because of their experience with personal electronic devices, many consumers are used to touch interfaces based on capacitive sensing, and they have come to expect these interfaces to be reliable and operate accurately.
Capacitive technology, however, is affected by environmental noise and other factors which can cause systems to not respond to finger touches or to trigger false touches. Unless developers tune sensors, accuracy and reliability can be severely reduced. By understanding how capacitive sensors work and how they can be designed to self-tune themselves to compensate for noise, developers can build robust systems that make their appliances more reliable, cost-effective, and easier to use.
Capacitive Sensing
To understand the challenges behind designing a robust user interface, it helps to first take a brief look at the technology behind a capacitive measurement system. Figure 1 shows a cross-sectional view of a capacitive sensor board.
Figure 1: Cross-sectional view of a capacitive-sensing board
To sense the presence of a finger, a capacitive sensing system must first know the sensor capacitance in the absence of a finger (see Figure 2a), also known as the parasitic capacitance (Cp). When a finger approaches or touches the sensor (see Figure 2b), the sensor capacitance will change, resulting in another capacitance called the finger capacitance (Cf) in parallel to the Cp. In the presence of a finger, the total sensor capacitance (Cx) is given by Equation 1:
Cx = Cp +_ Cf – Equation 1
Figure 2(a): Sensor capacitance in the absence of finger
Figure 2(b): Sensor capacitance in the presence of finger
To be able to analyze the sensor capacitance using a microcontroller, the sensor capacitance (Cx) needs to be converted into a digital value. Figure 3 shows the block diagram of one of the capacitive sensing preprocessing circuit. (Note: There are several methods for measuring sensor capacitance.)
Figure 3: Pre-processing circuit for capacitance measurement
This system uses a switched capacitor block that emulates the sensor capacitance Cx using a resistance Req, a programmable current source (Idac), an external capacitor (Cmod), and a precision analog comparator. The Idac charges Cmod continuously until the voltage on Cmod crosses Vref and the comparator output is high. The Idac is then disconnected and Cmod discharges through Req until the voltage on Cmod drops below Vref. The comparator output is now low until Cmod charges to Vref again. Cx will be greater in the presence of a finger and the emulated Req will be less according to Equation 2:
Req = 1/FsCx – Equation 2
where Fs is the switching frequency of the switched capacitor block.
Thus, when a finger is present, Cmod discharges faster and the comparator output stays high for a shorter time. This means that a higher capacitance value corresponds to a shorter high time for the comparator. The resulting bit stream as shown in Figure 1 can be fed to a counter for a fixed amount of time. This counter value or “raw counts” provides an indication of the magnitude of Cx.
The fixed amount of time for which the counter counts also determines the number of raw counts and can be referred to as the resolution. When the resolution is increased, the counter counts for a longer period of time and this increases the raw counts. Put another way, resolution is also the highest number of raw counts possible.
Tuning
Figure 4 shows the design flow for a capacitive sensor touch interface. However, capacitive sensors must operate in the real world where variations in components, environmental operating conditions, and noise can impact sensor performance and reliability.
Tuning is a critical process for ensuring that a sensor functions correctly and consistently. This is achieved by identifying and determining optimum values for a set of sensor parameters to maintain a sufficient signal-to-noise ratio (SNR) and finger threshold. In general, a 5:1 SNR is the minimum requirement for a robust sensor design (see Figure 5). To avoid false triggering caused by changes in capacitive due to atmospheric changes, a finger threshold of between 65-80% of the signal strength is recommended to ensure reliable finger detection.
Figure 5: Raw sensor data is comprised of finger response and noise. Finger response, also called signal strength, is the difference in raw counts seen by the sensing system when a finger is placed on the sensor.
While sensor controller manufacturers provide guidelines to aid engineers in the tuning process, achieve the ideal tuning parameters for the system involves an iterative process. For a sensor controller with a capacitive sensing algorithm implemented similar to the one shown in Figure 3, the tuning procedure will follow the steps shown in Figure 6.
Developers can implement tuning parameters either by writing code specific to the operation of the sensors in firmware, through external components, or by configuring the controller. With a firmware approach, developers have flexibility; however, whenever tuning parameters need to be changed, the firmware also needs to be modified and updated.
Alternatively, designers can simplify system firmware development by utilizing a fixed-function/non-programmable capacitive sensor controller. Tuning parameters, in this case, must either be implemented using external components on the board or by sending configuration data over a communication interface such as I2C.
With this approach, whenever tuning parameters need to be changed, either the user interface board need to be reworked or configuration data needs to be updated. Developers need to be aware that tuning can be time-consuming, especially if the PCB or overlay needs to be changed between iterations.
Information is shared by www.ideasroad.com
No comments:
Post a Comment