Page 1 of 1

rtc wakealarm not working as expected

Posted: 09 Sep 2023, 19:10
by gplben
Hi. Porteus Kiosk works perfectly for me except for wake from suspend.

I'm initially trying to use the rtc_wake parameter to wake from suspend (S3 state) in this way:

Code: Select all

rtc_wake=Monday-09:30 Tuesday-12:30 Wednesday-09:30 Thursday-09:30 Friday-09:30 Saturday-09:30
It doesn't seem to work as expected for me so, I've tried to troubleshoot via SSH with these steps:

Clear the wakealarm:

Code: Select all

echo 0 > /sys/class/rtc/rtc0/wakealarm
Add a wakealarm for 3 minutes from now:

Code: Select all

echo $(date +%s -d "+ 3 minutes") > /sys/class/rtc/rtc0/wakealarm
Display the results:

Code: Select all

cat /sys/class/rtc/rtc0/wakealarm
I enter the results in https://www.epochconverter.com to verify it added the correct time 3 minutes from now.

Suspend the machine:

Code: Select all

echo mem >/sys/power/state
The machine does not wake on its own 3 minutes later. It will only wake by pressing the keyboard.

I booted the same machine into Lubuntu 23.04, followed the same steps as above and it wakes after 3 minutes as expected.

Any thoughts on why it doesn't wake as expected in Porteus Kiosk 5.5?

Thanks much!

rtc wakealarm not working as expected

Posted: 10 Sep 2023, 12:33
by fanthom
Hello gplben,

Does it wake if you power off the PC completely?

Thanks

rtc wakealarm not working as expected

Posted: 11 Sep 2023, 18:16
by gplben
Fanthom,
After a few hours of frustration, I believe that I've determined that it was UTC that was throwing me off and the rtc_wake parameter is now working.

I had initially put

Code: Select all

run_command=sleep 20; hwclock --systohc
into my config because the hardware clock was 4 hours off when I'd look at the BIOS.

I put that command in there only after I noticed that rtc_wake was not working. I think I was not patient enough initially, because I think Porteus Kiosk runs the RTC wake script every 60 seconds after booting. I wasn't waiting that long in my troubleshooting.

At least I think something like that was happening.

Thanks for taking the time to respond, but I believe all is well now!