background image

 

 

Liquid-Tolerant Design Considerations 

CY8C20xx7/S CapSense

®

 Design Guide

 

Doc. No. 001-78329 Rev. *E 

61 

Figure 6-6. Schematic View of Polarity Select 

 

6.1.2  Guard Sensor 

Figure 6-7. PCB with Shield and Guard Sensor 

 

A guard sensor is a copper trace, as shown in 

Figure 6-9

that surrounds all the sensors on the PCB, which is used to 

detect the presence of a continuous water stream or a large liquid spill. When a water stream or a large liquid spill is 
present  on  the  sensing  surface,  a  large-capacitance  C

ST

  is  added  to  the  system,  as  shown  in 

Figure  6-8

.  This 

capacitance  may  be  several  times  larger  than  C

LD

.  Because  of  this,  the  effect  of  the  shield  electrode  is  completely 

masked and the raw counts measured by the sensor will be the same as or even higher than a finger touch. In this 
situation, a guard sensor will help; when it detects a water stream, it will block the other sensors from triggering. 

PCB

 

 

 

 

 

 

 

 

Shield Electrode 

 

 

 

 

   

 

 

 

Guard Sensor

 

Sensor Pads

 

Содержание CY8C20xx7/S CapSense Series

Страница 1: ...CY8C20xx7 S AN78329 CapSense Design Guide Doc No 001 78329 Rev E Cypress Semiconductor 198 Champion Court San Jose CA 95134 1709 Phone USA 800 858 1810 Phone Intnl 408 943 2600 www cypress com...

Страница 2: ...subject to worldwide patent protection United States and foreign United States copyright laws and international treaty provisions Cypress hereby grants to licensee a personal non exclusive non transfe...

Страница 3: ...ser Modules 20 3 1 2 CY8C20xx7 S QuietZone Starter Kit 21 3 1 3 CapSense Data Viewing Tools 21 3 2 User Module Overview 22 3 3 CapSense User Module Global Arrays 22 3 3 1 Raw Count 23 3 3 2 Baseline 2...

Страница 4: ...EMCPLUS UM 44 4 3 9 Firmware Design Guidelines 45 4 4 Design Migration from CY8C20xx6A AS to CY8C20xx7 S 47 4 4 1 Discontinued Support User Modules 47 4 4 2 Improvement and New Features 47 4 4 3 Pin C...

Страница 5: ...2 C Slave Implementation in Sleep Mode 67 8 1 4 Sleep Mode Complications 67 8 1 5 Pending Interrupts 67 8 1 6 Global Interrupt Enable 68 8 2 Post Wakeup Execution Sequence 68 8 2 1 PLL Mode Enabled 68...

Страница 6: ...l and mechanical design considerations for CapSense Low power design considerations for CapSense Additional resources and support for designing CapSense into your system 1 2 Cypress s CapSense Documen...

Страница 7: ...pe 12 Test and evaluate system functionality and CapSense performance Performance satisfactory 13 Production Yes No Topics covered in this document 1 Understanding CapSense technology 4 Mechanical des...

Страница 8: ...045 CY8C20055 CY8C20065 CY8C20xx6A CY8C20xx7 AN59389 Host Sourced Serial Programming for CY8C20xx6A CY8C20xx6AS CY8C20xx6L and CY8C20xx7 S 11 CY8C20xx7 S CapSense Design Guide this document CapSense C...

Страница 9: ...y sensing in the presence of metal objects Supports longer trace lengths Maximum load of 100 pF 3 MHz Device Features High performance low power M8C Harvard architecture processor Up to 4 MIPS with 24...

Страница 10: ...ce documentation Read about the sourcefile hex file in the PSoC Designer User Guide Bracketed Bold Displays keyboard commands in procedures Enter or Ctrl C File Open Represents menu paths File Open Ne...

Страница 11: ...ng Methods in CY8C20xx7 S Figure 2 1 CapSense Implementation in a CY8C20xx7 S PSoC Device CY8C20xx7 S CMOD Sensor 1 CX 1 Sensor 2 CX 2 Sensor 3 CX 3 Sensor 4 CX 4 Sensor n CX n As shown in Figure 2 1...

Страница 12: ...f magnitude greater than CF CP usually ranges from 10 pF to 20 pF but in extreme cases can be as high as 50 pF CF usually ranges from 0 1 pF to 0 4 pF The magnitude of CP is of critical importance whe...

Страница 13: ...d Capacitor Input The CSD method in the CY8C20xx7 S device incorporates CX into a switched capacitor circuit as Figure 2 3 shows Figure 2 4 Pin Configured as Switched Capacitor Input Analog Mux Bus AM...

Страница 14: ...erred as IDAC or modulation IDAC in this document The sigma delta converter also requires an external integrating capacitor CMOD as Figure 2 3 on page 13 shows The recommended value of CMOD is 2 2 nF...

Страница 15: ...High Level Parameters should be tuned to optimum values for reliable touch detection For a detailed discussion on tuning see CapSense Performance Tuning with User Modules 2 2 2 CapSense Sigma Delta CS...

Страница 16: ...2 2 1 Switched Capacitor Input The CSDPLUS method in CY8C20xx7 S devices incorporates CX into a switched capacitor circuit as Figure 2 9 shows Figure 2 9 Pin Configured as Switched Capacitor Input Ana...

Страница 17: ...ation IDAC and is referred as IDAC or modulation IDAC in this document The other 7 bit IDAC known as the compensation IDAC is either always ON or always OFF This IDAC is referred as Compensation IDAC...

Страница 18: ...cally tunes them out 2 2 3 1 Process Variation The SmartSense_EMCPLUS User Module UM for the CY8C20xx7 S is designed to work with sensor parasitic capacitance in the range 5 pF to 45 pF typical sensor...

Страница 19: ...opment Feasibility Study Schematics Design PCB Layout Design Mechanical Design Review System Integration Design Validation Production SmartSense based Capacitive User Interface Design Cycle Firmware D...

Страница 20: ...a drag and drop design environment using a library of user modules User modules are configured either through the Device Editor GUI or by writing into specific registers with firmware PSoC Designer c...

Страница 21: ...For a detailed procedure for creating a PSoC Designer project and configuring the User Module wizard refer to the datasheet of the specific user module For code examples on CapSense user modules see...

Страница 22: ...for scanning sensors Low level parameters are unique to each type of sensing method and are described in CSD CSDPLUS User Module Low Level Parameters and SmartSense_EMCPLUS User Module Parameters High...

Страница 23: ...es of sensors are stored in UMname_waSnsBaseline integer array This array is defined in the header file UMname h 3 3 3 Difference Count Signal The difference count which is also known as the signal of...

Страница 24: ...r If the difference count value of a sensor is greater than the finger threshold value the sensor is judged as active This definition assumes that the hysteresis level is set to 0 and debounce is set...

Страница 25: ...ommended value see Set High Level Parameters 3 4 1 3 Debounce The Debounce parameter prevents spikes in raw counts from changing the sensor state from OFF to ON For the sensor state to transition from...

Страница 26: ...lower limit of noise counts in the raw count The baselining update algorithm is paused when the raw count is below the baseline and the difference between them is greater than this threshold Possible...

Страница 27: ...o a higher range but a lower sensitivity as explained here According to Equation 2 9 the raw count can be related to CX and IDAC as follows raw count GC CX 2N 1 ICOMP IDAC Equation 3 2 Where GC is the...

Страница 28: ...also moves the raw count corresponding to CP towards the maximum value of raw count 2 N For very high gain values the raw count saturates as the plot of GC3 shows Therefore you should tune the conver...

Страница 29: ...ases Note that this increase in signal may not proportionally increase the SNR because of the variations in noise counts when the compensation IDAC is used The dual IDAC mode complicates the tuning pr...

Страница 30: ...parameter sets the prescaler ratio and determines the precharge switch output frequency This parameter also affects the PRS output frequency Possible values are 1 2 4 8 16 32 64 128 and 256 3 4 2 8 PR...

Страница 31: ...ice the scan time and RAM memory and setting the immunity level to High consumes three times the scan time and RAM memory for sensor implementation compared to the Low immunity mode Possible values ar...

Страница 32: ...No 001 78329 Rev E 32 Figure 3 14 PSoC Designer SmartSense_EMC_PLUS Sensor Setting 3 5 1 3 Sensor Sensitivity This parameter is used to increase and decrease the sensitivity of a sensor Possible valu...

Страница 33: ...larger than the CapSense noise The CapSense signal is compared to the CapSense noise by using a quantity called signal to noise ratio SNR Before discussing the meaning of SNR for CapSense it is first...

Страница 34: ...in the tuning process the sensor capacitor must be fully charged and discharged during each cycle The charge discharge path switches between two states at a rate set by a user module parameter called...

Страница 35: ...compensate for any changes introduced by a finger and the moving finger will not be detected If the update rate is too slow relatively slow environmental changes may be mistaken for fingers During de...

Страница 36: ...ibes these parameters and provides guidance about how each should be tuned based on system characteristics and other parameters By default hardware parameters are global settings that apply to all Cap...

Страница 37: ...of the maximum raw counts Note down the SNR Repeat this procedure with a higher value of compensation IDAC until maximum SNR is achieved Note that a higher compensation IDAC value results in higher s...

Страница 38: ...2 N 1 Table 4 2 gives recommended resolution settings based on CP and the finger capacitance CF CF is the change in capacitance of a sensor when a finger is placed on the sensor CF depends on overlay...

Страница 39: ...LUS_waSnsResult and CSDPLUS_waSnsDiff respectively The high level API parameter settings are based primarily on ambient noise and finger signal strength as indicated by this data Noise and signal stre...

Страница 40: ...determined at runtime by the SmartSense_EMCPLUS User Module You should not use APIs that modify these CSD parameters in firmware unless you know exactly what effect it has in your design To migrate a...

Страница 41: ...sensitivity 0 1 pF leads to a stronger signal from the sensor Designs with thicker overlays require stronger signals from sensors for proper implementation The available options for sensitivity select...

Страница 42: ...2 C slave interface the master clock should operate within the reduced specification mentioned earlier Not doing this will lead to data corruption I 2 C bus conjunction or inconsistent behavior from...

Страница 43: ...an be calculated from the previous tables using Equation 4 1 Sampling time for the previously mentioned configuration 24 MHz of IMO and 0 3 pF of sensitivity is chosen from Table 4 4 it is 680 s Proce...

Страница 44: ...sor raw count SmartSense_EMCPLUS_waSnsResult sensor normalized signal SmartSense_EMCPLUS_baSnsSignal and sensor finger threshold SmartSense_EMCPLUS_baBtnFThreshold must be observed during the tuning p...

Страница 45: ...d of the signal on the Port_0 1 pin is 4 9 ms the period is twice the loop time as the port pin is toggled If the parasitic capacitance of one sensor is increased to approximately 15 pF the scan time...

Страница 46: ...case main loop execution time This is the sum of the worst case scan times of the individual CapSense sensors If the parasitic capacitance of the sensor is close to the boundary of the SmartSense_EMCP...

Страница 47: ...C slave interface I2CSBUF User Module with dedicated 32 byte buffer eliminating clock stretching by the slave Improved I 2 C interface also supports wakeup interrupt from I 2 C slave address match ev...

Страница 48: ...ctric constant decrease the overlay thickness and increase the button diameter Table 5 1 Overlay Material Dielectric Strength Material r Breakdown Voltage V mm Minimum Overlay Thickness at 12 kV mm Ai...

Страница 49: ...nected to chassis ground As recommended in PCB Layout Guidelines providing a hatched ground plane around the button or slider sensor can redirect the ESD event away from the sensor and CapSense contro...

Страница 50: ...wer planes If the CapSense controller PCB is connected to the power supply by a cable minimize the cable length and consider using a shielded cable Place a ferrite bead around power supply or communic...

Страница 51: ...nt The average current consumed by the device over a long period can be calculated by using the following equation Equation 5 1 The average power consumed by the device can be calculated as follows Eq...

Страница 52: ...utput pin in the oscilloscope and measure the time period between two toggles This gives the active time Assign this value to tACT 5 Apply sleep scan to the project The period of the sleep scan cycle...

Страница 53: ...any port pin having an odd number as pin number For a CapSense controller if the current budget of odd port pin is 100 mA the total current drawn though all odd port pins should not exceed 100 mA In...

Страница 54: ...l The worst case noise appears in the CapSense system when the GPIO state is changed from a no current flow state for example all LEDs OFF to a maximum current flow state for example all LEDs ON The G...

Страница 55: ...nt Noise To prevent sensor false triggers due to GPIO load transients the sensor baseline can be updated using rule based algorithms One of the methods to compensate the baseline is explained here Fig...

