pressure16 2.0.0.0
|
API for configuring and manipulating Pressure 16 Click driver. More...
Topics | |
Pressure 16 Registers List | |
List of registers of Pressure 16 Click driver. | |
Pressure 16 Registers Settings | |
Settings for registers of Pressure 16 Click driver. | |
Pressure 16 MikroBUS Map | |
MikroBUS pin mapping of Pressure 16 Click driver. | |
Functions | |
void | pressure16_cfg_setup (pressure16_cfg_t *cfg) |
Pressure 16 configuration object setup function. | |
void | pressure16_drv_interface_selection (pressure16_cfg_t *cfg, pressure16_drv_t drv_sel) |
Pressure 16 driver interface setup function. | |
err_t | pressure16_init (pressure16_t *ctx, pressure16_cfg_t *cfg) |
Pressure 16 initialization function. | |
err_t | pressure16_default_cfg (pressure16_t *ctx) |
Pressure 16 default configuration function. | |
err_t | pressure16_generic_write (pressure16_t *ctx, uint8_t reg, uint8_t *data_in, uint8_t len) |
Pressure 16 data writing function. | |
err_t | pressure16_generic_read (pressure16_t *ctx, uint8_t reg, uint8_t *data_out, uint8_t len) |
Pressure 16 data reading function. | |
err_t | pressure16_get_device_id (pressure16_t *ctx, uint8_t *dev_id) |
Pressure 16 get device ID function. | |
err_t | pressure16_sw_reset (pressure16_t *ctx) |
Pressure 16 software reset function. | |
err_t | pressure16_set_interrupt_config (pressure16_t *ctx, pressure16_int_cfg_t int_cfg_data) |
Pressure 16 set interrupt configuration function. | |
err_t | pressure16_get_interrupt_config (pressure16_t *ctx, pressure16_int_cfg_t *int_cfg_data) |
Pressure 16 get interrupt configuration function. | |
err_t | pressure16_set_ctrl_config (pressure16_t *ctx, pressure16_ctrl_cfg_t ctrl_cfg_data) |
Pressure 16 set control configuration function. | |
err_t | pressure16_get_ctrl_config (pressure16_t *ctx, pressure16_ctrl_cfg_t *ctrl_cfg_data) |
Pressure 16 get control configuration function. | |
err_t | pressure16_get_pressure (pressure16_t *ctx, float *pressure) |
Pressure 16 get pressure function. | |
err_t | pressure16_get_temperature (pressure16_t *ctx, float *temperature) |
Pressure 16 get temperature function. | |
err_t | pressure16_get_press_temp (pressure16_t *ctx, float *pressure, float *temperature) |
Pressure 16 get pressure and temperature function. | |
uint8_t | pressure16_get_interrupt (pressure16_t *ctx) |
Pressure 16 get interrupt function. | |
API for configuring and manipulating Pressure 16 Click driver.
Any initialization code needed for MCU to function properly. Do not remove this line or clock might not be set correctly.
void pressure16_cfg_setup | ( | pressure16_cfg_t * | cfg | ) |
Pressure 16 configuration object setup function.
This function initializes click configuration structure to initial values.
[out] | cfg | : Click configuration structure. See pressure16_cfg_t object definition for detailed explanation. |
err_t pressure16_default_cfg | ( | pressure16_t * | ctx | ) |
Pressure 16 default configuration function.
This function executes a default configuration of Pressure 16 click board.
[in] | ctx | : Click context object. See pressure16_t object definition for detailed explanation. |
0
- Success, -1
- Error.void pressure16_drv_interface_selection | ( | pressure16_cfg_t * | cfg, |
pressure16_drv_t | drv_sel ) |
Pressure 16 driver interface setup function.
This function sets a serial driver interface which will be used further in the click driver.
[out] | cfg | : Click configuration structure. See pressure16_cfg_t object definition for detailed explanation. |
[in] | drv_sel | : Driver interface selection. See pressure16_drv_t object definition for detailed explanation. |
err_t pressure16_generic_read | ( | pressure16_t * | ctx, |
uint8_t | reg, | ||
uint8_t * | data_out, | ||
uint8_t | len ) |
Pressure 16 data reading function.
This function reads a desired number of data bytes starting from the selected register.
[in] | ctx | : Click context object. See pressure16_t object definition for detailed explanation. |
[in] | reg | : Start register address. |
[out] | data_out | : Output read data. |
[in] | len | : Number of bytes to be read. |
0
- Success, -1
- Error.err_t pressure16_generic_write | ( | pressure16_t * | ctx, |
uint8_t | reg, | ||
uint8_t * | data_in, | ||
uint8_t | len ) |
Pressure 16 data writing function.
This function writes a desired number of data bytes starting from the selected register.
[in] | ctx | : Click context object. See pressure16_t object definition for detailed explanation. |
[in] | reg | : Start register address. |
[in] | data_in | : Data to be written. |
[in] | len | : Number of bytes to be written. |
0
- Success, -1
- Error.err_t pressure16_get_ctrl_config | ( | pressure16_t * | ctx, |
pressure16_ctrl_cfg_t * | ctrl_cfg_data ) |
Pressure 16 get control configuration function.
This function get control configuration of the WSEN-PADS Absolute Pressure Sensor on the Pressure 16 Click board™.
[in] | ctx | : Click context object. See pressure16_t object definition for detailed explanation. |
[out] | ctrl_cfg_data | : Control configuration object. |
0
- Success, -1
- Error.err_t pressure16_get_device_id | ( | pressure16_t * | ctx, |
uint8_t * | dev_id ) |
Pressure 16 get device ID function.
This function reads a device ID from PRESSURE16_REG_DEVICE_ID register address of the WSEN-PADS Absolute Pressure Sensor on the Pressure 16 Click board™.
[in] | ctx | : Click context object. See pressure16_t object definition for detailed explanation. |
[out] | dev_id | : Device ID. |
0
- Success, -1
- Error.uint8_t pressure16_get_interrupt | ( | pressure16_t * | ctx | ) |
Pressure 16 get interrupt function.
This function get interrupt state of the WSEN-PADS Absolute Pressure Sensor on the Pressure 16 Click board™.
[in] | ctx | : Click context object. See pressure16_t object definition for detailed explanation. |
See #err_t definition for detailed explanation.
err_t pressure16_get_interrupt_config | ( | pressure16_t * | ctx, |
pressure16_int_cfg_t * | int_cfg_data ) |
Pressure 16 get interrupt configuration function.
This function get interrupt configuration of the WSEN-PADS Absolute Pressure Sensor on the Pressure 16 Click board™.
[in] | ctx | : Click context object. See pressure16_t object definition for detailed explanation. |
[out] | int_cfg_data | : Interrupt configuration object. |
0
- Success, -1
- Error.err_t pressure16_get_press_temp | ( | pressure16_t * | ctx, |
float * | pressure, | ||
float * | temperature ) |
Pressure 16 get pressure and temperature function.
This function get pressure and temperature data of the WSEN-PADS Absolute Pressure Sensor on the Pressure 16 Click board™.
[in] | ctx | : Click context object. See pressure16_t object definition for detailed explanation. |
[out] | pressure | : Pressure data [ mbar ]. |
[out] | temperature | : Temperature data [ degree Celsius ]. |
0
- Success, -1
- Error.err_t pressure16_get_pressure | ( | pressure16_t * | ctx, |
float * | pressure ) |
Pressure 16 get pressure function.
This function get pressure data of the WSEN-PADS Absolute Pressure Sensor on the Pressure 16 Click board™.
[in] | ctx | : Click context object. See pressure16_t object definition for detailed explanation. |
[out] | pressure | : Pressure data [ mbar ]. |
0
- Success, -1
- Error.err_t pressure16_get_temperature | ( | pressure16_t * | ctx, |
float * | temperature ) |
Pressure 16 get temperature function.
This function get temperature data of the WSEN-PADS Absolute Pressure Sensor on the Pressure 16 Click board™.
[in] | ctx | : Click context object. See pressure16_t object definition for detailed explanation. |
[out] | temperature | : Temperature data [ degree Celsius ]. |
0
- Success, -1
- Error.err_t pressure16_init | ( | pressure16_t * | ctx, |
pressure16_cfg_t * | cfg ) |
Pressure 16 initialization function.
This function initializes all necessary pins and peripherals used for this click board.
[out] | ctx | : Click context object. See pressure16_t object definition for detailed explanation. |
[in] | cfg | : Click configuration structure. See pressure16_cfg_t object definition for detailed explanation. |
0
- Success, -1
- Error.err_t pressure16_set_ctrl_config | ( | pressure16_t * | ctx, |
pressure16_ctrl_cfg_t | ctrl_cfg_data ) |
Pressure 16 set control configuration function.
This function set control configuration of the WSEN-PADS Absolute Pressure Sensor on the Pressure 16 Click board™.
[in] | ctx | : Click context object. See pressure16_t object definition for detailed explanation. |
[in] | ctrl_cfg_data | : Control configuration object. |
0
- Success, -1
- Error.err_t pressure16_set_interrupt_config | ( | pressure16_t * | ctx, |
pressure16_int_cfg_t | int_cfg_data ) |
Pressure 16 set interrupt configuration function.
This function set interrupt configuration of the WSEN-PADS Absolute Pressure Sensor on the Pressure 16 Click board™.
[in] | ctx | : Click context object. See pressure16_t object definition for detailed explanation. |
[in] | int_cfg_data | : Interrupt configuration object. |
0
- Success, -1
- Error.err_t pressure16_sw_reset | ( | pressure16_t * | ctx | ) |
Pressure 16 software reset function.
This function performs a software reset of the WSEN-PADS Absolute Pressure Sensor on the Pressure 16 Click board™.
[in] | ctx | : Click context object. See pressure16_t object definition for detailed explanation. |
0
- Success, -1
- Error.