Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Adjust logging rate based on the DetectedActivity API #206

Open
kuro68k opened this issue Mar 27, 2023 · 2 comments
Open

Adjust logging rate based on the DetectedActivity API #206

kuro68k opened this issue Mar 27, 2023 · 2 comments

Comments

@kuro68k
Copy link

kuro68k commented Mar 27, 2023

The DetectedActivity API allows the app to respond to changes in activity, like going from sill to walking, or getting in a vehicle.

By adjusting the logging rate based on the current activity, significant battery savings could be made for people who like to keep logging for long periods of time.

https://developers.google.com/android/reference/com/google/android/gms/location/DetectedActivity

@GrazianoCapelli
Copy link
Member

Unfortunately we cannot use the DetectedActivity API because it is part of Google Play Services: we chosen to make an app that doesn't depends on any of them.
Anyway, we could implement an automatic logging adjustment basing on the type of activity, that could be detected basing on speed and other GPS information (the app already implements a basic activity recognition algorithm).

@kuro68k
Copy link
Author

kuro68k commented Apr 26, 2023

Thanks @GrazianoCapelli. Any implementation would be good. Maybe you could also use the device accelerometer to detect one of the most common situations where updates are unnecessary: the device is still, e.g. sat on a desk.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants