Here I add the flight time display, which can be reset by holding the
"#" button in flight time display mode.
I also added compile time flags in the source file to enable or disable
individual components in order to save space, as this addition makes the
code sufficiently large to require disabling some other feature to fit
in the watch. These flags are enabled by default, except for the display
of altitude change in Pascal.
One could for example disable the "test" feature which serves little purpose
for everyday use.
Change data type for on_time from u8 to u16 to accommodate 500ms.
Make buzzer off time shorter as 500ms on and 500ms off would not
complete in 1000ms, turning off some beeps.
The altimeter will turn itself off (to save battery) after some time,
if we reenable it after this or simply cycle through other functions
on line 1 while changing our altitude, we will see a false peak in
the vario displayand subsequently in the Vzmin and Vzmax stats.
This commit fixes this problem by ignoring the first seen altitude
difference.
The sound mode can now be toggled between the following selections by
holding the "#" key during vario display:
Off (default, no symbol displayed)
Ascent 0 (start beeping at 0.0m/s, beeper1 and beeper2 symbols displayed)
Ascent 1 (start beeping at 0.1m/s, beeper1 symbol displayed)
Both (beep for up or down, beeper1 and beeper2 symbols displayed)
Tone frequency, number and duration of beeps depend on climb rate.
- Pressing the "v" (down) button cycles between displays as follows:
* vario (in m/s)
Displays a signed fractional value representing the ascent or
descent speed in meters per second.
* vario (in Pascal)
Displays a signed integer value representing the ascent or
descent speed in Pascal/second.
* pressure (in hPa)
Displays a signed fraction representing the pressure measured at
the current altitude.
* max Vz (in m/s)
Displays the maximum vertical speed in meters/second.
* min Vz (in m/s)
Displays the minimum vertical speed in meters/second.
- A long press on the "#" button performs a context sensitive function:
* during vario display, enables or disables the vario sound.
When enabled, a symbol is shown on the display (beeper1).
* during max/min Vz display, resets both the max and min values.
- The "record" icon is flashed at one second intervals, indicating that
the watch is in vario mode and receiving pressure measurements.
Note that the upper line must be in altimeter mode for the vario to
work, as it relies on updates from the altimeter. If the altimeter
is not active, the vario display shows "noAlt".
Along with the vario changes, a call to "prout_tick()" was removed from
driver/timer.c as it was indirectly calling the display update function
from interrupt level.