How to address EMI/RFI interference in capacitive touch sensing
Rejecting unwanted noise is essential for accurate measurements from the sensors.
While doing that, effectively managing electromagnetic interference (EMI) through shielding, grounding, and filtering is also important, especially in high-interference environments. Techniques such as AC shielding, noise filtering, and thoughtful sensor design greatly improve signal quality, leading to reliable and long-lasting sensor operation.
Noise can interfere with electric signals and cause equipment malfunctions. EMI can be long—or short-range and travel through air, water, or solid materials, creating noise that affects sensing data and wastes time and resources. There are two main types of noise: conductive noise and radiative noise. The other is radiation noise, as shown in Figure 1. Conductive noise is transmitted through wires and printed circuits, while radiative noise propagates through the air.
To avoid EMI in sensor measurements, keep the cable length between a sensor and its signal amplifier as short as possible, as long cables act as antennae, picking up electrical and magnetic interference. Use twisted cable pairs to reduce induction wires, which helps prevent signal noise. Add shielding around cables by enclosing the insulated signal cables in a conductive layer.
Figure 1: Conductive and radiative noise transmitted in an electric circuit (Source)
Figure 2: An electronic circuit is covered with a metal shield to block incoming noise and manages the noise by routing it to the ground (Source)
Shielding
Shielding is essential for sensors to ensure accurate, reliable, and consistent performance in various environments. It protects against EMI, minimizes environmental and power supply noise, prevents ground loops and crosstalk, and helps comply with regulatory standards. By providing a noise-free operational environment, shielding enables sensors to function optimally, delivering precise measurements and extending their operational lifespan.
A properly shielded enclosure effectively prevents external interference. However, openings for adjustments, connectors, or ventilation can compromise shielding. The longest dimension of an opening determines its susceptibility to EMI leakage, which can be calculated using Equation 1:
Where λ = wavelength of the interference and L = maximum dimension of the opening
Figure 3: Capacitive sensor board with grounded shield (Source)
For example, in the AD7147 capacitive sensor board, the 1.0 mm distance between the Bottom of the Sensor Board and the Controller Board is designed to prevent direct sensor board contact with any conductive material. However, this gap does not effectively prevent EMI coupling from the controller board to the sensors. Placing a grounded metal shield between the capacitive sensor board and the main controller board avoids potential EMI-coupling issues, as shown in Figure 3.
Capacitive touch sensors are often prone to AC from various sources, including EMI from nearby AC power lines (typically at 50 Hz or 60 Hz, depending on the local power grid frequency and its harmonics). Power supply fluctuations and internal circuit noise can also affect the accuracy and reliability of touch detection. In the AD7147, AC shielding is designed for single-electrode capacitance sensors (grounded sensors). It includes an active shield output to minimize noise pickup in the sensor.
Illustration of how AC Shield helps to remove EMI in capacitive sensing
The AD7147 measures the capacitance between its CINx (Capacitance Input) pins and ground. Any stray capacitance to the ground in this signal path can affect the measurement. To eliminate stray capacitance to the ground, the ACSHIELD signal should shield the connection between the sensor and CINx, ensuring no AC flows between them, as shown in Figure 4. This shielding effectively prevents capacitance-to-ground pickup, allowing the AD7147 to be located up to 10 cm from the sensors and even on a separate PCB if adequately shielded.
Figure 4: AC Shield in AD7147 (Source)
As used in ADI's AD7147, AC shielding mitigates signal grounding issues in capacitance sensors by alternately switching the sensor between an excitation signal and a capacitance-to-digital converter (CDC), as shown in Figure 5.
Figure 5: Shield eliminates capacitance between the sensors and the shield (Source)
The AC Shield signal helps minimize problems related to parasitic capacitance, remote sensor connections, sensor routing, and the shielding of capacitive sensors. It also eliminates capacitance by eliminating the potential difference between the shield and the sensor/sensor traces.
EMI Filtering
Conducted noise: In capacitive touch systems, conducted noise originates from external power sources like mains or USB connections. Differing ground potentials between the system and the user can introduce AC signals, affecting sensor stability.
Radiated noise occurs due to electromagnetic fields emitted by electronic devices such as cell phones and fluorescent lights. These fields interfere with capacitive touch sensors, especially during scanning phases when the sensor acts as an antenna.
Software filtering in capacitive touch sensors
Filters in capacitive touch systems modify input signals to reduce noise and improve signal quality. The type of filter determines its specific function within the firmware code, affecting how it processes the input signal. Bandwidth defines the range of frequencies the filter passes effectively; narrower bandwidths reduce noise but may introduce delays in response times, whereas wider bandwidths prioritize faster responses but can allow more noise through. Designers balance these factors to optimize filter performance for noise reduction without compromising the system's ability to detect and respond to touch inputs promptly.
For example, three types of filters are commonly used in Microchip’s mTouch sensing solution applications.
1. Slew Rate Limiter
The Slew Rate Limiter (SRL) filter mitigates impulse noise in sensor readings by gradually adjusting the "current reading" variable based on new sensor values. This gradual adjustment reduces the impact of noise on the system, ensuring stable readings. Implementing the SRL filter requires a high-speed scanning technique and periodic updates to the "current reading" variable to allow for rapid response to touch inputs. A flag triggers the decoding function after a set number of samples, optimizing the balance between noise rejection and responsiveness in capacitive touch systems.
Figure 6: Slew rate limiter filter behavior (Source)
2. L-Point Running Averages
The described filtering technique averages the current value x[n]x[n]x[n] with the last L-1 values, either through a Finite Impulse Response (FIR) or Infinite Impulse Response (IIR) approach. Choosing L as a power of 2 allows efficient implementation using bit-shift operations instead of division. The FIR running average introduces a delay in system response due to its averaging nature, making it unsuitable for directly filtering reading signals but suitable for slow-moving baselines. Conversely, the IIR running average may be more responsive but requires careful consideration to avoid destabilizing fast-changing signals. Equation 1 represents the L-Point average in IIR.
Where:
y[n] = output at time ‘n’
x[n] = input at time ‘n’
L= memory of the filter
Figure 7: Comparison of FIR VS. IIR AVERAGES (Source)
The digital low pass filter discussed is a Butterworth filter, offering a more effective alternative to the L-point running average for noise reduction. By choosing suitable values for K and A, this filter can be efficiently implemented using bit-shift operations, making it computationally simple. As A approaches 1, the filter's cutoff frequency decreases, enhancing noise rejection but slightly increasing settling time. The Butterworth filter significantly improves the sensor's signal-to-noise ratio (SNR) compared to the running average, though the latter remains an easy and effective option for baseline filtering. Equation 2 represents the low pass butter worth filter.
Where:
y[n] = the output at time ’n’
x[ = the input at time ’n’
A = the filter’s coefficient (0 <= A < 1)
How to address common challenges in capacitive touch systems
Crosstalk: Occurs when a sensor is unintentionally activated by pressing an adjacent sensor, often due to sensors being placed too close together.
Solutions:
- Increase the distance between sensors.
- Reduce overlay thickness.
- Adjust thresholds or implement a “Most Pressed” algorithm.
Impulse noise: Impulse noise appears as sporadic spikes in readings due to external noise sources, which can destabilize the system.
Solutions:
- Use Slew Rate Limiter (SRL) filters.
- Increase sample rate for faster response.
Unresponsive buttons: Buttons do not respond when touched, often due to high thresholds or excessive noise.
Solutions:
- Lower the thresholds.
- Check for shifts in both directions.
- Increase hardware sensitivity by adjusting sensor area or overlay materials.
Flickering buttons: Buttons toggle states rapidly with a finger present due to sensitivity changes from noise.
Solutions:
- Implement threshold hysteresis.
- Increase debounce values.
- Adjust thresholds or improve hardware design.
Reversed operation: System behavior inverts, such as registering a press as a release, often due to high noise levels.
Solutions:
- Place thresholds on both sides of the baseline.
- Slow down the baseline's speed.
- Increase VDD to resist noise-induced behavior shifts.
Conclusion
To effectively manage Electromagnetic Interference (EMI) in capacitive sensing systems, this article provides a comparison of solutions Analog Devices’ AD7147—the implementation of robust strategies like shielding, grounding, and filtering. Shielding prevents external noise interference, ensuring consistent sensor performance, while grounding helps to manage noise by routing it away from sensitive components. Drawing from Microchip’s AN1334, filtering concepts, including techniques like the Slew Rate Limiter and Low Pass Butterworth filters, enhance signal quality by reducing noise and maintaining an optimal signal-to-noise ratio. These measures are crucial for maintaining the accuracy and reliability of sensors in high-interference environments, thereby improving system performance, and extending the lifespan of the sensors.