mirror of
https://github.com/koreader/koreader.git
synced 2025-08-10 00:52:38 +00:00
Tested in Kobo Aura HD. Suspend can still be interrrupted if user touches the screen after slided the power button and before the suspend function is called (2s delay). Reason for this is still unkown.
16 lines
277 B
Bash
16 lines
277 B
Bash
#!/bin/sh
|
|
export PATH=$PATH:/sbin:/usr/sbin
|
|
|
|
#disable wifi
|
|
if lsmod | grep -q sdio_wifi_pwr ; then
|
|
wlarm_le -i eth0 down
|
|
ifconfig eth0 down
|
|
/sbin/rmmod -r dhd
|
|
/sbin/rmmod -r sdio_wifi_pwr
|
|
fi
|
|
|
|
#go to sleep
|
|
sync
|
|
echo 1 > /sys/power/state-extended
|
|
echo mem > /sys/power/state
|