Questions tagged [doze]

45 questions
6
votes
2 answers

setAlarmClock() fires too late in doze mode

I have soooo much trouble getting my radio alarm clock working as intended and I have read a lot of threads here about that topic, but unfortunatley none did help me. AlarmManager am = (AlarmManager) getSystemService(ALARM_SERVICE); Intent…
Ben
  • 265
  • 3
  • 13
5
votes
0 answers

Wake up android app via push notification while in doze without FCM

Greatings! We are developing an android app with Xamarin that has to meet the following restrictions: wifi yes, but no internet connection no FCM/google play services (app should also work in China) push messages from a Manager-SW (uses…
Qi2019
  • 51
  • 3
5
votes
1 answer

Is it possible to completely disable the Doze mode and Standby mode?

I have a requirement to create an app that should run 24/7. I don't care about battery drain, becoz app will not be submitted to PlayStore and its only for the selected user.I also understand app will only last for one day, that is acceptable in my…
Jess
  • 85
  • 1
  • 8
4
votes
1 answer

How I can avoid battery optimization of Samsung devices? (S6, S7 and S8)

I have a GPS tracking Android app that receives continuous push messages when someone requires user's position. Everytime that I receive a push, I start the location service that send positions during X time while he is receiving push messages. The…
Xose
  • 544
  • 1
  • 4
  • 12
4
votes
1 answer

Android doze mode influence

Have read a lot of documentation but did not find an answer for next question. If we have an app that should not be affected by doze (for example app with foreground service) will it also prevent other apps from being affected by doze? Point of…
Ihor DIM
  • 689
  • 1
  • 10
  • 22
4
votes
1 answer

Does moving the device wake it up from DOZE

I'm seeking information regarding the specific behavior of Android device during DOZE mode, also known as Idle mode. My app provides sensor info periodically with setExactAndAllowIdle() method. This of course doesn't work perfectly, but since the…
3
votes
0 answers

keeping a background service alive on Android 11

I have created an Enterprise mobility managament (EMM)app. When i launched it a few years ago my customer base probably had Android < 8 devices. I've recently had to update my app and the customer base are now using Android 11 devices. The…
turtleboy
  • 8,210
  • 27
  • 100
  • 199
3
votes
1 answer

Doze mode vs Network Status

I am developing an app to check Wi-Fi status. If there aren't Wi-Fi connection, the app has to show the disconnect symbol. From Marshmallow onwards, if the device enters in "Doze mode", my device network enters into suspended mode. If I wake my…
kavie
  • 2,154
  • 4
  • 28
  • 53
3
votes
0 answers

foreground location service with doze mode not working as expected

I have created a sample foreground service to check if it's possible to fetch location from background after every 15 mins or 30 mins. With introduction to doze mode alarm manager does not work at exact time. In foreground service I have tried…
3
votes
0 answers

Android Service stops on Nougat

I made an app to display battery and network info in the status bar. For over 10 months the app did a 100% reliable job on a Nexus 6P (Marshmallow). After I switched to a Pixel (Nougat 7.1.2) I recognised that the service seems to be getting…
Martin Pfeffer
  • 12,471
  • 9
  • 59
  • 68
2
votes
1 answer

How to change battery optimization settings manually AFTER requesting to ignore battery optimizations?

I use the following code to request ignore battery optimzation for an app. I can successfully request the permission. I am able to detect if the app is on the system's whitelist using isIgnoringBatteryOptimizations().
Air
  • 41
  • 2
  • 4
2
votes
0 answers

WebSocket in ForegroundService stops

i am currently building an Android App that connects via a WebSocket (via Java WebSockets from TooTallNate) to a Server.The Problem is that on my Moto Z Play (Android 8.0) and my Acer Iconia A3-A40 (Android 6.0) the WebSocket gets closed after a…
gabel
  • 21
  • 2
2
votes
2 answers

How to make a periodic background work (15 mins periodic interval) to run indefinitely on Oreo and later?

After Doze Mode was introduced in Android 8, Android has enforced many restrictions on background work which makes the app behave in an unintended way. In one of my apps , I used to fetch Battery Level every 15 mins and fire an alarm if battery…
Abhishek Luthra
  • 2,575
  • 1
  • 18
  • 34
2
votes
0 answers

ForgroundService affected by doze mode

My Alarm App keeps being late, although I'm starting a ForegroundService from the BroadcastReceiver and the onCreate() of the Service gehts called in time, but the onStartCommand() is called with delay (sometimes), which I assume is coming from the…
Ben
  • 265
  • 3
  • 13
2
votes
0 answers

Getting location updates when in idle mode

I have to find a solution to get location updates when in doze mode. It doesn't matter if the updates are continuous or for every 5 min or more. At the moment I have a foreground service that acquires a wake lock with a LocationListener in it. The…
dennis
  • 33
  • 4
1
2 3