Questions tagged [sleep-mode]

A power-saving condition of a computer or mobile device where it appears it is not on; the screen is not on and typically no sound is output. The computer's state is maintained in RAM.

Use this tag to identify questions related to checking on whether a device is in sleep mode, what capabilities are available in that mode, and how to "wake up" the device if appropriate.

206 questions
1
vote
1 answer

Sleeping mode on Android

My question is, what is the API for the sleep mode of a phone, if the phone is not used for a couple of minutes it goes into sleep mode right? Well what is the programming section on Android development is that?
Makar Emelyanov
  • 167
  • 5
  • 16
1
vote
3 answers

Best way for AutoHotkey v2 to send `Win+x`, `u`, `s` sequence

With AutoHotkey v2 I'm trying to put my computer to sleep using the sequence Win+x (to bring up the quick links menu), u (for "Shutdown…"), s (for "Sleep"). (If you know a better way to put the computer to sleep let me know, but this has been…
Garret Wilson
  • 18,219
  • 30
  • 144
  • 272
1
vote
0 answers

SupportFragmentManager is adding the same fragment multiple times when device is asleep

Like the title says. I have a dialogFragment I want to display in the click of a button. This works just fine. The problem is that when I put the phone to sleep with the fragment still showing, when I wake up the phone and reopen the app, there's…
1
vote
1 answer

React Native: Phone won't go to sleep while app is open

I'm trying to test some behavior in my React Native app when the phone goes to sleep, but the phone won't sleep when the app is open. I have the auto-lock set to 30s, and when the app's closed it does go to sleep. There are no keep-awake libraries…
gkeenley
  • 6,088
  • 8
  • 54
  • 129
1
vote
1 answer

File upload fails when phone screen turns off

In my web app, when submitting a form with a file to be uploaded, if the user pushes the button to turn the screen off before the upload finishes, it doesn't get uploaded. I'm assuming this is because the browser has been put into the background to…
McGrew
  • 812
  • 1
  • 9
  • 16
1
vote
1 answer

how to use Timer in sleep mode in watchkit

I am first in watchkit and I am going to make alarm app. After start app, app should play sound every some seconds(user can set this time interval). I am using Timer to count time interval, and if count time is 0 then play sound and resent timer…
Water Flower
  • 377
  • 7
  • 23
1
vote
0 answers

How to make sure a C# application will respond after waking up from sleep (windows 10)?

I have made a simple port listener which listens to a port, and if the sent request is satisfactory, it will put the computer to sleep. The application works when started, however, when I put the computer to sleep, and then wake it up; before…
meougal
  • 21
  • 1
1
vote
0 answers

SAMD21 or any other SAMx MCU : Pulse count in sleep mode

I have three external pins connected from the sensor to the SAMD21G18 MCU. The output of the sensor is voltage pulses on these three pins. I want to count the number of pulses with the timers peripherals. I want to count while sleeping. I want to…
Salvatore
  • 21
  • 2
1
vote
1 answer

How to put a GSM modem (e.g. SIM900A) to sleep mode?

As you probably guessed this question is not about a programming language but about arduino. I'm making a big project which includes a GSM SIM900A module but it draws too much power. I've looked up the datasheet but I didn't understand a lot as it…
1
vote
0 answers

CoreAudio: Is there any way to have active audio IO without preventing the system from sleeping?

I'm the author of an open source macOS HAL audio driver that acts as a proxy for another output audio device. It currently has an issue where, when the audio driver is loaded, it prevents the system from sleeping. This is because it is constantly…
Bri Bri
  • 2,169
  • 3
  • 19
  • 44
1
vote
1 answer

onResume and onPause loop when device in sleepmode?

When i put my device in sleep mode (lockscreen), the logcat gets flooded with calls to onPause and onResume this keeps looping and my broadcastreceivers keep getting unregistered and registered, it stops when i go back to the app. Is this normal? My…
Vince VD
  • 1,506
  • 17
  • 38
1
vote
1 answer

How to grab last time windows awoke from sleep or hibernate modes?

This question on superuser has some answers. I have looked through all the linked documentation provided, but it is a lot of documentation, and I do not really know what specific call I am looking for... Essentially what I am trying to do is grab…
M Y
  • 1,831
  • 4
  • 24
  • 52
1
vote
0 answers

Socket connection of an app stops when phone is not being charged

I have an chat app with socket.io and make a connection to the server. I don't know witch services and processes are turn off on stand by and when phone is not charging. When phone is on charger app works fine, connection is OK and stable, and…
1
vote
2 answers

MediaPlayer stops playing music from the internet after few minutes in sleep-mode

I have Android App which plays music from URL, but when my telephone goes to sleep-mode it plays 5 mins and then stops playing if I unlock my device its continue playing. I've tried this Playing music in sleep/standby mode in Android 2.3.3 solution…
Max Dev
  • 189
  • 1
  • 1
  • 12
1
vote
1 answer

Service interrupted when the phone falls asleep

In my application I start a service containing a fileobserver to monitor a directory. My problem is that after a while the service is interrupted and if you wake up the phone the service starts again. I also tried to hook the observer file to a…