[Q] reading "dumpsys alarm" - Galaxy Tab 3 Q&A, Help & Troubleshooting

The following is an excerpt from "dumpsys alarm" command that I found puzzling.
Alarm Stats:
com.oasisfeng.greenify +712ms running, 3 wakeups:
+678ms 0 wakes 23 alarms: cmp={com.oasisfeng.greenify/com.oasisfeng.greenify.CleanerService}
+34ms 3 wakes 3 alarms: act=com.oasisfeng.greenify.CLEAN_NOW cmp={com.oasisfeng.greenify/com.oasisfeng.greenify.CleanerService}
Click to expand...
Click to collapse
Why is the wakeup count different from the alarm count?

Related

[Q] MortScript Backlight Status

How to use the mortscript to get the backlight status or sleep mode?
I had wrote a alarm script to announce the time with file.wav
I used the ToggleDisplay(ON) to wake up the phone to Start the program and ToggleDisplay(OFF) to end the program.
If the phone is at sleep mode, it work fine. but if the user is using the phone, my script also turn off the screen after alarm announce.. i wanna... to keep the original staus of phone while my alarm is running,, any idea to catch the status of backlight or sleep mode?
Here is some hint...courtesy xda_uc
Code:
# ReadBacklight TimeOut values and Disable Backlight TimeOut
############################################################
BattSuspendTimeout = RegRead ("HKLM", "System\CurrentControlSet\Control\Power\Timeouts","BattSuspendTimeout")
ACSuspendTimeout = RegRead ("HKLM", "System\CurrentControlSet\Control\Power\Timeouts","ACSuspendTimeout")
BatteryTimeout = RegRead ("HKCU", "ControlPanel\Backlight", "BatteryTimeout")
ACTimeout = RegRead ("HKCU", "ControlPanel\Backlight", "ACTimeout")
Brightness = RegRead ("HKCU", "ControlPanel\Backlight", "Brightness")
ACBrightness = RegRead ("HKCU", "ControlPanel\Backlight", "ACBrightness")
RegWriteDword ("HKLM", "System\CurrentControlSet\Control\Power\Timeouts","BattSuspendTimeout",0)
RegWriteDword ("HKLM", "System\CurrentControlSet\Control\Power\Timeouts","ACSuspendTimeout",0)
RegWriteDword ("HKCU", "ControlPanel\Backlight", "BatteryTimeout", 0)
RegWriteDword ("HKCU", "ControlPanel\Backlight", "ACTimeout", 0)
RegWriteDword ("HKCU", "ControlPanel\Backlight", "Brightness", 10)
RegWriteDword ("HKCU", "ControlPanel\Backlight", "ACBrightness", 10)
I don't want to Disable Backlight TimeOut , ijust want to get the status of screen on or off.
Thank Your Reply , I still have no idea about the registry which you point out.... Is it the value will be change at screen on or off status...
edwinho said:
I don't want to Disable Backlight TimeOut , ijust want to get the status of screen on or off.
Thank Your Reply , I still have no idea about the registry which you point out.... Is it the value will be change at screen on or off status...
Click to expand...
Click to collapse
Do you want to keep the script running all the time?
did you consider to use notifications?
it was long time I touched mort but you might get some ideas about reading backlight status and do notifications from "paplight" there is kaiser and rhodium versions.
as I remember it they didnt even turn light on, but not always get triggered too.
well thats all the trouble about different standby modes in winmo.
try it and come back with results.
Thank your suggestion!!!
Yes I want to keep the voice announcer at every 15 or 30 or 60 min something like that "Now is 11:30. AM" , My porgram is work through all the status of Phone, Sleeping or Using Status ... ..But have some bugs on phone screen on...I found no way or command can detect the screen on status with mortscript. I don't want to install another program to act as part of my script..... so i will try your suggestion... and find the way through notifications..
Thank!!
You first need to understand what registry does to your backlight...the answer you are looking for is in the code that i gave you. Good luck.
edwinho said:
How to use the mortscript to get the backlight status or sleep mode?
Click to expand...
Click to collapse
Simply impossible!
But you always can ask the MortScript professionals:
http://forum.xda-developers.com/showthread.php?t=289197
ok, with another thought I may have a solution. read below.
in an answer to:
ai6908 said:
You first need to understand what registry does to your backlight...the answer you are looking for is in the code that i gave you. Good luck.
Click to expand...
Click to collapse
i see you want to be helpfull, but actually those reg values you posted will not help him at all with what he need.
they read timeout values, not status. there might, and probably is a value in registry which can be used to detect standby thought.
I guess you can't avoid using notifications as you can't have the code running all the time. I would freeze uppon standby, or keep pda awake. but winmo standby is behaving strengly, it depends if you have flight mode, wifi, gprs on in standby...
safe way is to use notifications. even they sometimes didn't trigger on one of my winmo in flight mode.
first try if the light goes ON when running your script with notif. it might be that light would stay off.
if not... this is the trick..
make another script, which run nonstop and get started on system startup. just simple few lines:
while 1=1 {
- check the entry - "yourapp/lasttick" If lasttick older then one minute (60 sec) then write reg. "yourapp/standby=1" else "yourapp/standby=0"
- write reg. entry "yourapp/tick= actual time in unix format"
- sleep 60 ( or whatever, but this is needed otherwise you freeze your phone)
}
we assume this script will freeze on standby and will not "tick"
your main announce script then will check on your reg value you using in the first script.
you cant read standby value of it of course as it always would be 0 on start of main script until another tick of secondary script. you need to do both:
if time minus 60 > "yourapp/tick" OR "yourapp/standby = 0"
the second part would cover us in case tick would come right after start of notification and main script.
remember this would not cover all situations.. its just to show you what I meant to do.
runaway situation: user will press power to use the phone and notification will come during first 60 secs following it.
edwinho said:
ijust want to get the status of screen on or off.
Click to expand...
Click to collapse
This is an excerpt of a script I am using to turn off the screen, might help you to get an idea how to determine whether screen is off and/or on.
Code:
#
# adjust to your needs
Set STEP_WIDTH, "20"
Set SCREEN_OFF_EXE, "ScreenOff.exe"
Set FULLFILEPATHNAME_SCREEN_OFF_EXE, "\My Flash Disk\SystemProgs\" & SCREEN_OFF_EXE
Sleep 300
#
# initially set to false
turnOff = 0
#
black = RGB ( 0, 0, 0 )
# get screen dimensions
wdth = ScreenWidth()
hght = ScreenHeight()
#
# test each xth pixel per row and column
For w = 1 To (wdth - %STEP_WIDTH%) Step %STEP_WIDTH%
For h = 1 To (hght - %STEP_WIDTH%) Step %STEP_WIDTH%
#
# get pixel's color
clr = ColorAt( w, h )
#
# if pixel's color isn't black,
# set to true
If (clr <> black)
turnOff = 1
EndIf
Sleep 50
#
Next
Sleep 50
Next
#
#
check screen on/off status
Hi all,
i'm also interested in checking whether the screen is on or off and I had the same idea to check the color of pixels and "deduce" the screen status that way.
What I'm experiencing that ColorAt() function always returns the wallpaper color even if the phone is in stand by... and therefore that method seems not to work.
Don't know whether I do something wrong or if someone has experienced the same.
Waiting for news.
Thanks in advance

