This class implement the module device KY040 which is a rotary encoder with a centrl switch push button.
More...
#include <ky040.h>
|
|
SwitchButton | central_switch |
| | the internal part of KY040 that behaves as a simple switch button
|
|
RotaryEncoder | encoder |
| | the internal part of the KY040 that behaves as a rotary encoder
|
This class implement the module device KY040 which is a rotary encoder with a centrl switch push button.
It inherits from UIController, because most of the time it will be used in a UI context. Otherwise, a separate implementation of RotaryEncoder aand/or SwitchButton will be suficient.
◆ KY040()
Construct a new KY040 object.
- Parameters
-
| central_switch_gpio | The GPIO pin connected to the central switch push button |
| encoder_clk_gpio | The GPIO pin connected to the clock signal that trig the IRQ on the rotary encoder |
| encoder_dt_gpio | The GPIO pin connected to the data signal that indicates the direction of the rotary encoder |
| call_back | The interupt service routine call by the clock signal IRQ |
| sw_conf | The central switch push button configuration for debounce processing |
| clk_conf | The clock signal configuration for debounce processing |
◆ process_central_switch_event()
◆ process_encoder_IRQ()
| void KY040::process_encoder_IRQ |
( |
uint32_t | event_mask | ) |
|
the call back function used to hide encoder from KY040 user
- Parameters
-
| event_mask | the IRQ data returned by the interrupt manager |
◆ update_UI_control_event_processor()
the update control event processor function used to hide encoder from KY040 user
- Parameters
-
The documentation for this class was generated from the following files: