Important changes to repositories hosted on mbed.com
Mbed hosted mercurial repositories are deprecated and are due to be permanently deleted in July 2026.
To keep a copy of this software download the repository Zip archive or clone locally using Mercurial.
It is also possible to export all your personal repositories from the account settings page.
Fork of BNO055_fusion by
Diff: BNO055.cpp
- Revision:
- 2:0f225b686cd5
- Parent:
- 1:cb7e19c0a702
- Child:
- 3:0ad6f85b178f
--- a/BNO055.cpp Tue Apr 07 12:03:58 2015 +0000
+++ b/BNO055.cpp Wed Apr 08 11:27:57 2015 +0000
@@ -7,7 +7,7 @@
* http://www.page.sannet.ne.jp/kenjia/index.html
* http://mbed.org/users/kenjiArai/
* Created: March 30th, 2015
- * Revised: April 7th, 2015
+ * Revised: April 8th, 2015
*
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
* INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE
@@ -306,7 +306,7 @@
}
/////////////// Check chip ready or not //////////////////
-uint8_t BNO055::chip_ready()
+uint8_t BNO055::chip_ready(void)
{
if (ready_flg == 0x0f) {
return 1;
@@ -314,6 +314,16 @@
return 0;
}
+/////////////// Read Calibration status //////////////////
+uint8_t BNO055::read_calib_status(void)
+{
+ select_page(0);
+ dt[0] = BNO055_CALIB_STAT;
+ _i2c.write(chip_addr, dt, 1, true);
+ _i2c.read(chip_addr, dt, 1, false);
+ return dt[0];
+}
+
/////////////// Change Fusion mode ///////////////////////
void BNO055::change_fusion_mode(uint8_t mode)
{
