10 years, 2 months ago.

I2C KL25Z MPR121 issue

Hey, I've been trying to get my FRDM Kl25z board interface with the MPR121 capacitive touch sensor. I've been using the example code here: http://mbed.org/users/sam_grove/code/MPR121_HelloWorld/rev/684222fa16bb which has apparently been tested with a Kl25z board. For some reason though, my board doesn't seem to acknowledge the chip; all the read and write operations return 0. Any suggestions on how I can debug the circuit? I've tested the chip with an Arduino and sample code, and the MPR121 chip worked just fine.

2 Answers

George Chen
poster
10 years, 2 months ago.

I used the MPR121 sparkfun board. I fixed the bug. I changed the code to use PTE1 and PTE0 for the I2C pins instead, and in result, they didn't work as well as expected, so I'm going to use PTC8 and PTC9 as you did. My copper pads are also small, so I used the same register values from the bldr website instead: http://bildr.org/2011/05/mpr121_arduino/ It works like a charm now!

Accepted Answer
10 years, 2 months ago.

Do you have the pull-up resistors installed on the I2C pins? I soldered to the MPR121 board from Sparkfun.

Have you made any changes to the example? If so, please share the code.