Questions tagged [android-doze-and-standby]
73 questions
2
votes
1 answer
Android - Disable Forced DozeMode or AppStandByMode
I have an application that uses a ForegroundService to send location updates to a server. Basically a tracker.
This ForegroundService has a Handler that periodically (using postDelayed) executes a block of code to send the location.
This works…

sebasira
- 1,739
- 1
- 22
- 41
2
votes
1 answer
App Standby Buckets - What are the restrictions on the "Never" bucket (bucket 50)
The Android documentation mentions the restrictions the OS imposes on apps for each of the following buckets: "active", "working set", "frequent", and "rare".
The only documentation I found for the "never" bucket (the bucket that apps that were…

dors
- 5,802
- 8
- 45
- 71
2
votes
0 answers
How to send emergency alerts from server to android app in realtime when app is closed? Using foreground service or by using other channel?
Current Implentation:
When event is generated at server I am sending notifications to android app using FCM, some notification are with normal priority and some with high priority.
When notifications with high priority are sent to android app, app…

Mobile Developer
- 21
- 1
2
votes
1 answer
Android service not working when phone is idle / dozing / locked
Good evening,
I've been trying to achieve something for several days now and I literally don't know what else to try, I've basically tried everything I found online and it still doesn't work but I have the feeling that once I find the solution it…

Louen
- 27
- 5
2
votes
1 answer
Will foreground service work in not wake-up time of doze mode
Android foreground service is good mechanism to prevent app from getting into App Standby mode, but foreground service will also work even in Doze mode?
I mean, Not in short wakeup periodic time of Doze mode, but in majority of sleeping time of…

Knowledge Drilling
- 986
- 1
- 8
- 22
2
votes
1 answer
How to detect the maintenance window will be closed event in Doze mode?
I want to start a hard Worker.class, but when phone switching to Doze mode and then maintenance window comes sometimes is not enough time to finish Job and I need an event to close timers and to save databases

Igor Kostenko
- 2,754
- 7
- 30
- 57
2
votes
1 answer
BroadcastReceiver has no internet access
I'm facing a problem with my broadcast receiver.
I have set an alarm for 6am, it has to fire my broadcast receiver, which only has to download some data from internet and process it.
If I set the alarm for 3pm, for example, it works fine. But the…

Federico Alvarez
- 1,459
- 1
- 19
- 30
2
votes
0 answers
Is there any API to know whether APP is in stand by mode?
Suppose user has not interact with an app. So when does it go to standby mode.
If it went to standby mode. Is there any API to know that??

BharatProteemGogoi
- 145
- 1
- 10
2
votes
1 answer
Manage Internet connection on Android Nougat or Android Oreo with enabled Battery saver
I have trouble with managing correctly Internet connection on new Android versions when device is unlocked with enabled battery saver.
android.permission.INTERNET and android.permission.ACCESS_NETWORK_STATE permissions are added to the manifest…

Dmytro Batyuk
- 957
- 8
- 15
2
votes
1 answer
Battery Optimizations whitelist not preventing Doze from deferring my app
My app sends GPS location data to my server every 15 minutes. This functionality is the central purpose of the app.
However, the GPS logging tapers off when the phone is turned off and not in use. Time between GPS records is 15 minutes for a while,…

paperduck
- 1,175
- 1
- 16
- 26
2
votes
2 answers
How to build a radio app without being affected by doze android?
Refered to this library https://github.com/iammert/RadioPlayerService
I have this code for playing/pause radio
if (!mRadioManager.isPlaying())
mRadioManager.startRadio(RADIO_URL[0]);
else
…

Erald Haka
- 182
- 2
- 10
2
votes
0 answers
Xamarin.Android: Service stopps working when screen off (Doze / App Standby mode)
I have to implement a service were I transmit GPS (Lat/Lon) every 120 sec. to my REST backend.
I have the problem that the service seems to stop working when the screen is turned off.
Attempt with a StartedService and a BroadcastReceiver
Attempt…

Erich Brunner
- 612
- 5
- 19
2
votes
0 answers
Doze Mode battery optimization, device specific issue
I implemented ignore battery optimization functionality programmatically.
I found lots of questions and answers but i want to know that the IGNORE_BATTERY_OPTIMIZATIONS is works only for pure android or is there any other cases?
I have couple of…

RaRa
- 2,024
- 1
- 18
- 29
2
votes
2 answers
Is it possible to track when an app enters "Doze on the Go" (AKA Doze Light, Doze Extended, and Doze 2)?
In Android "N", Doze has been extended with "Doze on the Go".
I'm looking for a way to detect when the device enters and leaves these new light doze IDLE and IDLE_MAINTENANCE states. (Basically the same question that was asked for regular Doze…

TrevorWiley
- 848
- 1
- 7
- 16
2
votes
1 answer
Unplugging the device via ADB: "can't find service"
I have to test how my app behaves in doze mode. According to the documentation, I first must make the device think it's unplugged by entering the following command in the terminal:
$ adb shell dumpsys battery unplug
However, nothing happens and it…

Tim
- 41,901
- 18
- 127
- 145