Lemonergy · Studio block

Multi-cell balancing interface

One to eight independently commanded current-sink circuits with per-cell voltage, current and power; no hardware I/O.

Implementation ID
balancing-interface
Reviewed
2026-10-27

Behavior

One to eight independently commanded current-sink circuits with per-cell voltage, current and power; no hardware I/O. The terminal current participates directly in Kirchhoff current balance and changes the connected battery state. Measurements are solved with the physical network.

Interface

Multi-cell balancing interface interfaceInputs or arguments on the left, observed outputs on the right. Conserving terminals appear below the component. The tables give units and behavior.Multi-cell balancing interfaceStudio blockcurrent1voltage1current1power1p1n1
Original Lemonergy interface view. Lines identify ports; they are not a completed simulation circuit.
Ports and observed outputs
NameDirectionUnitMeaning
p1terminalV / AElectrical conserving connection. Across variables are shared at a node; through flows balance. A pN/nN pair is created for each configured circuit, up to eight.
n1terminalV / AElectrical conserving connection. Across variables are shared at a node; through flows balance.
current1inputAOptional typed command; otherwise the configured default is used. For balancing, currentN addresses the corresponding circuit.
voltage1outputVObserved voltage1. Each configured circuit has corresponding numbered measurements.
current1outputAObserved current1. Each configured circuit has corresponding numbered measurements.
power1outputWObserved power1. Each configured circuit has corresponding numbered measurements.

Parameters

Defaults are initial model values. Select values for your own model and operating conditions.

Configuration fields
ParameterUnitDefaultMeaning and limits
Number of balancing circuits
circuits
circuits1Number of balancing circuits. Numerical bounds are model-validation limits, not physical operating ratings.
Minimum 1; Maximum 8
Default current per balancing circuit
defaultCurrentA
A0Default current per balancing circuit. Numerical bounds are model-validation limits, not physical operating ratings.
Minimum 0; Maximum 1000000

Equations and rules

  • I[j] = max(0, commanded current[j])
  • P[j] = V[j]*I[j]

Worked example

Multi-cell balancing interface worked example

The bundled two-cell model commands 0.1 A from circuit 1 and zero from circuit 2. The first cell has 4 V OCV and 0.1 Ω resistance, giving 3.99 V under bleed. The second 3.7 V cell remains unloaded.

Open Studio example after release →
Numerical checks for the bundled synthetic example
OutputTime (s)Expected valueUnitAbsolute tolerance
First bleed current
current1
10.1A1e-06
First cell voltage
voltage1
13.99V1e-06

Use in a workflow

Multi-cell balancing interface worked example

One to eight independently commanded current-sink circuits with per-cell voltage, current and power; no hardware I/O.

  1. Multi-cell balancing interface: One to eight independently commanded current-sink circuits with per-cell voltage, current and power; no hardware I/O. The terminal current participates directly in Kirchhoff current balance and changes the connected battery state. Measurements are solved with the physical network.
    • Use the parameter values in the block reference.
    • Implementation tested locally; public release pending.
Open Studio example after release

Connected concepts

Limits and interpretation

  • This is a simulated electrical interface without a target-hardware driver. SOC and temperature pass-throughs, diagnostic mode flags and hardware-specific communication are outside this interface.
  • One to eight independently commanded circuits per instance. The default contract shows one circuit; the worked example configures two.

Scientific and mathematical references

These sources explain the scientific and mathematical background. The behavior, interface and limits above define the Lemonergy implementation; a citation does not imply every model option in the source is implemented.

  1. Getting Started with the BQ76925

    Texas Instruments · 2019

    Technical reference · A concrete BMS analog front-end example: cell voltage, current, temperature measurement and MCU integration.

Implementation sources

This reference follows the public interface and locally verified numerical checks for an upcoming release.

Contract: Lemonergy Studio public contract · Verification record: verification-2026-10-27

  • docs/glossary/native-block-verification.json

This implementation and its workflow uses (JSON) · Knowledge graph (JSON-LD)