From 4d4fef591bdfef3c4b5a194befb5cfde32d2ee79 Mon Sep 17 00:00:00 2001 From: ehofman Date: Fri, 27 Jun 2003 08:45:35 +0000 Subject: [PATCH] Melchior FRANZ: These patches add a clock instrument, which allows to model failure ("serviceable") and to adjust the time independently of the system time (defaults to GMT). The main incentive is to make the p51d clock work and adjustable via the knob. o Offers a time string ("12:03:15") for the LCD or for LED clocks, or an empty string in case of failure/power off. The instrument assumes that digital clocks are battery buffered, so they will be updated even if there's nothing on the display. o Offers the number of seconds since midnight for analog clocks, like in the p51d. This number is not increased if !serviceable. So the clock will stand still and continue where it stopped when it's serviceable again. I did not consider voltage yet, because the Mustang's clock will need a lot more current than the LCD clock. The instrument is updated 4 times per second but returns immediately if neither time nor offset changed. The function getGMTString() in fg_props.cxx could be removed after applying these patches. --- Aircraft/Instruments/clock.xml | 4 ++-- preferences.xml | 4 ++++ 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/Aircraft/Instruments/clock.xml b/Aircraft/Instruments/clock.xml index fd9e1b8e5..05103a0c6 100644 --- a/Aircraft/Instruments/clock.xml +++ b/Aircraft/Instruments/clock.xml @@ -84,13 +84,13 @@ properties' values. text-value - /sim/time/gmt-string + /instrumentation/clock/indicated-string x-shift - -34 + -31 y-shift diff --git a/preferences.xml b/preferences.xml index 2c1648a29..954c70685 100644 --- a/preferences.xml +++ b/preferences.xml @@ -544,6 +544,10 @@ Started September 2000 by David Megginson, david@megginson.com true + + true + 0 +