proximity 2.0.0.0
|
Functions | |
void | proximity_cfg_setup (proximity_cfg_t *cfg) |
Config Object Initialization function. | |
PROXIMITY_RETVAL | proximity_init (proximity_t *ctx, proximity_cfg_t *cfg) |
Initialization function. | |
void | proximity_write_byte (proximity_t *ctx, uint8_t w_addr, uint8_t w_data) |
Functions for write one byte in register. | |
uint8_t | proximity_read_byte (proximity_t *ctx, uint8_t r_addr) |
Functions for read byte from register. | |
void | proximity_read_data (proximity_t *ctx, uint8_t r_addr, uint8_t *rcv_data, uint8_t n_len) |
Functions for read data from register. | |
void | proximity_write_data (proximity_t *ctx, uint8_t w_addr, uint8_t *wr_data, uint8_t n_len) |
Functions for write data. | |
void | proximity_set_default_mode (proximity_t *ctx) |
Functions for sets default mode. | |
void | proximity_set_upper_threshold (proximity_t *ctx) |
Functions for sets upper threshold. | |
uint16_t | proximity_read_prox_data (proximity_t *ctx) |
Functions for reads Proximity data. | |
uint16_t | proximity_read_ambient_light (proximity_t *ctx) |
Functions for reads Ambient light. | |
void proximity_cfg_setup | ( | proximity_cfg_t * | cfg | ) |
Config Object Initialization function.
cfg | Click configuration structure. |
@description This function initializes click configuration structure to init state.
PROXIMITY_RETVAL proximity_init | ( | proximity_t * | ctx, |
proximity_cfg_t * | cfg ) |
Initialization function.
ctx | Click object. |
cfg | Click configuration structure. |
@description This function initializes all necessary pins and peripherals used for this click.
uint16_t proximity_read_ambient_light | ( | proximity_t * | ctx | ) |
Functions for reads Ambient light.
ctx | Click object |
uint8_t proximity_read_byte | ( | proximity_t * | ctx, |
uint8_t | r_addr ) |
Functions for read byte from register.
ctx | Click object |
r_addr | Register which will be read |
one | byte data which is read from the register |
void proximity_read_data | ( | proximity_t * | ctx, |
uint8_t | r_addr, | ||
uint8_t * | rcv_data, | ||
uint8_t | n_len ) |
Functions for read data from register.
ctx | Click object |
r_addr | Register which will be read |
rcv_data | Output buffer |
n_len | Number of bytes will be reads |
uint16_t proximity_read_prox_data | ( | proximity_t * | ctx | ) |
Functions for reads Proximity data.
ctx | Click object |
void proximity_set_default_mode | ( | proximity_t * | ctx | ) |
Functions for sets default mode.
ctx | Click object |
void proximity_set_upper_threshold | ( | proximity_t * | ctx | ) |
Functions for sets upper threshold.
ctx | Click object |
void proximity_write_byte | ( | proximity_t * | ctx, |
uint8_t | w_addr, | ||
uint8_t | w_data ) |
Functions for write one byte in register.
ctx | Click object |
w_addr | Register in which the data will be written |
w_data | Data which be written in the register |
void proximity_write_data | ( | proximity_t * | ctx, |
uint8_t | w_addr, | ||
uint8_t * | wr_data, | ||
uint8_t | n_len ) |
Functions for write data.
ctx | Click object |
w_addr | Register |
wr_data | Buffer with data |
n_len | Number of bytes will be writting |