Adaptive Cell Balancing For Modular Battery Management Systems