update battery data when AC was (un)plugged