When I try to use this sensor through I2c I get weird readings from the y axis....
(With the data above the Acc is 3x filtered and the gyro is raw )
I am reading the correct addresses...
MSB = i2cread(GYRO, 0x29);
LSB = i2cread(GYRO, 0x28);
xGyro = ((MSB << 8) | LSB);
MSB = i2cread(GYRO, 0x2B);
LSB = i2cread(GYRO, 0x2A);
yGyro = ((MSB << 8) | LSB);
MSB = i2cread(GYRO, 0x2D);
LSB = i2cread(GYRO, 0x2C);
zGyro = ((MSB << 8) | LSB);
When I use the pololu library for the l3g4200d it seems that the raw data comes in correctly as I would expect it to with all the axis hovering around 0 if stationary. Inspecting the pololu library the raw data just gets read and stored immediately without any filtering or modification.
Does anyone have any input on this? Ive read somewhere that you need to set CS pin high to use I2c with l3g4200d but I am using this sensor from the GY-80 board. Is there something I'm not understanding?