Capacitive touch switch uses CPLD Nevada

Capacitive switches are becoming popular

Local Companies

Fransworth Technical Services
(702) 940-6910
Las Vegas, NV
Dyncorp Technical Services Llc
(702) 879-3878
Indian Springs, NV
Mrs Management Resource Services
(775) 828-1176
5519 Alpha Ave
Reno, NV
Gyronautics Technical Services
(702) 940-6836
1112 Desert Ln
Las Vegas, NV
Digital Wizardry
(775) 324-3226
Reno, NV
It Professional Inc
(775) 841-5483
2533 N Carson St
Carson City, NV
Maklaf Operations Inc
(775) 886-0857
Carson City, NV
Universal Technical Services
(702) 658-8910
2704 Tanagrine Dr
North Las Vegas, NV
Fisher Technical Services Inc
(702) 643-8891
6959 Speedway Blvd
Las Vegas, NV
Raytheon Technical Services Co
(702) 361-6600
901 Grier Dr
Las Vegas, NV

Capacitive touch switch uses CPLD

provided by: EDN

Capacitive touch switches work by measuring the change in capacitance of a PCB (printed-circuit-board) pattern depending on the placement of a user?s finger over a sensing pad. Capacitive switches are becoming popular because they are less expensive than mechanical switches. Using the features of an Altera (www.altera.com) MAX IIZ CPLD (complex-programmable-logic device), you can implement a touch-switch decoder with no external components. The touch sensor employs an 8?mm-diameter sensing pad on the PCB using the solder mask as a dielectric. The circuit decodes a single switch, but you could use the approach for multiple switches, and it has programmable sensing thresholds that allow for different PCB layouts and dielectrics.

Figure 1 shows a simple circuit with no external components other than the capacitive-switch layout on the PCB. A basic touch-switch PCB layout is on the left. It comprises only an 8?mm copper circle surrounded by copper that connects to ground. The dashed line shows that the center sensor connects to the CPLD using a via and a backside copper trace. A solder mask acting as a dielectric covers the center sensor and ground. The PCB touch sensor becomes a variable capacitor, CTOUCH.

The variable capacitor is part of a relaxation oscillator. The CPLD has a built-in weak pullup resistor on each I/O pin. CTOUCH and the weak pullup resistor create an RC circuit. If the PINOSC (pin-oscillator) signal is low, the I/O pin will be low, making the D input to the PINOSC LPM (library-of-parameterized-modules) register low. LPM blocks come from the Quartus II LPM.

The register and other logic in the circuit use a free-running, 4.4?MHz internal oscillator, ALTUFM oscillator, as a clock. On the rising edge of the clock, PINOSC goes low, making the buffer-driving pin go to a high-impedance state. The weak pullup resistor slowly makes the pin voltage rise based on an RC time constant. Not touching the switch causes it to have the lowest capacitance and fastest rise time. Touching the switch causes it to have the highest capacitance and the slowest rise time. The pin-I/O buffer uses the Schmitt-trigger option of the CPLD to reduce the noise sensitivity of the slow-rising pin signal. Once the pin node reaches the high-voltage threshold, the D input of the PINOSC registers a zero. On the next clock edge, the PINOSC signal goes low, driving the pin node low for one full clock cycle. This PINOSC circuit oscillates at two fundamental frequencies, depending on the state of the touch capacitor. Putting the register into the oscillator loop reduces noise and makes the oscillator stable and synchronous with the decoding logic. The PINOSC period is always a multiple of 1/4.4 MHz or the frequency of the internal oscillator.

The switch decoder counts the period of 16 PINOSC cycles and compares it with a known time period. If 16 or more cycles happen in less than the sample period, it means that no one is touching the switch. If fewer than 16 cycles happen in the sample period, it means that someone is touching the switch, and the PINOSC oscillation becomes slower. The lower LPM counter sets the sample period.

For example, the sample signal was active once every 80 clock cycles in a prototype (Figure 2). The upper LPM counter measures the period of 16 PINOSC cycles. After 16 cycles, the fast signal goes high and stays high until the sample signal resets it. The fast signal is a one in the prototype when 16 cycles occur in fewer than 80 cycles, making the fast signal a one when the sample signal is a one. When the sample signal is a one, the fast value clocks into the switch-LPM register. The switch-signal value updates every sample cycle with the current capacitive switch state. When you touch the switch, PINOSC is slow, and the fast signal remains a zero when the sample signal is a one, making the switch output zero. In the prototype design, the PINOSC period was three clock cycles when someone touched it and nine cycles when no one touched it. The switch threshold was five cycles. Therefore, the lower LPM-counter modulus was 5×16=80. You can use any value from four to eight, but four is too sensitive, and eight does not work for small fingers; hence, five is the best value. The upper LPM-counter modulus affects noise sensitivity. The larger the count, the more the circuit averages the period of oscillation. A low modulus makes the circuit more sensitive to random system noise. The five-cycle sensing point also allows margin for the ±25% variation among parts of the internal oscillator frequency.



author: Rafael Camarota, Altera, San Jose, CA

EDN. Copyright © 2008 Reed Business Information, a division of Reed Elsevier Inc. All rights reserved.

Featured National Company

Gold N West Surplus, Inc.

770-482-5995
2581 S. Stone Mountain/Lithonia Rd.
Lithonia, GA
www.goldnwest-surplus.com

Related Local Events
NAB 2009
Dates: 4/17/2009 - 4/23/2009
Location: Las Vegas Convention Center
Las Vegas NV
View Details

Northern Nevada Regional Business & Tech Show
Dates: 10/16/2020 - 10/16/2020
Location: .A. Nugget, Sparks
Sparks NV
View Details

Consumer Electronics Show
Dates: 1/8/2009 - 1/11/2009
Location: Las Vegas Convention Center
Las Vegas NV
View Details

Enabling Technology Forums
Dates: 1/8/2009 - 1/11/2009
Location: Las Vegas Convention Center
Las Vegas NV
View Details
Rate Article
     
Articles Insider

Rss   Delicious   Digg   Add To My Yahoo   Add To My Google   Bookmark   Search Plugin

Topics:
Advertising Engineering Home Services Retail & Consumer Services
Business Services Entertainment Industrial Goods & Services Software
Career Family Insurance Technology
Cars Financial Services Internet Telecommunications
Computer Hardware Food & Beverage Legal Transportation & Logistics
Construction Health Pets Travel
Education Home Electronics Real Estate Wedding