Hi!
I have been investigating the Concorde IVSI problem. I came to the
conclusion that the trouble is that the environment altitude and thus
the pressure (which is calculated from that) is lagging by 1 frame.
Normally that wouldn't be a problem, but the IVSI calculates rate of
change and it will use the new dt with the old value difference,
thereby arriving at bad results if dt changes (and it does).
My proposed fix would be to move the environment subsystem earlier in
the initialization and thus the update sequence, as per the attached
patches. Alternatively it should be possible to achieve a similar
result by delaying the dt value by one frame in the IVSI itself.
Any objections or comments?
PS: Many thanks to Aerotro who kept nagging everyone that Concorde is broken ;)
--
Csaba/Jester
Index: src/Main/fg_init.cxx
===================================================================
RCS file: /var/cvs/FlightGear-0.9/source/src/Main/fg_init.cxx,v
retrieving revision 1.189
diff -u -r1.189 fg_init.cxx
--- src/Main/fg_init.cxx 7 Oct 2007 19:27:05 -0000 1.189
+++ src/Main/fg_init.cxx 2 Nov 2007 17:29:07 -0000
@@ -1642,6 +1642,15 @@
// model or control parameters are set
fgAircraftInit(); // In the future this might not be the case.
+
+ ////////////////////////////////////////////////////////////////////
+ // Initialize the weather subsystem.
+ ////////////////////////////////////////////////////////////////////
+
+ // Initialize the weather modeling subsystem
+ globals->add_subsystem("environment", new FGEnvironmentMgr);
+
+
////////////////////////////////////////////////////////////////////
// Initialize the aircraft systems and instrumentation (before the
// autopilot.)
@@ -1688,14 +1697,6 @@
////////////////////////////////////////////////////////////////////
- // Initialize the weather subsystem.
- ////////////////////////////////////////////////////////////////////
-
- // Initialize the weather modeling subsystem
- globals->add_subsystem("environment", new FGEnvironmentMgr);
-
-
- ////////////////////////////////////////////////////////////////////
// Initialize the lighting subsystem.
////////////////////////////////////////////////////////////////////
Index: src/Main/fg_init.cxx
===================================================================
RCS file: /var/cvs/FlightGear-0.9/source/src/Main/fg_init.cxx,v
retrieving revision 1.172.2.14
diff -u -r1.172.2.14 fg_init.cxx
--- src/Main/fg_init.cxx 7 Oct 2007 19:27:06 -0000 1.172.2.14
+++ src/Main/fg_init.cxx 2 Nov 2007 17:30:56 -0000
@@ -1666,6 +1666,15 @@
// model or control parameters are set
fgAircraftInit(); // In the future this might not be the case.
+
+ ////////////////////////////////////////////////////////////////////
+ // Initialize the weather subsystem.
+ ////////////////////////////////////////////////////////////////////
+
+ // Initialize the weather modeling subsystem
+ globals->add_subsystem("environment", new FGEnvironmentMgr);
+
+
////////////////////////////////////////////////////////////////////
// Initialize the aircraft systems and instrumentation (before the
// autopilot.)
@@ -1712,14 +1721,6 @@
////////////////////////////////////////////////////////////////////
- // Initialize the weather subsystem.
- ////////////////////////////////////////////////////////////////////
-
- // Initialize the weather modeling subsystem
- globals->add_subsystem("environment", new FGEnvironmentMgr);
-
-
- ////////////////////////////////////////////////////////////////////
// Initialize the lighting subsystem.
////////////////////////////////////////////////////////////////////
-------------------------------------------------------------------------
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems? Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now >> http://get.splunk.com/
_______________________________________________
Flightgear-devel mailing list
Flightgear-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/flightgear-devel