Allowing the phone to sleep while using RTC alarm on Android

后端 未结 2 1861
终归单人心
终归单人心 2021-01-18 06:40

I\'ve been seeing some strange issues using the Alarm manager in Android, despite the fact that I\'m using RTC (non Wakeup) the phone will reliably send the PendingIntents o

2条回答
  •  暖寄归人
    2021-01-18 07:08

    I've just spent an hour trying to find out why my RTC alarm sends PendingIntents even when my phone is sleeping. And the answers is very simple, because it was pluged with USB so the phone had status "charging".

    Presumably something else was having the device awake at those moments.

    A lot of applications with notification ads (like AirPush, Leadbolt ect) wake up the device.

提交回复
热议问题