Performance versus power in capacitive touch sensing designs - Embedded.com

Performance versus power in capacitive touch sensing designs

Capacitive sensing has replaced mechanical buttons in a wide range of consumer appliances, including washing machines, music players, and mobile phones, to name a few.

This has been possible largely because capacitive sensors are durable, more reliable, and provide better aesthetics through their simple yet elegant user interface that supports multiple functionalities at literally the tip of a finger.

The quality of a capacitive sensing implementation, however, depends upon its response time and power consumption. Highly responsive systems give a real-time feel while reducing power consumption improves operating life in the case of battery-based devices.

In this article, we discuss some standard capacitive sensing elements and applications with a focus on balancing power consumption and response time for embedded engineers developing capacitive sensing interfaces.

Capacitive sensing: basic principles
Capacitive sensing can sense the movement of any conductor. The human body being a conductor, capacitive sensing can be used to detect the presence and absence of a finger or trace the movement of a finger. This gives an opportunity for designers to have human finger driven GUI (Graphical User Interface) menus, adding aesthetic value to their designs.

The change in capacitance due to the presence of a finger, or any conducting material for that matter, is measured using a capacitive sensor. A capacitance sensor would typically be a metal pad separated from the ground as shown in Figure 1 below . The Electric Field lines follow the path of least resistance which start from the sensor and end in the ground plane.

Figure 1: Electric Field Distribution in presence and absence of a finger.
As shown in Figure 2 below , the introduction of a finger would form a capacitor, the finger being one plate, the metal pad being the other and air serving as the dielectric. It can be termed as finger capacitance CF. Before the introduction of the finger there would be some parasitic capacitance CP between the metal pad and ground. The finger capacitance adds in parallel to CP and net capacitance becomes CP + CF.

Figure 2. Capacitance Model
Capacitive Sensing: Basic methods
There are many capacitive sensing controllers available on the market today using various sensing algorithms such as the relaxation oscillator method, methods based on switched capacitor(SC) front-ends, mutual capacitance sensing, phase delay and amplitude measurement, etc.

One important aspect for overcoming noise in capacitive systems is to have a robust sensing method which has low input impedance. The two most prevalent methods are:

1. Relaxation oscillator method (RO method) and its variants – The RO method contracts the oscillator using the capacitance of sensor and the variation in frequency is converted into counts.

2. Switched capacitance front-end (SC method) – The SC method converts the capacitance to counts by charging or discharging a reference capacitor with the sensor capacitance at a high frequency. Switched capacitor methods have a lower input impedance than relaxation oscillator methods and so provide better noise immunity.

Balancing power consumption and response time
With advances in technology, more electronic products are becoming battery-operated and power consumption has become a critical factor in design. With this in mind, system designer need to adjust system parameters so that system functionality is provided with the minimum active current.

When doing a complete system design for an application, care should be taken to estimate the power consumption of the system as a whole instead of the controller alone. For capacitive sensing, the total power consumption of the controller and the external circuitry should be considered.

External circuit: The aim should be to avoid any voltage difference between resistors. This is controller independent and depends mainly on the circuit design. A typical circuit using a capacitive sensor is shown in Figure 3 below.


Figure 3. Typical schematic of capacitive sensing circuit
The figure shows a CapSense device with three capacitive sensing buttons and three indicator LEDs. For example, In sleep mode, P0[5]-P0[7] and P1[0],P1[1] in the figure above are driven to high impedance state and P0[0]-P0[2], which are connected to capacitive sensing pads, are set to CMOS drive with a logical 0 driven to the port pins.

Controller power consumption: This mainly depends upon the efficiency of the controller. For a System-on-Chip (SoC), this depends on the number of resources active at that particular instance. Sleep mode is an effective method for extending battery life in capacitive sensing applications.

Important system parameters that affect battery life are the supply voltage, CPU speed, and the active and sleep time of the controller. This section discusses how to minimize active current and incorporate sleep mode into button sensing applications.

Power consumption is reduced by turning off unused resources or putting them to sleep. Resources can be the controller itself or external peripherals and circuit elements.

In case of an SoC, individual analog and global resources can also be put to sleep. Sleep current values are typically much less compared to active current values. Thus, when a system is not being used, it can be put into sleep for idle time so that the average current consumption is reduced.

Fig 4: Current Consumption vs Time
I average = (Iactive x Tactive + Isleep x Tsleep) / (Tactive + Tsleep )

The above equation shows how the Iaverage can be minimized to these requirements. The appropriate way to do that is minimize Iactive , Tactive and Isleep and maximize Tsleep . However, this will affect system response time.

Response Time
The response time of a system is defined as the time after which a valid output is given by the system after an input has been provided.

The controller goes into sleep mode and turns on the sleep timer. At periodic intervals, the controller then wakes up and scans the input for any activity. Suppose an input occurs while the controller is in sleep mode.

The controller can only sense the input only after it wakes up. Thus, the worst case response time of the system becomes the sleep timer interval. The graph in Figure 5 below shows a typical response time vs. current consumption curve. Developers can choose a response time and current consumption depending on the specific application requirements.

