Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[AE-74] Revamp Battery API for Nicla Sense ME #1

Closed
wants to merge 48 commits into from

Conversation

sebromero
Copy link
Owner

@sebromero sebromero commented Apr 28, 2023

Change log

🐛 Fixed Bugs

  • Fixed the incorrect calculation of the battery voltage percentage.
  • Fixed incorrect voltage reading by adding a tiny delay to give the chip time to wake up from High Impedance mode.
  • Fixed a slightly incorrect interpretation of the NTC values (introduced a new state 'Extreme' which indicates the charging has been suspended).
  • Fix edge case in the charging current setting that could cause an external value to be used instead of a programmatic one.
  • Fix incorrect TS and interrupt disable in enableCharging function

🚀 Enhancements

  • Added documentation to all functions related to power management.
  • Added error handling to catch error cases
  • Introduced Enums for battery charge level, temperature and operating status.
  • Avoided high impedance mode when connected through VIN to to correctly report charging status
  • Improved accuracy of battery voltage reading (disable charging while reading)

🆕 New Features

  • Implemented a WebBLE based battery monitor + sketch for easy testing without external power supply
  • Remove battery status function and replace with temp and charge level.
  • Added function for toggling battery NTC.
  • Added API for operating system status (e.g. charging).
  • Added API to set regulated battery voltage.
  • Added function to determine power source
  • Added function to disable charging state

@sebromero sebromero force-pushed the sebromero/pmic-fix branch 2 times, most recently from 4db30d2 to 7e5e789 Compare May 3, 2023 16:12
@sebromero sebromero force-pushed the sebromero/pmic-fix branch from e398b6b to b16d5ea Compare May 5, 2023 14:50
@sebromero sebromero force-pushed the sebromero/pmic-fix branch from 7e8b72e to d47a6db Compare May 9, 2023 13:26
@sebromero sebromero force-pushed the sebromero/pmic-fix branch 3 times, most recently from 4de1f9d to 34b9666 Compare May 10, 2023 14:06
@sebromero sebromero force-pushed the sebromero/pmic-fix branch from 7018622 to d399ee3 Compare May 10, 2023 15:44
@sebromero sebromero force-pushed the sebromero/pmic-fix branch from 9c88907 to 5fff648 Compare May 11, 2023 13:26
@sebromero sebromero closed this Aug 25, 2023
@sebromero sebromero deleted the sebromero/pmic-fix branch August 25, 2023 11:15
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