Created
April 16, 2019 21:26
-
-
Save pauly7300/1c1877e3b790f2d65fa2b56126a4d258 to your computer and use it in GitHub Desktop.
esp32_touch light example
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
esphome: | |
name: aaa | |
platform: ESP32 | |
board: mhetesp32devkit | |
wifi: | |
ssid: "wifi_ssid" | |
password: "wifipassword" | |
# Enable logging | |
logger: | |
# Enable Home Assistant API | |
api: | |
password: 'apipassword' | |
ota: | |
password: 'apipassword' | |
# Example configuration entry | |
esp32_touch: | |
setup_mode: False | |
# Example configuration entry | |
output: | |
- platform: ledc | |
pin: GPIO19 | |
id: gpio_19 | |
# Example usage in a light | |
light: | |
- platform: monochromatic | |
output: gpio_19 | |
id: kitchen_light | |
name: "Kitchen Light" | |
binary_sensor: | |
- platform: esp32_touch | |
name: "ESP32 Touch GPIO32" | |
pin: 32 | |
threshold: 500 | |
on_click: | |
min_length: 50ms | |
max_length: 350ms | |
then: | |
- light.toggle: | |
id: kitchen_light | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment