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.
Dependents: iBeacon acnsensa acnSENSA
Fork of ACD52832_LSM9DS1 by
Diff: LSM9DS1.cpp
- Revision:
- 2:4a4b17ad577e
- Parent:
- 1:45447b012eea
- Child:
- 3:d4f9aaab3bc3
--- a/LSM9DS1.cpp Fri Sep 23 12:15:01 2016 +0000
+++ b/LSM9DS1.cpp Wed Mar 08 13:35:56 2017 +0000
@@ -17,7 +17,7 @@
_i2c.write(TWI_MAG_ADDR, data, 0x02,0);
data[0] = (char)CTRL_REG2_M; // Target register
- data[1] = (char)0x00; // Data to write
+ data[1] = (char)0x00; // Full scale for the sensor (+-4g)
_i2c.write(TWI_MAG_ADDR, data, 0x02,0);
data[0] = (char)CTRL_REG3_M; // Target register
@@ -58,7 +58,7 @@
data[0] = (char)CTRL_REG6_XL; // Target register
- data[1] = (char)0xC7; // Data to write
+ data[1] = (char)0xC7; // +-2g -> See reference manual for more info (page 52)
_i2c.write(TWI_AG_ADDR, data, 0x02,0);
}
@@ -86,7 +86,7 @@
_i2c.write(TWI_AG_ADDR, data, 0x02,0);
data[0] = (char)CTRL_REG1_G; // Target register
- data[1] = (char)0xC0; // Data to write
+ data[1] = (char)0xC0; // 245 DPS scale
_i2c.write(TWI_AG_ADDR, data, 0x02,0);
