How to ensure client is always running?

Jon C. Crosby10 months ago

I'm new to Traccar. I've been using Life360 so my family can see where each other's locations, but wanted to see if I could use this + Home Assistant instead.

Everything is working great so far, except if someone closes the app on their phone or it restarts, they have to remember to open the client back up for it to keep working. Is there a way to make sure the app keeps running in the background as long as the device is on?

Anton Tananaev10 months ago

The app should run in the background unless you kill the app.

Jon C. Crosby10 months ago

Thanks for the quick reply!

Right, so if the user hits "Close All", then it stops sending location. The same when the device restarts.

Jon C. Crosby9 months ago

So... I need some way to keep getting location data from the phone even if the user closes the app (or prevent the app from being closed). Life360 didn't stop working when the user closed the app by swiping out of it, and I want Traccar Client to do the same. Any help?

Anton Tananaev9 months ago

We need to know how Life360 did it. If they did it by breaking Google/Apple policies, we probably won't be doing that.

I'm trying to achieve the same thing, basically for Tracca client to be always reporting its position back to the server for the purpose of home automation. There are other apps that does it such as Tado (dynamically turning up or down the desired thermostat temperature based on your distance to home).

dima-simfer9 months ago

There is an app for android calling "Automate". You can schedule opening Traccar some times a day or check is it running in foreground and open, if it's not. Or check every one-five-ten minutes.