MPR121 sensitivity

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

MPR121 sensitivity

4,492 Views
krekeltronics
Contributor II

I guys,

I have an MPR121 with two electrodes set up as small finger-size touch pads on a device. Vcc is 3.3V. The pads work perfectly when out of the enclosure, but when assembled into the enclosure I haven't yet been able to configure the MPR121 to trigger touch recognition for one or both of the pads. Out of the enclosure, the readings are around 210 at baseline steady state, then down to 50 or so when a finger is in direct contact with a pad.

Inside the enclosure, the pads are (for example) 208 at baseline then down to about 202, which never is recognized as a touch no matter what I use as a touch threshold.

It seems like the touch needs to be in direct contact with the pad in order for it to be recognized.

Has anyone ever experienced such a drastic decrease in sensitivity and effectiveness in an enclosure? I have been adjusting the thresholds as well as the auto configuration bytes, to no avail so far.

Configuration is something like this, with touch/release thresholds anywhere from 0x03/0x01 to 0x0F/0x0C:

// Section A
// This group controls filtering when data is > baseline.
mpr121Write(MHD_R, 0x01);
mpr121Write(NHD_R, 0x01);
mpr121Write(NCL_R, 0x00);
mpr121Write(FDL_R, 0x00);

// Section B
// This group controls filtering when data is < baseline.
mpr121Write(MHD_F, 0x01);
mpr121Write(NHD_F, 0x01);
mpr121Write(NCL_F, 0xFF);
mpr121Write(FDL_F, 0x02);

        // Proximity Detection

        mpr121Write(P_MHD_R, 0xFF);

        mpr121Write(P_NHD_R, 0xFF);

        mpr121Write(P_NCL_R, 0x00);

        mpr121Write(P_FDL_R, 0x00);

        mpr121Write(P_MHD_F, 0x01);

        mpr121Write(P_NHD_F, 0x01);

        mpr121Write(P_NCL_F, 0xFF);

        mpr121Write(P_FDL_F, 0xFF);

        mpr121Write(P_NHD_T, 0x00);

        mpr121Write(P_NCL_T, 0x00);

        mpr121Write(P_FDL_T, 0x00);

// Section C
// This group sets touch and release thresholds for each electrode
mpr121Write(ELE0_T, TOU_THRESH);
mpr121Write(ELE0_R, REL_THRESH);
mpr121Write(ELE1_T, TOU_THRESH);
mpr121Write(ELE1_R, REL_THRESH);

        mpr121Write(ELEP_T, PROX_H);

        mpr121Write(ELEP_R, PROX_L);

        // Section C2

        // Set the debounce for Touch and Release

        // D7 = 0, D6-D4 = Release, D3 = 0, D2-D0 = Touch

        mpr121Write(DEB_CFG, 0x33);

        // AFE config

        mpr121Write(ELE_CFG, 0x00); // Stop the touch momentarily

        //uint8_t afeConfig = mpr121Read(AFE_CFG);

        mpr121Write(AFE_CFG, 0b00111111);  // 0x10 is the default CDC (16uA)

        mpr121Write(ELE_CFG, 0x0C); // Stop the touch momentarily

        //afeConfig = mpr121Read(AFE_CFG);

// Section D
// Set the Filter Configuration
// Set ESI2
mpr121Write(FIL_CFG, 0b10000100);  // 0x04 is the default

// Section E
// Electrode Configuration
// Enable 6 Electrodes and set to run mode
// Set ELE_CFG to 0x00 to return to standby mode
// mpr121Write(ELE_CFG, 0x0C);// Enables all 12 Electrodes

        #define ELE_RUN 0b10010010

        mpr121Write(ELE_CFG, ELE_RUN);

//mpr121Write(ELE_CFG, 0x02);// Enable first 2 electrodes

      

          // charge to 70% of Vdd , high sensitivity

// Section F

        mpr121Write(ELE_CFG, 0x00); // Stop the touch momentarily

