java - alarm service not working in power saver mode of phone -


i have app using alarm service.using alarm service setting

pendingintent pendingintent = pendingintent.getbroadcast(this, 0,                 new intent("com.mindedges.pkg.intent.action.new_hour"),                 pendingintent.flag_update_current);  alarmmanager.setrepeating(alarmmanager.rtc_wakeup, alarmshedulehelper                 .getimmediatenexthour().gettimeinmillis(),                 alarmmanager.interval_hour, pendingintent); 

and there receiver , plays sound.

evertthing works fine on phone , of users , customers complain. " of time app fails show alarm , either few minutes late or when press power button unlock phone"

note customer have turned on power saver , have have included app active on standby mode

what possible reason?does alarm service not work in power saver mode?

related post :android alarmmanager.set(...): notification never received when battery low

i've empirically found timing repeating alarms wildly unpredictable. instance, when i've asked 35 minute period, i'll alarms @ 35 minutes intervals, hours apart, , within few minutes of each other.

i've found more predictable ask one-shot alarm , resubmit new 1 each time alarm fires.

that approach has apparently become google recommendation. alarmmanager page has following added description of setrepeating: "note: of api 19, repeating alarms inexact. if application needs precise delivery times must use one-time exact alarms, rescheduling each time described above. legacy applications targetsdkversion earlier api 19 continue have of alarms, including repeating alarms, treated exact."


Comments

Popular posts from this blog

Android layout hidden on keyboard show -

google app engine - 403 Forbidden POST - Flask WTForms -

c - Why would PK11_GenerateRandom() return an error -8023? -