bailuk / AAT

Another Activity Tracker for Android
https://bailu.ch/aat
GNU General Public License v3.0
150 stars 41 forks source link

Close app only via Task Manager #12

Closed Heineken closed 6 years ago

Heineken commented 6 years ago

After starting AAT without tracking, my GPS is not turned off until I kill AAT in the task manager. GPS is a potentially unwanted battery drain. Is that the intended behaviour? Expected behaviour: Sending AAT to the background deactivates GPS unless tracking is active. OR Repeatedly pressing back eventually closes the app and switches off GPS.

bailuk commented 6 years ago

It's not intended behavior, unless you've enabled GPS-lock (tap the GPS status view to toggle GPS-lock)

Heineken commented 6 years ago

Cannot confirm. GPS stays on even without GPS lock.

bailuk commented 6 years ago

I can't reproduce this. GPS always turns of after a few seconds when app is not on display and tracker is off (stopped). For some reason AAT never releases resources on your device. Can you give me some more information? Does this always happen? What happens if you just open the main screen and then immediately close it again with the back button?

Heineken commented 6 years ago

Yes, it always happens, even right after launching the app. It's on a Xperia Z3c with Android 6.0.1 (rooted stock rom) How else can I help?

Heineken commented 6 years ago

Same on Motorola Defy+ running SlimKat Rom (Android 4.4).

YuhanXu commented 6 years ago

Same on Motorola Moto X 2013, GPS keeps toggling on and off even the tracker is off.

bailuk commented 6 years ago

I've added log messages to the latest release to track this issue. If someone could send logcat output that would be very helpful.

Heineken commented 6 years ago

Where would I find that log? aat_data/log is empty. I updated today and tracked for a couple of hours.

bailuk commented 6 years ago

You can use adb and logcat from the Android SDK to save debug messages. There are also apps on f-droid that let you view / save log messages.

Heineken commented 6 years ago

OK. I started alogcat and set it to verbose level "debug", then started AAT 1.9β, waited for the Locator Icon to show, then exited and killed the app. Logcat only shows an idle message.

Heineken commented 6 years ago

OK, I checked again. GPS is switched off with a delay of about 12 seconds. On three different phones.