Hello,
is it possible to get the status of the alarm clock. I will trigger if a special alarm clock is enabled or or not. I have a Samsung Galaxy and I have two different alarms. One for the normal work week and one for special things which I use sporadic. I will trigger on the status of the alarm for the normal work week.
Has anyone an idea?
Thanks in advance for your help!
Alarm clock Trigger
Moderator: Martin
Re: Alarm clock Trigger
Is it trigger for the special or normal? (confused with your contradicting statement)
If it is regular, why don't just use Trigger : Time? Set the time to be the same as the alarm.
If it is special, you have to retrieve the data from the app which set the alarm. Usually it will set the value for the next alarm (trigger).
If it is not there, you should give Automagic write secure setting permission in PC through adb.
And then you can query the value for next_alarm_formatted in setting database - System.
If it is regular, why don't just use Trigger : Time? Set the time to be the same as the alarm.
If it is special, you have to retrieve the data from the app which set the alarm. Usually it will set the value for the next alarm (trigger).
If it is not there, you should give Automagic write secure setting permission in PC through adb.
And then you can query the value for next_alarm_formatted in setting database - System.
Index of Automagic useful thread List of my other useful posts (and others')
Xiaomi Redmi Note 5 (whyred), AOSP Extended v6.7 build 20200310 Official, Android Pie 9.0, Rooted.
Xiaomi Redmi Note 5 (whyred), AOSP Extended v6.7 build 20200310 Official, Android Pie 9.0, Rooted.
Re: Alarm clock Trigger
Sorry for the confusion .
I have one alarm in my standard samsung alarm clock for my work under the week and one for special things for work when I have to wake up at another time. I will trigger the on off status of these two alarms. Could I do that with the standard triggers or do I have to make a script? I am new in this topic ( android deep programming and al these things ) but I have many experience in other software things. So please excuse if I ask more than twice to your answers.
I have one alarm in my standard samsung alarm clock for my work under the week and one for special things for work when I have to wake up at another time. I will trigger the on off status of these two alarms. Could I do that with the standard triggers or do I have to make a script? I am new in this topic ( android deep programming and al these things ) but I have many experience in other software things. So please excuse if I ask more than twice to your answers.
Re: Alarm clock Trigger
So you want to detect if the regular or special alarm is active, then do something. The value next_alarm seems to provide only value for the next alarm only, but can't detect any status of the alarm.
The workaround is you have to create the alarm in automagic. I also use double alarm, one from android and another one from automagic (to make sure I really wake up). Use Time Trigger, notification and some Message Dialog/Confirmation Dialog. If you use confirm dialog, you can choose to snooze 5 minutes or stop the alarm. From there you can use script to set some Global variable to a state. Example global_regular_alarm = 1 or 0 if the alarm is off.
Then use Trigger Global Variable to check the state of the global_regular_alarm and do something when it changes.
The workaround is you have to create the alarm in automagic. I also use double alarm, one from android and another one from automagic (to make sure I really wake up). Use Time Trigger, notification and some Message Dialog/Confirmation Dialog. If you use confirm dialog, you can choose to snooze 5 minutes or stop the alarm. From there you can use script to set some Global variable to a state. Example global_regular_alarm = 1 or 0 if the alarm is off.
Then use Trigger Global Variable to check the state of the global_regular_alarm and do something when it changes.
Index of Automagic useful thread List of my other useful posts (and others')
Xiaomi Redmi Note 5 (whyred), AOSP Extended v6.7 build 20200310 Official, Android Pie 9.0, Rooted.
Xiaomi Redmi Note 5 (whyred), AOSP Extended v6.7 build 20200310 Official, Android Pie 9.0, Rooted.