Week 7 State of charge estimation
HOW TO SIMULATE THE BMS PROJECT MODEL IN SIMULINK?
Lithium-ion battery packs are widely used energy storage system in electric vechiles. The battery management system (BMS) is responsible of safe operation,perfomance,and battery life under divorse charge-discharge and environmental conditions. when designing a BMS battery cell voltage, temparature,soc,soh and charging profile has to be controlled and maintained.

please see in below link...
my MATLAB version has not working because my trial version expired and not supported the trial version to this BMS challenge..