Register Guidelines E-Books Search Today's Posts Mark Forums Read

Go Back   MobileRead Forums > E-Book Software > KOReader

Notices

Reply
 
Thread Tools Search this Thread
Old 01-28-2016, 10:05 PM   #1
embryo
Addict
embryo is out to avenge the death of his or her father, Domingo Montoya.embryo is out to avenge the death of his or her father, Domingo Montoya.embryo is out to avenge the death of his or her father, Domingo Montoya.embryo is out to avenge the death of his or her father, Domingo Montoya.embryo is out to avenge the death of his or her father, Domingo Montoya.embryo is out to avenge the death of his or her father, Domingo Montoya.embryo is out to avenge the death of his or her father, Domingo Montoya.embryo is out to avenge the death of his or her father, Domingo Montoya.embryo is out to avenge the death of his or her father, Domingo Montoya.embryo is out to avenge the death of his or her father, Domingo Montoya.embryo is out to avenge the death of his or her father, Domingo Montoya.
 
embryo's Avatar
 
Posts: 344
Karma: 34919
Join Date: Aug 2013
Device: Kobo Glo
KoReader's suspend problem on Kobos

Since KoReader has its own forum now, I can start a thread for an old, much discussed problem.

The random battery drainage when KoReader is in suspend mode.

I first noticed it around Aug/2014 and I did some experiments since then with no luck.
Many people have tried various things without success.
Lately I use this handy mod to power off the device instead of putting it to sleep.

There was this post at the main KoReader thread that make me try once again to substitute the KoReader's suspend script with that of the CoolReader's.
I used a 2015.05 version to extract the script.

The result was that after a night in suspend, the battery went from 100% to 77%, which shows that nothing changed.
At least with my Glo.
But since there is similar behavior with other models, so maybe its a common problem with a common fix...
embryo is offline   Reply With Quote
Old 01-29-2016, 03:06 AM   #2
church mouse
Groupie
church mouse ought to be getting tired of karma fortunes by now.church mouse ought to be getting tired of karma fortunes by now.church mouse ought to be getting tired of karma fortunes by now.church mouse ought to be getting tired of karma fortunes by now.church mouse ought to be getting tired of karma fortunes by now.church mouse ought to be getting tired of karma fortunes by now.church mouse ought to be getting tired of karma fortunes by now.church mouse ought to be getting tired of karma fortunes by now.church mouse ought to be getting tired of karma fortunes by now.church mouse ought to be getting tired of karma fortunes by now.church mouse ought to be getting tired of karma fortunes by now.
 
church mouse's Avatar
 
Posts: 197
Karma: 4850174
Join Date: Oct 2009
Location: UK
Device: Kobo Glo, Aura H2O, Tolino Vision 3HD
I was one of those who was having significant battery drainage during suspend on my H2O, however a combination of the following changes seems to have fixed the issue for me:

1. Replaced the Koreader suspend.sh with the suspend.sh from Coolreader (vlasovsoft)

2. Within the new suspend.sh I commented out the line . $ROOT/wifi_off.sh (Koreader does not have wifi_off.sh in Root and hunting for it seemed to make the suspend.sh unreliable). I do not use wifi so simply commenting out the line works for me.

3. Within frontend/device/kobo/device.lua I commented out the line [59] = "Power_SleepCover" (this is because I have a sleepcover, which also seemed to add unreliability in the suspend process in Koreader, which has no direct option to disable Sleepcover).

4. Finally, but this may be completely unnecessary, I extended to "12" from "10" the time in the line for UIManager:scheduleIn in frontend/device/generic/device.lua

All of my changes came from me sifting through the invaluable posts of much cleverer others both here and on Github. I don't know if they are all necessary, but they do seem to have worked for me.
church mouse is offline   Reply With Quote
 
Advertisement
Old 01-29-2016, 07:30 AM   #3
Alan_S
Groupie
Alan_S doesn't litterAlan_S doesn't litter
 
Alan_S's Avatar
 
Posts: 172
Karma: 152
Join Date: Aug 2007
Location: Sisak, Croatia
Device: Sony PRS650, Kobo Aura H2O
That's really strange, I mean, this business with suspending koreader not working.

For example, I don't use WiFi at all (with my H2O that is, not at all with my other devices) and I didn't change CoolReader's suspend script in any way. And while testing CoolReader's suspend script I used magetic cover to suspend device on and off.

I know that my 50 days of suspending device on one charge might be just pure luck, although very long streak of luck.

