Hello friends! I am trying to set up manual remotely triggered location updates on Android, but I’m having trouble getting the app to actually send location updates. I’ve tried a lot of things so far, so I’ll try to list them all here and maybe someone can spot what I might have missed? Thanks for your time
Context:
My wife and I want to be able to manually request a location update of the other’s device, so we can find each other when one is out on a walk. To be clear, this is a feature we both want to be able to use for practicality, there are no trust issues here. We don’t need continuous location updates, just on demand.
Current setup:
- Device is an S22
- Enabled HA background access
- Disabled battery optimizations
- Gave “all the time” location permission
- In sensors settings, location, we have Background location enabled, and Single accurate location also enabled. Minimum time set to 10000ms.
In a custom dashboard, I’ve set up a tap action per device that calls service notify.[device]
, with ttl: 0
and priority: high
, message request_location_update
.
I know that the notification reaches the phone, because I can see it in the app’s notification history.
Issue:
Location is only updated if the app is awake, or if a zone changes.
If not, it doesn’t seem to update, even tho it does seem to receive request_location_update
.
Sometimes it will work once.
If the device is plugged in, it might work more frequently.
I’m not sure what else I can try. Any ideas?