Function bal_compute_imbalance(voltage_t, uint16_t, voltage_t, uint16_t)¶
- Defined in File bal.h
Function Documentation¶
-
uint16_t
bal_compute_imbalance(voltage_t volts[], uint16_t count, voltage_t threshold, uint16_t cells[]) Computes the cells with voltage exceeding the given threshold + lowest cell voltage.
- Return
- amount of cells to be discharged
- Parameters
volts: Array of cell voltagescount: Size ofvoltsthreshold: Balancing tolerance (voltage + threshold)indexes: Output array of indexes to be balancedcells: array of cell’s indexes that need to be discharged