There also may be reasons why suspending doesn't work in same way for different kobo devices?
Alan_S is online now   Reply With Quote
Old 01-29-2016, 11:04 AM   #4
embryo
Addict
embryo is out to avenge the death of his or her father, Domingo Montoya.embryo is out to avenge the death of his or her father, Domingo Montoya.embryo is out to avenge the death of his or her father, Domingo Montoya.embryo is out to avenge the death of his or her father, Domingo Montoya.embryo is out to avenge the death of his or her father, Domingo Montoya.embryo is out to avenge the death of his or her father, Domingo Montoya.embryo is out to avenge the death of his or her father, Domingo Montoya.embryo is out to avenge the death of his or her father, Domingo Montoya.embryo is out to avenge the death of his or her father, Domingo Montoya.embryo is out to avenge the death of his or her father, Domingo Montoya.embryo is out to avenge the death of his or her father, Domingo Montoya.
 
embryo's Avatar
 
Posts: 344
Karma: 34919
Join Date: Aug 2013
Device: Kobo Glo
Quote:
Originally Posted by church mouse View Post
1. Replaced the Koreader suspend.sh with the suspend.sh from Coolreader (vlasovsoft)
OK, done that.

Quote:
2. Within the new suspend.sh I commented out the line . $ROOT/wifi_off.sh (Koreader does not have wifi_off.sh in Root and hunting for it seemed to make the suspend.sh unreliable). I do not use wifi so simply commenting out the line works for me.
There is no line like this in the script I've got.
Maybe its an older script?
Mine checks for the wifi status with this:
Code:
# 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
Quote:
3. Within frontend/device/kobo/device.lua I commented out the line [59] = "Power_SleepCover" (this is because I have a sleepcover, which also seemed to add unreliability in the suspend process in Koreader, which has no direct option to disable Sleepcover).
Since I don't have a sleepcover, this will not change anything I guess...

Quote:
4. Finally, but this may be completely unnecessary, I extended to "12" from "10" the time in the line for UIManager:scheduleIn in frontend/device/generic/device.lua
Is this some kind of delay before the suspend is executed?
I'll change that to 20 and see how it goes...
embryo is offline   Reply With Quote
Old 01-30-2016, 05:57 AM   #5
Alan_S
Groupie
Alan_S doesn't litterAlan_S doesn't litter
 
Alan_S's Avatar
 
Posts: 172
Karma: 152
Join Date: Aug 2007
Location: Sisak, Croatia
Device: Sony PRS650, Kobo Aura H2O
This is CoolReader's suspend script I'm using (just for everyone to be sure which one is used in my testing):

Code:
#!/bin/sh

export PATH=$PATH:/sbin:/usr/sbin

echo "suspend.sh: enter"

handler()
{
    kill -15 $pid
    echo 0 > /sys/power/state-extended
    echo "suspend.sh: killed"
    exit 1
}

trap handler SIGTERM

sleep 10 &
pid=$!
wait $pid

# 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

echo 1 > /sys/power/state-extended
echo "suspend.sh: delay 2s (dragon)"
sleep 2 &
pid=$!
wait $pid

echo "sleeping... zzz-zzz-zzz-zzz :)"
sync
echo mem > /sys/power/state
echo 0 > /sys/power/state-extended

echo "suspend.sh: normal exit"
This is first mentioned in this post.
Alan_S is online now   Reply With Quote
Old 01-30-2016, 09:06 AM   #6
church mouse
Groupie
church mouse ought to be getting tired of karma fortunes by now.church mouse ought to be getting tired of karma fortunes by now.church mouse ought to be getting tired of karma fortunes by now.church mouse ought to be getting tired of karma fortunes by now.church mouse ought to be getting tired of karma fortunes by now.church mouse ought to be getting tired of karma fortunes by now.church mouse ought to be getting tired of karma fortunes by now.church mouse ought to be getting tired of karma fortunes by now.church mouse ought to be getting tired of karma fortunes by now.church mouse ought to be getting tired of karma fortunes by now.church mouse ought to be getting tired of karma fortunes by now.
 
church mouse's Avatar
 
Posts: 197
Karma: 4850174
Join Date: Oct 2009
Location: UK
Device: Kobo Glo, Aura H2O, Tolino Vision 3HD
. $ROOT/wifi_off.sh will be found in the suspend.sh in the pbchess-2015.12_kobo build (the latest version, I think). The suspend.sh script differs from earlier builds.
church mouse is offline   Reply With Quote
Old 01-30-2016, 05:32 PM   #7
embryo
Addict
embryo is out to avenge the death of his or her father, Domingo Montoya.embryo is out to avenge the death of his or her father, Domingo Montoya.embryo is out to avenge the death of his or her father, Domingo Montoya.embryo is out to avenge the death of his or her father, Domingo Montoya.embryo is out to avenge the death of his or her father, Domingo Montoya.embryo is out to avenge the death of his or her father, Domingo Montoya.embryo is out to avenge the death of his or her father, Domingo Montoya.embryo is out to avenge the death of his or her father, Domingo Montoya.embryo is out to avenge the death of his or her father, Domingo Montoya.embryo is out to avenge the death of his or her father, Domingo Montoya.embryo is out to avenge the death of his or her father, Domingo Montoya.
 
