I2C Touch Sensor V1.1 doesn't work

Hi jacket

You are right! I can’t upload the code because after hitting “Add the file” it get an error message “The extension ino is not allowed.”?!

So I paste the code here… The output of the code is always “MPR00000”.

// ********************** CODE BEGIN ******************************************
// Arduino Wire library is required if I2Cdev I2CDEV_ARDUINO_WIRE implementation
// is used in I2Cdev.h
#include “Wire.h”

// SLCD
#include <SerialLCD.h>
#if ARDUINO < 100
#include <NewSoftSerial.h> //this is a must
#else
#include <SoftwareSerial.h>
#endif

// Touch Sensor
#include “I2Cdev.h”
#include “MPR121.h”

// Init LCD
SerialLCD slcd(11,12);//this is a must, assign soft serial pins
// Init Touch
MPR121 touch(0x5A);

uint8_t buffer = 0;

void setup() {
// set up
slcd.begin();
Serial.begin(9600);
// join I2C bus (I2Cdev library doesn’t do this automatically)
Wire.begin(0x5A);
touch.initialize();
slcd.print(“MPR”);
slcd.print(touch.testConnection(),DEC);

buffer = 0;
I2Cdev::readByte(0x5A, 4, &buffer);
slcd.print(buffer,DEC);

buffer = 0;
I2Cdev::readByte(0x5A, 5, &buffer);
slcd.print(buffer,DEC);

buffer = 0;
I2Cdev::readByte(0x5A, 6, &buffer);
slcd.print(buffer,DEC);

buffer = 0;
I2Cdev::readByte(0x5A, 7, &buffer);
slcd.print(buffer,DEC);
}

void loop() {
}

// ********************** CODE BEGIN ******************************************

Thanks for your help!

Roger