Added function to update altitude values