wakeup

How do I create an Activity that is visible on top of the lock screen

99封情书 提交于 2019-12-03 02:37:48
I'm receiving an incoming C2DM notification while the screen is locked. I'd like to wake up the screen and display the notification message on top of the lock screen using an Activity. I'm launching the notification Activity from my C2DM BroadcastReceiver as follows: Intent new_intent= new Intent().setClass( context, EIAlertDialog.class ); new_intent.addFlags( Intent.FLAG_ACTIVITY_CLEAR_TOP ); new_intent.addFlags( Intent.FLAG_ACTIVITY_NEW_TASK ); context.startActivity( new_intent ); and within the notification Activity's onCreate method, I wake up the screen as follows: PowerManager

Wakelock is not turning on the screen? Help?

淺唱寂寞╮ 提交于 2019-12-01 12:54:57
I have a signal that puts my app to sleep for a given number of minutes (using AlarmManager) and then wakes it back up. Everything is working except the screen doesn't ever come on. I'm using a wakelock like so from a BroadcastReceiver class: KeyguardManager key = (KeyguardManager) context.getSystemService(Context.KEYGUARD_SERVICE); KeyguardLock lock = key.newKeyguardLock(TAG); lock.disableKeyguard(); Log.v(TAG, "alarm: disabled keyguard."); PowerManager pm = (PowerManager) context.getSystemService(Context.POWER_SERVICE); gpsMain.wl = pm.newWakeLock(PowerManager.SCREEN_BRIGHT_WAKE_LOCK, TAG);

Wakelock is not turning on the screen? Help?

纵饮孤独 提交于 2019-12-01 10:13:06
问题 I have a signal that puts my app to sleep for a given number of minutes (using AlarmManager) and then wakes it back up. Everything is working except the screen doesn't ever come on. I'm using a wakelock like so from a BroadcastReceiver class: KeyguardManager key = (KeyguardManager) context.getSystemService(Context.KEYGUARD_SERVICE); KeyguardLock lock = key.newKeyguardLock(TAG); lock.disableKeyguard(); Log.v(TAG, "alarm: disabled keyguard."); PowerManager pm = (PowerManager) context

Wake up Android Phone/tablet?

≡放荡痞女 提交于 2019-11-30 08:41:56
问题 I've got a push notification-app, is there any way to wake up the screen (just make it light up) whenever I receive a push notification? if you want some code just let me know! and Thank you for your answers! 回答1: You can do it using a WakeLock this way: When you set your notification: WakeLock screenOn = ((PowerManager)getSystemService(POWER_SERVICE)).newWakeLock(PowerManager.SCREEN_BRIGHT_WAKE_LOCK | PowerManager.ACQUIRE_CAUSES_WAKEUP, "example"); screenOn.acquire(); And, IMPORTANT ,

Wake the device up when app prompts user

戏子无情 提交于 2019-11-29 08:10:25
I'm using handler to repeatedly prompt user for an input every e.g. 5 minutes. When the device goes into sleeping mode and screen is locked, how can I wake the device up when my app prompts user for input? I've tried this but it doesn't seem to work. I've added WAKE_LOCK permission in the manifest. class BtHandler extends Handler { private PowerManager pm; private WakeLock wl; @Override public void handleMessage(Message msg) { pm = (PowerManager)FixedNode.this.getSystemService(Context.POWER_SERVICE); if (!pm.isScreenOn()) { wl = pm.newWakeLock(PowerManager.FULL_WAKE_LOCK, "TAG"); wl.acquire();

Wake up Android Phone/tablet?

对着背影说爱祢 提交于 2019-11-29 07:36:22
I've got a push notification-app, is there any way to wake up the screen (just make it light up) whenever I receive a push notification? if you want some code just let me know! and Thank you for your answers! You can do it using a WakeLock this way: When you set your notification: WakeLock screenOn = ((PowerManager)getSystemService(POWER_SERVICE)).newWakeLock(PowerManager.SCREEN_BRIGHT_WAKE_LOCK | PowerManager.ACQUIRE_CAUSES_WAKEUP, "example"); screenOn.acquire(); And, IMPORTANT , release the wakelock when you don't need it anymore: screenOn.release(); 来源: https://stackoverflow.com/questions

Is there a way to wakeup suspended app in iOS without user or server intervention

笑着哭i 提交于 2019-11-28 09:06:10
Is there way to wakeup iOS app without using "The significant-change location service"? I need to wakeup my app without server or user intervention Some thing similar to Alarm clock wherein you get an alert popup when it's time to wakeup. UILocalNotification - Won't work since it would need user and sever intervention. Silent Push Notifications - Won't work since you cannot send local notifications as Silent push notifications. These can only be sent by Server. Which means it would need Server intervention. Background Fetch - Won't work since there is not guaranteed trigger time. Am I missing

ARM: Start/Wakeup/Bringup the other CPU cores/APs and pass execution start address?

你离开我真会死。 提交于 2019-11-28 05:05:24
I've been banging my head with this for the last 3-4 days and I can't find a DECENT explanatory documentation (from ARM or unofficial) to help me. I've got an ODROID-XU board (big.LITTLE 2 x Cortex-A15 + 2 x Cortex-A7) board and I'm trying to understand a bit more about the ARM architecture. In my "experimenting" code I've now arrived at the stage where I want to WAKE UP THE OTHER CORES FROM THEIR WFI (wait-for-interrupt) state. The missing information I'm still trying to find is: 1. When getting the base address of the memory-mapped GIC I understand that I need to read CBAR; But no piece of

How to turn on monitor after wake-up from suspend mode? [closed]

∥☆過路亽.° 提交于 2019-11-28 02:03:08
问题 Closed . This question needs to be more focused. It is not currently accepting answers. Want to improve this question? Update the question so it focuses on one problem only by editing this post. Closed 2 years ago . I need to wake up a PC from sleep to perform some actions using C#. I've used CreateWaitableTimer functions, everything goes fine. At given time the PC wakes up but the monitor stays in power save mode (turned off)! So I want to know, how to turn the monitor ON after wake up? PS I

Wake the device up when app prompts user

北城余情 提交于 2019-11-28 01:40:10
问题 I'm using handler to repeatedly prompt user for an input every e.g. 5 minutes. When the device goes into sleeping mode and screen is locked, how can I wake the device up when my app prompts user for input? I've tried this but it doesn't seem to work. I've added WAKE_LOCK permission in the manifest. class BtHandler extends Handler { private PowerManager pm; private WakeLock wl; @Override public void handleMessage(Message msg) { pm = (PowerManager)FixedNode.this.getSystemService(Context.POWER