Skip to content

Add Ready-screen battery indicator - #56

Merged
PurpleSentinel merged 1 commit into
v3from
feature/ready-screen-battery-icon
Aug 10, 2026
Merged

Add Ready-screen battery indicator#56
PurpleSentinel merged 1 commit into
v3from
feature/ready-screen-battery-icon

Conversation

@PurpleSentinel

Copy link
Copy Markdown
Contributor

Summary

  • add a standard proportionally filled battery icon above the Ready heading
  • overlay a high-contrast lightning bolt when RP2040 VBUS is present
  • estimate battery-only charge from smoothed GP29 readings and a bounded Li-ion curve
  • retain the last valid battery estimate while externally powered, with a documented startup fallback
  • update the user guide, README, and device installation command

Why

The Ready screen did not expose any power status. The Waveshare board provides a divided VSYS reading on GP29 and an RP2040 VBUS status bit, but USB power masks the isolated battery voltage. The implementation therefore reports battery-only voltage honestly and treats the initial full fill under USB as powered status rather than an exact cell measurement.

User impact

Drivers can see approximate remaining charge before starting a session and immediately recognize external power from the charging bolt. The 35×16 px icon is centered at the top of the circular display with a 12 px gap before Ready, preserving all existing settings and instructions.

Validation

  • python -m unittest discover -s tests -v — 82 tests passed
  • syntax and whitespace checks passed
  • verified VBUS detection and GP29 readings on the supported Waveshare RP2040 board
  • installed on hardware and visually inspected the framebuffer for icon clarity, charging-bolt contrast, circular fit, and title clearance

Closes#55

@PurpleSentinel
PurpleSentinel merged commit b486f3d into v3Aug 10, 2026
2 checks passed
@PurpleSentinel
PurpleSentinel deleted the feature/ready-screen-battery-icon branch August 10, 2026 10:57
Sign up for freeto join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Show battery charge icon and external-power indicator on Ready screen

2 participants

@PurpleSentinel@markr-sqr