baskerville / plato

Document reader
Other
1.25k stars 103 forks source link

[Issue] 30% battery drain in 24 hours in sleep mode #313

Closed rafcon-dev closed 6 months ago

rafcon-dev commented 1 year ago

Hello. I have a kobo libra 2. I love the interface speed and minimalism of Plato. However, I've run into an issue regarding battery usage. With the default ui, on sleep mode the battery drains around 1%-2% per day, which I believe is fine. However, with Plato in sleep mode I get a small drain for one day or two, but then in 24 hours it gets drained like 30%. How can I better pinpoint what might be causing this?

NiLuJe commented 1 year ago

Are you using a sleep cover?

rafcon-dev commented 1 year ago

I have stopped using it as I had read it might cause these issues, so no

A sábado, 5/08/2023, 17:35, NiLuJe @.***> escreveu:

Are you using a sleep cover?

— Reply to this email directly, view it on GitHub https://github.com/baskerville/plato/issues/313#issuecomment-1666549128, or unsubscribe https://github.com/notifications/unsubscribe-auth/AUN5UJWXLMO36HKCPQ4ALG3XTZY5DANCNFSM6AAAAAA3FIA2OQ . You are receiving this because you authored the thread.Message ID: @.***>

baskerville commented 1 year ago

Please follow the instructions given in this comment.

rafcon-dev commented 1 year ago

I have read that thread and I've installed the latest Plato binary you mentioned at the end. I'll test it for a few days and see how it goes. Thanks!

baskerville commented 1 year ago

I have read that thread and I've installed the latest Plato binary you mentioned at the end.

Since you don't have a SleepCover, you'd better just follow the instructions given in the aforementioned comment.

rafcon-dev commented 1 year ago

Ok, I've done that then, let's see. Cheers

rafcon-dev commented 11 months ago

Here is a log file. Massive battery drain to 0 in the last couple days, from about 50% or so Thank you for your time, looking forward to an update on this archive.log

baskerville commented 11 months ago

You're not using a sleep cover, but you do have lots of sleep cover events in your log, hence you must have magnets near your device when it rests.

rafcon-dev commented 11 months ago

That's quite weird. I suppose then that it'd get solved by the changes to the handling of VAL_REPEAT in the latest version?

baskerville commented 11 months ago

I suppose then that it'd get solved by the changes to the handling of VAL_REPEAT in the latest version?

Yes, it should.

rafcon-dev commented 9 months ago

Hey again. Unfortunately it doesn't seem to have solved the issue. Just a couple hours ago I left it with no cover, and went from 35%->8%. Can you send me a logging executable again so we can pinpoint this?

Thank you for your time.

rafcon-dev commented 9 months ago

I decided to install koreader just to see if a similar issue arrises, but no, with koreader in sleep for 10 days with occasionals wake ups, it lost around 12%, which I believe is reasonable.

baskerville commented 9 months ago

Here's the logging binary (install 0.9.40 first).

plato-0.9.40-log_events-01.zip

rafcon-dev commented 7 months ago

Here is the log file. It should contain a recent battery drop of like 15% in one day or two I believe. archive.zip

Many thanks!

baskerville commented 7 months ago

It seems you're using the previous logging binary (the went to sleep/woke up timestamps are more precise as of 0.9.40).

What's the value of auto-power-off in Settings.toml?

rafcon-dev commented 7 months ago

That's weird, I do believe I have replaced the binary with the latest you posted. I do have 0.9.40. I'll replace it again for good measure

That value is: auto-power-off = 3.0

Cheers!

baskerville commented 7 months ago

The comment about the binary was probably wrong. I was puzzled by the log and didn't notice something much more problematic : it stops 29 hours after September 24, 2023!

rafcon-dev commented 7 months ago

ahem, that's strange, sorry about that, I deleted the file and a new one was created, here is a new one. Had a battery drain to 0 a few days ago, and now 30% in a couple days. archive.log

Again, thank you!

baskerville commented 7 months ago

As far as local time goes, it seems you went from 2023 to 2000!

Maybe @NiLuJe has seen this before?

It also seems that your device is sometimes woken up by mysterious events:

Went to sleep on January 6, 2000 at 20:49:09.
Woke up on January 6, 2000 at 20:49:17.
Went to sleep on January 6, 2000 at 20:50:04.
Woke up on January 6, 2000 at 20:50:09.
Went to sleep on January 6, 2000 at 20:50:37.
Woke up on January 6, 2000 at 20:50:44.
Went to sleep on January 6, 2000 at 20:50:59.
Woke up on January 6, 2000 at 20:51:07.
Went to sleep on January 6, 2000 at 20:51:22.
Woke up on January 6, 2000 at 20:51:28.
Went to sleep on January 6, 2000 at 20:51:43.
Woke up on January 6, 2000 at 22:09:08.
Went to sleep on January 6, 2000 at 22:09:23.
Woke up on January 6, 2000 at 22:09:33.

The log stops on March 27, 2000 and I doubt, given its size, that it showcases any of the drains.

NiLuJe commented 7 months ago

If it's plugged in at the time, possibly charge thresholds being crossed?

The usual culprit is the hall sensor, though, but you should be seeing the matching input events if it's logging those :s.

The gyro is a wakeup source, too, but only from standby, not suspend, so that one ought to be out (and, again, input events ;p)...

NiLuJe commented 7 months ago

That leaves the RTC, which could be dodgy (the broken date would certainly lead credence to that theory...).

rafcon-dev commented 6 months ago

Here's a new log, with the correct time. I checked on it almost every day for a couple weeks, and it lost around 1-2% per day, until around 50%. Checked on it today and it was dead, in around 2 days. From the logs apparently it woke up by itself after I checked up on it and never went to sleep again? It's been on a wooden table, so no magnetic stuff around... info.log

baskerville commented 6 months ago

Thanks, I think I understand the bug now.

rafcon-dev commented 6 months ago

That's awesome, at last the nasty critter shall be squished! Best of luck, and thank you!

baskerville commented 6 months ago

Please try the attached binary and see if it's fixed.

plato-0.9.40-fix_313-01.zip

rafcon-dev commented 6 months ago

Thank you, will report back in a few days!

samriggio commented 6 months ago

Please try the attached binary and see if it's fixed.

plato-0.9.40-fix_313-01.zip

I was having a similar issue with battery drain, but there's been no issues the past week using the "fixed" binary. 👍

rafcon-dev commented 6 months ago

Can confirm, seems to be solved, got around 2% per day with some light usage! Thank you very much for your work, bought you a coffee.