![]() |
#1 |
Junior Member
![]() Posts: 6
Karma: 10
Join Date: Sep 2019
Device: KT4
|
Find out wakeup reason
After wakeup from sleep (echo mem > /sys/power/state), is there a reliable way, beside parsing dmesg, of finding it the wakeup was due to Button, RTC, or USB power?
OS is 5.12 (Linux 4.1). Thanks! |
![]() |
![]() |
![]() |
#2 |
Going Viral
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 17,212
Karma: 18210809
Join Date: Feb 2012
Location: Central Texas
Device: No K1, PW2, KV, KOA
|
What all have you tried and with what result?
(5.12.anything is rather new, you may be the first to have tried its behavior in this case.) Last edited by knc1; 09-23-2019 at 08:53 AM. |
![]() |
![]() |
Advert | |
|
![]() |
#3 |
BLAM!
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 13,506
Karma: 26047202
Join Date: Jun 2010
Location: Paris, France
Device: Kindle 2i, 3g, 4, 5w, PW, PW2, PW5; Kobo H2O, Forma, Elipsa, Sage, C2E
|
An rtc wakeup may trigger some extra logging from some of Amazon's stuff. But then again, maybe not if it wasn't setup by Amazon stuff ^^.
Otherwise, I don't think there's anything relevant in sysfs on those older kernels, but it can't hurt to take a look. |
![]() |
![]() |
![]() |
#4 |
Connoisseur
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 52
Karma: 616590
Join Date: Feb 2019
Device: K4 KT4 PW4 PW5
|
try:
Code:
POWERD_STATES=`lipc-get-prop -s com.lab126.powerd state` if [ "$POWERD_STATES" == "screenSaver" ] || [ "POWERD_STATES" == "suspended" ] ; then # caused by RTC not by button press fi |
![]() |
![]() |
![]() |
#5 | |
Going Viral
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 17,212
Karma: 18210809
Join Date: Feb 2012
Location: Central Texas
Device: No K1, PW2, KV, KOA
|
Quote:
(Use the "go advanced" editor choice to find and use the attachment functions.) |
|
![]() |
![]() |
Advert | |
|
![]() |
|
![]() |
||||
Thread | Thread Starter | Forum | Replies | Last Post |
RTC wakeup KT4 | yparitcher | Kindle Developer's Corner | 1 | 09-26-2019 02:06 PM |
Power consumption, sleep and wakeup issues | ansman | Kindle Developer's Corner | 9 | 02-10-2016 03:46 AM |
IQ PocketBook IQ: battery drain from random wakeup? | hiaig | PocketBook | 10 | 03-15-2011 09:16 AM |
【Best PDF Size】I find The reason of slowing When Read PDF file | linlance | Sony Reader | 0 | 03-11-2010 08:13 AM |