Figure 5: Average Current vs Scan Rate
As per above the discussion, if the sleep timer interval is increased, the response time is degraded. However, the average current consumption also decreases according to the equation above.

So when designing an application, one should arrive at a tradeoff between power consumption and response time. Here we discuss an example of a 3-button capacitive sensing system that illustrates how to balance power consumption and response time.

Consider a Bluetooth headset having three capacitive sensing buttons for answer/disconnect, Volume Up and Volume down For a person using such a Bluetooth handset, assume the following usage profile in Table 1 below:


Table 1. Usage Profile for a Bluetooth handset (To view larger image, click here )
In this way, power consumption for the design may be generated to choose the best values that fit the design, depending on the specifications of the controller being used.

Techniques for reduced power capacitive sensing
As discussed earlier, for reducing power consumption in capacitive sensing solutions, a sleep timer can be implemented to make the controller sleep and wake up periodically and scan the capacitive sensor I/Os to check for user activity. Optimal settings should be selected so that users do not have slow response and therefore a poor use experience.

Once any activity is detected, it is necessary to set up a ‘time without activity’ check while in normal operation that would wait some time interval before going to sleep mode. This would make sure that the normal operation routine is not constantly going to sleep after a calculation.

The advantage of this would be that the system could likely have a longer sleep duration during idle mode with minimal effect on the user experience. Here are some techniques specific to reducing power consumption in capacitive sensing systems.

Gang Sensing: As the number of capacitive sensors increases, for a constant scan rate, power consumption increases. In a similar way, for the same number of sensors, if the scanning rate is increased then power consumption increases.

Decreasing the number of sensors basically means reducing the number of sensors available for scan. It is possible to combine all the sensors and scan them only once.

This is called Gang Capacitive Sensing. The gang is considered as a single sensor and the capacitive sensing algorithm scans only one sensor. Once activity is detected and confirmed, the sensors are disconnected and scanned individually.

CPU utilization during scanning: While scanning a sensor, the CPU keeps waiting for the maximum time to let the hardware finish the job of scanning. This idle CPU time may be utilized to do other necessary system computations.

For example, if a software filter is applied to sensor data, while scanning the second sensor, the filter computation of the first sensor can be completed in parallel. This reduces the CPU active time, in turn reducing power consumption.

Slowing the CPU during scanning: While the CPU waits for scanning to complete, the CPU frequency is reduced to its lowest speed to reduce the active current. However, there is a problem when an interrupt is posted and serviced, since the CPU time for this will increase. This can be countered by increasing the CPU frequency in the Interrupt Service Routine.

Use partial sensing: If ganging sensors is not possible, scan the minimum number sensors to check for any activity. For instance, in a track pad or slider design, one obviously would not need to check every sensor to look for activity. A subset could be checked to register any activity.

Use proximity sensing: Instead of scanning all the sensors, every time the controller wakes up, only a proximity sensor is scanned. In the case of any activity, the other sensors can be scanned.

Capacitive sensors: power consumption issues
Capacitive sensors such as buttons, sliders, and proximity sensors can be implemented easily in an embedded design. The type of the sensor varies depending on their use and the applications where they fit in. Selecting the right sensors for an application gives a better feel to the user. However, there are some power consideration issues that need to be considered.

Buttons. Capacitive sensing buttons can be used to implement the ON/OFF switch. Some examples are the user interfaces of TVs, monitors, audio systems, photo frames, home security systems, washing machines, MP3 players, refrigerators, remote controls, and microwave ovens. Matrix pattern buttons are used in applications such as calculator keypad, QWERTY keyboards, etc.

Sliders. Sliders are used for controls requiring gradual adjustments. Examples include lighting control (dimmer), volume control, graphic equalization, and speed control.

In a linear slider, the segments are placed in a straight line pattern. In radial Slider, the sensors are arranged in a circular fashion.

The power consumption for buttons and sliders will depend on the parasitic capacitance of the sensor. The greater the parasitic capacitance, the longer the scan time and to achieve the desired SNR.

Increased scan time will contribute to increased active time and hence leads to increased average current consumption. Proper layout guidelines should be followed with utmost care to keep parasitic capacitance at a minimum.

Proximity sensors. The purpose of a proximity sensor is to detect the presence of an approaching object rather than determine its exact position.

Examples include the glowing of backlight LEDs of buttons when user brings a hand near a car audio system, bringing up a menu on the screen, and lighting LEDs to show where the capacitive sensors are located in the case of a digital frame.

In such a case, the sensor parasitic capacitance is very high and sensitivity is high as well. Both contribute to increased scan time and hence increased power consumption.

In the case of a proximity sensor, developers should note that the sleep time interval cannot more as the other sensors (buttons and/or slider) should become active within 200 ms to have a real time experience for the user.

Pushkar Nandkar is working as an Applications engineer in Cypress Semiconductors . He graduated from College of Engineering Pune. His areas of interest include Capacitive sensing solutions and embedded design.
Bala Satish Gurlinka is working as an Applications engineer in Cypress Semiconductors. He graduated from NIT Allahabad. His areas of interest include analog circuit design and HID/wireless communications.

Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.