for my students set_m_axes_offset
Dependencies: X_NUCLEO_COMMON ST_INTERFACES
Diff: lis3mdl.h
- Revision:
- 4:00493226e59f
- Parent:
- 0:7376fbeb1d4a
- Child:
- 7:fa19aa1a666d
--- a/lis3mdl.h Mon Oct 02 09:28:58 2017 +0200 +++ b/lis3mdl.h Fri Oct 06 11:48:36 2017 +0000 @@ -250,10 +250,11 @@ #define LIS3MDL_I2C_MULTIPLEBYTE_CMD ((uint8_t)0x80) /** - * @brief Device Address + * @brief I2C Device Address */ - -#define LIS3MDL_M_MEMS_ADDRESS 0x3C // SAD[1] = 1 +//#define LIS3MDL_M_MEMS_ADDRESS 0x3C // SAD[1] = 1 +#define LIS3MDL_M_MEMS_ADDRESS_LOW 0x38 // SAD[1] = 0 +#define LIS3MDL_M_MEMS_ADDRESS_HIGH 0x3C // SAD[1] = 1 /** * @brief Device Identifier. Default value of the WHO_AM_I register. @@ -422,7 +423,7 @@ /* extended features of LSM6DS0. See the example of */ /* LSM6DS3 in lsm6ds3.h */ /* ------------------------------------------------------- */ - +typedef enum { LIS3MDL_SPI_4_WIRE = (uint8_t)0x00, LIS3MDL_SPI_3_WIRE = (uint8_t)0x04} LIS3MDL_SPIMode_t; /** @addtogroup LIS3MDL_Exported_Variables LIS3MDL_Exported_Variables * @{ */