aboutsummaryrefslogtreecommitdiff
path: root/src/Altimeter.qml (follow)
AgeCommit message (Collapse)Author
2023-07-12Fix inverted altimeter behaviour and allow negative altimeter calibrationsdodoradio
The altimeter was erroneously made to add to the sea level air pressure instead of subtracting from it, which resulted in inverted behaviour. This has now been fixed. This also allows setting a negative altimeter offset
2023-07-10Add altimeterdodoradio
Asteroid watches don't generally have a pressure sensor, as it isn't generally exposed by android's HAL. Hence we use the basic 12Pa/m relationship to calculate an approximation for altitude from the pressure sensor (barometer) reading. This kind of precision seems appropriate given that a) we don't expect this to be used as a flight computer and b) the android barometer, while precise, isn't super accurate anyway. In order to make the reading a bit more useful, we allow the user to calibrate the current altitude. Since we allow separate calibration of this from the barometer calibration, we use the uncalibrated barometer reading as the input for our calculation.