optoencoder5 2.1.0.0
|
API for configuring and manipulating Opto Encoder 5 Click driver. More...
Modules | |
Opto Encoder 5 MikroBUS Map | |
MikroBUS pin mapping of Opto Encoder 5 Click driver. | |
Optoencoder5_set | |
Functions | |
void | optoencoder5_cfg_setup (optoencoder5_cfg_t *cfg) |
Opto Encoder 5 configuration object setup function. More... | |
err_t | optoencoder5_init (optoencoder5_t *ctx, optoencoder5_cfg_t *cfg) |
Opto Encoder 5 initialization function. More... | |
void | optoencoder5_enable (optoencoder5_t *ctx) |
Opto Encoder 5 enable function. More... | |
void | optoencoder5_disable (optoencoder5_t *ctx) |
Opto Encoder 5 disable function. More... | |
uint8_t | optoencoder5_get_out_state (optoencoder5_t *ctx) |
Opto Encoder 5 get state function. More... | |
API for configuring and manipulating Opto Encoder 5 Click driver.
void optoencoder5_cfg_setup | ( | optoencoder5_cfg_t * | cfg | ) |
Opto Encoder 5 configuration object setup function.
This function initializes click configuration structure to initial values.
[out] | cfg | : Click configuration structure. See optoencoder5_cfg_t object definition for detailed explanation. |
void optoencoder5_disable | ( | optoencoder5_t * | ctx | ) |
Opto Encoder 5 disable function.
This function disables the slotted optical switch of Opto Encoder 5 click board.
[in] | ctx | : Click context object. See optoencoder5_t object definition for detailed explanation. |
void optoencoder5_enable | ( | optoencoder5_t * | ctx | ) |
Opto Encoder 5 enable function.
This function enables the slotted optical switch of Opto Encoder 5 click board.
[in] | ctx | : Click context object. See optoencoder5_t object definition for detailed explanation. |
uint8_t optoencoder5_get_out_state | ( | optoencoder5_t * | ctx | ) |
Opto Encoder 5 get state function.
This function detecting slotted optical switch states of Opto Encoder 5 click board.
[in] | ctx | : Click context object. See optoencoder5_t object definition for detailed explanation. |
0
- Open, 1
- Closed. err_t optoencoder5_init | ( | optoencoder5_t * | ctx, |
optoencoder5_cfg_t * | cfg | ||
) |
Opto Encoder 5 initialization function.
This function initializes all necessary pins and peripherals used for this click board.
[out] | ctx | : Click context object. See optoencoder5_t object definition for detailed explanation. |
[in] | cfg | : Click configuration structure. See optoencoder5_cfg_t object definition for detailed explanation. |
0
- Success, -1
- Error. See #err_t definition for detailed explanation.