Repository navigation
Releases: int08h/waveshare-ups-hat-e
Releases · int08h/waveshare-ups-hat-e
Release list
0.1.3
v0.1.3
- Replaced manual bit manipulation with idiomatic
u16::from_le_bytes()andi16::from_le_bytes()for register conversions - Fixed off-by-one error in signed current read: The milliamps field in
BatteryStatewas incorrectly calculated due to a sign conversion error. Values like -1 mA were returned as 0, and -32768 mA as -32767. The battery current is now correctly interpreted as a signed 16-bit integer.
0.1.2
New APIs
get_communication_state()- returns BQ4050 and IP2368 chip communication statusget_software_revision()- returns UPS firmware revisionis_battery_low()- checks if total battery voltage is below thresholdforce_power_off()- initiates unconditional power-off in 30 secondsis_power_off_pending()- checks if a power-off has been initiated
Examples
- New
force_power_off.rsexample binary - Enhanced
ups_monitor.rswith software revision, communication, and battery state
Release 0.1.1
Full Changelog: https://github.com/int08h/waveshare-ups-hat-e/commits/0.1.1