mirror of
https://github.com/esphome/esphome.git
synced 2026-09-29 16:00:23 +00:00
38 lines
854 B
YAML
38 lines
854 B
YAML
esphome:
|
|
on_boot:
|
|
then:
|
|
- counter.set_value:
|
|
id: counter_sensor
|
|
value: 100
|
|
- counter.increment: counter_sensor
|
|
- counter.increment:
|
|
id: counter_sensor
|
|
value: -5
|
|
- counter.increment:
|
|
id: counter_sensor
|
|
value: !lambda "return 5000000000LL;"
|
|
|
|
sensor:
|
|
- platform: counter
|
|
id: counter_sensor
|
|
name: Counter
|
|
- platform: counter
|
|
id: counter_no_restore
|
|
name: Counter No Restore
|
|
restore: false
|
|
initial_value: 10
|
|
- platform: template
|
|
id: source_sensor
|
|
lambda: return 1.0;
|
|
update_interval: 1s
|
|
- platform: counter
|
|
name: Counter Of Sensor
|
|
sensor: source_sensor
|
|
- platform: counter
|
|
name: Counter Of Binary Sensor
|
|
binary_sensor: source_binary_sensor
|
|
|
|
binary_sensor:
|
|
- platform: template
|
|
id: source_binary_sensor
|