I'm working with MMA9555L module through an i2c interface, but I'm having a problem with pedometer function in MMA9555L. For a sanity check, I read back the version information which is ok and gets back the desired data but when I want to read the data from pedometer application, the slave returns nonsense data. Here is my code:
void pedometerConfigRegs(); //sets the configuration registers of the pedometer application
//send these bytes to the part: 0x15, 0x20, 0x00, 0x11, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xE0, 0x00, 0xB6, 0x44, 0x04, 0x83, 0x05, 0x82, 0x00, 0x00, 0x00
void pedometerReadValue(); //reads back from the slave
//send these bytes to the part: 0x15, 0x30, 0x00, 0x0C
Any help is highly appreciated.