// Enable Auto Config and auto Reconfig
mpr121Write(ATO_CFG0, 0x0B);    // Auto-Config, and try twice.
mpr121Write(ATO_CFGU, 0xC9);// USL = (Vdd-0.7)/vdd*256 = 0xC9 @3.3V   0xC9 = 201
mpr121Write(ATO_CFGL, 0x72);// LSL = 0.65*USL = 0x82 @3.3V            0x82 = 130
mpr121Write(ATO_CFGT, 0xB5);// Target = 0.9*USL = 0xB5 @3.3V          0xB5 = 181

        mpr121Write(ELE_CFG, ELE_RUN);  // Start Touch again

Labels (1)
0 Kudos
5 Replies

876 Views
reyes
NXP TechSupport
NXP TechSupport

Hi Patrick,

Your registers configuration seems to be correct, but I’m more worried about the physical configuration of the touch pads.

I don’t totally understand what you mean when you mention that the pads are “out of the enclosure” and “assembled into the enclosure”, but it is true that if the ambient around the pads change, it could affect the performance of the touch detection.

Another think that it’s making me some noise it’s your comment “It seems like the touch needs to be in direct contact with the pad in order for it to be recognized”, well, the answer would be yes, in order to detect a touch with the MPR121, it’s important to make the touch directly into the pads or trough a thin dielectric, no air gaps or big dielectric are allowed by the touch detection with the MPR121.

Also, the layout in these kind of devices are very critical, for example, it’s important to place planes all over the board, but just behind the touch pad electrodes, an x-hatch pattern plane it’s recommended to avoid noisy signals.

You can find these and a lot more recommendations for touch application in the following application note: http://cache.freescale.com/files/sensors/doc/app_note/AN3863.pdf

Best Regards,

Jose

0 Kudos

876 Views
giuseppemodugno
Contributor I

I have the same problem of patrick. I think the enclosure is a plastic cabinet. I can't think the end user has to touch the electrical PCB, so a box/cabinet is needed. Maybe the cabinet that patrick is using is too thick.

With this big limitation about the thickness of the external layer, it's difficult to implement a good lighting system as a middle layer between PCB and overlay label. I know other touch controllers (for example, from Microchip) are able to reach more distance (5mm) so they let us to use a thickier middle layer.

Is MPR121 able to sense touch from a bigger distance?

0 Kudos

876 Views
reyes
NXP TechSupport
NXP TechSupport

Hi,

We usually don’t recommend to use dielectric thicker than 3mm, because this would affect on the electrode crosstalk if two electrodes are too close or not detect the touch at all, in other words, if the dielectric it’s too thick and the electrodes are too closed, the MPR121 could detect the touch on the wrong electrode (if detects the touch).

Usually, under the right circumstances, you should not have any problem to detect a touch from 3mm away from the electrode, but it is very important to avoid air gaps between electrode and finger touch, follow the recommendations for the correct electrode design from the application note AN3863, while bigger the electrode, better the sensitivity, do not use very thick dielectrics, etc.

AN3863: http://cache.freescale.com/files/sensors/doc/app_note/AN3863.pdf

Regards,

Jose

0 Kudos

876 Views
giuseppemodugno
Contributor I

Hello Jose,

thank you for your answer.

In the MPR121 kit the keypad PCB is protected with a very thin transparent layer (what is its material?). In this assembly, I need to make a phisical touch between my skin and the transparent layer, otherwise the touch isn't detected. How to increase the distance to 3mm as you say? Is there a better way to design the keypad PCB electrodes or to configure the MPR121 in order to increase the sensivity?

The AN3863 doesn't suggest a good material for the dielectric, mostly for backlight purposes. It only suggests to use reverse mounted LEDs with a hole to transfer the light into the panel. I think I have to use a good dielectric that can diffuse the light in a omogenous way on the surface. Which kind of material is good for this purpose?

0 Kudos

876 Views
reyes
NXP TechSupport
NXP TechSupport

Hi Giuseppe Modugno,

The material of the dielectric in the MPR121 kit it’s acrylic.

Please take a look at section 3.2 of the application note from the link below to find out the dielectric constant on different materials for the dielectric.

AN1985: http://cache.freescale.com/files/sensors/doc/app_note/AN1985.pdf

Regards,

Jose

0 Kudos