koreader/koreader — pull request #269 by giorgio130 (2013-09-09 19:37:44+00:00)
Title: (Almost Working) Suspend support for kobos

There is still a problem I can't figure out.
```
function Device:Suspend()
UIManager:show(InfoMessage:new{
text = _("Standby"),
timeout = 4,
})
Screen:refresh(0)
local fl = self:getFrontlight()
if fl ~= nil then
fl:sleep()
end
util.usleep(1500000)
self.screen_saver_mode = true
os.execute("./kobo_suspend.sh")
end
```
regardless of the value I put for usleep, the device gets suspended before the InfoMessage can be shown or the light can be turned off. So right now suspend works, but there's no visual clue about that. Also if you forget to turn off the light it keeps draining the battery. Any help appreciated!