1. Prepare the setup
Goal: have everything OpenBMS needs to charge, discharge and learn your battery, and a link to your PC.
- OpenBMS board and a 2 to 7 cell Li-ion or Li-Po pack.
- Charger with constant current / constant voltage (CC/CV) that gives up to 2C (twice the capacity).
- Load for about 1C discharge. We suggest the OpenBMS Test Bench: up to 600 W, adjustable from 1 to 20 Ω. Any resistive or electronic load also works.
- USB to UART adapter with 3.3 V logic levels, to connect OpenBMS to OpenBMS Studio on your PC.
Example: 7-cell 2000 mAh pack
- Charger: up to 4 A at 29.4 V (7 × 4.2 V), so a 30 V / 5 A lab power supply.
- Load: about 2 A at 25.2 V, so around 12.6 Ω. On the OpenBMS Test Bench, 2 resistors are enabled (12.5 Ω).
- UART adapter: FT232 or CH340 based, set to 3.3 V.
2. Configure OpenBMS
Goal: tell OpenBMS what battery it protects. Connect the board to your PC with the UART adapter and set your pack in OpenBMS Studio. The settings are saved on the board and used after a restart.
- Pack: number of cells in series (2 to 7) and cell capacity.
- Cell voltage window: maximum and minimum cell voltage. The learning test charges up to the maximum and discharges down to the minimum.
- Protections: over- and under-voltage, charge and discharge over-current, and over- and under-temperature, each with its threshold and delay.
- Charging: full-charge cell voltage and termination current, used to detect a full pack.
- Balancing: start voltage and the cell difference that switches balancing on.
- Calibration: shunt, voltage gains and NTC values of your board.
Example: 7-cell 2000 mAh pack
- Pack: 7 cells, 2000 mAh.
- Cell voltage window: 4.2 V maximum, 3.0 V minimum.
- Over- and under-voltage protection: 4.25 V and 2.8 V per cell, a little outside the window so normal use never trips it.
- Charge over-current: 6 A (3C), above the 4 A the charger can give.
- Discharge over-current: 10 A (5C) for longer overloads, 20 A as fast short-circuit cut-off.
- Over-temperature: 60 °C, and 45 °C while charging.
- Under-temperature: −20 °C, and 0 °C while charging.
- Full charge: highest cell at 4.15 V and current below 100 mA for 10 s, then the state of charge is set to 100 %.
- Balancing: starts at 3.9 V when a cell is 20 mV above the lowest, only below 45 °C, with 50 Ω bleed resistors.
- Calibration: 2 mΩ shunt and the NTC values of your sensor; the default values work for a standard OpenBMS board.
3. Run the learning test (HPPC)
Goal: let OpenBMS measure your battery and build a model of every cell. The on-board HPPC test (Hybrid Pulse Power Characterisation) charges or discharges the pack in steps with short current pulses and learns from the voltage response. Run it once per pack, in two parts.
Before you start:
- Configuration from step 2 is done and the board has been restarted.
- Temperature between 15 and 35 °C. The test does not start outside this range, and stops if the pack stays outside it for 5 minutes.
- Current between 0.5C and 2C. A test with too low or too high current is stopped.
Charge test: start with an empty pack and the charger connected. OpenBMS switches the charge current in pulses until the highest cell reaches the maximum cell voltage. It learns the charge model: open-circuit voltage, internal resistance and two RC time constants over the full state-of-charge range.
Discharge test: start with a full pack and the load connected. OpenBMS switches the load in pulses until the lowest cell reaches the minimum cell voltage. It learns the discharge model and the real capacity of every cell.
If a protection trips or the test is stopped, nothing is saved and the test can be run again.
Example: 7-cell 2000 mAh pack
- Allowed current: 1 to 4 A.
- Charge test: pack empty (cells at 3.0 V), 30 V / 5 A supply connected, runs until a cell reaches 4.2 V.
- Discharge test: pack full (cells at 4.2 V), Test Bench with 2 resistors connected (about 2 A), runs until a cell reaches 3.0 V.
4. Ready to use!
Goal: use your battery with OpenBMS watching every cell. After both learning tests OpenBMS has a model of your pack, so you never need to run the test again.
- Connect your real load or charger in place of the test setup.
- Accurate state of charge for every cell, corrected at full charge and at rest.
- Protection and balancing run all the time.
- State of health: OpenBMS keeps learning the real capacity as the pack ages.
- Read everything in OpenBMS Studio, or from your own microcontroller over UART, I2C or CAN.
Example: 7-cell 2000 mAh pack
- Disconnect the Test Bench and connect the pack to your device, for example a drone or an e-board.
- OpenBMS Studio shows the state of charge of the pack and of each of the 7 cells.
- Charge it with your normal charger: OpenBMS sets 100 % when the pack is full and balances the cells above 3.9 V.