Questions tagged [power-saving]

For questions about optimising apps to save mobile power, or to manage the inbuilt power saving features within a device for an application. Needs to be used with relevant technology tags e.g. android Not to focus on the device end, but the application end of the technology.

For questions about optimising apps to save mobile power, or to manage the inbuilt power saving features within a device for an application. Needs to be used with relevant technology tags e.g. android.
Not to focus on the device end, but the application end of the technology.

72 questions
4
votes
1 answer

How to tell if screensaver is temporarily disabled?

Say, when a YouTube video is played via Google Chrome browser, or any video/sound in a Windows Media Player, both temporarily disable a screensaver if one is set up in a user's control panel. This happens only for the duration of the video being…
c00000fd
  • 20,994
  • 29
  • 177
  • 400
4
votes
1 answer

fine granularity nanosleep not power efficient in c++ program on linux

I am trying to call a sampling function periodically within a C++ thread on my linux machine. I would like to restart my function after a very short period, ideally 1 msec, but I'm finding that the power (in Watts) consumed for a 1 msec period is…
jst14
  • 43
  • 4
3
votes
1 answer

How to track (if possible) an Android device (latest versions) in the background at regular intervals?

Premise The user should always be informed of the use of his sensitive data (like collecting the location in the background), this question aims to better understand the latest limitations introduced on Android use of location and background…
Mattia
  • 31
  • 2
3
votes
0 answers

What is system API for stoping Doze for an App on Android Marshmallow

I am looking for android system API implementation for avoiding Doze for particular application. Rather requesting user to confirm adding in whitelisted app for doze.
Kdads
  • 31
  • 3
3
votes
2 answers

Is GPS more accurate when android tablet/phone is plugged in

If an android tablet (Nexus 7) is plugged into a power source, does the GPS stay on and therefore provide more accuracy? I am thinking of when a tablet is in a vehicle, mounted and always plugged in.
michael
  • 2,577
  • 5
  • 39
  • 62
2
votes
1 answer

Manually pairing Bluetooth Decives in Android?

I was reading this http://developer.android.com/guide/topics/wireless/bluetooth.html#QueryingPairedDevices which is allot of help on how to pair,connect to a bluetooth device. I have a situation where I have several BT devices that are in…
Piotr Kula
  • 9,597
  • 8
  • 59
  • 85
2
votes
1 answer

Continual wake and sleep for minimal power usage on linux?

I'd like to use a linux pc purely to collect rss feeds, but would like to minimise it's power usage as much as possible. Presumably I would create some kind of cron job to bring it in and out of sleep mode or are there better ways of tackling this?
Dan
  • 33,953
  • 24
  • 61
  • 87
2
votes
1 answer

How to get the thread execution state?

On Windows, each thread has an execution state which can be set by calling SetThreadExecutionState. For example, if a thread calls: SetThreadExecutionState(ES_CONTINUOUS | ES_DISPLAY_REQUIRED) then Windows will not turn off the display, until that…
MoaByter
  • 31
  • 3
2
votes
0 answers

Android - How to detect "Power Save mode" in Huawei or other devices?

I’m making some optimizations on my app for devices with "power saving mode" enabled. Here's the sample code: import android.content.Context; import android.os.PowerManager; import android.provider.Settings; //for MIUI private boolean…
2
votes
1 answer

streaming UDP packets with esp32 access point cause massive packet loss

I'm currently running my esp32 wroom as Access Point to stream UDP packets (~100 packets per second, 1Ko per packet) to different smartphones. At close range, I lost about 30% of the packets at steady rate. It not unusual to lose packets with UDP…
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

Android 9: how to get locations with power saving mode and screen off

As documented officially, Android 9 makes a number of improvements to battery saver mode. For example, location services may be disabled when the screen is off. See https://developer.android.com/about/versions/pie/power#battery-saver I tested it on…
adou600
  • 191
  • 2
  • 5
2
votes
2 answers

How to keep GPS receiver location updates when the app is in background ( Google Play Service Location API)

Sorry this is a long question, but I'm hoping that one of you experts out there can help a novice who is going quietly mad!! I have an Android app which uses a background service to get GPS fixes (using Google Play Services) every 20 seconds. It…
Chris S
  • 83
  • 3
  • 12
2
votes
1 answer

Battery impact of polling for location updates less often?

I've read a lot of conflicting information on this. Suppose I use the Fused Location API in PRIORITY_HIGH_ACCURACY mode, does it make much difference if I set the interval to, say, 10 minutes vs 1 minute? 1 hour vs 10 seconds? If so, how…
2
votes
1 answer

Is there a battery saving methode when reading GPS sensor in time intervals?

I'm developing an android app which collect GPS sensor data in time intervals programatically (one per 5min). So it drains the battery badly. Is there any way to optimize the power consumption? Is there a way to disable or sleep GPS sensor when it…