dac2 2.0.0.0
|
Functions | |
void | dac2_cfg_setup (dac2_cfg_t *cfg) |
Config Object Initialization function. | |
DAC2_RETVAL | dac2_init (dac2_t *ctx, dac2_cfg_t *cfg) |
Initialization function. | |
void | dac2_generic_transfer (dac2_t *ctx, uint8_t *wr_buf, uint16_t wr_len, uint8_t *rd_buf, uint16_t rd_len) |
Generic transfer function. | |
void | dac2_default_cfg (dac2_t *ctx) |
Click Default Configuration function. | |
void | dac2_clr_dac_2_reg (dac2_t *ctx) |
Asynchronous Clear Input function. | |
void | dac2_write_output_voltage_procentage (dac2_t *ctx, uint8_t value_pct) |
Procentage generic write function. | |
void | dac2_write_output_voltage_data (dac2_t *ctx, uint16_t value_data) |
Data generic write function. | |
void dac2_cfg_setup | ( | dac2_cfg_t * | cfg | ) |
Config Object Initialization function.
cfg | Click configuration structure. |
@description This function initializes click configuration structure to init state.
void dac2_clr_dac_2_reg | ( | dac2_t * | ctx | ) |
Asynchronous Clear Input function.
ctx | Click object. |
@description This function clears all registers and causes the DAC voltage outputs to drop to 0V for LTC2601.
void dac2_default_cfg | ( | dac2_t * | ctx | ) |
Click Default Configuration function.
ctx | Click object. |
@description This function executes default configuration for LTC2601 click.
void dac2_generic_transfer | ( | dac2_t * | ctx, |
uint8_t * | wr_buf, | ||
uint16_t | wr_len, | ||
uint8_t * | rd_buf, | ||
uint16_t | rd_len ) |
Generic transfer function.
ctx | Click object. |
wr_buf | Write data buffer |
wr_len | Number of byte in write data buffer |
rd_buf | Read data buffer |
rd_len | Number of byte in read data buffer |
@description Generic SPI transfer, for sending and receiving packages
DAC2_RETVAL dac2_init | ( | dac2_t * | ctx, |
dac2_cfg_t * | cfg ) |
Initialization function.
dac2 | Click object. |
cfg | Click configuration structure. |
@description This function initializes all necessary pins and peripherals used for this click.
void dac2_write_output_voltage_data | ( | dac2_t * | ctx, |
uint16_t | value_data ) |
Data generic write function.
ctx | Click object. |
value_pct | Required 16-bit data of output voltage. |
@description This function required 16-bit data value ( from 0 to 65535 ) convert to digital input and transforms it to the output voltage from 0 to Vref [mV].
void dac2_write_output_voltage_procentage | ( | dac2_t * | ctx, |
uint8_t | value_pct ) |
Procentage generic write function.
ctx | Click object. |
value_pct | Required percentage of output voltage ( from 0% to 100%). |
@description This function required percentage value ( from 0% to 100% ) convert to digital input and transforms it to the output voltage from 0 to Vref [mV].