1 #ifndef _TWR_MODULE_ENCODER_H 2 #define _TWR_MODULE_ENCODER_H 4 #include <twr_button.h> 65 #endif // _TWR_MODULE_ENCODER_H int twr_module_encoder_get_increment(void)
Read encoder delta increment (can be positive or negative number)
Event button clicked (pressed and released within certain time)
Event button hold (pressed for longer time)
twr_button_t * twr_module_encoder_get_button_instance(void)
Get encoder button instance.
void twr_module_encoder_init(void)
Initialize Encoder Module.
void twr_module_encoder_set_event_handler(void(*event_handler)(twr_module_encoder_event_t, void *), void *event_param)
Set callback function.
Event error (module is not present)
twr_module_encoder_event_t
Callback events.
bool twr_module_encoder_is_present(void)
Get Encoder Module is pressent, can use without twr_module_encoder_init.
void twr_module_encoder_deinit(void)
Deinitialize Encoder Module.