Advertisement
p33j4y

HA: Night & Day on graphs

May 26th, 2020
1,301
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
YAML 1.24 KB | None | 0 0
  1. #################################################
  2. ### KONFIG ENCJI I AUTOMATYKI
  3. #################################################
  4.  
  5. input_number:
  6.   0_cfg_nightime:
  7.     name: 0_cfg_nightime
  8.     min: 0
  9.     max: 1
  10.     step: 1
  11.  
  12. automation:
  13. - id: auto_noc_dzien
  14.   trigger:
  15.  - <TU DAJ TRIGGER NP. CZASOWY/Z SENSORA NOC/DZIEŃ
  16.   action:
  17.   - service: input_number.set_value
  18.     data_template:
  19.       entity_id: input_number.0_cfg_nightime
  20.       value: "{% if <TU PODAJ SWÓJ WARUNEK NA NOC> %}1{% else %}0{% endif %}"
  21.  
  22. #################################################
  23. ### LOVELACE - PRZYKŁADOWA KARTA Z WYKRESEM
  24. #################################################
  25. - type: custom:mini-graph-card
  26.   name: "Temperatura"
  27.   entities:
  28.  - sensor.2_off_temperature
  29.   - entity: input_number.0_cfg_nightime
  30.     color: "#444444"
  31.     show_line: false
  32.     show_points: false
  33.     show_legend: false
  34.     y_axis: secondary
  35.   group: true
  36.   hours_to_show: 48
  37.   points_per_hour: 1
  38.   hour24: true
  39.   decimals: 1
  40.   animate: true
  41.   show:
  42.     points: false
  43.     extrema: true
  44.     fill: fade
  45.   color_thresholds_transition: smooth
  46.   color_thresholds:
  47.   - value: 17
  48.     color: "#00d9d9"
  49.   - value: 22
  50.     color: "#ff8000"
  51.   - value: 27
  52.     color: "#ff2626"
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement