There is a couple of interesting battery tools for the pi-top, but no proper widget yet. I have started porting the standard lxde power widget for use with the pi-top but other than setting up github I haven't made much progress seeing how I only just started today. Anyone with some programming experience who would like to jump on board with this project please visit github and search bstone108/pt-battery-widget and request to join the project!
I've already got a good part of the legwork done on finding out how we can pull data without need for root access, but someone else might have a better method. Please join in and help us get a functional widget!
I have no questions, I'm already learning how to talk to the battery via the official pi top battery script and for simplicity probably just going to make use of that script and just make it a package requirement for the battery applet. please check the github project I mentioned above for the info I've collected and the source code in progress.
I see, advice taken. I'll see what I can come up with. it's going to be a bit of a learning curve for me too as I'm a very novice programmer. I'm very very good at finding and fixing bugs, but never been too great at writing something from scratch. Guess now is as good of a time as any to learn! Luckily calling ic2 isn't any harder than just asking the script for info. I just need to see if I can do so in a way that bypasses root restrictions on older versions of raspbian and ubuntu. can worry about that detail later, for now I need to worry about just getting a working prototype.
The existing pt-hub-controller actually works fine with latest raspian. I have no issues with brightness or auto power off, if you're having issues make sure you're pt-hub-controller app is up to date via apt repository. I have no intention of replacing what already works, at least not initially. That being said some battery widget settings to automatically manage brightness when power gets low, and so on might be additions for the future, but for now the pt-hub software works fine as is. I’m starting initially by just getting a working power meter with auto shutdown capabilities added in in widget format. The code currently in the GitHub project is an already working power meter but it works via acpi so I’m in process of gutting those functions and writing i2cget calls [scrapped script calls at your recommendation] If you want to help with that, feel free to check out the script and submit your additions. The widget itself is already a working widget so none of that part has to be written.