Get / Set sensor settings.
Get / Set sensor settings.
bmp3_set_sensor_settings
int8_t bmp3_set_sensor_settings(uint32_t desired_settings, struct bmp3_settings *settings, struct bmp3_dev *dev)
This API sets the power control(pressure enable and temperature enable), over sampling,...
This API sets the power control(pressure enable and
temperature enable), over sampling, odr and filter settings in the sensor.
- Parameters
-
| [in] | desired_settings | : Variable used to select the settings which are to be set in the sensor. |
| [in] | settings | : Structure instance of bmp3_settings |
| [in] | dev | : Structure instance of bmp3_dev. |
- Note
- : Below are the macros to be used by the user for selecting the desired settings. User can do OR operation of these macros for configuring multiple settings.
* ---------------------|----------------------------------------------
* desired_settings | Functionality
* ---------------------|----------------------------------------------
* BMP3_SEL_PRESS_EN | Enable/Disable pressure.
* BMP3_SEL_TEMP_EN | Enable/Disable temperature.
* BMP3_SEL_PRESS_OS | Set pressure oversampling.
* BMP3_SEL_TEMP_OS | Set temperature oversampling.
* BMP3_SEL_IIR_FILTER | Set IIR filter.
* BMP3_SEL_ODR | Set ODR.
* BMP3_SEL_OUTPUT_MODE | Set either open drain or push pull
* BMP3_SEL_LEVEL | Set interrupt pad to be active high or low
* BMP3_SEL_LATCH | Set interrupt pad to be latched or nonlatched.
* BMP3_SEL_DRDY_EN | Map/Unmap the drdy interrupt to interrupt pad.
* BMP3_SEL_I2C_WDT_EN | Enable/Disable I2C internal watch dog.
* BMP3_SEL_I2C_WDT | Set I2C watch dog timeout delay.
* ---------------------|----------------------------------------------
*
- Returns
- Result of API execution status
- Return values
-
| 0 | -> Success |
| >0 | -> Warning |
| <0 | -> Error |
bmp3_get_sensor_settings
int8_t bmp3_get_sensor_settings(struct bmp3_settings *settings, struct bmp3_dev *dev)
This API gets the power control(power mode, pressure enable and temperature enable),...
This API gets the power control(power mode, pressure enable and
temperature enable), over sampling, odr, filter, interrupt control and advance settings from the sensor.
- Parameters
-
- Returns
- Result of API execution status
- Return values
-
| 0 | -> Success |
| >0 | -> Warning |
| <0 | -> Error |