PCF8883 capacitive touch sensor unreliable in push-button mode

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

PCF8883 capacitive touch sensor unreliable in push-button mode

1,306 Views
tedj1
Contributor II

Hi.  I'm testing the PCF8883 aboard the UM10370 demo board.  I'm finding that if jumpered into Pulse or Toggle mode, it works quite reliably.  However, if jumpered to Push-Button mode, it is unreliable.  The LED aboard the demo usually just stays on indefinitely (locks up).  But I need Push-Button mode, because I need to capture the moment when the touch pad is no longer touched as well as when it is first touched.  Can anyone offer me any suggestion as to how I might get Push-Button mode to work reliably?  Thanks so much.

Addendum:

My need requires a rather large sensor plate area (about 15 cm x 7.5 cm) and about a 10 cm coax to the sensor electronics and I'm using a solid (unhatched) pcb ground plane of sorts, so I suspect the lock-up in push-button mode is related to a too high input capacitance.  I might try hatching the large sensor area (and the ground plane) if other remedies prove futile.  I'm using the demo board with its default component values described in doc UM10370.  One of the posters mentioned:

"If the sensitivity of Ccpc is set closer to the upper limits or the sampling frequency is increased, the sensor can be put in a state where a sense event triggers and the output remains high forever after. The type pin is grounded (pushbutton mode), but the capacitive event should clear when your hand is pulled away. This lock up does not occur with middle range Ccpc and Clin values.  We are trying to push the sensing distance out as far as possible, so there may be an increased susceptibility to noise, but it only seems to lock after a sense trigger."

The documents recommend first getting the sensor to switch reliably, which I assume the lock-up to be symptomatic of, so the 5 step process in UM10370 for first getting reliable switching would seem to be the first task, which I read as follows:

1) "CIN is the total input capacitance (CSensor + Ccable + CF). CF should be chosen such that CIN is about 30 pF. This can be checked by measuring the voltage over CCPC which should then be about 1/2 VDD."  On the demo board, I should measure VCPC @ TP2 (jumpering J12 and then J16 to avoid CMOS lock-up of the on-board buffer).  Since I'm powering the demo board from the USB, I must assume (never stated therein) a VDD of 3.3V.  Thus, I should expect a VCPC of about 1.65V at TP2.  So I should vary CF to arrive at that voltage.

2) "RS and CF form a low pass filter. The typical values are likely to be correct for most applications." and a typical value of 6.8k is mentioned.  6.8k is not the value of the resistor (5.1k) currently aboard the demo board.  RS(R2) along with CF(C1) form a low pass filter at the input, so to reduce sensitivity to high frequencies, I'd need to increase RS(R2) to increase the time constant to decrease the 3dB point frequency of the filter.  Cutting the 5.1k resistor right off the board (or cutting its trace) and substituting another resistor at RU2 would be the only way to increase the input effective series resistance, otherwise I'd just get a (lower) parallel resistance by adding another at RU2 without the cut.

3) "This resistance (RC) compensates large input capacitances (long coaxial cable, larger sensor plate area). Smaller resistor values should be used with larger input capacitances."  I'll observe the 5k(min) 39k(typ) 50k(max) criteria for the effective resistance. In that case, I can leave the default R1 resistor in parallel and just add an additional RC resistor at RU1 to reduce the effective resistance with a parallel resistance.

4) "CCPC determines the sensitivity of the sensor. If the sensitivity is increased, the possibility of incorrect switching due to interfering electrical fields is also increased."  Since my large sensor plate increases the sensitivity and I'm evidently getting 'incorrect switching', I should reduce CCPC for lower sensitivity using an X7R (low leakage) ceramic chip capacitor observing 90nF(min), 470nF(typ), 2500nF(max).  Unfortunately, the only way to reduce CCPC is to cut the default CCPC(C6) right off the board and substitute another between the holes/pads at CU6, since adding a parallel CCPC will only increase the effective CCPC.

5) "CCLIN determines the internal sampling frequency and therefore the reaction time of the switch. Smaller values of CCLIN correspond to shorter reaction times."  Shorter reaction times correspond to higher sampling frequencies, so I should increase Clin for a lower sampling freq observing 0nF(min), 22(typ), 100pF(max).  So, to get a larger value, I can leave the existing CCLIN and place and another capacitor between the CU4 holes/pads, since parallel capacitances are cumulative.

