mirror of
https://github.com/AstronautCheetah/frame-tweaks.git
synced 2026-10-17 13:00:18 +02:00
Asleep, the service can't run, so the switch stays as it was. With 1% swings charging is on a few minutes at a time, and on this Frame it went to sleep at 00:59, six minutes after charging resumed at 77% (limit 78%), and woke at 99%. charge-limit-sleep (jeepney, started by `charge-limit --run`) holds a logind delay lock on sleep, as SteamVR's services do; on PrepareForSleep it runs `charge-limit --before-sleep`, which pauses charging (as its own pause) when the battery is within 10% of the limit or over it, then releases the lock; on waking it runs `charge-limit --once` and takes the lock again. A lower battery still charges while asleep, so a nearly empty Frame isn't left low. status.sh says "Not charging until the battery is below N% (now M%)" when the battery is well over the limit instead of "Holding at N%", and warns when the watch on sleep isn't running.