CapSense Slider – CSD on Radon (Capacitive Sensing – Sigma-Delta Modulator) Algorithm

CapSense Slider – CSDR (Capacitive Sensing – Sigma-Delta Modulator) Algorithm (Support CY8C24x94 Family)

 

Functional Description

Driver Properties

Interface Schematic

 

Functional Description

This input driver provides a finger position value for a capacitive sensor slider control.  Capacitive sensors can be used as non-contact switches, able to detect the presence of a finger through glass, plastic or other non-metallic materials using a simple PCB trace as the sensor.

 

A slider sensor array can be used where gradual control adjustments are required. Examples include a lighting dimmer control, volume control, or speed control. The sensors are mechanically adjacent to one another on the circuit board.  Actuation of one sensor results in partial actuation of adjacent sensors. The finger position along the slider is found by computing the centroid location from the set of activated sensors.  The practical lower limit for sliders is five elements; the upper limit in PSoC Express is 15 sensors.

 

This driver must be associated with a CapSense CSDR Property driver.  Multiple CSDR sensor drivers (button, slider, etc.) can be used in one project and will all associate with a single CSDR Property driver.

 

The operation of the capacitive sensor is dependent on the hardware implementation and the configured driver properties.  The CSDR Property and CSDR Slider driver property values must be tuned for the specific hardware implementation to achieve optimal performance.

 

This driver has an associated Tuner that allows the configuration properties to be dynamically configured or “tuned” from PSoC Express while your project is running on target hardware. 

 

Refer to Cypress Application Note AN2292 for capacitive sensor circuit layout guidelines.   Additional information on CapSense is available at www.cypress.com/CapSense.

 

Hardware Interface: The capacitive sensors are connected to analog input pins routed to an internal PSoC Analog MUX bus.  This driver will use one input pin for each slider element when the Diplexing property is disabled.  If Diplexing is enabled, the driver will use N pins to support 2N slider elements.

 

Software Interface: The finger position is provided as an 8-bit unsigned value in the range from 0 to the specified Slider Resolution value.  A value of 0 indicates that no finger is present or an error condition has been detected.

 

Go Back to Top of the Page

 

Driver Properties

User Configurable Properties:

 

Number of Sensor Pins: This is the number of PSoC sensor pins that will be connected to the slider sensor array elements.  The number of pins will be the same as the number of sensors when Diplexing is disabled.  If diplexing is enabled, N pins will support 2N sensor elements. The number of sensor pins can be from 5 to 15.  The maximum number of sensors may be limited by the RAM or pin count resources of the selected PSoC device.

 

SliderResolution:  Specifies the resolution of the slider location value.  The calculated finger location along the centroid is often fractional.  In order to more accurately report the location of the finger, the centroid value is scaled to provide the specified resolution, for example a range of 0 to 100 for 12 sensors.

 

Diplexing:  When enabled, each PSoC sensor pin is connected to two physical sensors in the slider array. This allows increased resolution for a given number of PSoC pins. 

The PSoC pins must be carefully mapped to the physical sensors to support diplexed operation.  The sensors in the first (or numerically lower) half of the sensors are mapped sequentially to the PSoC sensor pins.  The sensor pin routing for the second (upper) half of the sensors is established so that adjacent sensor actuation in one half does not result in adjacent sensor actuation in the other half. 

The pin assignments for the second half of the sensor elements must be done by using an indexing offset of three.  The figure below shows eight PSoC sensor inputs (0 – 7) associated with 16 sensor elements:

 

 

For example the PSoC pin (#1) associated with the second sensor element is also connected to the 12th element.

Scan Speed:  Controls how fast the sensors are scanned. Slower scanning speeds result in slower sensor response.  The lowest Scanning Speed that meets the design requirements should be selected.  A slower scan speed offers a number of advantages: improved SNR, increased immunity to power supply and temperature changes, and lower system interrupt service overhead.

Scanning Resolution: Sets the scanning resolution in bits. The sensors can be scanned with resolutions ranging 8, 10 or 12 bits. The maximum raw count for scanning resolution for N bits is 2N-1.

Increasing the resolution improves sensitivity and the SNR of touch detection.

Values:

            8

            10

            12

         Default Value: 12

 

Ref Value:  Sets the comparator reference value for a sensor.  If the design has sensors with substantial capacitance differences (for example sensors with different sizes or shapes), the raw count values can be balanced by selecting a higher reference level for the sensors with larger capacitance.  An increased reference level will decrease sensor sensitivity.

 

0 corresponds to the minimum value (1/4 Vdd).

8 corresponds to the maximum value (3/4Vdd).

 

Expose Tuning Values:  This property causes the internal driver Difference value to be included in the exposed project Register Map.  This value is the current difference between the Baseline and RawCount values.  The Baseline value is a historically weighted count value tracking the inherent parasitic capacitance of the sensor with no finger present.  The RawCount is the current count value for the sensor.  The difference value is useful for fine-tuning the response of the sensor.  This property must be set to “Yes” to use the driver Tuner functionality.

 

Go Back to Top of the Page

 

Interface Schematic

 

 

Go Back to Top of the Page