buck16 2.0.0.0
|
API for configuring and manipulating Buck 16 Click driver. More...
Modules | |
Buck 16 Registers List | |
List of registers of Buck 16 Click driver. | |
Buck 16 Registers Settings | |
Settings for registers of Buck 16 Click driver. | |
Buck 16 MikroBUS Map | |
MikroBUS pin mapping of Buck 16 Click driver. | |
Functions | |
void | buck16_cfg_setup (buck16_cfg_t *cfg) |
Buck 16 configuration object setup function. More... | |
err_t | buck16_init (buck16_t *ctx, buck16_cfg_t *cfg) |
Buck 16 initialization function. More... | |
err_t | buck16_generic_write (buck16_t *ctx, uint8_t cmd, uint8_t cmd_bits, uint16_t tx_data) |
Data writing function. More... | |
void | buck16_enable_output (buck16_t *ctx, uint8_t enable) |
Enable/Disable voltage output. More... | |
err_t | buck16_set_potentiometer (buck16_t *ctx, uint16_t rwb) |
Set potentiometer resistivity. More... | |
err_t | buck16_set_output (buck16_t *ctx, uint16_t vout) |
Set output voltage. More... | |
API for configuring and manipulating Buck 16 Click driver.
void buck16_cfg_setup | ( | buck16_cfg_t * | cfg | ) |
Buck 16 configuration object setup function.
This function initializes click configuration structure to initial values.
[out] | cfg | : Click configuration structure. See buck16_cfg_t object definition for detailed explanation. |
void buck16_enable_output | ( | buck16_t * | ctx, |
uint8_t | enable | ||
) |
Enable/Disable voltage output.
This function sets pin that enables or disables voltage output.
[in] | ctx | : Click context object. See buck16_t object definition for detailed explanation. |
[in] | enable | : Pin state to set. |
err_t buck16_generic_write | ( | buck16_t * | ctx, |
uint8_t | cmd, | ||
uint8_t | cmd_bits, | ||
uint16_t | tx_data | ||
) |
Data writing function.
This function writes a data to the selected command.
[in] | ctx | : Click context object. See buck16_t object definition for detailed explanation. |
[in] | cmd | : Command to send. |
[in] | cmd_bits | : Configuration command bits. |
[in] | tx_data | : Command data. |
0
- Success, -1
- Error.err_t buck16_init | ( | buck16_t * | ctx, |
buck16_cfg_t * | cfg | ||
) |
Buck 16 initialization function.
This function initializes all necessary pins and peripherals used for this click board.
[out] | ctx | : Click context object. See buck16_t object definition for detailed explanation. |
[in] | cfg | : Click configuration structure. See buck16_cfg_t object definition for detailed explanation. |
0
- Success, -1
- Error.err_t buck16_set_output | ( | buck16_t * | ctx, |
uint16_t | vout | ||
) |
Set output voltage.
This function sets voltage value on output.
[in] | ctx | : Click context object. See buck16_t object definition for detailed explanation. |
[in] | vout | : Output voltage to set in mV. |
0
- Success, -1
- Error.err_t buck16_set_potentiometer | ( | buck16_t * | ctx, |
uint16_t | rwb | ||
) |
Set potentiometer resistivity.
This function sets potentiometer value.
[in] | ctx | : Click context object. See buck16_t object definition for detailed explanation. |
[in] | rwb | : Resistivity to set with potentiometer. |
0
- Success, -1
- Error.