Charging voltage control