oneshot 2.0.0.0
|
Functions | |
void | oneshot_cfg_setup (oneshot_cfg_t *cfg) |
Config Object Initialization function. | |
ONESHOT_RETVAL | oneshot_init (oneshot_t *ctx, oneshot_cfg_t *cfg) |
Initialization function. | |
void | oneshot_default_cfg (oneshot_t *ctx) |
Click Default Configuration function. | |
void | oneshot_generic_write (oneshot_t *ctx, uint8_t reg, uint8_t *data_buf, uint8_t len) |
Generic write function. | |
void | oneshot_generic_read (oneshot_t *ctx, uint8_t reg, uint8_t *data_buf, uint8_t len) |
Generic read function. | |
float | oneshot_get_resistance (oneshot_t *ctx) |
Get resistance function. | |
uint8_t | oneshot_digital_read_rst (oneshot_t *ctx) |
Digital read reset function. | |
void | oneshot_digital_write_cs (oneshot_t *ctx, uint8_t signal) |
Digital write chip select function. | |
void oneshot_cfg_setup | ( | oneshot_cfg_t * | cfg | ) |
Config Object Initialization function.
cfg | Click configuration structure. |
@description This function initializes click configuration structure to init state.
void oneshot_default_cfg | ( | oneshot_t * | ctx | ) |
Click Default Configuration function.
ctx | Click object. |
@description This function executes default configuration for OneShot click.
uint8_t oneshot_digital_read_rst | ( | oneshot_t * | ctx | ) |
Digital read reset function.
ctx | Click object. |
@description This function reads the digital signal from the RST pin.
void oneshot_digital_write_cs | ( | oneshot_t * | ctx, |
uint8_t | signal ) |
Digital write chip select function.
ctx | Click object. |
signal | Digital output signal. |
@description This function writes the specified digital signal to the CS pin.
void oneshot_generic_read | ( | oneshot_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 oneshot_generic_write | ( | oneshot_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.
float oneshot_get_resistance | ( | oneshot_t * | ctx | ) |
Get resistance function.
ctx | Click object. |
@description This function reads the resistance data from the AD5241 chip.
ONESHOT_RETVAL oneshot_init | ( | oneshot_t * | ctx, |
oneshot_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.