Created
March 29, 2020 03:18
-
-
Save ironicbadger/1a4504b3a23d9952cec0c61127b6ac4f to your computer and use it in GitHub Desktop.
home assistant covid tracker
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
cards: | |
- content: >- | |
# Quarantine-o-meter | |
The gauge meters display the amount of time spend at home in the last 7 | |
days. Where Alex left the house (on average) {{ | |
(states("sensor.quarantine_meter_alex_times_left")|int / 7) | round(1) }} | |
times per day and Cat {{ | |
(states("sensor.quarantine_meter_cat_times_left")|int / 7) | round(1) }} | |
times per day. | |
type: markdown | |
- cards: | |
- entity: sensor.quarantine_meter_alex | |
max: 100 | |
min: 0 | |
name: Alex Home % | |
severity: | |
green: 95 | |
red: 0 | |
yellow: 80 | |
theme: Backend-selected | |
type: gauge | |
- entity: sensor.quarantine_meter_cat | |
max: 100 | |
min: 0 | |
name: Cat Home % | |
severity: | |
green: 95 | |
red: 0 | |
yellow: 80 | |
theme: Backend-selected | |
type: gauge | |
type: horizontal-stack | |
type: vertical-stack |
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
## covid | |
- platform: history_stats | |
name: Quarantine meter Alex | |
entity_id: person.alex | |
state: "home" | |
type: ratio | |
duration: | |
days: 7 | |
end: "{{ now() }}" | |
- platform: history_stats | |
name: Quarantine meter Cat | |
entity_id: person.cat | |
state: "home" | |
type: ratio | |
duration: | |
days: 7 | |
end: "{{ now() }}" | |
- platform: history_stats | |
name: Quarantine meter Alex times left | |
entity_id: person.alex | |
state: "home" | |
type: count | |
duration: | |
days: 7 | |
end: "{{ now() }}" | |
- platform: history_stats | |
name: Quarantine meter Cat times left | |
entity_id: person.cat | |
state: "home" | |
type: count | |
duration: | |
days: 7 | |
end: "{{ now() }}" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment