91 lines
1.8 KiB
YAML
91 lines
1.8 KiB
YAML
esphome:
|
|
name: pingfuss1
|
|
platform: ESP8266
|
|
board: nodemcuv2
|
|
|
|
# Enable logging
|
|
logger:
|
|
|
|
# Enable Home Assistant API
|
|
# DISABLED - We currently do not need it for operation. Maybe someday
|
|
|
|
# api:
|
|
# password: !secret ttfpassword
|
|
|
|
ota:
|
|
password: !secret ttfpassword
|
|
|
|
wifi:
|
|
ssid: !secret wifi_ssid
|
|
password: !secret wifi_password
|
|
fast_connect: true
|
|
|
|
|
|
# Example configuration entry
|
|
mqtt:
|
|
broker: !secret mqtt_broker_1
|
|
username: !secret mqtt_broker_1_username
|
|
password: !secret mqtt_broker_1_password
|
|
|
|
# Example configuration entry
|
|
binary_sensor:
|
|
- platform: gpio
|
|
pin:
|
|
number: D2
|
|
inverted: true
|
|
mode:
|
|
input: true
|
|
pullup: true
|
|
id: "Fusstaste_BLAU"
|
|
internal: true
|
|
#filters:
|
|
# - delayed_on: 10ms
|
|
# - delayed_off: 50ms
|
|
on_multi_click:
|
|
- timing:
|
|
- ON for at most 700ms
|
|
- OFF for at least 50ms
|
|
then:
|
|
- mqtt.publish:
|
|
topic: tabletenniscounter/control/score/count
|
|
payload: "1"
|
|
qos: 2
|
|
- timing:
|
|
- ON for at least 1s
|
|
then:
|
|
- mqtt.publish:
|
|
topic: tabletenniscounter/control/score/undo
|
|
payload: ""
|
|
qos: 2
|
|
- platform: gpio
|
|
pin:
|
|
number: D3
|
|
inverted: true
|
|
mode:
|
|
input: true
|
|
pullup: true
|
|
id: "Fusstaste_ROT"
|
|
internal: true
|
|
#filters:
|
|
# - delayed_on: 10ms
|
|
# - delayed_off: 50ms
|
|
on_multi_click:
|
|
- timing:
|
|
- ON for at most 700ms
|
|
- OFF for at least 50ms
|
|
then:
|
|
- mqtt.publish:
|
|
topic: tabletenniscounter/control/score/count
|
|
payload: "0"
|
|
qos: 2
|
|
- timing:
|
|
- ON for at least 1s
|
|
then:
|
|
- mqtt.publish:
|
|
topic: tabletenniscounter/control/score/undo
|
|
payload: ""
|
|
qos: 2
|
|
|
|
|
|
|