Skip to content

Instantly share code, notes, and snippets.

View FredrickB's full-sized avatar

Fredrick Biering FredrickB

View GitHub Profile
@FredrickB
FredrickB / binary_sensor.yaml
Last active September 9, 2018 08:48
Wrapping Strips Guard (https://www.stripsbysensative.com/guard/) readings for opening/closing of door in a Template Binary Sensor for Home-Assistant and referencing in automations
...
- platform: template
sensors:
your_door_sensor_reference_name:
friendly_name: "Some friendly name for door"
device_class: door
value_template: "{{ states('sensor.sensative_strips_access_control') | float <= 22 }}"
...
@FredrickB
FredrickB / groups.yaml
Last active September 9, 2018 08:47
Grouping a custom Template Binary Sensor representation of Strips Guard in a custom group in Home-Assistant
...
some_group_name:
name: "Friendly name of HA group"
view: yes # Must be enabled to have the group be visible in HA dashboard
entities:
- binary_sensor.your_door_sensor_reference_name
...
@FredrickB
FredrickB / automations.yaml
Created September 9, 2018 08:49
Adding a custom Template Binary Sensor representation of Strips Guard as a trigger in an automation
...
# Trigger automation if door has been opened and has stayed open for 10 minutes
- id: door_sensor_automation_id
alias: "Some friendly name for automation"
trigger:
platform: state
entity_id: binary_sensor.your_door_sensor_reference_name
from: 'off'
to: 'on'
for: