wifi and websocket connection added
This commit is contained in:
@@ -4,21 +4,19 @@
|
||||
SensorManager::SensorManager() {}
|
||||
|
||||
void SensorManager::sensorSetup() {
|
||||
Serial.println();
|
||||
Serial.println("BNO080 Read Example");
|
||||
|
||||
delay(1000); // Wait for BNO to boot
|
||||
|
||||
Wire.setClockStretchLimit(150000L); // Default stretch limit 150mS
|
||||
Wire.begin();
|
||||
|
||||
//wait for the sensor to start before continue
|
||||
if (myIMU.begin() == false) {
|
||||
delay(1000);
|
||||
Serial.println(".");
|
||||
}
|
||||
//start sensorfunction and start autocalibration
|
||||
//once calibration is enabled it attempts to every 5 min
|
||||
|
||||
Wire.setClock(400000); //Increase I2C data rate to 400kHz
|
||||
myIMU.calibrateAll(); //Turn on cal for Accel, Gyro, and Mag
|
||||
myIMU.enableGyroIntegratedRotationVector(100);
|
||||
myIMU.enableGyroIntegratedRotationVector(100); //send data every 100ms
|
||||
myIMU.enableMagnetometer(100); //Send data update every 100ms
|
||||
myIMU.saveCalibration(); //Saves the current dynamic calibration data (DCD) to memory
|
||||
myIMU.requestCalibrationStatus(); //Sends command to get the latest calibration status
|
||||
|
Reference in New Issue
Block a user