Skip to content

Improve battery handling#2

Open
pelle-c wants to merge 1 commit into
mainfrom
improve_battery_handling
Open

Improve battery handling#2
pelle-c wants to merge 1 commit into
mainfrom
improve_battery_handling

Conversation

@pelle-c
Copy link
Copy Markdown
Owner

@pelle-c pelle-c commented Aug 25, 2024

The values given by the ADC are not very accurate. The introduced errors pose a risk for over-voltage on the battery, which in worst case can lead to an explosion.

This commit aims to mitigate the above by doing the following:

  • Adding correction values in order for the reported values to match the real ones
  • Adding IIR filter (from Jahnkeanater) to get more smooth readings
  • Adding hysteresis for when to restart charging, to avoid charge/discharge toggling

The values given by the ADC are not very accurate. The introduced errors pose a
risk for over-voltage on the battery, which in worst case can lead to an explosion.

This commit aims to mitigate the above by doing the following:

* Adding correction values in order for the reported values to match the real ones
* Adding IIR filter (from Jahnkeanater) to get more smooth readings
* Adding hysteresis for when to restart charging, to avoid charge/discharge toggling
Sign up for free to 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.

1 participant