I am using the L3GD20H breakout from Adafruit on Particle Photon. In the library (Adafruit_L3GD20) on particle photon, when I set the range of the accelerometer to 500 deg/sec or 2000 deg/sec, the initialization of the board fails. The board is working perfects with range as 250 deg/sec. Do you know why?
Thanks,
Sanjay
Code: Select all
_____
void setup()
{
delay(3000);
Serial.println("Initializing Gyro L3GD20H");
// Try to initialise and warn if we couldn't detect the chip
//if (gyro.begin(gyro.L3DS20_RANGE_250DPS))
//if (!gyro.begin(gyro.L3DS20_RANGE_500DPS))
if (!gyro.begin(gyro.L3DS20_RANGE_2000DPS))
{
gyro_initialized = true;
Serial.println("L3GD20H init complete");
}
else
{
Particle.publish("Error initializing gyro", PRIVATE);
Serial.print("Error initializing gyro");
}
}