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.
Diff: LIS2DH/LIS2DH.cpp
- Revision:
- 3:a7396ed925e6
- Parent:
- 0:7b5d37ca532f
- Child:
- 5:37a1e69f0f0f
diff -r 17d5a74fc2c4 -r a7396ed925e6 LIS2DH/LIS2DH.cpp
--- a/LIS2DH/LIS2DH.cpp Wed Oct 09 11:31:00 2019 +0000
+++ b/LIS2DH/LIS2DH.cpp Mon Oct 14 09:45:36 2019 +0000
@@ -200,13 +200,15 @@
///
/// set the data rate, enable all axis
///
+ /*
dataRate = dataRate & 0xF;
if (dataRate > 0x9) {
dataRate = 0x9;
}
+ */
ctrl_reg1.bit.ODR = dataRate; ///< set the data rate
- ctrl_reg1.bit.LPen = 0x0; ///< disable low power mode
+ ctrl_reg1.bit.LPen = 0x1; ///< enable low power
ctrl_reg1.bit.Zen = 0x1; ///< enable z
ctrl_reg1.bit.Yen = 0x1; ///< enable y
ctrl_reg1.bit.Xen = 0x1; ///< enable x
