I am not very familiar with home assistant. I have been searching for a automation with a state trigger.
What i want is if a unifi accesspoint is not connected to the netwerk anymore is that there has to start a automation.
alias: Unifi AP automation
trigger:
- entity_id: device_tracker.paul
platform: state
to: 'off'
condition: []
action:
- data: {}
entity_id: automation.spambot_AP
service: automation.turn_on
But its not working. Its probely not very hard but i cant figure it out myself…
Can someone help me with this problem?
Sometimes there is a slight delay when devices drop from the network before it’s reported. If I remember correctly the default polling interval with the unifi platform is 300 secs.
In my case I monitor if my network cameras are offline so I use the ping command every 60 seconds. If it doesn’t return a ping my automation is triggered.
Unifi AP’s will have a management IP address you can ping.
It might be a bug in the integration, mind enabling all debug logs for UniFi in hass and sharing those with me? Preferably on 0.109 since I’ve improved quite a few things, including logging
@Coolie1101 Aah it says nothing about monitoring the device itself. I thought if you can see how many devices are on the AP then you can also see if the AP is on or off. But it seems like it cant unfortunately.