Read / Write data to the given register address.
Read / Write data to the given register address.
bmp3_set_regs
int8_t
bmp3_set_regs(uint8_t *reg_addr,
const uint8_t *reg_data, uint8_t len,
const struct bmp3_dev *dev);
int8_t bmp3_set_regs(uint8_t *reg_addr, const uint8_t *reg_data, uint32_t len, struct bmp3_dev *dev)
This API writes the given data to the register address of the sensor.
This API writes the given data to the register address of the sensor.
- Parameters
-
| [in] | reg_addr | : Register address to where the data to be written. |
| [in] | reg_data | : Pointer to data buffer which is to be written in the sensor. |
| [in] | len | : No. of bytes of data to write. |
| [in] | dev | : Structure instance of bmp3_dev. |
- Returns
- Result of API execution status
- Return values
-
| 0 | -> Success |
| >0 | -> Warning |
| <0 | -> Error |
bmp3_get_regs
int8_t bmp3_get_regs(uint8_t reg_addr, uint8_t *reg_data, uint32_t len, struct bmp3_dev *dev)
This API reads the data from the given register address of the sensor.
This API reads the data from the given register address of the sensor.
- Parameters
-
| [in] | reg_addr | : Register address from where the data to be read |
| [out] | reg_data | : Pointer to data buffer to store the read data. |
| [in] | len | : No. of bytes of data to be read. |
| [in] | dev | : Structure instance of bmp3_dev. |
- Returns
- Result of API execution status
- Return values
-
| 0 | -> Success |
| >0 | -> Warning |
| <0 | -> Error |