Skip to content

Charging improvements #9

Description

@jkaflik

Context

Current firmware has basic charge control with fixed thresholds and EMA-filtered ADC readings. Upstream OpenMower LowLevel has more operational behavior around charge retry, regen, and high-level configurable limits.

Current Local Behavior

  • Reads battery voltage, charge voltage, and charge current.
  • Enables charging based on fixed cutoffs from src/hardware.h.
  • Publishes basic power topics.
  • Uses EMA filtering.

Upstream Reference Behavior

OpenMower LowLevel:

  • Uses configurable v_charge_cutoff, i_charge_cutoff, and v_battery_cutoff.
  • Disables charging when limits are exceeded.
  • Retries charging after a delay instead of continuously toggling.
  • Keeps charge path enabled for regen when not docked.
  • Supports an option to ignore charge current if needed.

Acceptance Criteria

  • Add a charge retry delay after charging is disabled by cutoff conditions.
  • Preserve or explicitly evaluate upstream regen behavior when no charger/dock voltage is present.
  • Make charge thresholds configurable from ROS 2 or document why compile-time constants are sufficient for now.
  • Avoid rapid charge-enable toggling around thresholds.
  • Publish whether charging is currently allowed/enabled separately from charger presence.
  • Review fixed thresholds in src/hardware.h against upstream defaults and HW 0.13.x expectations.

Notes

This should remain conservative. If there is uncertainty around safe thresholds, prefer disabling charging and surfacing the reason in telemetry.

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions