Hi HA community,
I am trying to get some of my automations into Node-red.
One is to auto set alarm (Alarmo) to arm away when both my wife and my device is detected being 'not_home".
I have this working today in HA automations, but in Node-red i have the device item to use, but cannot seem to do wife_mobile & …
Should I create a group and put both devices in a group and then have HA mark group as “not_home” when both are away? Or should I be looking at creating a manual entity to that would allow Node-red to use this way.
Current automation in yaml which I want to move into Node-red is:
alias: Auto Arm Alarm when not home
description: ''
trigger:
- platform: device
device_id: <removed>
domain: device_tracker
entity_id: device_tracker.sm_g975f
type: leaves
zone: zone.home
id: '1704'
- platform: device
device_id: <removed>
domain: device_tracker
entity_id: device_tracker.jess_s21
type: leaves
zone: zone.home
id: '2105'
condition:
- condition: device
device_id: <removed>
domain: device_tracker
entity_id: device_tracker.sm_g975f
type: is_not_home
- condition: and
conditions:
- condition: device
device_id: <removed>
domain: device_tracker
entity_id: device_tracker.jess_s21
type: is_not_home
- condition: and
conditions:
- condition: device
device_id: >removed>
domain: alarm_control_panel
entity_id: alarm_control_panel.alarmo
type: is_disarmed
- condition: time
after: '08:00:00'
before: '19:00:00'
action:
- service: alarm_control_panel.alarm_arm_away
target:
device_id: <removed>
entity_id: alarm_control_panel.alarmo
- service: notify.mobile_app_jess_s21
data:
message: Alarm is ARMED due to both Matt & Jess being away from Home
title: Alarm ARMED Automatically - Both Away
- service: notify.mobile_app_sm_g975f
data:
title: Alarm ARMED Automatically - Both Away
message: Alarm is ARMED due to both Matt & Jess being away from Home
mode: single
Appreciate any insights.
Thank you.