Страница 56: ...he OFF condition 2 At instant 2 a finger is on the sensor and the shift in raw count difference count is greater than the finger threshold 3 Because the shift in difference count is greater than the f...

Страница 57: ...Finger Touch Shift Due to GPIO Load Transient Difference Count is Zero Due to Baseline Compensation LED OFF LED ON Sensor Status Baseline Rawcount 1 2 3 4 LED OFF Baseline Compensated Rawcount Returns...

Страница 58: ...ice humidity changes or any other liquids For such applications shield electrodes and guard sensors can provide robust touch sensing 6 1 Shield Electrode and Guard Sensor Figure 6 1 PCB Layout with Sh...

Страница 59: ...tic Layout Firmware development 6 1 1 1 Schematic Select the proper pin to drive the shield electrode out signal The following pins should be used to drive the shield electrode out signal Port pins P0...

Страница 60: ..._2_2 Buf 2 Port_0_2 Buf 3 Port_0_0 Buf 4 Port_1_2 The shield drive buffers are OFF by default select the desired shield drive buffer Figure 6 5 shows the enabling of Buf 0 such that the shield signal...

Страница 61: ...eam or a large liquid spill When a water stream or a large liquid spill is present on the sensing surface a large capacitance CST is added to the system as shown in Figure 6 8 This capacitance may be...

Страница 62: ...mplemented in firmware One CapSense pin and a counter hardware software are required to implement the guard sensor When a water stream or a large liquid spill is present on the board the guard sensor...

Страница 63: ...opper hatch recommendations Top layer 7 mil trace and 45 mil grid 15 percent fill Bottom layer 7 mil trace and 70 mil grid 10 percent fill The shield electrode between buttons should be at least 10 mm...

Страница 64: ...y sensor Because detecting a hand relies on the capacitance change from electric field changes any stray capacitance or objects affecting the electrical field around the wire will affect the range of...

Страница 65: ...rly helpful when the proximity sensor must operate in the presence of metal A wire sensor increases the beneficial effect of the shield electrode because it can be located farther from the shield elec...

Страница 66: ...device is sleeping to allow extra processing 8 1 Additional Power Saving Techniques All of the power saving techniques with the exception of sleep mode is application based Some of them produce undesi...

Страница 67: ...he SLP_CFG2 register Call the M8C_Sleep function this sets the SLEEP bit Bit 3 within the CPU_SCR0 register Note Data retention during sleep and deep sleep modes in the 32 byte I 2 C buffer is guarant...

Страница 68: ...U speed However this register just sets a divider of SYSCLK which means that the CPU speed will vary between part families with different SYSCLKs Typically SYSCLK is 24 MHz OSC_CR0 0xf8 CPU 3 Mhz IMO...

Страница 69: ...8 Hz 64 Hz and 512 Hz the timer generates an interrupt It is often useful to periodically wake the CapSense controller up to do some processing or check for activity An example of this is to periodic...

Страница 70: ...of devices on the CY8C20xx7 S web page 9 2 Datasheet The datasheet for the CapSense CY8C20xx7 S family of devices are available at www cypress com CY8C20xx7 S Datasheet 9 3 Technical Reference Manual...

Страница 71: ...ly does not have on chip debug OCD capability if a debug platform is needed then the CY8C20xx6A Universal CapSense Controller Kit is available The Universal CapSense Controller Kits feature predefined...

Страница 72: ...5 and P1 5 of the CY8C20237 24SXI device Two GPIOs connected to pins P0 7 and P0 4 of CY8C20237 24SXI to drive LEDs D1 and D2 Shield electrode is connected to pin P1 2 to drive shield plane Programmi...

Страница 73: ...Resources CY8C20xx7 S CapSense Design Guide Doc No 001 78329 Rev E 73 Figure 9 3 Liquid Tolerant Button Design with I 2 C Header on CY8C20437...

Страница 74: ...e developed in a drag and drop design environment using a library of fully characterized analog and digital functions including CapSense PSoC Designer comes with a built in C compiler and an embedded...

Страница 75: ...ink to QuietZone Starter Kit external web Updated Section 3 4 2 4 Pg 40 Added table 4 8 Updated Section 6 1 1 1 D 01 21 2015 PRIA DCHE Added sections Switched Capacitor Input and Sigma Delta Converter...

Отзывы: