Updated battery sensing in computer software and testing in Arduino