diff --git a/examples/Example10-PrintPacket/Example10-PrintPacket.ino b/examples/Example10-PrintPacket/Example10-PrintPacket.ino index 1a9d786..cbdd4a0 100644 --- a/examples/Example10-PrintPacket/Example10-PrintPacket.ino +++ b/examples/Example10-PrintPacket/Example10-PrintPacket.ino @@ -16,7 +16,7 @@ Hardware Connections: Attach the Qwiic Shield to your Arduino/Photon/ESP32 or other Plug the sensor onto the shield - Serial.print it out at 9600 baud to serial monitor. + Serial.print it out at 115200 baud to serial monitor. */ #include diff --git a/examples/Example11-AdvancedConfig/Example11-AdvancedConfig.ino b/examples/Example11-AdvancedConfig/Example11-AdvancedConfig.ino index 26f1d2e..2db3995 100644 --- a/examples/Example11-AdvancedConfig/Example11-AdvancedConfig.ino +++ b/examples/Example11-AdvancedConfig/Example11-AdvancedConfig.ino @@ -16,7 +16,7 @@ Hardware Connections: Attach the Qwiic Shield to your Arduino/Photon/ESP32 or other Plug the sensor onto the shield - Serial.print it out at 9600 baud to serial monitor. + Serial.print it out at 115200 baud to serial monitor. */ #include @@ -26,7 +26,7 @@ BNO080 myIMU; void setup() { - Serial.begin(9600); + Serial.begin(115200); Serial.println(); Serial.println("BNO080 Read Example"); @@ -34,7 +34,7 @@ void setup() //The first argument is the I2C address of the sensor, either 0x4B (default) or 0x4A //The second is the I2C port to use. Wire, Wire1, softWire, etc. - myIMU.begin(0x4A, Wire1); + myIMU.begin(0x4A, Wire1); Wire1.setClock(400000); //Increase I2C data rate to 400kHz diff --git a/examples/Example12-LinearAccelerometer/Example12-LinearAccelerometer.ino b/examples/Example12-LinearAccelerometer/Example12-LinearAccelerometer.ino index 90b8fd0..0896281 100644 --- a/examples/Example12-LinearAccelerometer/Example12-LinearAccelerometer.ino +++ b/examples/Example12-LinearAccelerometer/Example12-LinearAccelerometer.ino @@ -13,7 +13,7 @@ Hardware Connections: Attach the Qwiic Shield to your Arduino/Photon/ESP32 or other Plug the sensor onto the shield - Serial.print it out at 9600 baud to serial monitor. + Serial.print it out at 115200 baud to serial monitor. */ #include @@ -23,7 +23,7 @@ BNO080 myIMU; void setup() { - Serial.begin(9600); + Serial.begin(115200); Serial.println(); Serial.println("BNO080 Read Example"); diff --git a/examples/Example13-TimeStamp/Example13-TimeStamp.ino b/examples/Example13-TimeStamp/Example13-TimeStamp.ino index 0d7e4a9..06e8d12 100644 --- a/examples/Example13-TimeStamp/Example13-TimeStamp.ino +++ b/examples/Example13-TimeStamp/Example13-TimeStamp.ino @@ -16,7 +16,7 @@ Hardware Connections: Attach the Qwiic Shield to your Arduino/Photon/ESP32 or other Plug the sensor onto the shield - Serial.print it out at 9600 baud to serial monitor. + Serial.print it out at 115200 baud to serial monitor. */ #include @@ -26,7 +26,7 @@ BNO080 myIMU; void setup() { - Serial.begin(9600); + Serial.begin(115200); Serial.println(); Serial.println("BNO080 Read Example"); diff --git a/examples/Example14-TwoSensors/Example14-TwoSensors.ino b/examples/Example14-TwoSensors/Example14-TwoSensors.ino index e456289..768f433 100644 --- a/examples/Example14-TwoSensors/Example14-TwoSensors.ino +++ b/examples/Example14-TwoSensors/Example14-TwoSensors.ino @@ -17,7 +17,7 @@ Hardware Connections: Attach the Qwiic Shield to your Arduino/Photon/ESP32 or other Plug the sensor onto the shield - Serial.print it out at 9600 baud to serial monitor. + Serial.print it out at 115200 baud to serial monitor. */ #include @@ -28,7 +28,7 @@ BNO080 myIMU2; //Closed I2C ADR jumper - goes to address 0x4A void setup() { - Serial.begin(9600); + Serial.begin(115200); Serial.println(); Serial.println("BNO080 Read Example"); diff --git a/examples/Example15-RawReadings/Example15-RawReadings.ino b/examples/Example15-RawReadings/Example15-RawReadings.ino index 48955ef..1d0c0de 100644 --- a/examples/Example15-RawReadings/Example15-RawReadings.ino +++ b/examples/Example15-RawReadings/Example15-RawReadings.ino @@ -13,7 +13,7 @@ Hardware Connections: Attach the Qwiic Shield to your Arduino/Photon/ESP32 or other Plug the sensor onto the shield - Serial.print it out at 9600 baud to serial monitor. + Serial.print it out at 115200 baud to serial monitor. */ #include @@ -23,7 +23,7 @@ BNO080 myIMU; void setup() { - Serial.begin(9600); + Serial.begin(115200); Serial.println(); Serial.println("BNO080 Read Example"); @@ -84,4 +84,4 @@ void loop() Serial.println(); } -} \ No newline at end of file +} diff --git a/examples/Example17-EulerAngles/Example17-EulerAngles.ino b/examples/Example17-EulerAngles/Example17-EulerAngles.ino new file mode 100644 index 0000000..deeba06 --- /dev/null +++ b/examples/Example17-EulerAngles/Example17-EulerAngles.ino @@ -0,0 +1,86 @@ +/* + Using the BNO080 IMU + + Example : Euler Angles + By: Paul Clark + Date: April 28th, 2020 + + Based on: Example1-RotationVector + By: Nathan Seidle + SparkFun Electronics + Date: December 21st, 2017 + License: This code is public domain but you buy me a beer if you use this and we meet someday (Beerware license). + + Feel like supporting our work? Buy a board from SparkFun! + https://www.sparkfun.com/products/14586 + + This example shows how to output the Euler angles: roll, pitch and yaw. + The yaw (compass heading) is tilt-compensated, which is nice. + https://en.wikipedia.org/wiki/Conversion_between_quaternions_and_Euler_angles + https://github.com/sparkfun/SparkFun_MPU-9250-DMP_Arduino_Library/issues/5#issuecomment-306509440 + + It takes about 1ms at 400kHz I2C to read a record from the sensor, but we are polling the sensor continually + between updates from the sensor. Use the interrupt pin on the BNO080 breakout to avoid polling. + + Hardware Connections: + Attach the Qwiic Shield to your Arduino/Photon/ESP32 or other + Plug the sensor onto the shield + Serial.print it out at 115200 baud to serial monitor. +*/ + +#include + +#include "SparkFun_BNO080_Arduino_Library.h" +BNO080 myIMU; + +void setup() +{ + Serial.begin(115200); + Serial.println(); + Serial.println("BNO080 Read Example"); + + Wire.begin(); + + //Are you using a ESP? Check this issue for more information: https://github.com/sparkfun/SparkFun_BNO080_Arduino_Library/issues/16 +// //================================= +// delay(100); // Wait for BNO to boot +// // Start i2c and BNO080 +// Wire.flush(); // Reset I2C +// IMU.begin(BNO080_DEFAULT_ADDRESS, Wire); +// Wire.begin(4, 5); +// Wire.setClockStretchLimit(4000); +// //================================= + + if (myIMU.begin() == false) + { + Serial.println(F("BNO080 not detected at default I2C address. Check your jumpers and the hookup guide. Freezing...")); + while (1) + ; + } + + Wire.setClock(400000); //Increase I2C data rate to 400kHz + + myIMU.enableRotationVector(50); //Send data update every 50ms + + Serial.println(F("Rotation vector enabled")); + Serial.println(F("Output in form roll, pitch, yaw")); +} + +void loop() +{ + //Look for reports from the IMU + if (myIMU.dataAvailable() == true) + { + float roll = (myIMU.getRoll()) * 180.0 / PI; // Convert roll to degrees + float pitch = (myIMU.getPitch()) * 180.0 / PI; // Convert pitch to degrees + float yaw = (myIMU.getYaw()) * 180.0 / PI; // Convert yaw / heading to degrees + + Serial.print(roll, 1); + Serial.print(F(",")); + Serial.print(pitch, 1); + Serial.print(F(",")); + Serial.print(yaw, 1); + + Serial.println(); + } +} diff --git a/examples/Example2-Accelerometer/Example2-Accelerometer.ino b/examples/Example2-Accelerometer/Example2-Accelerometer.ino index 2a64c7e..738b321 100644 --- a/examples/Example2-Accelerometer/Example2-Accelerometer.ino +++ b/examples/Example2-Accelerometer/Example2-Accelerometer.ino @@ -13,7 +13,7 @@ Hardware Connections: Attach the Qwiic Shield to your Arduino/Photon/ESP32 or other Plug the sensor onto the shield - Serial.print it out at 9600 baud to serial monitor. + Serial.print it out at 115200 baud to serial monitor. */ #include @@ -23,7 +23,7 @@ BNO080 myIMU; void setup() { - Serial.begin(9600); + Serial.begin(115200); Serial.println(); Serial.println("BNO080 Read Example"); diff --git a/examples/Example3-Gyro/Example3-Gyro.ino b/examples/Example3-Gyro/Example3-Gyro.ino index 2557ab6..420df94 100644 --- a/examples/Example3-Gyro/Example3-Gyro.ino +++ b/examples/Example3-Gyro/Example3-Gyro.ino @@ -16,7 +16,7 @@ Hardware Connections: Attach the Qwiic Shield to your Arduino/Photon/ESP32 or other Plug the sensor onto the shield - Serial.print it out at 9600 baud to serial monitor. + Serial.print it out at 115200 baud to serial monitor. */ #include @@ -26,7 +26,7 @@ BNO080 myIMU; void setup() { - Serial.begin(9600); + Serial.begin(115200); Serial.println(); Serial.println("BNO080 Read Example"); diff --git a/examples/Example4-Magnetometer/Example4-Magnetometer.ino b/examples/Example4-Magnetometer/Example4-Magnetometer.ino index 3905b7e..64bacac 100644 --- a/examples/Example4-Magnetometer/Example4-Magnetometer.ino +++ b/examples/Example4-Magnetometer/Example4-Magnetometer.ino @@ -16,7 +16,7 @@ Hardware Connections: Attach the Qwiic Shield to your Arduino/Photon/ESP32 or other Plug the sensor onto the shield - Serial.print it out at 9600 baud to serial monitor. + Serial.print it out at 115200 baud to serial monitor. */ #include @@ -26,7 +26,7 @@ BNO080 myIMU; void setup() { - Serial.begin(9600); + Serial.begin(115200); Serial.println(); Serial.println("BNO080 Read Example"); diff --git a/examples/Example5-StepCounter/Example5-StepCounter.ino b/examples/Example5-StepCounter/Example5-StepCounter.ino index 664f92c..3a83b03 100644 --- a/examples/Example5-StepCounter/Example5-StepCounter.ino +++ b/examples/Example5-StepCounter/Example5-StepCounter.ino @@ -16,7 +16,7 @@ Hardware Connections: Attach the Qwiic Shield to your Arduino/Photon/ESP32 or other Plug the sensor onto the shield - Serial.print it out at 9600 baud to serial monitor. + Serial.print it out at 115200 baud to serial monitor. */ #include @@ -26,7 +26,7 @@ BNO080 myIMU; void setup() { - Serial.begin(9600); + Serial.begin(115200); Serial.println(); Serial.println("BNO080 Read Example"); diff --git a/examples/Example6-MetaData/Example6-MetaData.ino b/examples/Example6-MetaData/Example6-MetaData.ino index 85b20e4..01e9a29 100644 --- a/examples/Example6-MetaData/Example6-MetaData.ino +++ b/examples/Example6-MetaData/Example6-MetaData.ino @@ -16,7 +16,7 @@ Hardware Connections: Attach the Qwiic Shield to your Arduino/Photon/ESP32 or other Plug the sensor onto the shield - Serial.print it out at 9600 baud to serial monitor. + Serial.print it out at 115200 baud to serial monitor. */ #include @@ -26,7 +26,7 @@ BNO080 myIMU; void setup() { - Serial.begin(9600); + Serial.begin(115200); Serial.println(); Serial.println("BNO080 Reading Metadata Example"); diff --git a/examples/Example7-StabilityClassifier/Example7-StabilityClassifier.ino b/examples/Example7-StabilityClassifier/Example7-StabilityClassifier.ino index 6803ad9..c02f52c 100644 --- a/examples/Example7-StabilityClassifier/Example7-StabilityClassifier.ino +++ b/examples/Example7-StabilityClassifier/Example7-StabilityClassifier.ino @@ -17,7 +17,7 @@ Hardware Connections: Attach the Qwiic Shield to your Arduino/Photon/ESP32 or other Plug the sensor onto the shield - Serial.print it out at 9600 baud to serial monitor. + Serial.print it out at 115200 baud to serial monitor. */ #include @@ -27,7 +27,7 @@ BNO080 myIMU; void setup() { - Serial.begin(9600); + Serial.begin(115200); Serial.println(); Serial.println("BNO080 Read Example"); diff --git a/examples/Example8-ActivityClassifier/Example8-ActivityClassifier.ino b/examples/Example8-ActivityClassifier/Example8-ActivityClassifier.ino index 55c0546..cd45d0a 100644 --- a/examples/Example8-ActivityClassifier/Example8-ActivityClassifier.ino +++ b/examples/Example8-ActivityClassifier/Example8-ActivityClassifier.ino @@ -25,7 +25,7 @@ Hardware Connections: Attach the Qwiic Shield to your Arduino/Photon/ESP32 or other Plug the sensor onto the shield - Serial.print it out at 9600 baud to serial monitor. + Serial.print it out at 115200 baud to serial monitor. */ #include @@ -37,7 +37,7 @@ byte activityConfidences[9]; //This array will be filled with the confidence lev void setup() { - Serial.begin(9600); + Serial.begin(115200); Serial.println(); Serial.println("BNO080 Read Example"); @@ -54,7 +54,7 @@ void setup() //Send data update every 50ms, with sensor specific config word //Pass in a pointer to our activityConfidences array as well - myIMU.enableActivityClassifier(50, enableActivities, activityConfidences); + myIMU.enableActivityClassifier(50, enableActivities, activityConfidences); Serial.println(F("Activity Classifier enabled")); } @@ -66,7 +66,7 @@ void loop() { //getActivityClassifier will modify our activityConfidences array //It will return the most likely activity as well. - byte mostLikelyActivity = myIMU.getActivityClassifier(); + byte mostLikelyActivity = myIMU.getActivityClassifier(); Serial.print("Most likely activity: "); printActivityName(mostLikelyActivity); diff --git a/examples/Example9-Calibrate/Example9-Calibrate.ino b/examples/Example9-Calibrate/Example9-Calibrate.ino index 5b671a2..29b5f06 100644 --- a/examples/Example9-Calibrate/Example9-Calibrate.ino +++ b/examples/Example9-Calibrate/Example9-Calibrate.ino @@ -16,7 +16,7 @@ Hardware Connections: Attach the Qwiic Shield to your Arduino/Photon/ESP32 or other Plug the sensor onto the shield - Serial.print it out at 9600 baud to serial monitor. + Serial.print it out at 115200 baud to serial monitor. */ #include @@ -26,7 +26,7 @@ BNO080 myIMU; void setup() { - Serial.begin(9600); + Serial.begin(115200); Serial.println(); Serial.println("BNO080 Read Example"); @@ -84,7 +84,7 @@ void loop() { Serial.println("Calibration data failed to store. Please try again."); } - + //myIMU.endCalibration(); //Turns off all calibration //In general, calibration should be left on at all times. The BNO080 //auto-calibrates and auto-records cal data roughly every 5 minutes diff --git a/examples/SPI/Example12-LinearAccelerometer/Example12-LinearAccelerometer.ino b/examples/SPI/Example12-LinearAccelerometer/Example12-LinearAccelerometer.ino index 104ea07..ac67042 100644 --- a/examples/SPI/Example12-LinearAccelerometer/Example12-LinearAccelerometer.ino +++ b/examples/SPI/Example12-LinearAccelerometer/Example12-LinearAccelerometer.ino @@ -13,7 +13,7 @@ Hardware Connections: Attach the Qwiic Shield to your Arduino/Photon/ESP32 or other Plug the sensor onto the shield - Serial.print it out at 9600 baud to serial monitor. + Serial.print it out at 115200 baud to serial monitor. */ #include @@ -29,7 +29,7 @@ byte imuRSTPin = 7; void setup() { - Serial.begin(9600); + Serial.begin(115200); Serial.println(); Serial.println("BNO080 Read Example"); @@ -63,4 +63,3 @@ void loop() Serial.println(); } } - diff --git a/examples/SPI/Example17-EulerAngles/Example17-EulerAngles.ino b/examples/SPI/Example17-EulerAngles/Example17-EulerAngles.ino new file mode 100644 index 0000000..251dbe6 --- /dev/null +++ b/examples/SPI/Example17-EulerAngles/Example17-EulerAngles.ino @@ -0,0 +1,105 @@ +/* + Using the BNO080 IMU + + Example : Euler Angles + By: Paul Clark + Date: April 28th, 2020 + + Based on: Example1-RotationVector + By: Nathan Seidle + SparkFun Electronics + Date: July 27th, 2018 + License: This code is public domain but you buy me a beer if you use this and we meet someday (Beerware license). + + Feel like supporting our work? Buy a board from SparkFun! + https://www.sparkfun.com/products/14686 + + This example shows how to output the Euler angles: roll, pitch and yaw. + The yaw (compass heading) is tilt-compensated, which is nice. + https://en.wikipedia.org/wiki/Conversion_between_quaternions_and_Euler_angles + https://github.com/sparkfun/SparkFun_MPU-9250-DMP_Arduino_Library/issues/5#issuecomment-306509440 + + This example shows how to use the SPI interface on the BNO080. It's fairly involved + and requires 7 comm wires (plus 2 power), soldering the PS1 jumper, and clearing + the I2C jumper. We recommend using the Qwiic I2C interface, but if you need speed + SPI is the way to go. + + Hardware modifications: + The PS1 jumper must be closed + The PS0 jumper must be open. PS0/WAKE is connected and the WAK pin is used to bring the IC out of sleep. + The I2C pull up jumper must be cleared/open + + Hardware Connections: + Don't hook the BNO080 to a normal 5V Uno! Either use the Qwiic system or use a + microcontroller that runs at 3.3V. + Arduino 13 = BNO080 SCK + 12 = SO + 11 = SI + 10 = !CS + 9 = WAK + 8 = !INT + 7 = !RST + 3.3V = 3V3 + GND = GND +*/ + +#include + +#include "SparkFun_BNO080_Arduino_Library.h" +BNO080 myIMU; + +//These pins can be any GPIO +byte imuCSPin = 10; +byte imuWAKPin = 9; +byte imuINTPin = 8; +byte imuRSTPin = 7; + +void setup() +{ + Serial.begin(115200); + Serial.println(); + Serial.println(F("BNO080 SPI Read Example")); + + myIMU.enableDebugging(Serial); //Pipe debug messages to Serial port + + if(myIMU.beginSPI(imuCSPin, imuWAKPin, imuINTPin, imuRSTPin) == false) + { + Serial.println(F("BNO080 over SPI not detected. Are you sure you have all 6 connections? Freezing...")); + while(1) + ; + } + + //You can also call begin with SPI clock speed and SPI port hardware + //myIMU.beginSPI(imuCSPin, imuWAKPin, imuINTPin, imuRSTPin, 1000000); + //myIMU.beginSPI(imuCSPin, imuWAKPin, imuINTPin, imuRSTPin, 1000000, SPI1); + + //The IMU is now connected over SPI + //Please see the other examples for library functions that you can call + + myIMU.enableRotationVector(50); //Send data update every 50ms + + Serial.println(F("Rotation vector enabled")); + Serial.println(F("Output in form roll, pitch, yaw")); +} + +void loop() +{ + delay(10); //You can do many other things. We spend most of our time printing and delaying. + + //Look for reports from the IMU + if (myIMU.dataAvailable() == true) + { + float roll = (myIMU.getRoll()) * 180.0 / PI; // Convert roll to degrees + float pitch = (myIMU.getPitch()) * 180.0 / PI; // Convert pitch to degrees + float yaw = (myIMU.getYaw()) * 180.0 / PI; // Convert yaw / heading to degrees + + Serial.print(roll, 1); + Serial.print(F(",")); + Serial.print(pitch, 1); + Serial.print(F(",")); + Serial.print(yaw, 1); + + Serial.println(); + } + +} diff --git a/keywords.txt b/keywords.txt index 17b52d8..06e022c 100644 --- a/keywords.txt +++ b/keywords.txt @@ -1,5 +1,5 @@ ####################################### -# Syntax Coloring Map +# Syntax Coloring Map ####################################### ####################################### @@ -115,6 +115,10 @@ getRawMagX KEYWORD2 getRawMagY KEYWORD2 getRawMagZ KEYWORD2 +getRoll KEYWORD2 +getPitch KEYWORD2 +getYaw KEYWORD2 + ####################################### # Constants (LITERAL1) diff --git a/src/SparkFun_BNO080_Arduino_Library.cpp b/src/SparkFun_BNO080_Arduino_Library.cpp index c706996..04dc99f 100644 --- a/src/SparkFun_BNO080_Arduino_Library.cpp +++ b/src/SparkFun_BNO080_Arduino_Library.cpp @@ -341,6 +341,82 @@ void BNO080::parseInputReport(void) //TODO additional feature reports may be strung together. Parse them all. } +// Quaternion to Euler conversion +// https://en.wikipedia.org/wiki/Conversion_between_quaternions_and_Euler_angles +// https://github.com/sparkfun/SparkFun_MPU-9250-DMP_Arduino_Library/issues/5#issuecomment-306509440 +// Return the roll (rotation around the x-axis) in Radians +float BNO080::getRoll() +{ + float dqw = getQuatReal(); + float dqx = getQuatI(); + float dqy = getQuatJ(); + float dqz = getQuatK(); + + float norm = sqrt(dqw*dqw + dqx*dqx + dqy*dqy + dqz*dqz); + dqw = dqw/norm; + dqx = dqx/norm; + dqy = dqy/norm; + dqz = dqz/norm; + + float ysqr = dqy * dqy; + + // roll (x-axis rotation) + float t0 = +2.0 * (dqw * dqx + dqy * dqz); + float t1 = +1.0 - 2.0 * (dqx * dqx + ysqr); + float roll = atan2(t0, t1); + + return (roll); +} + +// Return the pitch (rotation around the y-axis) in Radians +float BNO080::getPitch() +{ + float dqw = getQuatReal(); + float dqx = getQuatI(); + float dqy = getQuatJ(); + float dqz = getQuatK(); + + float norm = sqrt(dqw*dqw + dqx*dqx + dqy*dqy + dqz*dqz); + dqw = dqw/norm; + dqx = dqx/norm; + dqy = dqy/norm; + dqz = dqz/norm; + + float ysqr = dqy * dqy; + + // pitch (y-axis rotation) + float t2 = +2.0 * (dqw * dqy - dqz * dqx); + t2 = t2 > 1.0 ? 1.0 : t2; + t2 = t2 < -1.0 ? -1.0 : t2; + float pitch = asin(t2); + + return (pitch); +} + +// Return the yaw / heading (rotation around the z-axis) in Radians +float BNO080::getYaw() +{ + float dqw = getQuatReal(); + float dqx = getQuatI(); + float dqy = getQuatJ(); + float dqz = getQuatK(); + + float norm = sqrt(dqw*dqw + dqx*dqx + dqy*dqy + dqz*dqz); + dqw = dqw/norm; + dqx = dqx/norm; + dqy = dqy/norm; + dqz = dqz/norm; + + float ysqr = dqy * dqy; + + // yaw (z-axis rotation) + float t3 = +2.0 * (dqw * dqz + dqx * dqy); + float t4 = +1.0 - 2.0 * (ysqr + dqz * dqz); + float yaw = atan2(t3, t4); + + return (yaw); +} + //Return the rotation vector quaternion I float BNO080::getQuatI() { diff --git a/src/SparkFun_BNO080_Arduino_Library.h b/src/SparkFun_BNO080_Arduino_Library.h index 5627532..2de5306 100644 --- a/src/SparkFun_BNO080_Arduino_Library.h +++ b/src/SparkFun_BNO080_Arduino_Library.h @@ -215,6 +215,10 @@ class BNO080 int16_t getRawMagY(); int16_t getRawMagZ(); + float getRoll(); + float getPitch(); + float getYaw(); + void setFeatureCommand(uint8_t reportID, uint16_t timeBetweenReports); void setFeatureCommand(uint8_t reportID, uint16_t timeBetweenReports, uint32_t specificConfig); void sendCommand(uint8_t command);