ambient9 2.0.0.0
|
Functions | |
void | ambient9_cfg_setup (ambient9_cfg_t *cfg) |
Config Object Initialization function. | |
AMBIENT9_RETVAL | ambient9_init (ambient9_t *ctx, ambient9_cfg_t *cfg) |
Initialization function. | |
void | ambient9_generic_write (ambient9_t *ctx, uint8_t reg, uint8_t *data_buf, uint8_t len) |
Generic write function. | |
void | ambient9_generic_read (ambient9_t *ctx, uint8_t reg, uint8_t *data_buf, uint8_t len) |
Generic read function. | |
uint8_t | ambient9_get_int_status (ambient9_t *ctx) |
Generic function for getting int pin status. | |
uint32_t | ambient9_als_data (ambient9_t *ctx) |
Generic function for reading ALS data from sensor. | |
uint16_t | ambient9_proxy_data (ambient9_t *ctx) |
Generic function for reading proximity data from sensor. | |
void | ambient9_enable_data (ambient9_t *ctx, uint8_t als_ps) |
Function for enabeling sensor for ALS or proximity. | |
uint32_t ambient9_als_data | ( | ambient9_t * | ctx | ) |
Generic function for reading ALS data from sensor.
ctx | Click object. |
void ambient9_cfg_setup | ( | ambient9_cfg_t * | cfg | ) |
Config Object Initialization function.
cfg | Click configuration structure. |
@description This function initializes click configuration structure to init state.
void ambient9_enable_data | ( | ambient9_t * | ctx, |
uint8_t | als_ps ) |
Function for enabeling sensor for ALS or proximity.
ctx | Click object. |
als_ps | Als or proximiy macro |
void ambient9_generic_read | ( | ambient9_t * | ctx, |
uint8_t | reg, | ||
uint8_t * | data_buf, | ||
uint8_t | len ) |
Generic read function.
ctx | Click object. |
reg | Register address. |
data_buf | Output data buf |
len | Number of the bytes to be read |
@description This function reads data from the desired register.
void ambient9_generic_write | ( | ambient9_t * | ctx, |
uint8_t | reg, | ||
uint8_t * | data_buf, | ||
uint8_t | len ) |
Generic write function.
ctx | Click object. |
reg | Register address. |
data_buf | Data buf to be written. |
len | Number of the bytes in data buf. |
@description This function writes data to the desired register.
uint8_t ambient9_get_int_status | ( | ambient9_t * | ctx | ) |
Generic function for getting int pin status.
ctx | Click object. |
AMBIENT9_RETVAL ambient9_init | ( | ambient9_t * | ctx, |
ambient9_cfg_t * | cfg ) |
Initialization function.
ambient9 | Click object. |
cfg | Click configuration structure. |
@description This function initializes all necessary pins and peripherals used for this click.
uint16_t ambient9_proxy_data | ( | ambient9_t * | ctx | ) |
Generic function for reading proximity data from sensor.
ctx | Click object. |