I launched this discussion because I searched a lot and did not find the solution, even the owner of the extension did not answer my questions. I understand his situation, he may be busy
I am trying to run the timer in the background but all attempts are unsuccessfu
The extension has used background tasks 4.0
This is a file AIA n.aia (466.8 KB)
My goal is when I press a button the timer works and when I go back to the application and press another button the timer stops, this does not stop.
With that, the same problem (the internet is weak) exists.
I waited 3 minutes to reopen the application.
Because the Internet is very weak in my area, I need to do that without the Internet at all.
Thank you for your interest in helping me
Since there was / is no Doze mode on Android 5.x, it is sufficient to set TimerAlwaysFires = true. As long as the app is not closed, it should work on Android < 6 (API < 23, Doze mode was introduced with Android 6).
Note: Whether the timer works in the background (app not visible, in idle / sleep mode) has nothing to do with a BackgroundTask, but depends on whether Doze mode is active or not.