Input
KY-040 rotary encoder
Endless rotation with a push-click — the perfect menu controller.
Pinout
- VCCpower (3.3 V)
- CLKdigital
- DTdigital
- SWdigital
- GNDground
Bench notes
If the count moves two steps per detent, only act on the falling edge of CLK (as this code does).
- Typical price
- $1.10
- Libraries
- none needed
- Prompt keywords
- encoder, rotary, scroll, menu