embryo's Avatar
 
Posts: 344
Karma: 34919
Join Date: Aug 2013
Device: Kobo Glo
Thank you.
I was getting the coolreader builds from here, and I thought it was abandoned.
Checking its forum, I found the 15.12 build and got the suspend.sh from there.
I will try it after some days, because since I changed that delay value, the reader seems to behaves normally.
Could be a coincidence, so I have to give it some more days...
Quote:
Originally Posted by church mouse View Post
. $ROOT/wifi_off.sh will be found in the suspend.sh in the pbchess-2015.12_kobo build (the latest version, I think). The suspend.sh script differs from earlier builds.
embryo is offline   Reply With Quote
Old 01-31-2016, 06:56 AM   #8
Alan_S
Groupie
Alan_S doesn't litterAlan_S doesn't litter
 
Alan_S's Avatar
 
Posts: 172
Karma: 152
Join Date: Aug 2007
Location: Sisak, Croatia
Device: Sony PRS650, Kobo Aura H2O
Looking at my version, it's 2015.07, so I used older version from latest in my testing.
Alan_S is online now   Reply With Quote
Old 02-01-2016, 08:37 AM   #9
NiLuJe
BLAM!
NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.
 
NiLuJe's Avatar
 
Posts: 6,973
Karma: 6553737
Join Date: Jun 2010
Location: Paris, France
Device: Kindle 2i, 3g, 4, 5w, (PW) & PW2; Kobo H2O
If all it takes is another 2s more of delay, I'll take that .
NiLuJe is offline   Reply With Quote
Old 02-04-2016, 08:29 AM   #10
embryo
Addict
embryo is out to avenge the death of his or her father, Domingo Montoya.embryo is out to avenge the death of his or her father, Domingo Montoya.embryo is out to avenge the death of his or her father, Domingo Montoya.embryo is out to avenge the death of his or her father, Domingo Montoya.embryo is out to avenge the death of his or her father, Domingo Montoya.embryo is out to avenge the death of his or her father, Domingo Montoya.embryo is out to avenge the death of his or her father, Domingo Montoya.embryo is out to avenge the death of his or her father, Domingo Montoya.embryo is out to avenge the death of his or her father, Domingo Montoya.embryo is out to avenge the death of his or her father, Domingo Montoya.embryo is out to avenge the death of his or her father, Domingo Montoya.
 
embryo's Avatar
 
Posts: 344
Karma: 34919
Join Date: Aug 2013
Device: Kobo Glo
Well, the news are bad.
After some normal behavior but with a couple of big drainages (15-20% overnight) the final straw was that after a day left in suspend with 43%, it went dead (0%).
So the delay is not working, or not working all the time, or is unrelated.

The problem is that I don't have anything else to check, since as I saw, the older scripts are identical to the new one with the exception of the wifi_off section that is just separated to a script of its own (maybe to be used from elsewhere too).

Something that could be worth checking is the preventfreeze script from KSM, that I can not disable otherwise my Glo freezes. I thing some of the other Kobo models don't need it.
It could be nice if the suspend script could disable/enable it.
The code is simple:
Code:
while :
do
  sleep 1
done
but maybe prevents the reader to really suspend.

Other than that I will up the delay to 30 just in case ...
embryo is offline   Reply With Quote
Old 02-04-2016, 08:54 AM   #11
Alan_S
Groupie
Alan_S doesn't litterAlan_S doesn't litter
 
Alan_S's Avatar
 
Posts: 172
Karma: 152
Join Date: Aug 2007
Location: Sisak, Croatia
Device: Sony PRS650, Kobo Aura H2O
Quote:
Originally Posted by embryo View Post
the final straw was that after a day left in suspend with 43%, it went dead (0%).
For my device, 43% is pretty low, at that time I seriously start thinking about charging battery, so it looks like "normal" draining. Of course, it's not normal, it should lasted more, but well...

Did you tried suspend script I posted here? For some reason it looks like it works on my device. But, of course, further testing could disprove this.
Alan_S is online now   Reply With Quote
Old 02-04-2016, 10:35 AM   #12
embryo
Addict
embryo is out to avenge the death of his or her father, Domingo Montoya.embryo is out to avenge the death of his or her father, Domingo Montoya.embryo is out to avenge the death of his or her father, Domingo Montoya.embryo is out to avenge the death of his or her father, Domingo Montoya.embryo is out to avenge the death of his or her father, Domingo Montoya.embryo is out to avenge the death of his or her father, Domingo Montoya.embryo is out to avenge the death of his or her father, Domingo Montoya.embryo is out to avenge the death of his or her father, Domingo Montoya.embryo is out to avenge the death of his or her father, Domingo Montoya.embryo is out to avenge the death of his or her father, Domingo Montoya.embryo is out to avenge the death of his or her father, Domingo Montoya.
 
embryo's Avatar
 
Posts: 344
Karma: 34919
Join Date: Aug 2013
Device: Kobo Glo
Quote:
Originally Posted by Alan_S View Post
For my device, 43% is pretty low, at that time I seriously start thinking about charging battery, so it looks like "normal" draining. Of course, it's not normal, it should lasted more, but well...
There is a problem with the power meter accuracy in koreader.
The only way I found to see the actual percent is by exiting the koreader and go to the KSM>Tools>checkbattery.sh, or Nickel.
So yes, when you see 43% just in koreader it might be really much lower, but not in my case.
Quote:
Originally Posted by Alan_S View Post
Did you tried suspend script I posted here? For some reason it looks like it works on my device. But, of course, further testing could disprove this.
As I said, all the scripts are exactly the same with the exception of the wifi section that is moved to an other script in 2015.12 version.
That version does not close the wifi, but other than that its the same.
embryo is offline   Reply With Quote
Old 02-04-2016, 04:43 PM   #13
NiLuJe
BLAM!
NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.
 
NiLuJe's Avatar
 
Posts: 6,973
Karma: 6553737
Join Date: Jun 2010
Location: Paris, France
Device: Kindle 2i, 3g, 4, 5w, (PW) & PW2; Kobo H2O
To be exact, there's a problem with what the OS (and/or the HW itself) tells us about the battery status in general, it's potentially as bad in nickel .
The battery status in the top menu should always be up to date (as far as the OS tells us).

I don't know about the infinite loop script, since I don't use KSM and don't have an affected device anyway, but, yeah, killing it might be a good thing to try. But since it's not KOReader's job to launch it, it'd need some patching on KSM's side to make sure it's restarted if need be? Or something.
NiLuJe is offline   Reply With Quote
Old 02-05-2016, 07:58 AM   #14
Alan_S
Groupie
Alan_S doesn't litterAlan_S doesn't litter
 
Alan_S's Avatar
 
Posts: 172
Karma: 152
Join Date: Aug 2007
Location: Sisak, Croatia
Device: Sony PRS650, Kobo Aura H2O
For faulty battery reading, I noticed that on numerous devices, not just kobos. Even my cell phone (or mobile, however it's called in your country) was stuck in 55% from different apps for battery monitoring for days, till I "forced" reading.

What I want to say, it really can be something deeper in system (i.e. linux), not koreader related.

Only real problem I see here is that koreader's suspend script doesn't enable device's battery to last as long as it last with nickel or CoolReader. On the other hand, I have workaround, to shut device off.
Alan_S is online now   Reply With Quote
Old 02-13-2016, 08:34 PM   #15
embryo
Addict
embryo is out to avenge the death of his or her father, Domingo Montoya.embryo is out to avenge the death of his or her father, Domingo Montoya.embryo is out to avenge the death of his or her father, Domingo Montoya.embryo is out to avenge the death of his or her father, Domingo Montoya.embryo is out to avenge the death of his or her father, Domingo Montoya.embryo is out to avenge the death of his or her father, Domingo Montoya.embryo is out to avenge the death of his or her father, Domingo Montoya.embryo is out to avenge the death of his or her father, Domingo Montoya.embryo is out to avenge the death of his or her father, Domingo Montoya.embryo is out to avenge the death of his or her father, Domingo Montoya.embryo is out to avenge the death of his or her father, Domingo Montoya.
 
embryo's Avatar
 
Posts: 344
Karma: 34919
Join Date: Aug 2013
Device: Kobo Glo
Just to conclude this experiment with the use of cool reader suspend script, I have to state that for my Glo it totally failed.

There where randomly times that it seemed it was working, but also times that I was losing more than 5% per hour (in suspend).
The last one, was from 100% to 0% after almost 3 days in suspend (with no reading).
It could have died earlier AFAIK but even like that is unusable.

Maybe its my device, but until something new happens from the devs, its back to Shut down, which is not that bad after all! ;o)
embryo is offline   Reply With Quote
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Koreader running on Kobos (all of them, hopefully!) giorgio130 KOReader 2647 09-15-2016 09:43 AM
Aura H2O Problem with KSM and/or Koreader -> Nickel full freeze johnnyb Kobo Developer's Corner 8 04-15-2015 02:18 AM
Mini KOreader--Request to solve CHM parsing the Chinese code problem sbwtxj Kobo Developer's Corner 0 11-01-2014 01:06 PM
PW2 [Koreader] Rendering problem on KPW2 natto Kindle Developer's Corner 1 04-10-2014 10:42 AM
iLiad Reason for suspend problem bitz iRex Developer's Corner 0 10-01-2007 06:41 PM


All times are GMT -4. The time now is 08:50 PM.


MobileRead.com is a privately owned, operated and funded community.