...in that order.  But I think it would best to go straight for steps 4 and 5 though, considering the poster's advice.

4 Replies

1,143 Views
reyes
NXP TechSupport
NXP TechSupport

Hi,

For testing purposes, it is recommended to use the 9V battery to avoid noise which could cause undesired touch detection or not response to the touch.

I tested using my PCF8883 board (OM11055/UM10370) with a 9V battery (and using its default HW configuration) and I do not have any problem using the Push-Button mode.

 

What I’m thinking is affecting your tests is the response time of the sensor, the charge-discharge cycle is governed by the sampling rate (fs). The sampling rate can be adjusted within a specified range by selecting the value of CCLIN on pin CLIN. I recommend you to change the 0.47pF capacitor on C5 for a 0.22pF capacitor to increase the sampling rate to 1kHz.

Regards,

Jose

0 Kudos

1,143 Views
tedj1
Contributor II

CCLIN.png

Hi Jose,

Thanks for your reply.  In my copy of UM10370 (and presumably also upon my demo evaluation board), there is an installed 22pF capacitor for C4 (not 0.22pf - two orders of magnitude larger) and an additional CCLIN can be placed at CU4 and those two are connected to CLIN pin 7.  And the 'Optimize step by step' section lists a min(0pF), typ(22pF), max(100nF) for CCLIN.  I assume the 100nF is a typo and it really means 100pF.  You surely mean C5 and not C4 if our documents are the same.  Anyway, I'm currently at 22pF for CCLIN (C4) as I think you recommend and CU4 is currently unpopulated.  Since parallel capacitances are cumulative, I would need to cut the trace to C4 to try a lower value capacitance, and will try that if you still recommend it if you agree with this paragraph.

I assume you offer that recommendation in view of the fact that my sense plate is rather large (about 15 cm x 7.5 cm) with 10cm of coax and a solid backing ground plate?  I don't mean to be difficult and I really do appreciate your taking the time to reply substantively.  But it's electronics, so gotta thrash out the details.

I hooked up to a 9V battery.  VDD is 9.41V, TP1 (VDDREG) is 4.18V, TP2 (the buffered VCPC) reads 3.31V.  Switching is not reliable.  Changed back to USB.  VDD is 4.97V (not 3.3V as I expected - my goof), TP1 is 4.17V, TP2 is 3.30V.  Switching is more reliable, but still not entirely so.  Notice that VDDREG and buffered VCPC are quite stable.

0 Kudos

1,143 Views
reyes
NXP TechSupport
NXP TechSupport

Hi Ted,

 

You are correct, sorry about that, I was referring to the C5 (CCLIN) capacitor, and I checked and it is 22pF for a sampling rate of 1 kHz already.

 

I didn’t realize that you have a large external sense plate, for your application, then I think that you need to add an external pull-down resistor on the IN pin.

For good performance, the total amount of capacitance on the input (CSENS + CCABLE + CF) should be in the proper range, the optimum point being around 30 pF. These conditions allow the control loop to adapt to the static capacitance on CSENS and to compensate for slow changes in the sensing plate capacitance. A higher capacitive input loading is possible if an additional discharge resistor RC is placed as shown in Figure 16. Resistor RC simply reduces the discharge time such that the internal timing requirements are fulfilled.

 

Regards,

Jose

1,143 Views
tedj1
Contributor II

Hi Jose.  I regret to say that for the benefit of my sanity, I decided to go with the Atmel/Microchip 556-AT42QT1011-MAHR touch sensor chip.  I already had an Atmel AT42QT1070 demo module on-hand, which has proven to be rock stable in its operation and is intrinsically a 'switch mode' device (output stays on forever while touched), requires very few external components, has a low power mode making it practical for battery powered use, and is even reasonably priced at $0.48 at Newark and a little more at Mouser.  So, for those who were getting headaches in trying to use switch mode successfully with their PCF8883, that would appear to be a good solution.  Sorry to 'advertise' for them here at an NXP forum, but I think it in this case appropriate.

0 Kudos