Skip to content
GitLab
Projects Groups Topics Snippets
  • /
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
  • Sign in
  • L liquidprompt
  • Project information
    • Project information
    • Activity
    • Labels
    • Members
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributor statistics
    • Graph
    • Compare revisions
  • Issues 33
    • Issues 33
    • List
    • Boards
    • Service Desk
    • Milestones
  • Merge requests 15
    • Merge requests 15
  • CI/CD
    • CI/CD
    • Pipelines
    • Jobs
    • Schedules
  • Deployments
    • Deployments
    • Environments
    • Releases
  • Packages and registries
    • Packages and registries
    • Package Registry
    • Container Registry
    • Terraform modules
  • Monitor
    • Monitor
    • Incidents
  • Analytics
    • Analytics
    • Value stream
    • CI/CD
    • Repository
  • Wiki
    • Wiki
  • Snippets
    • Snippets
  • Activity
  • Graph
  • Create a new issue
  • Jobs
  • Commits
  • Issue Boards
Collapse sidebar
  • Johann Dreo
  • liquidprompt
  • Merge requests
  • !419

Feature/393 multiple batteries

  • Review changes

  • Download
  • Patches
  • Plain diff
Closed Johann Dreo requested to merge github/fork/towo/feature/393-multiple-batteries into develop Jan 12, 2016
  • Overview 2
  • Commits 4
  • Pipelines 0
  • Changes 1

Created by: towo

Patch to add feature for reading out the state of multiple batteries. Uses a combined percentage of last full charge capacities to deduce the current system overall battery level.

Essentially: (battery0_percentage * battery0_capacity + battery1_percentage * battery1_capacity + [...])/(battery0_capacity + battery1_capacity + ...)

Might include some small rounding errors due to using bc at scale 2 to get the floating point parts of the calculation.

Rebased from master to develop, for full disclosure.

This would resolve nojhan/liquidprompt#393

Assignee
Assign to
Reviewers
Request review from
Time tracking
Source branch: github/fork/towo/feature/393-multiple-batteries