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: LIS331.cpp
- Revision:
- 5:3443fb9646bd
- Parent:
- 4:c3df518a938e
- Child:
- 6:53e92e7fc073
diff -r c3df518a938e -r 3443fb9646bd LIS331.cpp
--- a/LIS331.cpp Fri Jan 07 16:31:35 2011 +0000
+++ b/LIS331.cpp Fri Jan 07 16:37:00 2011 +0000
@@ -93,34 +93,34 @@
}
-void LIS331:setFullScaleRange8g(void){ // Does not preserve rest of CTRL_REG_4!
+void LIS331::setFullScaleRange8g(void){ // Does not preserve rest of CTRL_REG_4!
char tx[2];
tx[0] = CTRL_REG_4;
tx[1] = 0x30;
- i2c_.write((LIS331_I2C_ADDRESS << 1) & 0xFE, &tx, 2);
+ i2c_.write((LIS331_I2C_ADDRESS << 1) & 0xFE, tx, 2);
}
-void LIS331:setFullScaleRange4g(void){ // Does not preserve rest of CTRL_REG_4!
+void LIS331::setFullScaleRange4g(void){ // Does not preserve rest of CTRL_REG_4!
char tx[2];
tx[0] = CTRL_REG_4;
tx[1] = 0x10;
- i2c_.write((LIS331_I2C_ADDRESS << 1) & 0xFE, &tx, 2);
+ i2c_.write((LIS331_I2C_ADDRESS << 1) & 0xFE, tx, 2);
}
-void LIS331:setFullScaleRange2g(void){ // Does not preserve rest of CTRL_REG_4!
+void LIS331::setFullScaleRange2g(void){ // Does not preserve rest of CTRL_REG_4!
char tx[2];
tx[0] = CTRL_REG_4;
tx[1] = 0x00;
- i2c_.write((LIS331_I2C_ADDRESS << 1) & 0xFE, &tx, 2);
+ i2c_.write((LIS331_I2C_ADDRESS << 1) & 0xFE, tx, 2);
}