Disable alarm auto snooze?

Anyone know if you can do this? I feel like my alarm goes off for like 15 seconds before it snooze automatically for like 10 minutes. I need more tone for the alarm to get me moving lol

6.0.1 feature missing

Anyone else is missing the new 6.0.1 feature 'do not disturb ---- until next alarm'?. Coming from a 6P and it was there on the 6.0.1 update...
there is on mine. You need to set an alarm first
Like Red said, you need to have an alarm set first. AND... Any automatic "do no disturb" settings like, "every day from xx : xx to xx : xx" will override the "do not disturb until next alarm". So if you have the phone automatically do not disturb until 8am every day, but you need to wake up at 6am and set the do not disturb to until next alarm before your usual rules kick in... at 6am, do not disturb will not automatically turn off with the alarm. It'll stay on until 8am. Just FYI.
Thanks! Embarrassed, hehehe...
Enviado desde mi Nexus 9 mediante Tapatalk

Alarm bug

Today 2 of my alarms didn't sound and showed as missed. The third one sounded 3 minutes later.
When I go to alarms menu most of the time it does not show any alarm and don't allow me to create a new one(I can choose the time but it doesn't save it). I have to try many times to make it work.
Am I the only one with this bug?
The only alarm related bug I've seen on Q beta 3 are that the next alarm shown in the notification shade is shown as the end of the current calendar event (if one is in progress) or the start of the next calendar event. The next alarm shown on the AOD is also the current time +5 minutes.
I haven't missed any alarms to my knowledge.

Alarm for tizen

Bought a GW3 for my wife and got an Active 1st generation as a bonus, i dont use watches, just a xiaomi in bedtime as an a vibration alarm to not wake my wife. Tried the alarm on the active but it just gives one short vibration at a time, can I configured it to keep vibrating, or is there an alarm app no tizen that allow me to do so? I tried searching on Galaxy Store but could find one

Categories

Resources