I recently switched from Locative to GPS Logger. The lack of random drift and more consistent reporting, have made me quite happy with that choice. Interval position reporting rather than reporting when a boundary is crossed has knocked out my approaching home automation. A geofence large enough to detect me before I get home would also encompass a nearby freeway, where leaving home via the freeway is also coming toward my home. If I could use my speed as a condition, it would be easy to discriminate between leaving on the freeway or coming home on the frontage road. The get request from GPS Logger includes speed, but I haven’t found that exposed in HA. Is it available?
Well so much for that, I found it where it should be, under the tracked device in states. Not sure why I didn’t see it when looking this weekend.
I had a chance to put this to use today, but it didn’t go as expected.
For both of the devices I am tracking, if I look in the Developer <> States screen, I see each device, and it has speed as an attribute.
I’ve tried to add the following condition to an automation:
- condition: numeric_state
entity_id: device_tracker.98899a385aXXXXXXXX.speed
below: 22.352
But this is throwing a configuration error:
2017-08-13 16:00:46 ERROR (MainThread) [homeassistant.config] Invalid config for [automation]: Entity ID device_tracker.98899a385aXXXXXXXXX.speed is an invalid entity id for dictionary value @ data[‘condition’][0][‘conditions’][0][‘entity_id’]. Got None.
What is the correct format to compare the speed to a max value?