charger26 2.1.0.0
|
API for configuring and manipulating Charger 26 Click driver. More...
Topics | |
Charger 26 MikroBUS Map | |
MikroBUS pin mapping of Charger 26 Click driver. | |
Charger26_set | |
Functions | |
void | charger26_cfg_setup (charger26_cfg_t *cfg) |
Charger 26 configuration object setup function. | |
err_t | charger26_init (charger26_t *ctx, charger26_cfg_t *cfg) |
Charger 26 initialization function. | |
void | charger26_default_cfg (charger26_t *ctx) |
Charger 26 default configuration function. | |
void | charger26_set_vsel (charger26_t *ctx, uint8_t vout_sel) |
Charger 26 select charger voltage function. | |
void | charger26_set_isel (charger26_t *ctx, uint8_t iout_sel) |
Charger 26 select charger current function. | |
void | charger26_enable_output (charger26_t *ctx, uint8_t output_state) |
Charger 26 enable charger output function. | |
uint8_t | charger26_get_chg_state (charger26_t *ctx) |
Charger 26 chg pin reading function. | |
API for configuring and manipulating Charger 26 Click driver.
Any initialization code needed for MCU to function properly. Do not remove this line or clock might not be set correctly.
void charger26_cfg_setup | ( | charger26_cfg_t * | cfg | ) |
Charger 26 configuration object setup function.
This function initializes click configuration structure to initial values.
[out] | cfg | : Click configuration structure. See charger26_cfg_t object definition for detailed explanation. |
void charger26_default_cfg | ( | charger26_t * | ctx | ) |
Charger 26 default configuration function.
This function executes a default configuration of Charger 26 click board.
[in] | ctx | : Click context object. See charger26_t object definition for detailed explanation. |
void charger26_enable_output | ( | charger26_t * | ctx, |
uint8_t | output_state ) |
Charger 26 enable charger output function.
This function is used to set output of Charger 26 click board.
[in] | ctx | : Click context object. See charger26_t object definition for detailed explanation. |
[in] | output_state | : Output state. |
uint8_t charger26_get_chg_state | ( | charger26_t * | ctx | ) |
Charger 26 chg pin reading function.
This function reads the state of the chg pin of Charger 26 click board.
[in] | ctx | : Click context object. See charger26_t object definition for detailed explanation. |
0
- Battery is charging, 1
- Battery isn't charging. err_t charger26_init | ( | charger26_t * | ctx, |
charger26_cfg_t * | cfg ) |
Charger 26 initialization function.
This function initializes all necessary pins and peripherals used for this click board.
[out] | ctx | : Click context object. See charger26_t object definition for detailed explanation. |
[in] | cfg | : Click configuration structure. See charger26_cfg_t object definition for detailed explanation. |
0
- Success, -1
- Error. See #err_t definition for detailed explanation. void charger26_set_isel | ( | charger26_t * | ctx, |
uint8_t | iout_sel ) |
Charger 26 select charger current function.
This function is used to set charging current of Charger 26 click board.
[in] | ctx | : Click context object. See charger26_t object definition for detailed explanation. |
[in] | iout_sel | : Charging current selection. |
void charger26_set_vsel | ( | charger26_t * | ctx, |
uint8_t | vout_sel ) |
Charger 26 select charger voltage function.
This function is used to set charging voltage of Charger 26 click board.
[in] | ctx | : Click context object. See charger26_t object definition for detailed explanation. |
[in] | iout_sel | : Charging current selection. |