Commit Graph

10 Commits

Author SHA1 Message Date
Jeff Curless
7839828b34 Update driver code to fix indenting...
The Editor tried to make changes for me...
2025-12-30 18:11:47 -05:00
Jeff Curless
804d056f83 Add support to change the shutdown threshold.
The default value for shutdown is less than 5% of battery life left.
Once the system hits this value (or the one specified by the user) the
system will shutdown.

The soc_shutdown value can be changed to 0 to disable this feature, just
realise that the system will lose power and unsafely shutdown.

Also added install and remove functionality.
2025-11-01 17:12:22 -04:00
Jeff Curless
3c4b7e0b5e Add support for trixie.
Apparently things start differently with trixie, so modified the system
monitor code to keep trying to allocate the resources it needs (and
adapter and a client to the i2c bus).  This mades the code work,
and startup is not affected.
2025-10-28 20:07:26 -04:00
Jeff Curless
050f0a0147 Add supprt for automatic shutdown at 5%
Automatically shutdown the system when the battery hits 5% left if the
system is not plugged in.  The shutdown does *not* save data, so might
want to look into how to make it save data (or possibly just generate a
warning.
2025-10-12 23:24:15 -04:00
Jeff Curless
020dda1ba4 General cleanup, allow for named messages to dmesg 2025-10-12 13:30:35 -04:00
Jeff Curless
cc9a4678f3 Update the code with comments
Add a clean script...
2025-10-06 22:25:37 -04:00
Jeff Curless
2b01bb114e Minor changes code still working 2025-10-06 21:03:11 -04:00
Jeff Curless
cafc3fbf2b Mostly working
Need to perform code cleanup, and make sure startup of the driver
contains everything it needs to properly verify the status of the
battery.

Could use code to get the voltage etc, however I don't see that code in
the argon40 python stuff so I'd have to investigate the I2C device.
2025-10-06 19:55:49 -04:00
Jeff Curless
22c6bf718f Attempting to build on Trixie with older headers 2025-10-06 09:01:20 -04:00
Jeff Curless
7bf55073be Start porting the test driver over to the oneUp
Start porting the driver to the argon oneUp
2025-10-05 22:49:45 -04:00