I set multiple alarms and in order to control them I change my phone's time. They will work normally ? What In other words, will alarms collapse if I change my phone's time?
Asked
Active
Viewed 172 times
2 Answers
1
Well it all depends on the type you have passed in the set method of alarm Manger.
if you have used ELAPSED_REALTIME or ELAPSED_REALTIME_WAKEUP, alarm will not trigger
ELAPSED_REALTIME
Added in API level 1
int ELAPSED_REALTIME
Alarm time in SystemClock.elapsedRealtime() (time since boot, including sleep). This alarm does not wake the device up; if it goes off while the device is asleep, it will not be delivered until the next time the device wakes up.
if you have user RTC or RTC_WAKEUP, alarm will be triggered according the device time
RTC
Added in API level 1
int RTC
Alarm time in System.currentTimeMillis() (wall clock time in UTC). This alarm does not wake the device up; if it goes off while the device is asleep, it will not be delivered until the next time the device wakes up.

Suhaib Roomy
- 2,501
- 1
- 16
- 22
0
I don't know what you mean by collapse. But the alarm is only aware of the device's time and so if you do change your device time, it should work against that instead.

Passer by
- 562
- 9
- 14