Predictive Health Management for Batteries in Connected Environments