analogmux5 2.0.0.0
|
API for configuring and manipulating Analog MUX 5 Click driver. More...
Topics | |
Analog MUX 5 MikroBUS Map | |
MikroBUS pin mapping of Analog MUX 5 Click driver. | |
Ch_select | |
Functions | |
void | analogmux5_cfg_setup (analogmux5_cfg_t *cfg) |
Analog MUX 5 configuration object setup function. | |
err_t | analogmux5_init (analogmux5_t *ctx, analogmux5_cfg_t *cfg) |
Analog MUX 5 initialization function. | |
err_t | analogmux5_default_cfg (analogmux5_t *ctx) |
Analog MUX 5 default configuration function. | |
err_t | analogmux5_read_an_pin_value (analogmux5_t *ctx, uint16_t *data_out) |
Analog MUX 5 read AN pin value function. | |
err_t | analogmux5_read_an_pin_voltage (analogmux5_t *ctx, float *data_out) |
Analog MUX 5 read AN pin voltage level function. | |
void | analogmux5_enable (analogmux5_t *ctx) |
Analog MUX 5 enable function. | |
void | analogmux5_disable (analogmux5_t *ctx) |
Analog MUX 5 disable function. | |
err_t | analogmux5_select_ch (analogmux5_t *ctx, uint8_t ch_select) |
Analog MUX 5 set channel function. | |
API for configuring and manipulating Analog MUX 5 Click driver.
Any initialization code needed for MCU to function properly. Do not remove this line or clock might not be set correctly.
void analogmux5_cfg_setup | ( | analogmux5_cfg_t * | cfg | ) |
Analog MUX 5 configuration object setup function.
This function initializes click configuration structure to initial values.
[out] | cfg | : Click configuration structure. See analogmux5_cfg_t object definition for detailed explanation. |
err_t analogmux5_default_cfg | ( | analogmux5_t * | ctx | ) |
Analog MUX 5 default configuration function.
This function executes a default configuration of Analog MUX 5 click board.
[in] | ctx | : Click context object. See analogmux5_t object definition for detailed explanation. |
0
- Success, -1
- Error.void analogmux5_disable | ( | analogmux5_t * | ctx | ) |
Analog MUX 5 disable function.
This function disable all switch channels.
[in] | ctx | : Click context object. See analogmux5_t object definition for detailed explanation. |
void analogmux5_enable | ( | analogmux5_t * | ctx | ) |
Analog MUX 5 enable function.
This function enable all switch channels.
[in] | ctx | : Click context object. See analogmux5_t object definition for detailed explanation. |
err_t analogmux5_init | ( | analogmux5_t * | ctx, |
analogmux5_cfg_t * | cfg ) |
Analog MUX 5 initialization function.
This function initializes all necessary pins and peripherals used for this click board.
[out] | ctx | : Click context object. See analogmux5_t object definition for detailed explanation. |
[in] | cfg | : Click configuration structure. See analogmux5_cfg_t object definition for detailed explanation. |
0
- Success, -1
- Error.err_t analogmux5_read_an_pin_value | ( | analogmux5_t * | ctx, |
uint16_t * | data_out ) |
Analog MUX 5 read AN pin value function.
This function reads results of AD conversion of the AN pin.
[in] | ctx | : Click context object. See analogmux5_t object definition for detailed explanation. |
[out] | data_out | : Output ADC result. |
0
- Success, -1
- Error.err_t analogmux5_read_an_pin_voltage | ( | analogmux5_t * | ctx, |
float * | data_out ) |
Analog MUX 5 read AN pin voltage level function.
This function reads results of AD conversion of the AN pin and converts them to proportional voltage level.
[in] | ctx | : Click context object. See analogmux5_t object definition for detailed explanation. |
[out] | data_out | : Output voltage level of the analog pin [V]. |
0
- Success, -1
- Error.err_t analogmux5_select_ch | ( | analogmux5_t * | ctx, |
uint8_t | ch_select ) |
Analog MUX 5 set channel function.
This function sets the active channel.
[in] | ctx | : Click context object. See analogmux5_t object definition for detailed explanation. |
[in] | ch_select | :
|
0
- Success, -1
- Error.