diff options
author | Rocco Marco Guglielmi <roccomarco.guglielmi@live.com> | 2016-09-22 16:01:28 +0000 |
---|---|---|
committer | Rocco Marco Guglielmi <roccomarco.guglielmi@live.com> | 2016-09-22 16:01:28 +0000 |
commit | dd525d05dbf985837da4616ee52ffb1b732df607 (patch) | |
tree | 6e05b97b7c9dde43655f382ecc096ce5abcdb4a5 /os/ex | |
parent | 43972ad3c82a8f2b0c78b1997d81da162d958ce5 (diff) | |
download | ChibiOS-dd525d05dbf985837da4616ee52ffb1b732df607.tar.gz ChibiOS-dd525d05dbf985837da4616ee52ffb1b732df607.tar.bz2 ChibiOS-dd525d05dbf985837da4616ee52ffb1b732df607.zip |
Updated LSM6DS0 driver and related STM32 Nucleo F401RE demo
git-svn-id: svn://svn.code.sf.net/p/chibios/svn/trunk@9770 35acf78f-673a-0410-8e92-d51de3d6d3f4
Diffstat (limited to 'os/ex')
-rw-r--r-- | os/ex/ST/lsm6ds0.c | 4 | ||||
-rw-r--r-- | os/ex/ST/lsm6ds0.h | 4 |
2 files changed, 4 insertions, 4 deletions
diff --git a/os/ex/ST/lsm6ds0.c b/os/ex/ST/lsm6ds0.c index 707c7b90c..17f02b52f 100644 --- a/os/ex/ST/lsm6ds0.c +++ b/os/ex/ST/lsm6ds0.c @@ -75,6 +75,7 @@ typedef enum { uint8_t lsm6ds0I2CReadRegister(I2CDriver *i2cp, lsm6ds0_sad_t sad, uint8_t reg,
msg_t* msgp) {
msg_t msg;
+ uint8_t txbuf = reg;
#if defined(STM32F103_MCUCONF)
uint8_t rxbuf[2];
msg = i2cMasterTransmitTimeout(i2cp, sad, &txbuf, 1, rxbuf, 2,
@@ -84,8 +85,7 @@ uint8_t lsm6ds0I2CReadRegister(I2CDriver *i2cp, lsm6ds0_sad_t sad, uint8_t reg, }
return rxbuf[0];
#else
- uint8_t txbuf, rxbuf;
- txbuf = reg;
+ uint8_t rxbuf;
msg = i2cMasterTransmitTimeout(i2cp, sad, &txbuf, 1, &rxbuf, 1,
TIME_INFINITE);
if(msgp != NULL){
diff --git a/os/ex/ST/lsm6ds0.h b/os/ex/ST/lsm6ds0.h index 34efdcec3..20bef3134 100644 --- a/os/ex/ST/lsm6ds0.h +++ b/os/ex/ST/lsm6ds0.h @@ -41,7 +41,7 @@ /**
* @brief LSM6DS0 driver version string.
*/
-#define EX_LSM6DS0_VERSION "1.0.0"
+#define EX_LSM6DS0_VERSION "1.0.1"
/**
* @brief LSM6DS0 driver version major number.
@@ -56,7 +56,7 @@ /**
* @brief LSM6DS0 driver version patch number.
*/
-#define EX_LSM6DS0_PATCH 0
+#define EX_LSM6DS0_PATCH 1
/** @} */
/**
|