mirror of
https://github.com/esphome/esphome.git
synced 2025-10-29 22:24:26 +00:00
Add on_clockwise and on_anticlockwise triggers to rotary encoder (#1330)
This commit is contained in:
@@ -586,6 +586,10 @@ sensor:
|
||||
- sensor.rotary_encoder.set_value:
|
||||
id: rotary_encoder1
|
||||
value: !lambda 'return -1;'
|
||||
on_clockwise:
|
||||
- logger.log: "Clockwise"
|
||||
on_anticlockwise:
|
||||
- logger.log: "Anticlockwise"
|
||||
- platform: pulse_width
|
||||
name: Pulse Width
|
||||
pin: GPIO12
|
||||
|
||||
Reference in New Issue
Block a user