updated usage of readAltitude()