]> git.mxchange.org Git - flightgear.git/commitdiff
Latest round of JSBSim updates.
authorcurt <curt>
Fri, 30 Mar 2001 01:04:50 +0000 (01:04 +0000)
committercurt <curt>
Fri, 30 Mar 2001 01:04:50 +0000 (01:04 +0000)
82 files changed:
FlightGear.dsp
src/FDM/JSBSim.cxx
src/FDM/JSBSim.hxx
src/FDM/JSBSim/FGAerodynamics.cpp
src/FDM/JSBSim/FGAerodynamics.h
src/FDM/JSBSim/FGAircraft.cpp
src/FDM/JSBSim/FGAircraft.h
src/FDM/JSBSim/FGAtmosphere.cpp
src/FDM/JSBSim/FGAtmosphere.h
src/FDM/JSBSim/FGAuxiliary.cpp
src/FDM/JSBSim/FGAuxiliary.h
src/FDM/JSBSim/FGCoefficient.cpp
src/FDM/JSBSim/FGCoefficient.h
src/FDM/JSBSim/FGConfigFile.cpp
src/FDM/JSBSim/FGConfigFile.h
src/FDM/JSBSim/FGControls.cpp
src/FDM/JSBSim/FGControls.h
src/FDM/JSBSim/FGDefs.h
src/FDM/JSBSim/FGEngine.cpp
src/FDM/JSBSim/FGEngine.h
src/FDM/JSBSim/FGFCS.cpp
src/FDM/JSBSim/FGFCS.h
src/FDM/JSBSim/FGFDMExec.cpp
src/FDM/JSBSim/FGFDMExec.h
src/FDM/JSBSim/FGForce.cpp
src/FDM/JSBSim/FGForce.h
src/FDM/JSBSim/FGGroundReactions.cpp
src/FDM/JSBSim/FGGroundReactions.h
src/FDM/JSBSim/FGInertial.cpp
src/FDM/JSBSim/FGInertial.h
src/FDM/JSBSim/FGInitialCondition.cpp
src/FDM/JSBSim/FGInitialCondition.h
src/FDM/JSBSim/FGLGear.cpp
src/FDM/JSBSim/FGLGear.h
src/FDM/JSBSim/FGMassBalance.cpp
src/FDM/JSBSim/FGMassBalance.h
src/FDM/JSBSim/FGMatrix.cpp
src/FDM/JSBSim/FGMatrix.h
src/FDM/JSBSim/FGModel.cpp
src/FDM/JSBSim/FGModel.h
src/FDM/JSBSim/FGNozzle.cpp
src/FDM/JSBSim/FGNozzle.h
src/FDM/JSBSim/FGOutput.cpp
src/FDM/JSBSim/FGOutput.h
src/FDM/JSBSim/FGPiston.cpp
src/FDM/JSBSim/FGPiston.h
src/FDM/JSBSim/FGPosition.cpp
src/FDM/JSBSim/FGPosition.h
src/FDM/JSBSim/FGPropeller.cpp
src/FDM/JSBSim/FGPropeller.h
src/FDM/JSBSim/FGPropulsion.cpp
src/FDM/JSBSim/FGPropulsion.h
src/FDM/JSBSim/FGRocket.cpp
src/FDM/JSBSim/FGRocket.h
src/FDM/JSBSim/FGRotation.cpp
src/FDM/JSBSim/FGRotation.h
src/FDM/JSBSim/FGRotor.cpp
src/FDM/JSBSim/FGRotor.h
src/FDM/JSBSim/FGState.cpp
src/FDM/JSBSim/FGState.h
src/FDM/JSBSim/FGTank.cpp
src/FDM/JSBSim/FGTank.h
src/FDM/JSBSim/FGThruster.cpp
src/FDM/JSBSim/FGThruster.h
src/FDM/JSBSim/FGTranslation.cpp
src/FDM/JSBSim/FGTranslation.h
src/FDM/JSBSim/FGTrim.cpp
src/FDM/JSBSim/FGTrim.h
src/FDM/JSBSim/FGTrimAxis.cpp
src/FDM/JSBSim/FGTrimAxis.h
src/FDM/JSBSim/FGTurboJet.cpp
src/FDM/JSBSim/FGTurboJet.h
src/FDM/JSBSim/FGTurboShaft.cpp
src/FDM/JSBSim/FGTurboShaft.h
src/FDM/JSBSim/FGUtility.cpp
src/FDM/JSBSim/FGUtility.h
src/FDM/JSBSim/FGfdmSocket.cpp
src/FDM/JSBSim/FGfdmSocket.h
src/FDM/JSBSim/JSBSim.cpp
src/FDM/JSBSim/Makefile.am
src/FDM/flight.cxx
src/Main/main.cxx

index 641015b58cdd5bb9881a6969f5c8a5788a2741c1..81baa88754df0f35c96936effcc15d1057739d69 100644 (file)
@@ -112,6 +112,21 @@ SOURCE=.\src\Aircraft\aircraft.cxx
 \r
 !ENDIF \r
 \r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\Aircraft\aircraft.hxx\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_Aircraft"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_Aircraft"\r
+\r
+!ENDIF \r
+\r
 # End Source File\r
 # End Group\r
 # Begin Group "Lib_Airports"\r
@@ -134,6 +149,21 @@ SOURCE=.\src\Airports\runways.cxx
 # End Source File\r
 # Begin Source File\r
 \r
+SOURCE=.\src\Airports\runways.hxx\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_Airports"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_Airports"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
 SOURCE=.\src\Airports\simple.cxx\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
@@ -146,6 +176,21 @@ SOURCE=.\src\Airports\simple.cxx
 \r
 !ENDIF \r
 \r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\Airports\simple.hxx\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_Airports"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_Airports"\r
+\r
+!ENDIF \r
+\r
 # End Source File\r
 # End Group\r
 # Begin Group "Lib_Autopilot"\r
@@ -168,6 +213,21 @@ SOURCE=.\src\Autopilot\auto_gui.cxx
 # End Source File\r
 # Begin Source File\r
 \r
+SOURCE=.\src\Autopilot\auto_gui.hxx\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_Autopilot"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_Autopilot"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
 SOURCE=.\src\Autopilot\newauto.cxx\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
@@ -180,6 +240,21 @@ SOURCE=.\src\Autopilot\newauto.cxx
 \r
 !ENDIF \r
 \r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\Autopilot\newauto.hxx\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_Autopilot"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_Autopilot"\r
+\r
+!ENDIF \r
+\r
 # End Source File\r
 # End Group\r
 # Begin Group "Lib_Cockpit"\r
@@ -202,6 +277,21 @@ SOURCE=.\src\Cockpit\cockpit.cxx
 # End Source File\r
 # Begin Source File\r
 \r
+SOURCE=.\src\Cockpit\cockpit.hxx\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_Cockpit"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_Cockpit"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
 SOURCE=.\src\Cockpit\hud.cxx\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
@@ -217,6 +307,36 @@ SOURCE=.\src\Cockpit\hud.cxx
 # End Source File\r
 # Begin Source File\r
 \r
+SOURCE=.\src\Cockpit\hud.hxx\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_Cockpit"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_Cockpit"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\Cockpit\hud_opts.hxx\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_Cockpit"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_Cockpit"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
 SOURCE=.\src\Cockpit\hud_card.cxx\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
@@ -382,7 +502,7 @@ SOURCE=.\src\Cockpit\panel.cxx
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\Cockpit\panel_io.cxx\r
+SOURCE=.\src\Cockpit\panel.hxx\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
@@ -397,7 +517,7 @@ SOURCE=.\src\Cockpit\panel_io.cxx
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\Cockpit\radiostack.cxx\r
+SOURCE=.\src\Cockpit\panel_io.cxx\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
@@ -412,7 +532,7 @@ SOURCE=.\src\Cockpit\radiostack.cxx
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\Cockpit\steam.cxx\r
+SOURCE=.\src\Cockpit\panel_io.hxx\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
@@ -425,141 +545,141 @@ SOURCE=.\src\Cockpit\steam.cxx
 !ENDIF \r
 \r
 # End Source File\r
-# End Group\r
-# Begin Group "Lib_Controls"\r
-\r
-# PROP Default_Filter ""\r
 # Begin Source File\r
 \r
-SOURCE=.\src\Controls\controls.cxx\r
+SOURCE=.\src\Cockpit\radiostack.cxx\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\Lib_Controls"\r
+# PROP Intermediate_Dir "Release\Lib_Cockpit"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\Lib_Controls"\r
+# PROP Intermediate_Dir "Debug\Lib_Cockpit"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
-# End Group\r
-# Begin Group "Lib_Balloon"\r
-\r
-# PROP Default_Filter ""\r
 # Begin Source File\r
 \r
-SOURCE=.\src\FDM\Balloon\BalloonSim.cpp\r
+SOURCE=.\src\Cockpit\radiostack.hxx\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\Lib_Balloon"\r
+# PROP Intermediate_Dir "Release\Lib_Cockpit"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\Lib_Balloon"\r
+# PROP Intermediate_Dir "Debug\Lib_Cockpit"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
-# End Group\r
-# Begin Group "Lib_JSBSim"\r
-\r
-# PROP Default_Filter ""\r
 # Begin Source File\r
 \r
-SOURCE=.\src\FDM\JSBSim\FGAircraft.cpp\r
+SOURCE=.\src\Cockpit\steam.cxx\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\Lib_JSBSim"\r
+# PROP Intermediate_Dir "Release\Lib_Cockpit"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\Lib_JSBSim"\r
+# PROP Intermediate_Dir "Debug\Lib_Cockpit"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\FDM\JSBSim\FGAtmosphere.cpp\r
+SOURCE=.\src\Cockpit\steam.hxx\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\Lib_JSBSim"\r
+# PROP Intermediate_Dir "Release\Lib_Cockpit"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\Lib_JSBSim"\r
+# PROP Intermediate_Dir "Debug\Lib_Cockpit"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
+# End Group\r
+# Begin Group "Lib_Controls"\r
+\r
+# PROP Default_Filter ""\r
 # Begin Source File\r
 \r
-SOURCE=.\src\FDM\JSBSim\FGAuxiliary.cpp\r
+SOURCE=.\src\Controls\controls.cxx\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\Lib_JSBSim"\r
+# PROP Intermediate_Dir "Release\Lib_Controls"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\Lib_JSBSim"\r
+# PROP Intermediate_Dir "Debug\Lib_Controls"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\FDM\JSBSim\FGCoefficient.cpp\r
+SOURCE=.\src\Controls\controls.hxx\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\Lib_JSBSim"\r
+# PROP Intermediate_Dir "Release\Lib_Controls"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\Lib_JSBSim"\r
+# PROP Intermediate_Dir "Debug\Lib_Controls"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
+# End Group\r
+# Begin Group "Lib_Balloon"\r
+\r
+# PROP Default_Filter ""\r
 # Begin Source File\r
 \r
-SOURCE=.\src\FDM\JSBSim\FGConfigFile.cpp\r
+SOURCE=.\src\FDM\Balloon\BalloonSim.cpp\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\Lib_JSBSim"\r
+# PROP Intermediate_Dir "Release\Lib_Balloon"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\Lib_JSBSim"\r
+# PROP Intermediate_Dir "Debug\Lib_Balloon"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\FDM\JSBSim\FGControls.cpp\r
+SOURCE=.\src\FDM\Balloon\BalloonSim.h\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\Lib_JSBSim"\r
+# PROP Intermediate_Dir "Release\Lib_Balloon"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\Lib_JSBSim"\r
+# PROP Intermediate_Dir "Debug\Lib_Balloon"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
+# End Group\r
+# Begin Group "Lib_JSBSim"\r
+\r
+# PROP Default_Filter ""\r
 # Begin Source File\r
 \r
-SOURCE=.\src\FDM\JSBSim\FGFCS.cpp\r
+SOURCE=.\src\FDM\JSBSim\FGAircraft.cpp\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
@@ -574,7 +694,7 @@ SOURCE=.\src\FDM\JSBSim\FGFCS.cpp
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\FDM\JSBSim\FGFDMExec.cpp\r
+SOURCE=.\src\FDM\JSBSim\FGAircraft.h\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
@@ -589,7 +709,7 @@ SOURCE=.\src\FDM\JSBSim\FGFDMExec.cpp
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\FDM\JSBSim\FGInitialCondition.cpp\r
+SOURCE=.\src\FDM\JSBSim\FGAtmosphere.cpp\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
@@ -604,7 +724,7 @@ SOURCE=.\src\FDM\JSBSim\FGInitialCondition.cpp
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\FDM\JSBSim\FGLGear.cpp\r
+SOURCE=.\src\FDM\JSBSim\FGAtmosphere.h\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
@@ -619,7 +739,7 @@ SOURCE=.\src\FDM\JSBSim\FGLGear.cpp
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\FDM\JSBSim\FGMatrix.cpp\r
+SOURCE=.\src\FDM\JSBSim\FGAuxiliary.cpp\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
@@ -634,7 +754,7 @@ SOURCE=.\src\FDM\JSBSim\FGMatrix.cpp
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\FDM\JSBSim\FGModel.cpp\r
+SOURCE=.\src\FDM\JSBSim\FGAuxiliary.h\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
@@ -649,7 +769,7 @@ SOURCE=.\src\FDM\JSBSim\FGModel.cpp
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\FDM\JSBSim\FGOutput.cpp\r
+SOURCE=.\src\FDM\JSBSim\FGCoefficient.cpp\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
@@ -664,7 +784,7 @@ SOURCE=.\src\FDM\JSBSim\FGOutput.cpp
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\FDM\JSBSim\FGPosition.cpp\r
+SOURCE=.\src\FDM\JSBSim\FGCoefficient.h\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
@@ -679,7 +799,7 @@ SOURCE=.\src\FDM\JSBSim\FGPosition.cpp
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\FDM\JSBSim\FGRotation.cpp\r
+SOURCE=.\src\FDM\JSBSim\FGConfigFile.cpp\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
@@ -694,7 +814,7 @@ SOURCE=.\src\FDM\JSBSim\FGRotation.cpp
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\FDM\JSBSim\FGState.cpp\r
+SOURCE=.\src\FDM\JSBSim\FGConfigFile.h\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
@@ -709,7 +829,7 @@ SOURCE=.\src\FDM\JSBSim\FGState.cpp
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\FDM\JSBSim\FGTranslation.cpp\r
+SOURCE=.\src\FDM\JSBSim\FGControls.cpp\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
@@ -724,7 +844,7 @@ SOURCE=.\src\FDM\JSBSim\FGTranslation.cpp
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\FDM\JSBSim\FGTrim.cpp\r
+SOURCE=.\src\FDM\JSBSim\FGControls.h\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
@@ -739,7 +859,7 @@ SOURCE=.\src\FDM\JSBSim\FGTrim.cpp
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\FDM\JSBSim\FGTrimAxis.cpp\r
+SOURCE=.\src\FDM\JSBSim\FGDefs.h\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
@@ -754,7 +874,7 @@ SOURCE=.\src\FDM\JSBSim\FGTrimAxis.cpp
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\FDM\JSBSim\FGUtility.cpp\r
+SOURCE=.\src\FDM\JSBSim\FGFCS.cpp\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
@@ -769,7 +889,7 @@ SOURCE=.\src\FDM\JSBSim\FGUtility.cpp
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\FDM\JSBSim\FGEngine.cpp\r
+SOURCE=.\src\FDM\JSBSim\FGFCS.h\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
@@ -784,7 +904,7 @@ SOURCE=.\src\FDM\JSBSim\FGEngine.cpp
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\FDM\JSBSim\FGTank.cpp\r
+SOURCE=.\src\FDM\JSBSim\FGFDMExec.cpp\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
@@ -799,7 +919,7 @@ SOURCE=.\src\FDM\JSBSim\FGTank.cpp
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\FDM\JSBSim\FGfdmSocket.cpp\r
+SOURCE=.\src\FDM\JSBSim\FGFDMExec.h\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
@@ -812,2218 +932,5008 @@ SOURCE=.\src\FDM\JSBSim\FGfdmSocket.cpp
 !ENDIF \r
 \r
 # End Source File\r
-# End Group\r
-# Begin Group "Lib_filtersjb"\r
-\r
-# PROP Default_Filter ""\r
 # Begin Source File\r
 \r
-SOURCE=.\src\FDM\JSBSim\filtersjb\FGDeadBand.cpp\r
+SOURCE=.\src\FDM\JSBSim\FGInitialCondition.cpp\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\Lib_filtersjb"\r
+# PROP Intermediate_Dir "Release\Lib_JSBSim"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\Lib_filtersjb"\r
+# PROP Intermediate_Dir "Debug\Lib_JSBSim"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\FDM\JSBSim\filtersjb\FGFCSComponent.cpp\r
+SOURCE=.\src\FDM\JSBSim\FGInitialCondition.h\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\Lib_filtersjb"\r
+# PROP Intermediate_Dir "Release\Lib_JSBSim"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\Lib_filtersjb"\r
+# PROP Intermediate_Dir "Debug\Lib_JSBSim"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\FDM\JSBSim\filtersjb\FGFilter.cpp\r
+SOURCE=.\src\FDM\JSBSim\FGLGear.cpp\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\Lib_filtersjb"\r
+# PROP Intermediate_Dir "Release\Lib_JSBSim"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\Lib_filtersjb"\r
+# PROP Intermediate_Dir "Debug\Lib_JSBSim"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\FDM\JSBSim\filtersjb\FGFlaps.cpp\r
+SOURCE=.\src\FDM\JSBSim\FGLGear.h\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\Lib_filtersjb"\r
+# PROP Intermediate_Dir "Release\Lib_JSBSim"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\Lib_filtersjb"\r
+# PROP Intermediate_Dir "Debug\Lib_JSBSim"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\FDM\JSBSim\filtersjb\FGGain.cpp\r
+SOURCE=.\src\FDM\JSBSim\FGMatrix.cpp\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\Lib_filtersjb"\r
+# PROP Intermediate_Dir "Release\Lib_JSBSim"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\Lib_filtersjb"\r
+# PROP Intermediate_Dir "Debug\Lib_JSBSim"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\FDM\JSBSim\filtersjb\FGGradient.cpp\r
+SOURCE=.\src\FDM\JSBSim\FGMatrix.h\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\Lib_filtersjb"\r
+# PROP Intermediate_Dir "Release\Lib_JSBSim"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\Lib_filtersjb"\r
+# PROP Intermediate_Dir "Debug\Lib_JSBSim"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\FDM\JSBSim\filtersjb\FGSummer.cpp\r
+SOURCE=.\src\FDM\JSBSim\FGModel.cpp\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\Lib_filtersjb"\r
+# PROP Intermediate_Dir "Release\Lib_JSBSim"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\Lib_filtersjb"\r
+# PROP Intermediate_Dir "Debug\Lib_JSBSim"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\FDM\JSBSim\filtersjb\FGSwitch.cpp\r
+SOURCE=.\src\FDM\JSBSim\FGModel.h\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\Lib_filtersjb"\r
+# PROP Intermediate_Dir "Release\Lib_JSBSim"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\Lib_filtersjb"\r
+# PROP Intermediate_Dir "Debug\Lib_JSBSim"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
-# End Group\r
-# Begin Group "Lib_LaRCsim"\r
-\r
-# PROP Default_Filter ""\r
 # Begin Source File\r
 \r
-SOURCE=.\src\FDM\LaRCsim\atmos_62.c\r
+SOURCE=.\src\FDM\JSBSim\FGOutput.cpp\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\Lib_LaRCsim"\r
+# PROP Intermediate_Dir "Release\Lib_JSBSim"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\Lib_LaRCsim"\r
+# PROP Intermediate_Dir "Debug\Lib_JSBSim"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\FDM\LaRCsim\default_model_routines.c\r
+SOURCE=.\src\FDM\JSBSim\FGOutput.h\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\Lib_LaRCsim"\r
+# PROP Intermediate_Dir "Release\Lib_JSBSim"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\Lib_LaRCsim"\r
+# PROP Intermediate_Dir "Debug\Lib_JSBSim"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\FDM\LaRCsim\ls_accel.c\r
+SOURCE=.\src\FDM\JSBSim\FGPosition.cpp\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\Lib_LaRCsim"\r
+# PROP Intermediate_Dir "Release\Lib_JSBSim"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\Lib_LaRCsim"\r
+# PROP Intermediate_Dir "Debug\Lib_JSBSim"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\FDM\LaRCsim\ls_aux.c\r
+SOURCE=.\src\FDM\JSBSim\FGPosition.h\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\Lib_LaRCsim"\r
+# PROP Intermediate_Dir "Release\Lib_JSBSim"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\Lib_LaRCsim"\r
+# PROP Intermediate_Dir "Debug\Lib_JSBSim"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\FDM\LaRCsim\ls_geodesy.c\r
+SOURCE=.\src\FDM\JSBSim\FGRotation.cpp\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\Lib_LaRCsim"\r
+# PROP Intermediate_Dir "Release\Lib_JSBSim"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\Lib_LaRCsim"\r
+# PROP Intermediate_Dir "Debug\Lib_JSBSim"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\FDM\LaRCsim\ls_gravity.c\r
+SOURCE=.\src\FDM\JSBSim\FGRotation.h\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\Lib_LaRCsim"\r
+# PROP Intermediate_Dir "Release\Lib_JSBSim"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\Lib_LaRCsim"\r
+# PROP Intermediate_Dir "Debug\Lib_JSBSim"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\FDM\LaRCsim\ls_init.c\r
+SOURCE=.\src\FDM\JSBSim\FGState.cpp\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\Lib_LaRCsim"\r
+# PROP Intermediate_Dir "Release\Lib_JSBSim"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\Lib_LaRCsim"\r
+# PROP Intermediate_Dir "Debug\Lib_JSBSim"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\FDM\LaRCsim\ls_matrix.c\r
+SOURCE=.\src\FDM\JSBSim\FGState.h\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\Lib_LaRCsim"\r
+# PROP Intermediate_Dir "Release\Lib_JSBSim"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\Lib_LaRCsim"\r
+# PROP Intermediate_Dir "Debug\Lib_JSBSim"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\FDM\LaRCsim\ls_model.c\r
+SOURCE=.\src\FDM\JSBSim\FGTranslation.cpp\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\Lib_LaRCsim"\r
+# PROP Intermediate_Dir "Release\Lib_JSBSim"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\Lib_LaRCsim"\r
+# PROP Intermediate_Dir "Debug\Lib_JSBSim"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\FDM\LaRCsim\ls_step.c\r
+SOURCE=.\src\FDM\JSBSim\FGTranslation.h\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\Lib_LaRCsim"\r
+# PROP Intermediate_Dir "Release\Lib_JSBSim"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\Lib_LaRCsim"\r
+# PROP Intermediate_Dir "Debug\Lib_JSBSim"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\FDM\LaRCsim\ls_trim.c\r
+SOURCE=.\src\FDM\JSBSim\FGTrim.cpp\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\Lib_LaRCsim"\r
+# PROP Intermediate_Dir "Release\Lib_JSBSim"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\Lib_LaRCsim"\r
+# PROP Intermediate_Dir "Debug\Lib_JSBSim"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\FDM\LaRCsim\c172_aero.c\r
+SOURCE=.\src\FDM\JSBSim\FGTrim.h\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\Lib_LaRCsim"\r
+# PROP Intermediate_Dir "Release\Lib_JSBSim"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\Lib_LaRCsim"\r
+# PROP Intermediate_Dir "Debug\Lib_JSBSim"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\FDM\LaRCsim\c172_engine.c\r
+SOURCE=.\src\FDM\JSBSim\FGTrimAxis.cpp\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\Lib_LaRCsim"\r
+# PROP Intermediate_Dir "Release\Lib_JSBSim"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\Lib_LaRCsim"\r
+# PROP Intermediate_Dir "Debug\Lib_JSBSim"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\FDM\LaRCsim\c172_gear.c\r
+SOURCE=.\src\FDM\JSBSim\FGTrimAxis.h\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\Lib_LaRCsim"\r
+# PROP Intermediate_Dir "Release\Lib_JSBSim"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\Lib_LaRCsim"\r
+# PROP Intermediate_Dir "Debug\Lib_JSBSim"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\FDM\LaRCsim\c172_init.c\r
+SOURCE=.\src\FDM\JSBSim\FGUtility.cpp\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\Lib_LaRCsim"\r
+# PROP Intermediate_Dir "Release\Lib_JSBSim"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\Lib_LaRCsim"\r
+# PROP Intermediate_Dir "Debug\Lib_JSBSim"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\FDM\LaRCsim\navion_init.h\r
+SOURCE=.\src\FDM\JSBSim\FGUtility.h\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\Lib_LaRCsim"\r
+# PROP Intermediate_Dir "Release\Lib_JSBSim"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\Lib_LaRCsim"\r
+# PROP Intermediate_Dir "Debug\Lib_JSBSim"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\FDM\LaRCsim\navion_aero.c\r
+SOURCE=.\src\FDM\JSBSim\FGEngine.cpp\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\Lib_LaRCsim"\r
+# PROP Intermediate_Dir "Release\Lib_JSBSim"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\Lib_LaRCsim"\r
+# PROP Intermediate_Dir "Debug\Lib_JSBSim"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\FDM\LaRCsim\navion_engine.c\r
+SOURCE=.\src\FDM\JSBSim\FGEngine.h\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\Lib_LaRCsim"\r
+# PROP Intermediate_Dir "Release\Lib_JSBSim"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\Lib_LaRCsim"\r
+# PROP Intermediate_Dir "Debug\Lib_JSBSim"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\FDM\LaRCsim\navion_gear.c\r
+SOURCE=.\src\FDM\JSBSim\FGTank.cpp\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\Lib_LaRCsim"\r
+# PROP Intermediate_Dir "Release\Lib_JSBSim"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\Lib_LaRCsim"\r
+# PROP Intermediate_Dir "Debug\Lib_JSBSim"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\FDM\LaRCsim\navion_init.c\r
+SOURCE=.\src\FDM\JSBSim\FGTank.h\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\Lib_LaRCsim"\r
+# PROP Intermediate_Dir "Release\Lib_JSBSim"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\Lib_LaRCsim"\r
+# PROP Intermediate_Dir "Debug\Lib_JSBSim"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\FDM\LaRCsim\uiuc_aero.c\r
+SOURCE=.\src\FDM\JSBSim\FGfdmSocket.cpp\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\Lib_LaRCsim"\r
+# PROP Intermediate_Dir "Release\Lib_JSBSim"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\Lib_LaRCsim"\r
+# PROP Intermediate_Dir "Debug\Lib_JSBSim"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\FDM\LaRCsim\cherokee_aero.c\r
+SOURCE=.\src\FDM\JSBSim\FGfdmSocket.h\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\Lib_LaRCsim"\r
+# PROP Intermediate_Dir "Release\Lib_JSBSim"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\Lib_LaRCsim"\r
+# PROP Intermediate_Dir "Debug\Lib_JSBSim"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
+# End Group\r
+# Begin Group "Lib_filtersjb"\r
+\r
+# PROP Default_Filter ""\r
 # Begin Source File\r
 \r
-SOURCE=.\src\FDM\LaRCsim\cherokee_engine.c\r
+SOURCE=.\src\FDM\JSBSim\filtersjb\FGDeadBand.cpp\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\Lib_LaRCsim"\r
+# PROP Intermediate_Dir "Release\Lib_filtersjb"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\Lib_LaRCsim"\r
+# PROP Intermediate_Dir "Debug\Lib_filtersjb"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\FDM\LaRCsim\cherokee_gear.c\r
+SOURCE=.\src\FDM\JSBSim\filtersjb\FGDeadBand.h\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\Lib_LaRCsim"\r
+# PROP Intermediate_Dir "Release\Lib_filtersjb"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\Lib_LaRCsim"\r
+# PROP Intermediate_Dir "Debug\Lib_filtersjb"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\FDM\LaRCsim\cherokee_init.c\r
+SOURCE=.\src\FDM\JSBSim\filtersjb\FGFCSComponent.cpp\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\Lib_LaRCsim"\r
+# PROP Intermediate_Dir "Release\Lib_filtersjb"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\Lib_LaRCsim"\r
+# PROP Intermediate_Dir "Debug\Lib_filtersjb"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\FDM\LaRCsim\ls_interface.c\r
+SOURCE=.\src\FDM\JSBSim\filtersjb\FGFCSComponent.h\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\Lib_LaRCsim"\r
+# PROP Intermediate_Dir "Release\Lib_filtersjb"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\Lib_LaRCsim"\r
+# PROP Intermediate_Dir "Debug\Lib_filtersjb"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
-# End Group\r
-# Begin Group "Lib_UIUCModel"\r
-\r
-# PROP Default_Filter ""\r
 # Begin Source File\r
 \r
-SOURCE=.\src\FDM\UIUCModel\uiuc_1DdataFileReader.cpp\r
+SOURCE=.\src\FDM\JSBSim\filtersjb\FGFilter.cpp\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\Lib_UIUCModel"\r
+# PROP Intermediate_Dir "Release\Lib_filtersjb"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\Lib_UIUCModel"\r
+# PROP Intermediate_Dir "Debug\Lib_filtersjb"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\FDM\UIUCModel\uiuc_1Dinterpolation.cpp\r
+SOURCE=.\src\FDM\JSBSim\filtersjb\FGFilter.h\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\Lib_UIUCModel"\r
+# PROP Intermediate_Dir "Release\Lib_filtersjb"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\Lib_UIUCModel"\r
+# PROP Intermediate_Dir "Debug\Lib_filtersjb"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\FDM\UIUCModel\uiuc_2DdataFileReader.cpp\r
+SOURCE=.\src\FDM\JSBSim\filtersjb\FGFlaps.cpp\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\Lib_UIUCModel"\r
+# PROP Intermediate_Dir "Release\Lib_filtersjb"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\Lib_UIUCModel"\r
+# PROP Intermediate_Dir "Debug\Lib_filtersjb"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\FDM\UIUCModel\uiuc_2Dinterpolation.cpp\r
+SOURCE=.\src\FDM\JSBSim\filtersjb\FGFlaps.h\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\Lib_UIUCModel"\r
+# PROP Intermediate_Dir "Release\Lib_filtersjb"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\Lib_UIUCModel"\r
+# PROP Intermediate_Dir "Debug\Lib_filtersjb"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\FDM\UIUCModel\uiuc_aerodeflections.cpp\r
+SOURCE=.\src\FDM\JSBSim\filtersjb\FGGain.cpp\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\Lib_UIUCModel"\r
+# PROP Intermediate_Dir "Release\Lib_filtersjb"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\Lib_UIUCModel"\r
+# PROP Intermediate_Dir "Debug\Lib_filtersjb"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\FDM\UIUCModel\uiuc_betaprobe.cpp\r
+SOURCE=.\src\FDM\JSBSim\filtersjb\FGGain.h\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\Lib_UIUCModel"\r
+# PROP Intermediate_Dir "Release\Lib_filtersjb"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\Lib_UIUCModel"\r
+# PROP Intermediate_Dir "Debug\Lib_filtersjb"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\FDM\UIUCModel\uiuc_coef_drag.cpp\r
+SOURCE=.\src\FDM\JSBSim\filtersjb\FGGradient.cpp\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\Lib_UIUCModel"\r
+# PROP Intermediate_Dir "Release\Lib_filtersjb"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\Lib_UIUCModel"\r
+# PROP Intermediate_Dir "Debug\Lib_filtersjb"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\FDM\UIUCModel\uiuc_coef_lift.cpp\r
+SOURCE=.\src\FDM\JSBSim\filtersjb\FGGradient.h\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\Lib_UIUCModel"\r
+# PROP Intermediate_Dir "Release\Lib_filtersjb"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\Lib_UIUCModel"\r
+# PROP Intermediate_Dir "Debug\Lib_filtersjb"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\FDM\UIUCModel\uiuc_coef_pitch.cpp\r
+SOURCE=.\src\FDM\JSBSim\filtersjb\FGSummer.cpp\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\Lib_UIUCModel"\r
+# PROP Intermediate_Dir "Release\Lib_filtersjb"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\Lib_UIUCModel"\r
+# PROP Intermediate_Dir "Debug\Lib_filtersjb"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\FDM\UIUCModel\uiuc_coef_roll.cpp\r
+SOURCE=.\src\FDM\JSBSim\filtersjb\FGSummer.h\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\Lib_UIUCModel"\r
+# PROP Intermediate_Dir "Release\Lib_filtersjb"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\Lib_UIUCModel"\r
+# PROP Intermediate_Dir "Debug\Lib_filtersjb"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\FDM\UIUCModel\uiuc_coef_sideforce.cpp\r
+SOURCE=.\src\FDM\JSBSim\filtersjb\FGSwitch.cpp\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\Lib_UIUCModel"\r
+# PROP Intermediate_Dir "Release\Lib_filtersjb"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\Lib_UIUCModel"\r
+# PROP Intermediate_Dir "Debug\Lib_filtersjb"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\FDM\UIUCModel\uiuc_coef_yaw.cpp\r
+SOURCE=.\src\FDM\JSBSim\filtersjb\FGSwitch.h\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\Lib_UIUCModel"\r
+# PROP Intermediate_Dir "Release\Lib_filtersjb"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\Lib_UIUCModel"\r
+# PROP Intermediate_Dir "Debug\Lib_filtersjb"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
+# End Group\r
+# Begin Group "Lib_LaRCsim"\r
+\r
+# PROP Default_Filter ""\r
 # Begin Source File\r
 \r
-SOURCE=.\src\FDM\UIUCModel\uiuc_coefficients.cpp\r
+SOURCE=.\src\FDM\LaRCsim\atmos_62.c\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\Lib_UIUCModel"\r
+# PROP Intermediate_Dir "Release\Lib_LaRCsim"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\Lib_UIUCModel"\r
+# PROP Intermediate_Dir "Debug\Lib_LaRCsim"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\FDM\UIUCModel\uiuc_controlInput.cpp\r
+SOURCE=.\src\FDM\LaRCsim\atmos_62.h\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\Lib_UIUCModel"\r
+# PROP Intermediate_Dir "Release\Lib_LaRCsim"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\Lib_UIUCModel"\r
+# PROP Intermediate_Dir "Debug\Lib_LaRCsim"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\FDM\UIUCModel\uiuc_convert.cpp\r
+SOURCE=.\src\FDM\LaRCsim\default_model_routines.c\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\Lib_UIUCModel"\r
+# PROP Intermediate_Dir "Release\Lib_LaRCsim"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\Lib_UIUCModel"\r
+# PROP Intermediate_Dir "Debug\Lib_LaRCsim"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\FDM\UIUCModel\uiuc_engine.cpp\r
+SOURCE=.\src\FDM\LaRCsim\default_model_routines.h\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\Lib_UIUCModel"\r
+# PROP Intermediate_Dir "Release\Lib_LaRCsim"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\Lib_UIUCModel"\r
+# PROP Intermediate_Dir "Debug\Lib_LaRCsim"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\FDM\UIUCModel\uiuc_ice.cpp\r
+SOURCE=.\src\FDM\LaRCsim\ls_accel.c\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\Lib_UIUCModel"\r
+# PROP Intermediate_Dir "Release\Lib_LaRCsim"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\Lib_UIUCModel"\r
+# PROP Intermediate_Dir "Debug\Lib_LaRCsim"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\FDM\UIUCModel\uiuc_initializemaps.cpp\r
+SOURCE=.\src\FDM\LaRCsim\ls_accel.h\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\Lib_UIUCModel"\r
+# PROP Intermediate_Dir "Release\Lib_LaRCsim"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\Lib_UIUCModel"\r
+# PROP Intermediate_Dir "Debug\Lib_LaRCsim"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\FDM\UIUCModel\uiuc_map_CD.cpp\r
+SOURCE=.\src\FDM\LaRCsim\ls_aux.c\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\Lib_UIUCModel"\r
+# PROP Intermediate_Dir "Release\Lib_LaRCsim"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\Lib_UIUCModel"\r
+# PROP Intermediate_Dir "Debug\Lib_LaRCsim"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\FDM\UIUCModel\uiuc_map_CL.cpp\r
+SOURCE=.\src\FDM\LaRCsim\ls_aux.h\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\Lib_UIUCModel"\r
+# PROP Intermediate_Dir "Release\Lib_LaRCsim"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\Lib_UIUCModel"\r
+# PROP Intermediate_Dir "Debug\Lib_LaRCsim"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\FDM\UIUCModel\uiuc_map_CY.cpp\r
+SOURCE=.\src\FDM\LaRCsim\ls_cockpit.h\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\Lib_UIUCModel"\r
+# PROP Intermediate_Dir "Release\Lib_LaRCsim"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\Lib_UIUCModel"\r
+# PROP Intermediate_Dir "Debug\Lib_LaRCsim"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\FDM\UIUCModel\uiuc_map_Cm.cpp\r
+SOURCE=.\src\FDM\LaRCsim\ls_constants.h\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\Lib_UIUCModel"\r
+# PROP Intermediate_Dir "Release\Lib_LaRCsim"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\Lib_UIUCModel"\r
+# PROP Intermediate_Dir "Debug\Lib_LaRCsim"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\FDM\UIUCModel\uiuc_map_Cn.cpp\r
+SOURCE=.\src\FDM\LaRCsim\ls_generic.h\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\Lib_UIUCModel"\r
+# PROP Intermediate_Dir "Release\Lib_LaRCsim"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\Lib_UIUCModel"\r
+# PROP Intermediate_Dir "Debug\Lib_LaRCsim"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\FDM\UIUCModel\uiuc_map_Croll.cpp\r
+SOURCE=.\src\FDM\LaRCsim\ls_geodesy.c\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\Lib_UIUCModel"\r
+# PROP Intermediate_Dir "Release\Lib_LaRCsim"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\Lib_UIUCModel"\r
+# PROP Intermediate_Dir "Debug\Lib_LaRCsim"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\FDM\UIUCModel\uiuc_map_controlSurface.cpp\r
+SOURCE=.\src\FDM\LaRCsim\ls_geodesy.h\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\Lib_UIUCModel"\r
+# PROP Intermediate_Dir "Release\Lib_LaRCsim"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\Lib_UIUCModel"\r
+# PROP Intermediate_Dir "Debug\Lib_LaRCsim"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\FDM\UIUCModel\uiuc_map_engine.cpp\r
+SOURCE=.\src\FDM\LaRCsim\ls_gravity.c\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\Lib_UIUCModel"\r
+# PROP Intermediate_Dir "Release\Lib_LaRCsim"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\Lib_UIUCModel"\r
+# PROP Intermediate_Dir "Debug\Lib_LaRCsim"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\FDM\UIUCModel\uiuc_map_geometry.cpp\r
+SOURCE=.\src\FDM\LaRCsim\ls_gravity.h\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\Lib_UIUCModel"\r
+# PROP Intermediate_Dir "Release\Lib_LaRCsim"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\Lib_UIUCModel"\r
+# PROP Intermediate_Dir "Debug\Lib_LaRCsim"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\FDM\UIUCModel\uiuc_map_ice.cpp\r
+SOURCE=.\src\FDM\LaRCsim\ls_init.c\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\Lib_UIUCModel"\r
+# PROP Intermediate_Dir "Release\Lib_LaRCsim"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\Lib_UIUCModel"\r
+# PROP Intermediate_Dir "Debug\Lib_LaRCsim"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\FDM\UIUCModel\uiuc_map_init.cpp\r
+SOURCE=.\src\FDM\LaRCsim\ls_init.h\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\Lib_UIUCModel"\r
+# PROP Intermediate_Dir "Release\Lib_LaRCsim"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\Lib_UIUCModel"\r
+# PROP Intermediate_Dir "Debug\Lib_LaRCsim"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\FDM\UIUCModel\uiuc_map_keyword.cpp\r
+SOURCE=.\src\FDM\LaRCsim\ls_matrix.c\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\Lib_UIUCModel"\r
+# PROP Intermediate_Dir "Release\Lib_LaRCsim"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\Lib_UIUCModel"\r
+# PROP Intermediate_Dir "Debug\Lib_LaRCsim"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\FDM\UIUCModel\uiuc_map_mass.cpp\r
+SOURCE=.\src\FDM\LaRCsim\ls_matrix.h\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\Lib_UIUCModel"\r
+# PROP Intermediate_Dir "Release\Lib_LaRCsim"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\Lib_UIUCModel"\r
+# PROP Intermediate_Dir "Debug\Lib_LaRCsim"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\FDM\UIUCModel\uiuc_map_misc.cpp\r
+SOURCE=.\src\FDM\LaRCsim\ls_model.c\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\Lib_UIUCModel"\r
+# PROP Intermediate_Dir "Release\Lib_LaRCsim"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\Lib_UIUCModel"\r
+# PROP Intermediate_Dir "Debug\Lib_LaRCsim"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\FDM\UIUCModel\uiuc_map_record1.cpp\r
+SOURCE=.\src\FDM\LaRCsim\ls_model.h\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\Lib_UIUCModel"\r
+# PROP Intermediate_Dir "Release\Lib_LaRCsim"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\Lib_UIUCModel"\r
+# PROP Intermediate_Dir "Debug\Lib_LaRCsim"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\FDM\UIUCModel\uiuc_map_record2.cpp\r
+SOURCE=.\src\FDM\LaRCsim\ls_sim_control.h\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\Lib_UIUCModel"\r
+# PROP Intermediate_Dir "Release\Lib_LaRCsim"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\Lib_UIUCModel"\r
+# PROP Intermediate_Dir "Debug\Lib_LaRCsim"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\FDM\UIUCModel\uiuc_map_record3.cpp\r
+SOURCE=.\src\FDM\LaRCsim\ls_step.c\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\Lib_UIUCModel"\r
+# PROP Intermediate_Dir "Release\Lib_LaRCsim"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\Lib_UIUCModel"\r
+# PROP Intermediate_Dir "Debug\Lib_LaRCsim"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\FDM\UIUCModel\uiuc_map_record4.cpp\r
+SOURCE=.\src\FDM\LaRCsim\ls_step.h\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\Lib_UIUCModel"\r
+# PROP Intermediate_Dir "Release\Lib_LaRCsim"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\Lib_UIUCModel"\r
+# PROP Intermediate_Dir "Debug\Lib_LaRCsim"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\FDM\UIUCModel\uiuc_map_record5.cpp\r
+SOURCE=.\src\FDM\LaRCsim\ls_sym.h\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\Lib_UIUCModel"\r
+# PROP Intermediate_Dir "Release\Lib_LaRCsim"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\Lib_UIUCModel"\r
+# PROP Intermediate_Dir "Debug\Lib_LaRCsim"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\FDM\UIUCModel\uiuc_menu.cpp\r
+SOURCE=.\src\FDM\LaRCsim\ls_trim.c\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\Lib_UIUCModel"\r
+# PROP Intermediate_Dir "Release\Lib_LaRCsim"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\Lib_UIUCModel"\r
+# PROP Intermediate_Dir "Debug\Lib_LaRCsim"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\FDM\UIUCModel\uiuc_parsefile.cpp\r
+SOURCE=.\src\FDM\LaRCsim\ls_types.h\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\Lib_UIUCModel"\r
+# PROP Intermediate_Dir "Release\Lib_LaRCsim"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\Lib_UIUCModel"\r
+# PROP Intermediate_Dir "Debug\Lib_LaRCsim"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\FDM\UIUCModel\uiuc_recorder.cpp\r
+SOURCE=.\src\FDM\LaRCsim\c172_aero.c\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\Lib_UIUCModel"\r
+# PROP Intermediate_Dir "Release\Lib_LaRCsim"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\Lib_UIUCModel"\r
+# PROP Intermediate_Dir "Debug\Lib_LaRCsim"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\FDM\UIUCModel\uiuc_warnings_errors.cpp\r
+SOURCE=.\src\FDM\LaRCsim\c172_engine.c\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\Lib_UIUCModel"\r
+# PROP Intermediate_Dir "Release\Lib_LaRCsim"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\Lib_UIUCModel"\r
+# PROP Intermediate_Dir "Debug\Lib_LaRCsim"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\FDM\UIUCModel\uiuc_wrapper.cpp\r
+SOURCE=.\src\FDM\LaRCsim\c172_gear.c\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\Lib_UIUCModel"\r
+# PROP Intermediate_Dir "Release\Lib_LaRCsim"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\Lib_UIUCModel"\r
+# PROP Intermediate_Dir "Debug\Lib_LaRCsim"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
-# End Group\r
-# Begin Group "Lib_Flight"\r
-\r
-# PROP Default_Filter ""\r
 # Begin Source File\r
 \r
-SOURCE=.\src\FDM\ADA.cxx\r
+SOURCE=.\src\FDM\LaRCsim\c172_init.c\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\Lib_Flight"\r
+# PROP Intermediate_Dir "Release\Lib_LaRCsim"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\Lib_Flight"\r
+# PROP Intermediate_Dir "Debug\Lib_LaRCsim"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\FDM\Balloon.cxx\r
+SOURCE=.\src\FDM\LaRCsim\navion_init.h\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\Lib_Flight"\r
+# PROP Intermediate_Dir "Release\Lib_LaRCsim"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\Lib_Flight"\r
+# PROP Intermediate_Dir "Debug\Lib_LaRCsim"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\FDM\External.cxx\r
+SOURCE=.\src\FDM\LaRCsim\navion_aero.c\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\Lib_Flight"\r
+# PROP Intermediate_Dir "Release\Lib_LaRCsim"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\Lib_Flight"\r
+# PROP Intermediate_Dir "Debug\Lib_LaRCsim"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\FDM\flight.cxx\r
+SOURCE=.\src\FDM\LaRCsim\navion_engine.c\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\Lib_Flight"\r
+# PROP Intermediate_Dir "Release\Lib_LaRCsim"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\Lib_Flight"\r
+# PROP Intermediate_Dir "Debug\Lib_LaRCsim"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\FDM\IO360.cxx\r
+SOURCE=.\src\FDM\LaRCsim\navion_gear.c\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\Lib_Flight"\r
+# PROP Intermediate_Dir "Release\Lib_LaRCsim"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\Lib_Flight"\r
+# PROP Intermediate_Dir "Debug\Lib_LaRCsim"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\FDM\JSBSim.cxx\r
+SOURCE=.\src\FDM\LaRCsim\navion_init.c\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\Lib_Flight"\r
+# PROP Intermediate_Dir "Release\Lib_LaRCsim"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\Lib_Flight"\r
+# PROP Intermediate_Dir "Debug\Lib_LaRCsim"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\FDM\LaRCsim.cxx\r
+SOURCE=.\src\FDM\LaRCsim\uiuc_aero.c\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\Lib_Flight"\r
+# PROP Intermediate_Dir "Release\Lib_LaRCsim"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\Lib_Flight"\r
+# PROP Intermediate_Dir "Debug\Lib_LaRCsim"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\FDM\LaRCsimIC.cxx\r
+SOURCE=.\src\FDM\LaRCsim\cherokee_aero.c\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\Lib_Flight"\r
+# PROP Intermediate_Dir "Release\Lib_LaRCsim"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\Lib_Flight"\r
+# PROP Intermediate_Dir "Debug\Lib_LaRCsim"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\FDM\MagicCarpet.cxx\r
+SOURCE=.\src\FDM\LaRCsim\cherokee_engine.c\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\Lib_Flight"\r
+# PROP Intermediate_Dir "Release\Lib_LaRCsim"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\Lib_Flight"\r
+# PROP Intermediate_Dir "Debug\Lib_LaRCsim"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
-# End Group\r
-# Begin Group "Lib_GUI"\r
-\r
-# PROP Default_Filter ""\r
 # Begin Source File\r
 \r
-SOURCE=.\src\GUI\apt_dlg.cxx\r
+SOURCE=.\src\FDM\LaRCsim\cherokee_gear.c\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\Lib_GUI"\r
+# PROP Intermediate_Dir "Release\Lib_LaRCsim"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\Lib_GUI"\r
+# PROP Intermediate_Dir "Debug\Lib_LaRCsim"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\GUI\gui.cxx\r
+SOURCE=.\src\FDM\LaRCsim\cherokee_init.c\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\Lib_GUI"\r
+# PROP Intermediate_Dir "Release\Lib_LaRCsim"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\Lib_GUI"\r
+# PROP Intermediate_Dir "Debug\Lib_LaRCsim"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\GUI\gui_local.cxx\r
+SOURCE=.\src\FDM\LaRCsim\ls_interface.c\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\Lib_GUI"\r
+# PROP Intermediate_Dir "Release\Lib_LaRCsim"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\Lib_GUI"\r
+# PROP Intermediate_Dir "Debug\Lib_LaRCsim"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\GUI\mouse.cxx\r
+SOURCE=.\src\FDM\LaRCsim\ls_interface.h\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\Lib_GUI"\r
+# PROP Intermediate_Dir "Release\Lib_LaRCsim"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\Lib_GUI"\r
+# PROP Intermediate_Dir "Debug\Lib_LaRCsim"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
+# End Group\r
+# Begin Group "Lib_UIUCModel"\r
+\r
+# PROP Default_Filter ""\r
 # Begin Source File\r
 \r
-SOURCE=.\src\GUI\net_dlg.cxx\r
+SOURCE=.\src\FDM\UIUCModel\uiuc_1DdataFileReader.cpp\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\Lib_GUI"\r
+# PROP Intermediate_Dir "Release\Lib_UIUCModel"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\Lib_GUI"\r
+# PROP Intermediate_Dir "Debug\Lib_UIUCModel"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\GUI\sgVec3Slider.cxx\r
+SOURCE=.\src\FDM\UIUCModel\uiuc_1DdataFileReader.h\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\Lib_GUI"\r
+# PROP Intermediate_Dir "Release\Lib_UIUCModel"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\Lib_GUI"\r
+# PROP Intermediate_Dir "Debug\Lib_UIUCModel"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\GUI\trackball.c\r
+SOURCE=.\src\FDM\UIUCModel\uiuc_1Dinterpolation.cpp\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\Lib_GUI"\r
+# PROP Intermediate_Dir "Release\Lib_UIUCModel"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\Lib_GUI"\r
+# PROP Intermediate_Dir "Debug\Lib_UIUCModel"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
-# End Group\r
-# Begin Group "Lib_Joystick"\r
-\r
-# PROP Default_Filter ""\r
 # Begin Source File\r
 \r
-SOURCE=.\src\Joystick\joystick.cxx\r
+SOURCE=.\src\FDM\UIUCModel\uiuc_1Dinterpolation.h\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\Lib_Joystick"\r
+# PROP Intermediate_Dir "Release\Lib_UIUCModel"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\Lib_Joystick"\r
+# PROP Intermediate_Dir "Debug\Lib_UIUCModel"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
-# End Group\r
-# Begin Group "main"\r
-\r
-# PROP Default_Filter ""\r
 # Begin Source File\r
 \r
-SOURCE=.\src\Main\main.cxx\r
+SOURCE=.\src\FDM\UIUCModel\uiuc_2DdataFileReader.cpp\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\main"\r
+# PROP Intermediate_Dir "Release\Lib_UIUCModel"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_UIUCModel"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\FDM\UIUCModel\uiuc_2DdataFileReader.h\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_UIUCModel"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_UIUCModel"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\FDM\UIUCModel\uiuc_2Dinterpolation.cpp\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_UIUCModel"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_UIUCModel"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\FDM\UIUCModel\uiuc_2Dinterpolation.h\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_UIUCModel"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_UIUCModel"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\FDM\UIUCModel\uiuc_aerodeflections.cpp\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_UIUCModel"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_UIUCModel"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\FDM\UIUCModel\uiuc_aerodeflections.h\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_UIUCModel"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_UIUCModel"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\FDM\UIUCModel\uiuc_aircraftdir.h\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_UIUCModel"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_UIUCModel"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\FDM\UIUCModel\uiuc_aircraft.h\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_UIUCModel"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_UIUCModel"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\FDM\UIUCModel\uiuc_betaprobe.cpp\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_UIUCModel"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_UIUCModel"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\FDM\UIUCModel\uiuc_betaprobe.h\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_UIUCModel"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_UIUCModel"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\FDM\UIUCModel\uiuc_coef_drag.cpp\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_UIUCModel"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_UIUCModel"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\FDM\UIUCModel\uiuc_coef_drag.h\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_UIUCModel"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_UIUCModel"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\FDM\UIUCModel\uiuc_coef_lift.cpp\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_UIUCModel"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_UIUCModel"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\FDM\UIUCModel\uiuc_coef_lift.h\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_UIUCModel"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_UIUCModel"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\FDM\UIUCModel\uiuc_coef_pitch.cpp\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_UIUCModel"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_UIUCModel"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\FDM\UIUCModel\uiuc_coef_pitch.h\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_UIUCModel"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_UIUCModel"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\FDM\UIUCModel\uiuc_coef_roll.cpp\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_UIUCModel"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_UIUCModel"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\FDM\UIUCModel\uiuc_coef_roll.h\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_UIUCModel"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_UIUCModel"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\FDM\UIUCModel\uiuc_coef_sideforce.cpp\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_UIUCModel"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_UIUCModel"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\FDM\UIUCModel\uiuc_coef_sideforce.h\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_UIUCModel"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_UIUCModel"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\FDM\UIUCModel\uiuc_coef_yaw.cpp\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_UIUCModel"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_UIUCModel"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\FDM\UIUCModel\uiuc_coef_yaw.h\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_UIUCModel"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_UIUCModel"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\FDM\UIUCModel\uiuc_coefficients.cpp\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_UIUCModel"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_UIUCModel"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\FDM\UIUCModel\uiuc_coefficients.h\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_UIUCModel"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_UIUCModel"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\FDM\UIUCModel\uiuc_controlInput.cpp\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_UIUCModel"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_UIUCModel"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\FDM\UIUCModel\uiuc_controlInput.h\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_UIUCModel"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_UIUCModel"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\FDM\UIUCModel\uiuc_convert.cpp\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_UIUCModel"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_UIUCModel"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\FDM\UIUCModel\uiuc_convert.h\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_UIUCModel"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_UIUCModel"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\FDM\UIUCModel\uiuc_engine.cpp\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_UIUCModel"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_UIUCModel"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\FDM\UIUCModel\uiuc_engine.h\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_UIUCModel"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_UIUCModel"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\FDM\UIUCModel\uiuc_ice.cpp\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_UIUCModel"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_UIUCModel"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\FDM\UIUCModel\uiuc_ice.h\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_UIUCModel"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_UIUCModel"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\FDM\UIUCModel\uiuc_initializemaps.cpp\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_UIUCModel"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_UIUCModel"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\FDM\UIUCModel\uiuc_initializemaps.h\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_UIUCModel"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_UIUCModel"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\FDM\UIUCModel\uiuc_map_CD.cpp\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_UIUCModel"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_UIUCModel"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\FDM\UIUCModel\uiuc_map_CD.h\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_UIUCModel"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_UIUCModel"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\FDM\UIUCModel\uiuc_map_CL.cpp\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_UIUCModel"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_UIUCModel"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\FDM\UIUCModel\uiuc_map_CL.h\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_UIUCModel"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_UIUCModel"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\FDM\UIUCModel\uiuc_map_CY.cpp\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_UIUCModel"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_UIUCModel"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\FDM\UIUCModel\uiuc_map_CY.h\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_UIUCModel"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_UIUCModel"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\FDM\UIUCModel\uiuc_map_Cm.cpp\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_UIUCModel"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_UIUCModel"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\FDM\UIUCModel\uiuc_map_Cm.h\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_UIUCModel"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_UIUCModel"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\FDM\UIUCModel\uiuc_map_Cn.cpp\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_UIUCModel"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_UIUCModel"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\FDM\UIUCModel\uiuc_map_Cn.h\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_UIUCModel"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_UIUCModel"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\FDM\UIUCModel\uiuc_map_Croll.cpp\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_UIUCModel"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_UIUCModel"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\FDM\UIUCModel\uiuc_map_Croll.h\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_UIUCModel"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_UIUCModel"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\FDM\UIUCModel\uiuc_map_controlSurface.cpp\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_UIUCModel"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_UIUCModel"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\FDM\UIUCModel\uiuc_map_controlSurface.h\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_UIUCModel"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_UIUCModel"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\FDM\UIUCModel\uiuc_map_engine.cpp\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_UIUCModel"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_UIUCModel"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\FDM\UIUCModel\uiuc_map_engine.h\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_UIUCModel"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_UIUCModel"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\FDM\UIUCModel\uiuc_map_geometry.cpp\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_UIUCModel"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_UIUCModel"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\FDM\UIUCModel\uiuc_map_geometry.h\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_UIUCModel"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_UIUCModel"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\FDM\UIUCModel\uiuc_map_ice.cpp\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_UIUCModel"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_UIUCModel"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\FDM\UIUCModel\uiuc_map_ice.h\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_UIUCModel"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_UIUCModel"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\FDM\UIUCModel\uiuc_map_init.cpp\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_UIUCModel"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_UIUCModel"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\FDM\UIUCModel\uiuc_map_init.h\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_UIUCModel"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_UIUCModel"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\FDM\UIUCModel\uiuc_map_keyword.cpp\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_UIUCModel"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_UIUCModel"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\FDM\UIUCModel\uiuc_map_keyword.h\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_UIUCModel"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_UIUCModel"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\FDM\UIUCModel\uiuc_map_mass.cpp\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_UIUCModel"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_UIUCModel"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\FDM\UIUCModel\uiuc_map_mass.h\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_UIUCModel"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_UIUCModel"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\FDM\UIUCModel\uiuc_map_misc.cpp\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_UIUCModel"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_UIUCModel"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\FDM\UIUCModel\uiuc_map_misc.h\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_UIUCModel"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_UIUCModel"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\FDM\UIUCModel\uiuc_map_record1.cpp\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_UIUCModel"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_UIUCModel"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\FDM\UIUCModel\uiuc_map_record1.h\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_UIUCModel"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_UIUCModel"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\FDM\UIUCModel\uiuc_map_record2.cpp\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_UIUCModel"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_UIUCModel"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\FDM\UIUCModel\uiuc_map_record2.h\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_UIUCModel"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_UIUCModel"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\FDM\UIUCModel\uiuc_map_record3.cpp\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_UIUCModel"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_UIUCModel"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\FDM\UIUCModel\uiuc_map_record3.h\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_UIUCModel"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_UIUCModel"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\FDM\UIUCModel\uiuc_map_record4.cpp\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_UIUCModel"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_UIUCModel"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\FDM\UIUCModel\uiuc_map_record4.h\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_UIUCModel"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_UIUCModel"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\FDM\UIUCModel\uiuc_map_record5.cpp\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_UIUCModel"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_UIUCModel"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\FDM\UIUCModel\uiuc_map_record5.h\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_UIUCModel"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_UIUCModel"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\FDM\UIUCModel\uiuc_menu.cpp\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_UIUCModel"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_UIUCModel"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\FDM\UIUCModel\uiuc_menu.h\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_UIUCModel"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_UIUCModel"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\FDM\UIUCModel\uiuc_parsefile.cpp\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_UIUCModel"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_UIUCModel"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\FDM\UIUCModel\uiuc_parsefile.h\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_UIUCModel"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_UIUCModel"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\FDM\UIUCModel\uiuc_recorder.cpp\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_UIUCModel"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_UIUCModel"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\FDM\UIUCModel\uiuc_recorder.h\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_UIUCModel"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_UIUCModel"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\FDM\UIUCModel\uiuc_warnings_errors.cpp\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_UIUCModel"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_UIUCModel"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\FDM\UIUCModel\uiuc_warnings_errors.h\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_UIUCModel"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_UIUCModel"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\FDM\UIUCModel\uiuc_wrapper.cpp\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_UIUCModel"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_UIUCModel"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\FDM\UIUCModel\uiuc_wrapper.h\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_UIUCModel"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_UIUCModel"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# End Group\r
+# Begin Group "Lib_Flight"\r
+\r
+# PROP Default_Filter ""\r
+# Begin Source File\r
+\r
+SOURCE=.\src\FDM\ADA.cxx\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_Flight"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_Flight"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\FDM\ADA.hxx\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_Flight"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_Flight"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\FDM\Balloon.cxx\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_Flight"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_Flight"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\FDM\Balloon.h\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_Flight"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_Flight"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\FDM\External.cxx\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_Flight"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_Flight"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\FDM\External.hxx\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_Flight"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_Flight"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\FDM\flight.cxx\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_Flight"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_Flight"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\FDM\flight.hxx\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_Flight"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_Flight"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\FDM\IO360.cxx\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_Flight"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_Flight"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\FDM\IO360.hxx\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_Flight"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_Flight"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\FDM\JSBSim.cxx\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_Flight"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_Flight"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\FDM\JSBSim.hxx\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_Flight"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_Flight"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\FDM\LaRCsim.cxx\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_Flight"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_Flight"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\FDM\LaRCsim.hxx\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_Flight"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_Flight"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\FDM\LaRCsimIC.cxx\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_Flight"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_Flight"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\FDM\LaRCsimIC.hxx\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_Flight"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_Flight"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\FDM\MagicCarpet.cxx\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_Flight"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_Flight"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\FDM\MagicCarpet.hxx\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_Flight"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_Flight"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# End Group\r
+# Begin Group "Lib_GUI"\r
+\r
+# PROP Default_Filter ""\r
+# Begin Source File\r
+\r
+SOURCE=.\src\GUI\apt_dlg.cxx\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_GUI"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_GUI"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\GUI\apt_dlg.hxx\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_GUI"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_GUI"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\GUI\gui.cxx\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_GUI"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_GUI"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\GUI\gui.h\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_GUI"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_GUI"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\GUI\gui_local.cxx\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_GUI"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_GUI"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\GUI\gui_local.hxx\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_GUI"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_GUI"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\GUI\mouse.cxx\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_GUI"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_GUI"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\GUI\net_dlg.cxx\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_GUI"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_GUI"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\GUI\net_dlg.hxx\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_GUI"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_GUI"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\GUI\sgVec3Slider.cxx\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_GUI"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_GUI"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\GUI\sgVec3Slider.hxx\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_GUI"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_GUI"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\GUI\trackball.c\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_GUI"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_GUI"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\GUI\trackball.h\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_GUI"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_GUI"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# End Group\r
+# Begin Group "Lib_Joystick"\r
+\r
+# PROP Default_Filter ""\r
+# Begin Source File\r
+\r
+SOURCE=.\src\Joystick\joystick.cxx\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_Joystick"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_Joystick"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\Joystick\joystick.hxx\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_Joystick"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_Joystick"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# End Group\r
+# Begin Group "main"\r
+\r
+# PROP Default_Filter ""\r
+# Begin Source File\r
+\r
+SOURCE=.\src\Main\main.cxx\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\main"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\main"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\Main\bfi.cxx\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\main"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\main"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\Main\bfi.hxx\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\main"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\main"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\Main\fg_init.cxx\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\main"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\main"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\Main\fg_init.hxx\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\main"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\main"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\Main\fg_io.cxx\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\main"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\main"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\Main\fg_io.hxx\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\main"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\main"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\Main\fg_props.cxx\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\main"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\main"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\Main\fg_props.hxx\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\main"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\main"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\Main\fgfs.cxx\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\main"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\main"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\Main\fgfs.hxx\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\main"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\main"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\Main\globals.cxx\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\main"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\main"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\Main\globals.hxx\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\main"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\main"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\Main\keyboard.cxx\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\main"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\main"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\Main\keyboard.hxx\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\main"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\main"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\Main\options.cxx\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\main"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\main"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\Main\options.hxx\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\main"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\main"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\Main\splash.cxx\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\main"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\main"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\Main\splash.hxx\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\main"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\main"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\Main\viewer.cxx\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\main"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\main"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\Main\viewer.hxx\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\main"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\main"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\Main\viewer_lookat.cxx\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\main"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\main"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\Main\viewer_lookat.hxx\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\main"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\main"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\Main\viewer_rph.cxx\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\main"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\main"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\Main\viewer_rph.hxx\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\main"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\main"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\Main\viewmgr.cxx\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\main"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\main"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\Main\viewmgr.hxx\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\main"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\main"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# End Group\r
+# Begin Group "Lib_Navaids"\r
+\r
+# PROP Default_Filter ""\r
+# Begin Source File\r
+\r
+SOURCE=.\src\Navaids\fix.hxx\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_Navaids"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_Navaids"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\Navaids\fixlist.hxx\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_Navaids"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_Navaids"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\Navaids\fixlist.cxx\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_Navaids"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_Navaids"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\Navaids\ils.hxx\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_Navaids"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_Navaids"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\Navaids\ilslist.hxx\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_Navaids"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_Navaids"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\Navaids\ilslist.cxx\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_Navaids"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_Navaids"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\Navaids\mkrbeacons.hxx\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_Navaids"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_Navaids"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\Navaids\mkrbeacons.cxx\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_Navaids"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_Navaids"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\Navaids\nav.hxx\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_Navaids"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_Navaids"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\Navaids\navlist.hxx\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_Navaids"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_Navaids"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\Navaids\navlist.cxx\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_Navaids"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_Navaids"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# End Group\r
+# Begin Group "Lib_Network"\r
+\r
+# PROP Default_Filter ""\r
+# Begin Source File\r
+\r
+SOURCE=.\src\Network\protocol.cxx\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_Network"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_Network"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\Network\protocol.hxx\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_Network"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_Network"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\Network\atlas.cxx\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_Network"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_Network"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\Network\atlas.hxx\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_Network"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_Network"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\Network\garmin.cxx\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_Network"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_Network"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\Network\garmin.hxx\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_Network"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_Network"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\Network\joyclient.cxx\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_Network"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_Network"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\Network\joyclient.hxx\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_Network"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_Network"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\Network\native.cxx\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_Network"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_Network"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\Network\native.hxx\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_Network"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_Network"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\Network\nmea.cxx\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_Network"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_Network"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\Network\nmea.hxx\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_Network"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_Network"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\Network\props.cxx\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_Network"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_Network"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\Network\props.hxx\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_Network"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_Network"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\Network\pve.cxx\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_Network"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_Network"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\Network\pve.hxx\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_Network"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_Network"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\Network\ray.cxx\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_Network"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_Network"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\Network\ray.hxx\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_Network"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_Network"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\Network\rul.cxx\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_Network"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_Network"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\Network\rul.hxx\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_Network"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_Network"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# End Group\r
+# Begin Group "Lib_NetworkOLK"\r
+\r
+# PROP Default_Filter ""\r
+# Begin Source File\r
+\r
+SOURCE=.\src\NetworkOLK\net_send.cxx\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_NetworkOLK"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_NetworkOLK"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\NetworkOLK\net_hud.cxx\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_NetworkOLK"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\main"\r
+# PROP Intermediate_Dir "Debug\Lib_NetworkOLK"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\Main\bfi.cxx\r
+SOURCE=.\src\NetworkOLK\network.cxx\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\main"\r
+# PROP Intermediate_Dir "Release\Lib_NetworkOLK"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\main"\r
+# PROP Intermediate_Dir "Debug\Lib_NetworkOLK"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\Main\fg_init.cxx\r
+SOURCE=.\src\NetworkOLK\network.h\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\main"\r
+# PROP Intermediate_Dir "Release\Lib_NetworkOLK"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\main"\r
+# PROP Intermediate_Dir "Debug\Lib_NetworkOLK"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\Main\fg_io.cxx\r
+SOURCE=.\src\NetworkOLK\fgd.h\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\main"\r
+# PROP Intermediate_Dir "Release\Lib_NetworkOLK"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\main"\r
+# PROP Intermediate_Dir "Debug\Lib_NetworkOLK"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\Main\fg_props.cxx\r
+SOURCE=.\src\NetworkOLK\features.cxx\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\main"\r
+# PROP Intermediate_Dir "Release\Lib_NetworkOLK"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\main"\r
+# PROP Intermediate_Dir "Debug\Lib_NetworkOLK"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\Main\fgfs.cxx\r
+SOURCE=.\src\NetworkOLK\features.hxx\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\main"\r
+# PROP Intermediate_Dir "Release\Lib_NetworkOLK"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\main"\r
+# PROP Intermediate_Dir "Debug\Lib_NetworkOLK"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
+# End Group\r
+# Begin Group "Lib_Objects"\r
+\r
+# PROP Default_Filter ""\r
 # Begin Source File\r
 \r
-SOURCE=.\src\Main\globals.cxx\r
+SOURCE=.\src\Objects\newmat.cxx\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\main"\r
+# PROP Intermediate_Dir "Release\Lib_Objects"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\main"\r
+# PROP Intermediate_Dir "Debug\Lib_Objects"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\Main\keyboard.cxx\r
+SOURCE=.\src\Objects\newmat.hxx\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\main"\r
+# PROP Intermediate_Dir "Release\Lib_Objects"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\main"\r
+# PROP Intermediate_Dir "Debug\Lib_Objects"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\Main\options.cxx\r
+SOURCE=.\src\Objects\matlib.cxx\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\main"\r
+# PROP Intermediate_Dir "Release\Lib_Objects"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\main"\r
+# PROP Intermediate_Dir "Debug\Lib_Objects"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\Main\splash.cxx\r
+SOURCE=.\src\Objects\matlib.hxx\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\main"\r
+# PROP Intermediate_Dir "Release\Lib_Objects"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\main"\r
+# PROP Intermediate_Dir "Debug\Lib_Objects"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\Main\viewer.cxx\r
+SOURCE=.\src\Objects\obj.cxx\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\main"\r
+# PROP Intermediate_Dir "Release\Lib_Objects"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\main"\r
+# PROP Intermediate_Dir "Debug\Lib_Objects"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\Main\viewer_lookat.cxx\r
+SOURCE=.\src\Objects\obj.hxx\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\main"\r
+# PROP Intermediate_Dir "Release\Lib_Objects"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\main"\r
+# PROP Intermediate_Dir "Debug\Lib_Objects"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\Main\viewer_rph.cxx\r
+SOURCE=.\src\Objects\texload.c\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\main"\r
+# PROP Intermediate_Dir "Release\Lib_Objects"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\main"\r
+# PROP Intermediate_Dir "Debug\Lib_Objects"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\Main\viewmgr.cxx\r
+SOURCE=.\src\Objects\texload.h\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\main"\r
+# PROP Intermediate_Dir "Release\Lib_Objects"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\main"\r
+# PROP Intermediate_Dir "Debug\Lib_Objects"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\Objects\colours.h\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_Objects"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_Objects"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
 # End Group\r
-# Begin Group "Lib_Navaids"\r
+# Begin Group "Lib_Scenery"\r
+\r
+# PROP Default_Filter ""\r
+# Begin Source File\r
+\r
+SOURCE=.\src\Scenery\hitlist.cxx\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_Scenery"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_Scenery"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\Scenery\hitlist.hxx\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_Scenery"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_Scenery"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\Scenery\newcache.cxx\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_Scenery"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_Scenery"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\Scenery\newcache.hxx\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_Scenery"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_Scenery"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\Scenery\scenery.cxx\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_Scenery"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_Scenery"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\Scenery\scenery.hxx\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_Scenery"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_Scenery"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\Scenery\tileentry.cxx\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_Scenery"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_Scenery"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\Scenery\tileentry.hxx\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_Scenery"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_Scenery"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\Scenery\tilemgr.cxx\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_Scenery"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_Scenery"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\Scenery\tilemgr.hxx\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_Scenery"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_Scenery"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# End Group\r
+# Begin Group "Lib_Sound"\r
 \r
 # PROP Default_Filter ""\r
 # Begin Source File\r
 \r
-SOURCE=.\src\Navaids\fixlist.cxx\r
+SOURCE=.\src\Sound\beacon.cxx\r
+\r
+!IF  "$(CFG)" == "FlightGear - Win32 Release"\r
+\r
+# PROP Intermediate_Dir "Release\Lib_Sound"\r
+\r
+!ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
+\r
+# PROP Intermediate_Dir "Debug\Lib_Sound"\r
+\r
+!ENDIF \r
+\r
+# End Source File\r
+# Begin Source File\r
+\r
+SOURCE=.\src\Sound\beacon.hxx\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\Lib_Navaids"\r
+# PROP Intermediate_Dir "Release\Lib_Sound"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\Lib_Navaids"\r
+# PROP Intermediate_Dir "Debug\Lib_Sound"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\Navaids\ilslist.cxx\r
+SOURCE=.\src\Sound\morse.cxx\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\Lib_Navaids"\r
+# PROP Intermediate_Dir "Release\Lib_Sound"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\Lib_Navaids"\r
+# PROP Intermediate_Dir "Debug\Lib_Sound"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\Navaids\mkrbeacons.cxx\r
+SOURCE=.\src\Sound\morse.hxx\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\Lib_Navaids"\r
+# PROP Intermediate_Dir "Release\Lib_Sound"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\Lib_Navaids"\r
+# PROP Intermediate_Dir "Debug\Lib_Sound"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\Navaids\navlist.cxx\r
+SOURCE=.\src\Sound\soundmgr.cxx\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\Lib_Navaids"\r
+# PROP Intermediate_Dir "Release\Lib_Sound"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\Lib_Navaids"\r
+# PROP Intermediate_Dir "Debug\Lib_Sound"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
-# End Group\r
-# Begin Group "Lib_Network"\r
-\r
-# PROP Default_Filter ""\r
 # Begin Source File\r
 \r
-SOURCE=.\src\Network\protocol.cxx\r
+SOURCE=.\src\Sound\soundmgr.hxx\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\Lib_Network"\r
+# PROP Intermediate_Dir "Release\Lib_Sound"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\Lib_Network"\r
+# PROP Intermediate_Dir "Debug\Lib_Sound"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
+# End Group\r
+# Begin Group "Lib_Time"\r
+\r
+# PROP Default_Filter ""\r
 # Begin Source File\r
 \r
-SOURCE=.\src\Network\atlas.cxx\r
+SOURCE=.\src\Time\event.cxx\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\Lib_Network"\r
+# PROP Intermediate_Dir "Release\Lib_Time"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\Lib_Network"\r
+# PROP Intermediate_Dir "Debug\Lib_Time"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\Network\garmin.cxx\r
+SOURCE=.\src\Time\event.hxx\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\Lib_Network"\r
+# PROP Intermediate_Dir "Release\Lib_Time"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\Lib_Network"\r
+# PROP Intermediate_Dir "Debug\Lib_Time"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\Network\joyclient.cxx\r
+SOURCE=.\src\Time\fg_timer.cxx\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\Lib_Network"\r
+# PROP Intermediate_Dir "Release\Lib_Time"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\Lib_Network"\r
+# PROP Intermediate_Dir "Debug\Lib_Time"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\Network\native.cxx\r
+SOURCE=.\src\Time\fg_timer.hxx\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\Lib_Network"\r
+# PROP Intermediate_Dir "Release\Lib_Time"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\Lib_Network"\r
+# PROP Intermediate_Dir "Debug\Lib_Time"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\Network\nmea.cxx\r
+SOURCE=.\src\Time\light.cxx\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\Lib_Network"\r
+# PROP Intermediate_Dir "Release\Lib_Time"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\Lib_Network"\r
+# PROP Intermediate_Dir "Debug\Lib_Time"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\Network\props.cxx\r
+SOURCE=.\src\Time\light.hxx\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\Lib_Network"\r
+# PROP Intermediate_Dir "Release\Lib_Time"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\Lib_Network"\r
+# PROP Intermediate_Dir "Debug\Lib_Time"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\Network\pve.cxx\r
+SOURCE=.\src\Time\moonpos.cxx\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\Lib_Network"\r
+# PROP Intermediate_Dir "Release\Lib_Time"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\Lib_Network"\r
+# PROP Intermediate_Dir "Debug\Lib_Time"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\Network\ray.cxx\r
+SOURCE=.\src\Time\moonpos.hxx\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\Lib_Network"\r
+# PROP Intermediate_Dir "Release\Lib_Time"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\Lib_Network"\r
+# PROP Intermediate_Dir "Debug\Lib_Time"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\Network\rul.cxx\r
+SOURCE=.\src\Time\sunpos.cxx\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\Lib_Network"\r
+# PROP Intermediate_Dir "Release\Lib_Time"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\Lib_Network"\r
+# PROP Intermediate_Dir "Debug\Lib_Time"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
-# End Group\r
-# Begin Group "Lib_NetworkOLK"\r
-\r
-# PROP Default_Filter ""\r
 # Begin Source File\r
 \r
-SOURCE=.\src\NetworkOLK\net_send.cxx\r
+SOURCE=.\src\Time\sunpos.hxx\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\Lib_NetworkOLK"\r
+# PROP Intermediate_Dir "Release\Lib_Time"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\Lib_NetworkOLK"\r
+# PROP Intermediate_Dir "Debug\Lib_Time"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\NetworkOLK\net_hud.cxx\r
+SOURCE=.\src\Time\tmp.cxx\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\Lib_NetworkOLK"\r
+# PROP Intermediate_Dir "Release\Lib_Time"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\Lib_NetworkOLK"\r
+# PROP Intermediate_Dir "Debug\Lib_Time"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\NetworkOLK\network.cxx\r
+SOURCE=.\src\Time\tmp.hxx\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\Lib_NetworkOLK"\r
+# PROP Intermediate_Dir "Release\Lib_Time"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\Lib_NetworkOLK"\r
+# PROP Intermediate_Dir "Debug\Lib_Time"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
+# End Group\r
+# Begin Group "Lib_Weather"\r
+\r
+# PROP Default_Filter ""\r
 # Begin Source File\r
 \r
-SOURCE=.\src\NetworkOLK\features.cxx\r
+SOURCE=.\src\Weather\weather.cxx\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\Lib_NetworkOLK"\r
+# PROP Intermediate_Dir "Release\Lib_Weather"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\Lib_NetworkOLK"\r
+# PROP Intermediate_Dir "Debug\Lib_Weather"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
-# End Group\r
-# Begin Group "Lib_Objects"\r
-\r
-# PROP Default_Filter ""\r
 # Begin Source File\r
 \r
-SOURCE=.\src\Objects\newmat.cxx\r
+SOURCE=.\src\Weather\weather.hxx\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\Lib_Objects"\r
+# PROP Intermediate_Dir "Release\Lib_Weather"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\Lib_Objects"\r
+# PROP Intermediate_Dir "Debug\Lib_Weather"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
+# End Group\r
+# Begin Group "Lib_WeatherCM"\r
+\r
+# PROP Default_Filter ""\r
 # Begin Source File\r
 \r
-SOURCE=.\src\Objects\matlib.cxx\r
+SOURCE=.\src\WeatherCM\FGAirPressureItem.cpp\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\Lib_Objects"\r
+# PROP Intermediate_Dir "Release\Lib_WeatherCM"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\Lib_Objects"\r
+# PROP Intermediate_Dir "Debug\Lib_WeatherCM"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\Objects\obj.cxx\r
+SOURCE=.\src\WeatherCM\FGAirPressureItem.h\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\Lib_Objects"\r
+# PROP Intermediate_Dir "Release\Lib_WeatherCM"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\Lib_Objects"\r
+# PROP Intermediate_Dir "Debug\Lib_WeatherCM"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\Objects\texload.c\r
+SOURCE=.\src\WeatherCM\FGCloud.h\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\Lib_Objects"\r
+# PROP Intermediate_Dir "Release\Lib_WeatherCM"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\Lib_Objects"\r
+# PROP Intermediate_Dir "Debug\Lib_WeatherCM"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
-# End Group\r
-# Begin Group "Lib_Scenery"\r
-\r
-# PROP Default_Filter ""\r
 # Begin Source File\r
 \r
-SOURCE=.\src\Scenery\hitlist.cxx\r
+SOURCE=.\src\WeatherCM\FGCloudItem.cpp\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\Lib_Scenery"\r
+# PROP Intermediate_Dir "Release\Lib_WeatherCM"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\Lib_Scenery"\r
+# PROP Intermediate_Dir "Debug\Lib_WeatherCM"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\Scenery\newcache.cxx\r
+SOURCE=.\src\WeatherCM\FGCloudItem.h\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\Lib_Scenery"\r
+# PROP Intermediate_Dir "Release\Lib_WeatherCM"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\Lib_Scenery"\r
+# PROP Intermediate_Dir "Debug\Lib_WeatherCM"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\Scenery\scenery.cxx\r
+SOURCE=.\src\WeatherCM\FGLocalWeatherDatabase.cpp\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\Lib_Scenery"\r
+# PROP Intermediate_Dir "Release\Lib_WeatherCM"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\Lib_Scenery"\r
+# PROP Intermediate_Dir "Debug\Lib_WeatherCM"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\Scenery\tileentry.cxx\r
+SOURCE=.\src\WeatherCM\FGLocalWeatherDatabase.h\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\Lib_Scenery"\r
+# PROP Intermediate_Dir "Release\Lib_WeatherCM"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\Lib_Scenery"\r
+# PROP Intermediate_Dir "Debug\Lib_WeatherCM"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\Scenery\tilemgr.cxx\r
+SOURCE=.\src\WeatherCM\FGPhysicalProperties.cpp\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\Lib_Scenery"\r
+# PROP Intermediate_Dir "Release\Lib_WeatherCM"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\Lib_Scenery"\r
+# PROP Intermediate_Dir "Debug\Lib_WeatherCM"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
-# End Group\r
-# Begin Group "Lib_Sound"\r
-\r
-# PROP Default_Filter ""\r
 # Begin Source File\r
 \r
-SOURCE=.\src\Sound\morse.cxx\r
+SOURCE=.\src\WeatherCM\FGPhysicalProperties.h\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\Lib_Sound"\r
+# PROP Intermediate_Dir "Release\Lib_WeatherCM"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\Lib_Sound"\r
+# PROP Intermediate_Dir "Debug\Lib_WeatherCM"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\Sound\soundmgr.cxx\r
+SOURCE=.\src\WeatherCM\FGPhysicalProperty.cpp\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\Lib_Sound"\r
+# PROP Intermediate_Dir "Release\Lib_WeatherCM"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\Lib_Sound"\r
+# PROP Intermediate_Dir "Debug\Lib_WeatherCM"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
-# End Group\r
-# Begin Group "Lib_Time"\r
-\r
-# PROP Default_Filter ""\r
 # Begin Source File\r
 \r
-SOURCE=.\src\Time\event.cxx\r
+SOURCE=.\src\WeatherCM\FGPhysicalProperty.h\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\Lib_Time"\r
+# PROP Intermediate_Dir "Release\Lib_WeatherCM"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\Lib_Time"\r
+# PROP Intermediate_Dir "Debug\Lib_WeatherCM"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\Time\fg_timer.cxx\r
+SOURCE=.\src\WeatherCM\FGSnowRain.h\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\Lib_Time"\r
+# PROP Intermediate_Dir "Release\Lib_WeatherCM"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\Lib_Time"\r
+# PROP Intermediate_Dir "Debug\Lib_WeatherCM"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\Time\light.cxx\r
+SOURCE=.\src\WeatherCM\FGTemperatureItem.cpp\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\Lib_Time"\r
+# PROP Intermediate_Dir "Release\Lib_WeatherCM"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\Lib_Time"\r
+# PROP Intermediate_Dir "Debug\Lib_WeatherCM"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\Time\moonpos.cxx\r
+SOURCE=.\src\WeatherCM\FGTemperatureItem.h\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\Lib_Time"\r
+# PROP Intermediate_Dir "Release\Lib_WeatherCM"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\Lib_Time"\r
+# PROP Intermediate_Dir "Debug\Lib_WeatherCM"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\Time\sunpos.cxx\r
+SOURCE=.\src\WeatherCM\FGThunderstorm.cpp\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\Lib_Time"\r
+# PROP Intermediate_Dir "Release\Lib_WeatherCM"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\Lib_Time"\r
+# PROP Intermediate_Dir "Debug\Lib_WeatherCM"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\Time\tmp.cxx\r
+SOURCE=.\src\WeatherCM\FGThunderstorm.h\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\Lib_Time"\r
+# PROP Intermediate_Dir "Release\Lib_WeatherCM"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\Lib_Time"\r
+# PROP Intermediate_Dir "Debug\Lib_WeatherCM"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
-# End Group\r
-# Begin Group "Lib_Weather"\r
-\r
-# PROP Default_Filter ""\r
 # Begin Source File\r
 \r
-SOURCE=.\src\Weather\weather.cxx\r
+SOURCE=.\src\WeatherCM\FGTurbulenceItem.cpp\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
-# PROP Intermediate_Dir "Release\Lib_Weather"\r
+# PROP Intermediate_Dir "Release\Lib_WeatherCM"\r
 \r
 !ELSEIF  "$(CFG)" == "FlightGear - Win32 Debug"\r
 \r
-# PROP Intermediate_Dir "Debug\Lib_Weather"\r
+# PROP Intermediate_Dir "Debug\Lib_WeatherCM"\r
 \r
 !ENDIF \r
 \r
 # End Source File\r
-# End Group\r
-# Begin Group "Lib_WeatherCM"\r
-\r
-# PROP Default_Filter ""\r
 # Begin Source File\r
 \r
-SOURCE=.\src\WeatherCM\FGAirPressureItem.cpp\r
+SOURCE=.\src\WeatherCM\FGTurbulenceItem.h\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
@@ -3038,7 +5948,7 @@ SOURCE=.\src\WeatherCM\FGAirPressureItem.cpp
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\WeatherCM\FGCloudItem.cpp\r
+SOURCE=.\src\WeatherCM\FGVaporPressureItem.cpp\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
@@ -3053,7 +5963,7 @@ SOURCE=.\src\WeatherCM\FGCloudItem.cpp
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\WeatherCM\FGLocalWeatherDatabase.cpp\r
+SOURCE=.\src\WeatherCM\FGVaporPressureItem.h\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
@@ -3068,7 +5978,7 @@ SOURCE=.\src\WeatherCM\FGLocalWeatherDatabase.cpp
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\WeatherCM\FGPhysicalProperties.cpp\r
+SOURCE=.\src\WeatherCM\FGWeatherDefs.h\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
@@ -3083,7 +5993,7 @@ SOURCE=.\src\WeatherCM\FGPhysicalProperties.cpp
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\WeatherCM\FGPhysicalProperty.cpp\r
+SOURCE=.\src\WeatherCM\FGWeatherFeature.h\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
@@ -3098,7 +6008,7 @@ SOURCE=.\src\WeatherCM\FGPhysicalProperty.cpp
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\WeatherCM\FGTemperatureItem.cpp\r
+SOURCE=.\src\WeatherCM\FGWeatherUtils.h\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
@@ -3113,7 +6023,7 @@ SOURCE=.\src\WeatherCM\FGTemperatureItem.cpp
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\WeatherCM\FGThunderstorm.cpp\r
+SOURCE=.\src\WeatherCM\FGWeatherParse.cpp\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
@@ -3128,7 +6038,7 @@ SOURCE=.\src\WeatherCM\FGThunderstorm.cpp
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\WeatherCM\FGTurbulenceItem.cpp\r
+SOURCE=.\src\WeatherCM\FGWeatherParse.h\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
@@ -3143,7 +6053,7 @@ SOURCE=.\src\WeatherCM\FGTurbulenceItem.cpp
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\WeatherCM\FGVaporPressureItem.cpp\r
+SOURCE=.\src\WeatherCM\FGWeatherVectorWrap.h\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
@@ -3158,7 +6068,7 @@ SOURCE=.\src\WeatherCM\FGVaporPressureItem.cpp
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\WeatherCM\FGWeatherParse.cpp\r
+SOURCE=.\src\WeatherCM\FGWindItem.cpp\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
@@ -3173,7 +6083,7 @@ SOURCE=.\src\WeatherCM\FGWeatherParse.cpp
 # End Source File\r
 # Begin Source File\r
 \r
-SOURCE=.\src\WeatherCM\FGWindItem.cpp\r
+SOURCE=.\src\WeatherCM\FGWindItem.h\r
 \r
 !IF  "$(CFG)" == "FlightGear - Win32 Release"\r
 \r
index 1ca1edcce1eb0c887b8ac615e80eebf55cbdf279..3a040597fd36e7c0d8533ae5f5557add0711570b 100644 (file)
@@ -58,7 +58,9 @@
 
 /******************************************************************************/
 
-FGJSBsim::FGJSBsim( double dt ) {
+FGJSBsim::FGJSBsim( double dt ) 
+  : FGInterface(dt)
+{
     bool result;
    
     fdmex=new FGFDMExec;
@@ -76,11 +78,24 @@ FGJSBsim::FGJSBsim( double dt ) {
     result = fdmex->LoadModel( aircraft_path.str(),
                               engine_path.str(),
                               fgGetString("/sim/aircraft") );
-    int Neng=fdmex->GetAircraft()->GetNumEngines();
+    int Neng=fdmex->GetPropulsion()->GetNumEngines();
+//     int Neng=fdmex->GetAircraft()->GetNumEngines();
     SG_LOG(SG_FLIGHT,SG_INFO, "Neng: " << Neng );
     for(int i=0;i<Neng;i++) {
        add_engine( FGEngInterface() );
     }  
+    
+    fgSetDouble("/fdm/trim/pitch-trim",
+               fdmex->GetFCS()->GetPitchTrimCmd());
+    fgSetDouble("/fdm/trim/throttle",
+               fdmex->GetFCS()->GetThrottleCmd(0)/100.0);
+    fgSetDouble("/fdm/trim/aileron",
+               fdmex->GetFCS()->GetDaCmd());
+    fgSetDouble("/fdm/trim/rudder",
+               fdmex->GetFCS()->GetDrCmd());
+
+    trimmed = fgGetValue("/fdm/trim/trimmed",true);
+    trimmed->setBoolValue(false);
 
 }
 
@@ -203,7 +218,9 @@ bool FGJSBsim::update( int multiloop ) {
     
 
     copy_to_JSBsim();
-    
+
+    trimmed->setBoolValue(false);
+
     if(needTrim && fgGetBool("/sim/startup/trim")) {
        //fgic->SetSeaLevelRadiusFtIC( get_Sea_level_radius() );
        //fgic->SetTerrainAltitudeFtIC( scenery.cur_elev * SG_METER_TO_FEET );
@@ -217,15 +234,24 @@ bool FGJSBsim::update( int multiloop ) {
        if(!fgtrim->DoTrim()) {
            fgtrim->Report();
            fgtrim->TrimStats();
-       }  
+       } else {
+           trimmed->setBoolValue(true);
+       }    
        fgtrim->ReportState();
        delete fgtrim;
   
-       
-  needTrim=false;
-    
-         
-       controls.set_elevator_trim(fdmex->GetFCS()->GetPitchTrimCmd());
+       needTrim=false;
+  
+       fgSetDouble("/fdm/trim/pitch-trim",
+               fdmex->GetFCS()->GetPitchTrimCmd());
+       fgSetDouble("/fdm/trim/throttle",
+               fdmex->GetFCS()->GetThrottleCmd(0)/100.0);
+       fgSetDouble("/fdm/trim/aileron",
+               fdmex->GetFCS()->GetDaCmd());
+       fgSetDouble("/fdm/trim/rudder",
+               fdmex->GetFCS()->GetDrCmd());
+  
+       controls.set_elevator_trim(fdmex->GetFCS()->GetPitchTrimCmd());
        controls.set_elevator(fdmex->GetFCS()->GetDeCmd());
        controls.set_throttle(FGControls::ALL_ENGINES,
                              fdmex->GetFCS()->GetThrottleCmd(0)/100.0);
index 89b66ff5f8115660d14e9a3d3a2e82e24bf4b854..b6f50b435e35bcb616401f5eb1f2a3f0e6817b3e 100644 (file)
@@ -201,10 +201,11 @@ private:
     bool needTrim;
 
     int runcount;
-    bool trimmed;
     float trim_elev;
     float trim_throttle;
     
+    SGValue *trimmed;
+    
     void snap_shot(void);
 };
 
index d1a5a2564792a420b0a73e28c4f8168cb3edce35..6889ca27560588d48eaab0a83978a0ec9a9705f8 100644 (file)
@@ -37,9 +37,11 @@ INCLUDES
 
 #include "FGAerodynamics.h"
 
-static const char *IdSrc = "$Header$";
+static const char *IdSrc = "$Id$";
 static const char *IdHdr = ID_AERODYNAMICS;
 
+extern short debug_lvl;
+
 /*%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 CLASS IMPLEMENTATION
 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%*/
@@ -47,9 +49,17 @@ CLASS IMPLEMENTATION
 
 FGAerodynamics::FGAerodynamics(FGFDMExec* fgex) : FGModel(fgex)
 {
+  if (debug_lvl & 2) cout << "Instantiated: FGAerodynamics" << endl;
+}
+
+//%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 
+FGAerodynamics::~FGAerodynamics()
+{
+  if (debug_lvl & 2) cout << "Destroyed:    FGAerodynamics" << endl;
 }
 
+//%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 
 bool FGAerodynamics:: Run(void) {
 
@@ -61,8 +71,17 @@ bool FGAerodynamics:: Run(void) {
   }
 }
 
+//%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+
 bool FGAerodynamics::LoadAerodynamics(FGConfigFile* AC_cfg)
 {
 //
 }
 
+//%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+
+void FGAerodynamics::Debug(void)
+{
+    //TODO: Add your source code here
+}
+
index cc29cb7e6abd5b0942e612141ad44a76db1eacfc..beb7d209f920ab24ef0ba4c4142dca272ed85499 100644 (file)
@@ -40,7 +40,7 @@ INCLUDES
 
 #ifdef FGFS
 #  include <simgear/compiler.h>
-#  ifdef SG_HAVE_STD_INCLUDES
+#  ifdef FG_HAVE_STD_INCLUDES
 #    include <vector>
 #  else
 #    include <vector.h>
@@ -56,7 +56,7 @@ INCLUDES
 DEFINITIONS
 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%*/
 
-#define ID_AERODYNAMICS "$Header$"
+#define ID_AERODYNAMICS "$Id$"
 
 /*%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 FORWARD DECLARATIONS
@@ -90,7 +90,7 @@ public:
       @param Executive a pointer to the parent executive object */
   FGAerodynamics(FGFDMExec*);
   /// Destructor
-  ~FGAerodynamics(void);
+  ~FGAerodynamics();
 
   /** Runs the Aerodynamics model; called by the Executive
       @return false if no error */
@@ -99,6 +99,9 @@ public:
   /** Loads the Aerodynamics model
       @return true if successful */
   bool LoadAerodynamics(FGConfigFile* AC_cfg);
+  
+private:
+  void Debug(void);
 };
 
 //%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
index 566d324ec706c5f41f8b7d219858ca2bff52b742..ed10a42db3e6a1649efaa303ed39380dbea4d56d 100644 (file)
@@ -109,7 +109,7 @@ INCLUDES
 #  ifndef __BORLANDC__
 #    include <simgear/compiler.h>
 #  endif
-#  ifdef SG_HAVE_STD_INCLUDES
+#  ifdef FG_HAVE_STD_INCLUDES
 #    include <cmath>
 #  else
 #    include <math.h>
@@ -137,9 +137,23 @@ DEFINITIONS
 GLOBAL DATA
 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%*/
 
-static const char *IdSrc = "$Header$";
+static const char *IdSrc = "$Id$";
 static const char *IdHdr = ID_AIRCRAFT;
 
+extern char highint[5];
+extern char halfint[5];
+extern char normint[6];
+extern char reset[5];
+extern char underon[5];
+extern char underoff[6];
+extern char fgblue[6];
+extern char fgcyan[6];
+extern char fgred[6];
+extern char fggreen[6];
+extern char fgdef[6];
+
+extern short debug_lvl;
+
 /*%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 CLASS IMPLEMENTATION
 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%*/
@@ -153,7 +167,7 @@ FGAircraft::FGAircraft(FGFDMExec* fdmex) : FGModel(fdmex),
     vXYZcg(3),
     vXYZep(3),
     vEuler(3)
-    
+
 {
   Name = "FGAircraft";
 
@@ -163,37 +177,30 @@ FGAircraft::FGAircraft(FGFDMExec* fdmex) : FGModel(fdmex),
   AxisIdx["ROLL"]  = 3;
   AxisIdx["PITCH"] = 4;
   AxisIdx["YAW"]   = 5;
-  
+
   Coeff = new CoeffArray[6];
 
   GearUp = false;
-  
+
   alphaclmin = alphaclmax = 0;
 
-  numTanks = numEngines = numSelectedFuelTanks = numSelectedOxiTanks = 0;
+  if (debug_lvl & 2) cout << "Instantiated: " << Name << endl;
 }
 
 
 //%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 
 
-FGAircraft::~FGAircraft(void) { 
+FGAircraft::~FGAircraft() {
   unsigned int i,j;
-
-  if (Engine != NULL) {
-    for (i=0; i<numEngines; i++)
-      delete Engine[i];
-  }    
-  if (Tank != NULL) {
-    for (i=0; i<numTanks; i++)
-      delete Tank[i];
-  }    
   for (i=0; i<6; i++) {
     for (j=0; j<Coeff[i].size(); j++) {
       delete Coeff[i][j];
     }
   }
   delete[] Coeff;
+  
+  if (debug_lvl & 2) cout << "Destroyed:    FGAircraft" << endl;
 }
 
 //%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
@@ -209,7 +216,7 @@ bool FGAircraft::LoadAircraft(string aircraft_path, string engine_path, string f
 
 # ifndef macintosh
   aircraftCfgFileName = AircraftPath + "/" + fname + "/" + fname + ".xml";
-# else  
+# else
   aircraftCfgFileName = AircraftPath + ";" + fname + ";" + fname + ".xml";
 # endif
 
@@ -221,21 +228,22 @@ bool FGAircraft::LoadAircraft(string aircraft_path, string engine_path, string f
   while ((AC_cfg.GetNextConfigLine() != "EOF") &&
          (token = AC_cfg.GetValue()) != "/FDM_CONFIG") {
     if (token == "METRICS") {
-      cout << "  Reading Metrics" << endl;
+      cout << fgcyan << "\n  Reading Metrics" << fgdef << endl;
       ReadMetrics(&AC_cfg);
     } else if (token == "AERODYNAMICS") {
-      cout << "  Reading Aerodynamics" << endl;
+      cout << fgcyan << "\n  Reading Aerodynamics" << fgdef << endl;
       ReadAerodynamics(&AC_cfg);
     } else if (token == "UNDERCARRIAGE") {
-      cout << "  Reading Landing Gear" << endl;
+      cout << fgcyan << "\n  Reading Landing Gear" << fgdef << endl;
       ReadUndercarriage(&AC_cfg);
     } else if (token == "PROPULSION") {
-      cout << "  Reading Propulsion" << endl;
+      cout << fgcyan << "\n  Reading Propulsion" << fgdef << endl;
       ReadPropulsion(&AC_cfg);
     } else if (token == "FLIGHT_CONTROL") {
-      cout << "  Reading Flight Control" << endl;
+      cout << fgcyan << "\n  Reading Flight Control" << fgdef << endl;
       ReadFlightControls(&AC_cfg);
     } else if (token == "OUTPUT") {
+      cout << fgcyan << "\n  Reading Output directives" << fgdef << endl;
       ReadOutput(&AC_cfg);
     }
   }
@@ -275,9 +283,9 @@ void FGAircraft::MassChange() {
   static FGColumnVector vXYZtank(3);
   float Tw;
   float IXXt, IYYt, IZZt, IXZt;
-  unsigned int t;
-  unsigned int axis_ctr;
-
+//  unsigned int t;
+//  unsigned int axis_ctr;
+/*
   for (axis_ctr=1; axis_ctr<=3; axis_ctr++) vXYZtank(axis_ctr) = 0.0;
 
   // UPDATE TANK CONTENTS
@@ -327,34 +335,34 @@ void FGAircraft::MassChange() {
     if ((Fshortage <= 0.0) || (Oshortage <= 0.0)) Engine[e]->SetStarved();
     else Engine[e]->SetStarved(false);
   }
-
+*/
   Weight = EmptyWeight;
-  for (t=0; t<numTanks; t++)
-    Weight += Tank[t]->GetContents();
+//  for (t=0; t<numTanks; t++)
+//    Weight += Tank[t]->GetContents();
 
   Mass = Weight / GRAVITY;
   // Calculate new CG here.
 
   Tw = 0;
-  for (t=0; t<numTanks; t++) {
-    vXYZtank(eX) += Tank[t]->GetX()*Tank[t]->GetContents();
-    vXYZtank(eY) += Tank[t]->GetY()*Tank[t]->GetContents();
-    vXYZtank(eZ) += Tank[t]->GetZ()*Tank[t]->GetContents();
-
-    Tw += Tank[t]->GetContents();
-  }
+//  for (t=0; t<numTanks; t++) {
+//    vXYZtank(eX) += Tank[t]->GetX()*Tank[t]->GetContents();
+//    vXYZtank(eY) += Tank[t]->GetY()*Tank[t]->GetContents();
+//    vXYZtank(eZ) += Tank[t]->GetZ()*Tank[t]->GetContents();
+//
+//    Tw += Tank[t]->GetContents();
+//  }
 
   vXYZcg = (vXYZtank + EmptyWeight*vbaseXYZcg) / (Tw + EmptyWeight);
 
   // Calculate new moments of inertia here
 
   IXXt = IYYt = IZZt = IXZt = 0.0;
-  for (t=0; t<numTanks; t++) {
-    IXXt += ((Tank[t]->GetX()-vXYZcg(eX))/12.0)*((Tank[t]->GetX() - vXYZcg(eX))/12.0)*Tank[t]->GetContents()/GRAVITY;
-    IYYt += ((Tank[t]->GetY()-vXYZcg(eY))/12.0)*((Tank[t]->GetY() - vXYZcg(eY))/12.0)*Tank[t]->GetContents()/GRAVITY;
-    IZZt += ((Tank[t]->GetZ()-vXYZcg(eZ))/12.0)*((Tank[t]->GetZ() - vXYZcg(eZ))/12.0)*Tank[t]->GetContents()/GRAVITY;
-    IXZt += ((Tank[t]->GetX()-vXYZcg(eX))/12.0)*((Tank[t]->GetZ() - vXYZcg(eZ))/12.0)*Tank[t]->GetContents()/GRAVITY;
-  }
+//  for (t=0; t<numTanks; t++) {
+//    IXXt += ((Tank[t]->GetX()-vXYZcg(eX))/12.0)*((Tank[t]->GetX() - vXYZcg(eX))/12.0)*Tank[t]->GetContents()/GRAVITY;
+//    IYYt += ((Tank[t]->GetY()-vXYZcg(eY))/12.0)*((Tank[t]->GetY() - vXYZcg(eY))/12.0)*Tank[t]->GetContents()/GRAVITY;
+//    IZZt += ((Tank[t]->GetZ()-vXYZcg(eZ))/12.0)*((Tank[t]->GetZ() - vXYZcg(eZ))/12.0)*Tank[t]->GetContents()/GRAVITY;
+//    IXZt += ((Tank[t]->GetX()-vXYZcg(eX))/12.0)*((Tank[t]->GetZ() - vXYZcg(eZ))/12.0)*Tank[t]->GetContents()/GRAVITY;
+//  }
 
   Ixx = baseIxx + IXXt;
   Iyy = baseIyy + IYYt;
@@ -425,13 +433,8 @@ void FGAircraft::FMMass(void) {
 //%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 
 void FGAircraft::FMProp(void) {
-  for (unsigned int i=0;i<numEngines;i++) {
-
-    // Changes required here for new engine placement parameters (i.e. location and direction)
-
-    vForces(eX) += Engine[i]->CalcThrust();
-  }
-  
+    vForces += Propulsion->GetForces();
+    vMoments += Propulsion->GetMoments();
 }
 
 //%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
@@ -499,43 +502,17 @@ void FGAircraft::ReadMetrics(FGConfigFile* AC_cfg) {
 //%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 
 void FGAircraft::ReadPropulsion(FGConfigFile* AC_cfg) {
-  string token;
-  string engine_name;
-  string parameter;
-
-  AC_cfg->GetNextConfigLine();
-
-  while ((token = AC_cfg->GetValue()) != "/PROPULSION") {
-    *AC_cfg >> parameter;
-
-    if (parameter == "AC_ENGINE") {
-
-      *AC_cfg >> engine_name;
-      Engine[numEngines] = new FGEngine(FDMExec, EnginePath, engine_name, numEngines);
-      numEngines++;
-
-    } else if (parameter == "AC_TANK") {
-
-      Tank[numTanks] = new FGTank(AC_cfg);
-      switch(Tank[numTanks]->GetType()) {
-      case FGTank::ttFUEL:
-        numSelectedFuelTanks++;
-        break;
-      case FGTank::ttOXIDIZER:
-        numSelectedOxiTanks++;
-        break;
-      }
-      numTanks++;
-    }
+  if (!Propulsion->LoadPropulsion(AC_cfg)) {
+    cerr << "Propulsion not successfully loaded" << endl;
   }
 }
 
 //%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 
 void FGAircraft::ReadFlightControls(FGConfigFile* AC_cfg) {
-  string token;
-
-  FCS->LoadFCS(AC_cfg);
+  if (!FCS->LoadFCS(AC_cfg)) {
+    cerr << "Flight Controls not successfully loaded" << endl;
+  }
 }
 
 //%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
@@ -650,16 +627,18 @@ void FGAircraft::ReadPrologue(FGConfigFile* AC_cfg) {
   string token = AC_cfg->GetValue();
   string scratch;
   AircraftName = AC_cfg->GetValue("NAME");
-  cout << "Reading Aircraft Configuration File: " << AircraftName << endl;
-  scratch=AC_cfg->GetValue("VERSION").c_str();
+  cout << underon << "Reading Aircraft Configuration File" << underoff << ": "
+                       << highint << AircraftName << normint << endl;
+  scratch = AC_cfg->GetValue("VERSION").c_str();
 
   CFGVersion = AC_cfg->GetValue("VERSION");
-  cout << "                            Version: " << CFGVersion << endl;
+  cout << "                            Version: " << highint << CFGVersion
+                                                             << normint << endl;
   if (CFGVersion != NEEDED_CFG_VERSION) {
-    cout << endl << "YOU HAVE AN INCOMPATIBLE CFG FILE FOR THIS AIRCRAFT."
+    cout << endl << fgred << "YOU HAVE AN INCOMPATIBLE CFG FILE FOR THIS AIRCRAFT."
     " RESULTS WILL BE UNPREDICTABLE !!" << endl;
     cout << "Current version needed is: " << NEEDED_CFG_VERSION << endl;
-    cout << "         You have version: " << CFGVersion << endl << endl;
+    cout << "         You have version: " << CFGVersion << endl << fgdef << endl;
     //exit(-1);
   }
 
@@ -759,3 +738,10 @@ string FGAircraft::GetGroundReactionValues(void) {
   return GroundReactionValues;
 }
 
+//%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+
+void FGAircraft::Debug(void)
+{
+    //TODO: Add your source code here
+}
+
index c1b22e59075f419e52070e63c3092f9cc84d64c0..db1d62d7c62eae3598e503856becc1a65e681c2d 100644 (file)
@@ -19,7 +19,7 @@
  You should have received a copy of the GNU General Public License along with
  this program; if not, write to the Free Software Foundation, Inc., 59 Temple
  Place - Suite 330, Boston, MA  02111-1307, USA.
+
  Further information about the GNU General Public License can also be found on
  the world wide web at http://www.gnu.org.
  
@@ -40,7 +40,7 @@ INCLUDES
 
 #ifdef FGFS
 #  include <simgear/compiler.h>
-#  ifdef SG_HAVE_STD_INCLUDES
+#  ifdef FG_HAVE_STD_INCLUDES
 #    include <vector>
 #    include <iterator>
 #    include <map>
@@ -57,8 +57,7 @@ INCLUDES
 
 #include "FGModel.h"
 #include "FGCoefficient.h"
-#include "FGEngine.h"
-#include "FGTank.h"
+#include "FGPropulsion.h"
 #include "FGLGear.h"
 #include "FGConfigFile.h"
 #include "FGMatrix.h"
@@ -67,7 +66,7 @@ INCLUDES
 DEFINITIONS
 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%*/
 
-#define ID_AIRCRAFT "$Header$"
+#define ID_AIRCRAFT "$Id$"
 
 /*%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 FORWARD DECLARATIONS
@@ -86,7 +85,11 @@ CLASS DOCUMENTATION
     the Engines, Tanks, Propellers, Nozzles, Aerodynamic and Mass properties,
     landing gear, etc. These constituent parts may actually run as separate
     JSBSim models themselves, but the responsibility for initializing them and
-    for retrieving their force and moment contributions falls to FGAircraft.
+    for retrieving their force and moment contributions falls to FGAircraft.<br>
+    When an aircraft model is loaded the config file is parsed and for each of the
+    sections of the config file (propulsion, flight control, etc.) the
+    corresponding "ReadXXX()" method is called. From within this method the 
+    "Load()" method of that system is called (e.g. LoadFCS).
     @author Jon S. Berndt
     @version $Id$
     @see
@@ -119,7 +122,7 @@ public:
   FGAircraft(FGFDMExec *Executive);
   
   /// Destructor
-  ~FGAircraft(void);
+  ~FGAircraft();
 
   /** Runs the Aircraft model; called by the Executive
       @see JSBSim.cpp documentation
@@ -154,14 +157,6 @@ public:
   inline float GetWingSpan(void) { return WingSpan; }
   /// Gets the average wing chord
   inline float Getcbar(void) { return cbar; }
-  /** Gets an engine instance.
-      @param engine index of the engine instance
-      @return a pointer to the FGEngine instance of the requested engine */
-  inline FGEngine* GetEngine(int engine) { return Engine[engine]; }
-  /** Gets a tank instance.
-      @param tank index of the tank instance
-      @return a pointer to the FGTank instance of the requested tank */
-  inline FGTank* GetTank(int tank) { return Tank[tank]; }
   inline float GetWeight(void) { return Weight; }
   inline float GetMass(void) { return Mass; }
   inline FGColumnVector GetMoments(void) { return vMoments; }
@@ -171,7 +166,6 @@ public:
   inline float GetIyy(void) { return Iyy; }
   inline float GetIzz(void) { return Izz; }
   inline float GetIxz(void) { return Ixz; }
-  inline unsigned int GetNumEngines(void) { return numEngines; }
   inline FGColumnVector GetXYZcg(void) { return vXYZcg; }
   inline FGColumnVector GetXYZrp(void) { return vXYZrp; }
   inline FGColumnVector GetXYZep(void) { return vXYZep; }
@@ -230,18 +224,11 @@ private:
   string CFGVersion;
   string AircraftName;
 
-  unsigned int numTanks;
-  unsigned int numEngines;
-  unsigned int numSelectedOxiTanks;
-  unsigned int numSelectedFuelTanks;
-  FGTank* Tank[MAX_TANKS];           // need to make a vector
-  FGEngine *Engine[MAX_ENGINES];     // need to make a vector
-
   typedef map<string,int> AxisIndex;
   AxisIndex AxisIdx;
 
   typedef vector<FGCoefficient*> CoeffArray;
-  
+
   CoeffArray* Coeff;
 
   void DisplayCoeffFactors(vector <eParam> multipliers);
@@ -260,7 +247,9 @@ private:
   void ReadUndercarriage(FGConfigFile*);
   void ReadPrologue(FGConfigFile*);
   void ReadOutput(FGConfigFile*);
+  void Debug(void);
 };
 
 //%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 #endif
+
index 170f5e2328a078ba0c80167849ea58d71fa289d3..2862dfc6d513ff588364cfe9cd8d5c2559db48f3 100644 (file)
@@ -59,159 +59,160 @@ INCLUDES
 #include "FGDefs.h"
 #include "FGMatrix.h"
 
-static const char *IdSrc = "$Header$";
+static const char *IdSrc = "$Id$";
 static const char *IdHdr = ID_ATMOSPHERE;
 
+extern short debug_lvl;
+
 /*%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 CLASS IMPLEMENTATION
 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%*/
 
 
 FGAtmosphere::FGAtmosphere(FGFDMExec* fdmex) : FGModel(fdmex),
-                                                    vWindNED(3),
-                                                    vWindUVW(3)
+                                                    vWindNED(3)
 {
-    Name = "FGAtmosphere";
-    h = 0;
-    Calculate(h);
-    SLtemperature = temperature;
-    SLpressure    = pressure;
-    SLdensity     = density;
-    SLsoundspeed  = sqrt(SHRATIO*Reng*temperature);
-    useExternal=false;
-    vWindUVW(1)=0;vWindUVW(2)=0;vWindUVW(3)=0;
-    vWindNED(1)=0;vWindNED(2)=0;vWindNED(3)=0;
+  Name = "FGAtmosphere";
+  h = 0;
+  Calculate(h);
+  SLtemperature = temperature;
+  SLpressure    = pressure;
+  SLdensity     = density;
+  SLsoundspeed  = sqrt(SHRATIO*Reng*temperature);
+  useExternal=false;
+  vWindNED(1)=0;vWindNED(2)=0;vWindNED(3)=0;
+
+  if (debug_lvl & 2) cout << "Instantiated: " << Name << endl;
 }
 
+//%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 
 FGAtmosphere::~FGAtmosphere()
 {
+  if (debug_lvl & 2) cout << "Destroyed:    FGAtmosphere" << endl;
 }
 
+//%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 
 bool FGAtmosphere::Run(void)
 {
-    //cout << "In FGAtmosphere::Run(void)" << endl;
-    if (!FGModel::Run()) {                 // if false then execute this Run()
-        //do temp, pressure, and density first
-        if (!useExternal) {
-            //cout << "Atmosphere: Using internal model, altitude= ";
-            h = Position->Geth();
-
-            Calculate(h);
-        } else {
-            density = exDensity;
-            pressure = exPressure;
-            temperature = exTemperature;
-            //switch sign of wind components so that they are
-            //in aircraft reference frame.  The classic example is
-            //takeoff or landing where you always want to fly
-            //into the wind.  Suppose that an aircraft is
-            //taking off into the wind on the runway heading
-            //of pure north.  Into the wind means the wind is
-            //flowing to the south (or negative) direction,
-            //and we know that headwinds increase the relative
-            //velocity, so to make a positive delta U from the
-            //southerly wind the sign must be switched.
-            vWindNED *= -1;
-            vWindUVW  = State->GetTl2b()*vWindNED;
-        }
-        soundspeed = sqrt(SHRATIO*Reng*temperature);
-        //cout << "Atmosphere: soundspeed: " << soundspeed << endl;
-        State->Seta(soundspeed);
-
-
-    } else {                               // skip Run() execution this time
+  //cout << "In FGAtmosphere::Run(void)" << endl;
+  if (!FGModel::Run()) {                 // if false then execute this Run()
+    //do temp, pressure, and density first
+    if (!useExternal) {
+      //cout << "Atmosphere: Using internal model, altitude= ";
+      h = Position->Geth();
+
+      Calculate(h);
+    } else {
+      density = exDensity;
+      pressure = exPressure;
+      temperature = exTemperature;
     }
-    return false;
-}
 
+    psiw = atan2( vWindNED(2), vWindNED(1) );
 
-void FGAtmosphere::Calculate(float altitude)
-{
-    //see reference [1]
-
-    float slope,reftemp,refpress,refdens;
-    int i=0;
-    float htab[]={0,36089,82020,154198,173882,259183,295272,344484}; //ft.
-    // cout << "Atmosphere:  h=" << altitude << " rho= " << density << endl;
-    if (altitude <= htab[0]) {
-        altitude=0;
-    } else if (altitude >= htab[7]){
-        i = 7;
-        altitude = htab[7];
-    } else {
-        while (htab[i+1] < altitude) {
-            i++;
-        }
-    }
+    if (psiw < 0) psiw += 2*M_PI;
 
-    switch(i) {
-    case 0:     // sea level
-        slope     = -0.0035662; // R/ft.
-        reftemp   = 518.688;    // R
-        refpress  = 2116.17;    // psf
-        refdens   = 0.0023765;  // slugs/cubic ft.
-        break;
-    case 1:     // 36089 ft.
-        slope     = 0;
-        reftemp   = 389.988;
-        refpress  = 474.1;
-        refdens   = 0.0007078;
-        break;
-    case 2:     // 82020 ft.
-        slope     = 0.00164594;
-        reftemp   = 389.988;
-        refpress  = 52.7838;
-        refdens   = 7.8849E-5;
-        break;
-    case 3:     // 154198 ft.
-        slope     = 0;
-        reftemp   = 508.788;
-        refpress  = 2.62274;
-        refdens   = 3.01379E-6;
-        break;
-    case 4:     // 173882 ft.
-        slope     = -0.00246891;
-        reftemp   = 508.788;
-        refpress  = 1.28428;
-        refdens   = 1.47035e-06;
-        break;
-    case 5:     // 259183 ft.
-        slope     = 0;
-        reftemp   = 298.188;
-        refpress  = 0.0222008;
-        refdens   = 4.33396e-08;
-        break;
-    case 6:     // 295272 ft.
-        slope     = 0.00219459;
-        reftemp   = 298.188;
-        refpress  = 0.00215742;
-        refdens   = 4.21368e-09;
-        break;
-    case 7:     // 344484 ft.
-        slope     = 0;
-        reftemp   = 406.188;
-        refpress  = 0.000153755;
-        refdens   = 2.20384e-10;
-        break;
-    }
+    soundspeed = sqrt(SHRATIO*Reng*temperature);
+    //cout << "Atmosphere: soundspeed: " << soundspeed << endl;
+    State->Seta(soundspeed);
 
+  } else {                               // skip Run() execution this time
+  }
+  return false;
+}
 
-    if (slope == 0) {
-        temperature = reftemp;
-        pressure = refpress*exp(-GRAVITY/(reftemp*Reng)*(altitude-htab[i]));
-        density = refdens*exp(-GRAVITY/(reftemp*Reng)*(altitude-htab[i]));
-    } else {
-        temperature = reftemp+slope*(altitude-htab[i]);
-        pressure = refpress*pow(temperature/reftemp,-GRAVITY/(slope*Reng));
-        density = refdens*pow(temperature/reftemp,-(GRAVITY/(slope*Reng)+1));
-    }
+//%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 
-    //cout << "Atmosphere:  h=" << altitude << " rho= " << density << endl;
+void FGAtmosphere::Calculate(float altitude)
+{
+  //see reference [1]
+
+  float slope,reftemp,refpress,refdens;
+  int i=0;
+  float htab[]={0,36089,82020,154198,173882,259183,295272,344484}; //ft.
+  // cout << "Atmosphere:  h=" << altitude << " rho= " << density << endl;
+  if (altitude <= htab[0]) {
+    altitude=0;
+  } else if (altitude >= htab[7]){
+    i = 7;
+    altitude = htab[7];
+  } else {
+    while (htab[i+1] < altitude) {
+      i++;
+    }
+  }
+
+  switch(i) {
+  case 0:     // sea level
+    slope     = -0.0035662; // R/ft.
+    reftemp   = 518.688;    // R
+    refpress  = 2116.17;    // psf
+    refdens   = 0.0023765;  // slugs/cubic ft.
+    break;
+  case 1:     // 36089 ft.
+    slope     = 0;
+    reftemp   = 389.988;
+    refpress  = 474.1;
+    refdens   = 0.0007078;
+    break;
+  case 2:     // 82020 ft.
+    slope     = 0.00164594;
+    reftemp   = 389.988;
+    refpress  = 52.7838;
+    refdens   = 7.8849E-5;
+    break;
+  case 3:     // 154198 ft.
+    slope     = 0;
+    reftemp   = 508.788;
+    refpress  = 2.62274;
+    refdens   = 3.01379E-6;
+    break;
+  case 4:     // 173882 ft.
+    slope     = -0.00246891;
+    reftemp   = 508.788;
+    refpress  = 1.28428;
+    refdens   = 1.47035e-06;
+    break;
+  case 5:     // 259183 ft.
+    slope     = 0;
+    reftemp   = 298.188;
+    refpress  = 0.0222008;
+    refdens   = 4.33396e-08;
+    break;
+  case 6:     // 295272 ft.
+    slope     = 0.00219459;
+    reftemp   = 298.188;
+    refpress  = 0.00215742;
+    refdens   = 4.21368e-09;
+    break;
+  case 7:     // 344484 ft.
+    slope     = 0;
+    reftemp   = 406.188;
+    refpress  = 0.000153755;
+    refdens   = 2.20384e-10;
+    break;
+  }
+
+  if (slope == 0) {
+    temperature = reftemp;
+    pressure = refpress*exp(-GRAVITY/(reftemp*Reng)*(altitude-htab[i]));
+    density = refdens*exp(-GRAVITY/(reftemp*Reng)*(altitude-htab[i]));
+  } else {
+    temperature = reftemp+slope*(altitude-htab[i]);
+    pressure = refpress*pow(temperature/reftemp,-GRAVITY/(slope*Reng));
+    density = refdens*pow(temperature/reftemp,-(GRAVITY/(slope*Reng)+1));
+  }
+
+  //cout << "Atmosphere:  h=" << altitude << " rho= " << density << endl;
 
 }
 
+//%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 
-
+void FGAtmosphere::Debug(void)
+{
+    //TODO: Add your source code here
+}
 
index 964c0a5ddf27b4b52fe09300dbb995b3e15f2847..1a1bd1aa23362514eba9f00788b8514615fc2e39 100644 (file)
@@ -45,13 +45,13 @@ INCLUDES
 #include "FGModel.h"
 #include "FGMatrix.h"
 
-#define ID_ATMOSPHERE "$Header$"
+#define ID_ATMOSPHERE "$Id$"
 
 /*******************************************************************************
 COMMENTS, REFERENCES,  and NOTES
 ********************************************************************************
  
-[1]    Anderson, John D. "Introduction to Flight, Third Edition", McGraw-Hill,
+[1]   Anderson, John D. "Introduction to Flight, Third Edition", McGraw-Hill,
       1989, ISBN 0-07-001641-0
  
 *******************************************************************************
@@ -62,7 +62,7 @@ class FGAtmosphere : public FGModel {
 public:
 
   FGAtmosphere(FGFDMExec*);
-  ~FGAtmosphere(void);
+  ~FGAtmosphere();
   bool Run(void);
 
   inline float GetTemperature(void) {return temperature;}
@@ -90,12 +90,10 @@ public:
 
   inline void SetWindNED(float wN, float wE, float wD) { vWindNED(1)=wN; vWindNED(2)=wE; vWindNED(3)=wD;}
 
-  inline float GetWindN(void) { return vWindNED(1); }
-  inline float GetWindE(void) { return vWindNED(2); }
-  inline float GetWindD(void) { return vWindNED(3); }
-
-  inline FGColumnVector GetWindUVW(void) { return vWindUVW; }
-
+  inline FGColumnVector GetWindNED(void) { return vWindNED; }
+  
+  inline float GetWindPsi(void) { return psiw; }
+  
 protected:
 
 private:
@@ -106,13 +104,14 @@ private:
   float temperature,density,pressure,soundspeed;
   bool useExternal;
   float exTemperature,exDensity,exPressure;
-  FGColumnVector vWindNED,vWindUVW;
+  
+  FGColumnVector vWindNED;
+  float psiw;
 
   void Calculate(float altitude);
-
+  void Debug(void);
 };
 
-
-
 /******************************************************************************/
 #endif
+
index 3cd05ff0e97a463db11f94bf1ab2a8e57c401fe9..0fdc0573245a1f95c883a3d8ae012460c84dfb1b 100644 (file)
  ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
  FOR A PARTICULAR PURPOSE.  See the GNU General Public License for more
  details.
+
  You should have received a copy of the GNU General Public License along with
  this program; if not, write to the Free Software Foundation, Inc., 59 Temple
  Place - Suite 330, Boston, MA  02111-1307, USA.
+
  Further information about the GNU General Public License can also be found on
  the world wide web at http://www.gnu.org.
+
 FUNCTIONAL DESCRIPTION
 --------------------------------------------------------------------------------
 This class calculates various auxiliary parameters.
+
 REFERENCES
   Anderson, John D. "Introduction to Flight", 3rd Edition, McGraw-Hill, 1989
                     pgs. 112-126
 HISTORY
 --------------------------------------------------------------------------------
 01/26/99   JSB   Created
+
 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 INCLUDES
 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%*/
@@ -52,24 +52,33 @@ INCLUDES
 #include "FGOutput.h"
 #include "FGMatrix.h"
 
-static const char *IdSrc = "$Header$";
+static const char *IdSrc = "$Id$";
 static const char *IdHdr = ID_AUXILIARY;
 
+extern short debug_lvl;
+
 /*%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 CLASS IMPLEMENTATION
 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%*/
 
+
 FGAuxiliary::FGAuxiliary(FGFDMExec* fdmex) : FGModel(fdmex) {
   Name = "FGAuxiliary";
   vcas = veas = mach = qbar = pt = 0;
   psl = rhosl = 1;
   earthPosAngle = 0.0;
+  
+  if (debug_lvl & 2) cout << "Instantiated: " << Name << endl;
 }
 
+//%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 
-FGAuxiliary::~FGAuxiliary() {}
-
+FGAuxiliary::~FGAuxiliary()
+{
+  if (debug_lvl & 2) cout << "Destroyed:    FGAuxiliary" << endl;
+}
 
+//%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 
 bool FGAuxiliary::Run() {
   float A,B,D;
@@ -95,20 +104,43 @@ bool FGAuxiliary::Run() {
     A = pow(((pt-p)/psl+1),0.28571);
     vcas = sqrt(7*psl/rhosl*(A-1));
     veas = sqrt(2*qbar/rhosl);
-    
+
     vPilotAccel = Translation->GetUVWdot() + Aircraft->GetXYZep() * Rotation->GetPQRdot();
-    
-    
-    
+
     earthPosAngle += State->Getdt()*OMEGA_EARTH;
 
   } else {
   }
 
-
   return false;
 }
 
+//%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+
+float FGAuxiliary::GetHeadWind(void) {
+
+  float psiw,vw,psi;
+
+  psiw = Atmosphere->GetWindPsi();
+  psi = Rotation->Getpsi();
+  vw = Atmosphere->GetWindNED().Magnitude();
+  return -vw*cos(psiw - psi);
+}
+
+//%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+
+float FGAuxiliary::GetCrossWind(void) {
+
+  float psiw,vw,psi;
+
+  psiw = Atmosphere->GetWindPsi();
+  psi = Rotation->Getpsi();
+  vw = Atmosphere->GetWindNED().Magnitude();
+  return  vw*sin(psiw - psi);
+}
+
+//%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+
 void FGAuxiliary::GetState(void) {
   qbar = Translation->Getqbar();
   mach = Translation->GetMach();
@@ -118,3 +150,10 @@ void FGAuxiliary::GetState(void) {
 
 }
 
+//%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+
+void FGAuxiliary::Debug(void)
+{
+    //TODO: Add your source code here
+}
+
index 6d676ad58c7a6d632ab9aa5f57a4bc7311b572c8..b386896dc29b1f98b5fb91674de556c778ada65f 100644 (file)
@@ -46,7 +46,7 @@ INCLUDES
 DEFINITIONS
 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%*/
 
-#define ID_AUXILIARY "$Header"
+#define ID_AUXILIARY "$Id$"
 
 /*%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 FORWARD DECLARATIONS
@@ -76,7 +76,7 @@ public:
       @param Executive a pointer to the parent executive object */
   FGAuxiliary(FGFDMExec*);
   /// Destructor
-  ~FGAuxiliary(void);
+  ~FGAuxiliary();
 
   /** Runs the Auxiliary routines; called by the Executive
       @return false if no error */
@@ -93,6 +93,9 @@ public:
   
   inline float GetEarthPositionAngle(void) { return earthPosAngle; }
   
+  float GetHeadWind(void);
+  float GetCrossWind(void);
+  
  
 protected:
 
@@ -112,9 +115,12 @@ private:
   FGColumnVector vPilotAccel;
   
   float earthPosAngle;
+  
 
   void GetState(void);
+  void Debug(void);
 };
 
 //%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 #endif
+
index d29812e62587a43f56033e1680d98e04986e4282..f3c7bd1beb9189c1835b4ae1b02a13c8fe545572 100644 (file)
@@ -50,26 +50,35 @@ INCLUDES
 
 #include <iomanip.h>
 
-static const char *IdSrc = "$Header$";
+static const char *IdSrc = "$Id$";
 static const char *IdHdr = "ID_COEFFICIENT";
 
+extern char highint[5];
+extern char halfint[5];
+extern char normint[6];
+extern char reset[5];
+extern char underon[5];
+extern char underoff[6];
+extern char fgblue[6];
+extern char fgcyan[6];
+extern char fgred[6];
+extern char fggreen[6];
+extern char fgdef[6];
+
+extern short debug_lvl;
+
 /*%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 CLASS IMPLEMENTATION
 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%*/
 
 FGCoefficient::FGCoefficient(FGFDMExec* fdex, FGConfigFile* AC_cfg)
 {
-  int r, c, start, end, n;
-  float ftrashcan;
+  int start, end, n;
   string multparms;
-  char nullstring[13] = "            ";
-  
-  bias =0.0;
-  gain = 1.0;
-  
-  FDMExec     = fdex;
-  State       = FDMExec->GetState();
-  Table = 0;
+
+  FDMExec = fdex;
+  State   = FDMExec->GetState();
+  Table   = 0;
 
   if (AC_cfg) {
     name = AC_cfg->GetValue("NAME");
@@ -78,22 +87,7 @@ FGCoefficient::FGCoefficient(FGFDMExec* fdex, FGConfigFile* AC_cfg)
     AC_cfg->GetNextConfigLine();
     *AC_cfg >> description;
 
-    char bolden[5];
-    char unbolden[5];
-
-    bolden[0] = 27;
-    bolden[1] = '[';
-    bolden[2] = '1';
-    bolden[3] = 'm';
-    bolden[4] = '\0';
-
-    unbolden[0] = 27;
-    unbolden[1] = '[';
-    unbolden[2] = '0';
-    unbolden[3] = 'm';
-    unbolden[4] = '\0';
-
-    cout << "   " << bolden << name << unbolden << endl;
+    cout << "\n   " << highint << underon << name << underoff << normint << endl;
     cout << "   " << description << endl;
     cout << "   " << method << endl;
 
@@ -109,6 +103,9 @@ FGCoefficient::FGCoefficient(FGFDMExec* fdex, FGConfigFile* AC_cfg)
       if (type == TABLE) {
         *AC_cfg >> columns;
         cout << "Cols: " << columns;
+        Table = new FGTable(rows, columns);
+      } else {
+        Table = new FGTable(rows);
       }
 
       cout << endl;
@@ -151,136 +148,41 @@ FGCoefficient::FGCoefficient(FGFDMExec* fdex, FGConfigFile* AC_cfg)
       cout << "      Value = " << StaticValue << endl;
       break;
     case VECTOR:
-      Allocate(rows,2);
-
-      for (r=1;r<=rows;r++) {
-        *AC_cfg >> Table[r][0];
-        *AC_cfg >> Table[r][1];
-      }
-
-      for (r=1;r<=rows;r++) {
-        cout << "      ";
-        for (c=0;c<columns;c++) {
-          cout << Table[r][c] << "     ";
-        }
-        cout << endl;
-      }
-
-      break;
     case TABLE:
-      Allocate(rows, columns);
-
-      Table[0][0] = 0.0;
-
-      // Read the table in -- it should be in matrix format with the row
-      // independents as the first column and the column independents in
-      // the first row.  The implication of this layout is that there should
-      // be no value in the upper left corner of the matrix e.g:
-      //      0  10  20 30 ...
-      // -5   1  2   3  4  ...
-      //  ...
-
-      for (r=0; r<=rows; r++) {
-        for (c=0; c <= columns; c++) {
-          if ( !((r == 0) && (c == 0)) ) {
-            *AC_cfg >> Table[r][c];
-          }
-        }
-      }   
-      
-      /* for (c=1;c<=columns;c++) {
-        *AC_cfg >> Table[0][c];
-        for (r=1;r<=rows;r++) {
-          if ( c==1 ) *AC_cfg >> Table[r][0];
-          else *AC_cfg >> ftrashcan;
-          *AC_cfg >> Table[r][c];
-        }
-      } */
-      
-      for (r=0;r<=rows;r++) {
-        cout << "      ";
-        for (c=0;c<=columns;c++) {
-          if( ((r == 0) && (c == 0)) ) {
-             cout << nullstring;
-          } else {
-             cout.flags(ios::left);
-             cout << setw(12) << Table[r][c];
-          }
-        }
-        cout << endl;
-      }
+      *Table << *AC_cfg;
+      Table->Print();
 
       break;
     case EQUATION:
     case UNKNOWN:
       cerr << "Unimplemented coefficient type: " << type << endl;
-      break;  
+      break;
     }
     AC_cfg->GetNextConfigLine();
   }
+  if (debug_lvl & 2) cout << "Instantiated: FGCoefficient" << endl;
 }
 
 //%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 
-FGCoefficient::~FGCoefficient(void) {
-  DeAllocate();
-}
-
-//%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
-
-bool FGCoefficient::DeAllocate(void)
-{
-  if (Table != NULL ) {
-    for (unsigned int i=0; i<=rows; i++) delete[] Table[i];
-    
-    delete[] Table;
-  } 
-  
-  return true;
-}
-
-//%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
-
-bool FGCoefficient::Allocate(int r, int c)
+FGCoefficient::~FGCoefficient()
 {
-  rows = r;
-  columns = c;
-  Table = new float*[r+1];
-  for (int i=0;i<=r;i++) Table[i] = new float[c+1];
-  return true;
+  if (Table) delete Table;
+  if (debug_lvl & 2) cout << "Destroyed:    FGCoefficient" << endl;
 }
 
 //%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 
 float FGCoefficient::Value(float rVal, float cVal)
 {
-  float rFactor, cFactor, col1temp, col2temp, Value;
-  int r, c;
-  unsigned midx;
-
-  if (rows < 2 || columns < 2) return 0.0;
-
-  for (r=1;r<=rows;r++) if (Table[r][0] >= rVal) break;
-  for (c=1;c<=columns;c++) if (Table[0][c] >= cVal) break;
-  //cout << "Value(): rVal: " << rVal << " cVal: " << cVal << endl;
-  //cout << "Value(): r: " << r << " c: " << c << endl;
-  c = c < 2 ? 2 : (c > columns ? columns : c);
-  r = r < 2 ? 2 : (r > rows    ? rows    : r);
-
-  rFactor = (rVal - Table[r-1][0]) / (Table[r][0] - Table[r-1][0]);
-  cFactor = (cVal - Table[0][c-1]) / (Table[0][c] - Table[0][c-1]);
+  float Value;
+  unsigned int midx;
 
-  col1temp = rFactor*(Table[r][c-1] - Table[r-1][c-1]) + Table[r-1][c-1];
-  col2temp = rFactor*(Table[r][c] - Table[r-1][c]) + Table[r-1][c];
+  SD = Value = Table->GetValue(rVal, cVal);
 
-  Value = col1temp + cFactor*(col2temp - col1temp);
-  Value = (Value + bias)*gain;
-  SD = Value;
-  
   for (midx=0; midx < multipliers.size(); midx++) {
-    Value *= State->GetParameter(multipliers[midx]);
+      Value *= State->GetParameter(multipliers[midx]);
   }
-
   return Value;
 }
 
@@ -288,33 +190,13 @@ float FGCoefficient::Value(float rVal, float cVal)
 
 float FGCoefficient::Value(float Val)
 {
+  float Value;
+
+  SD = Value = Table->GetValue(Val);
   
+  for (unsigned int midx=0; midx < multipliers.size(); midx++) 
+      Value *= State->GetParameter(multipliers[midx]);
   
-  float Factor, Value;
-  int r;
-  unsigned midx;
-
-  if (rows < 2) return 0.0;
-
-  for (r=1;r<=rows;r++) if (Table[r][0] >= Val) break;
-  r = r < 2 ? 2 : (r > rows    ? rows    : r);
-
-  // make sure denominator below does not go to zero.
-  if (Table[r][0] != Table[r-1][0]) {
-    Factor = (Val - Table[r-1][0]) / (Table[r][0] - Table[r-1][0]);
-  } else {
-    Factor = 1.0;
-  }
-
-  Value = Factor*(Table[r][1] - Table[r-1][1]) + Table[r-1][1];
-  Value = (Value + bias)*gain;
-  SD = Value;
-
-  for (midx=0; midx < multipliers.size(); midx++) {
-    Value *= State->GetParameter(multipliers[midx]);
-
-  }
-
   return Value;
 }
 
@@ -323,15 +205,11 @@ float FGCoefficient::Value(float Val)
 float FGCoefficient::Value(void)
 {
        float Value;
-       unsigned midx;
 
-       Value = StaticValue;
-  Value = (Value + bias)*gain;
-  SD = Value;
+  SD = Value = StaticValue;
 
-  for (midx=0; midx < multipliers.size(); midx++) {
+  for (unsigned int midx=0; midx < multipliers.size(); midx++)
     Value *= State->GetParameter(multipliers[midx]);
-  }
 
   return Value;
 }
@@ -340,6 +218,7 @@ float FGCoefficient::Value(void)
 
 float FGCoefficient::TotalValue()
 {
+  
   switch(type) {
   case 0:
     return -1;
@@ -364,3 +243,8 @@ void FGCoefficient::DumpSD(void)
 
 //%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 
+void FGCoefficient::Debug(void)
+{
+    //TODO: Add your source code here
+}
+
index 9c8bdf3ad235a499887100998693bfad00c672b7..5cd6799c31cf52039caad5095f43a66b68a72bf7 100644 (file)
@@ -46,12 +46,13 @@ INCLUDES
 #include <string>
 #include "FGConfigFile.h"
 #include "FGDefs.h"
+#include "FGTable.h"
 
 /*%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 DEFINITIONS
 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%*/
 
-#define ID_COEFFICIENT "$Header"
+#define ID_COEFFICIENT "$Id$"
 
 using std::vector;
 
@@ -105,13 +106,12 @@ class FGCoefficient
   string name;
   string method;
   float StaticValue;
-  float **Table;
   eParam LookupR, LookupC;
   MultVec multipliers;
   int rows, columns;
   Type type;
   float SD; // Actual stability derivative (or other coefficient) value
-  float gain,bias;
+  FGTable *Table;
 
   FGFDMExec*      FDMExec;
   FGState*        State;
@@ -123,14 +123,11 @@ class FGCoefficient
   FGPosition*     Position;
   FGAuxiliary*    Auxiliary;
   FGOutput*       Output;
-  
-  bool DeAllocate(void);
-  bool Allocate(int, int);
 
 public:
   FGCoefficient(FGFDMExec*, FGConfigFile*);
-  ~FGCoefficient(void);
-  
+  ~FGCoefficient();
+
   float Value(float, float);
   float Value(float);
   float Value(void);
@@ -139,14 +136,10 @@ public:
   inline float GetSD(void) {return SD;}
   inline MultVec Getmultipliers(void) {return multipliers;}
   void DumpSD(void);
-  
-  inline float GetGain(void) { return gain; }
-  inline float GetBias(void) { return bias; }
-  inline void SetGain(float tt) { gain = tt; }
-  inline void SetBias(float tt) { bias = tt; }
-  inline void ResetGB(void) { gain = 1.0; bias = 0.0; }
-
+private:
+  void Debug(void);
 };
 
 //%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 #endif
+
index f74a1c128ef75383b6472f7e8e5f649101b3de2b..4d756992fd663a7e3162e67d432e1424a0d99629 100644 (file)
@@ -21,9 +21,11 @@ INCLUDES
 #include <stdlib.h>
 #include <math.h>
 
-static const char *IdSrc = "$Header$";
+static const char *IdSrc = "$Id$";
 static const char *IdHdr = "ID_CONFIGFILE";
 
+extern short debug_lvl;
+
 /*%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 CLASS IMPLEMENTATION
 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%*/
@@ -36,21 +38,28 @@ FGConfigFile::FGConfigFile(string cfgFileName)
   Opened = true;
   if (cfgfile.is_open()) GetNextConfigLine();
   else Opened = false;
+
+  if (debug_lvl & 2) cout << "Instantiated: FGConfigFile" << endl;
 }
 
+//%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 
-FGConfigFile::~FGConfigFile(void)
+FGConfigFile::~FGConfigFile()
 {
   cfgfile.close();
+  if (debug_lvl & 2) cout << "Destroyed:    FGConfigFile" << endl;
 }
 
+//%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 
 string FGConfigFile::GetNextConfigLine(void)
 {
   do {
     CurrentLine = GetLine();
-    if (CurrentLine.find("<COMMENT>") != CurrentLine.npos) CommentsOn = true;
-    if (CurrentLine.find("</COMMENT>") != CurrentLine.npos) {
+    if ((CurrentLine.find("<COMMENT>") != CurrentLine.npos) ||
+        (CurrentLine.find("<!--") != CurrentLine.npos)) CommentsOn = true;
+    if ((CurrentLine.find("</COMMENT>") != CurrentLine.npos) ||
+        (CurrentLine.find("-->") != CurrentLine.npos)) {
       CommentsOn = false;
       GetNextConfigLine();
     }
@@ -60,6 +69,7 @@ string FGConfigFile::GetNextConfigLine(void)
   return CurrentLine;
 }
 
+//%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 
 string FGConfigFile::GetValue(string val)
 {
@@ -128,12 +138,14 @@ string FGConfigFile::GetValue(string val)
   return string("");
 }
 
+//%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 
 string FGConfigFile::GetValue(void)
 {
   return GetValue("");
 }
 
+//%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 
 bool FGConfigFile::IsCommentLine(void)
 {
@@ -143,11 +155,12 @@ bool FGConfigFile::IsCommentLine(void)
   return false;
 }
 
+//%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 
 string FGConfigFile::GetLine(void)
 {
   string scratch = "";
-  unsigned int test;
+  int test;
 
   while ((test = cfgfile.get()) != EOF) {
     if (test >= 0x20) {
@@ -163,6 +176,8 @@ string FGConfigFile::GetLine(void)
   return scratch;
 }
 
+//%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+
 FGConfigFile& FGConfigFile::operator>>(double& val)
 {
   unsigned int pos, end;
@@ -178,6 +193,8 @@ FGConfigFile& FGConfigFile::operator>>(double& val)
   return *this;
 }
 
+//%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+
 FGConfigFile& FGConfigFile::operator>>(float& val)
 {
   unsigned int pos, end;
@@ -193,6 +210,8 @@ FGConfigFile& FGConfigFile::operator>>(float& val)
   return *this;
 }
 
+//%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+
 FGConfigFile& FGConfigFile::operator>>(int& val)
 {
   unsigned int pos, end;
@@ -208,6 +227,8 @@ FGConfigFile& FGConfigFile::operator>>(int& val)
   return *this;
 }
 
+//%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+
 FGConfigFile& FGConfigFile::operator>>(eParam& val)
 {
   unsigned int pos, end;
@@ -223,6 +244,8 @@ FGConfigFile& FGConfigFile::operator>>(eParam& val)
   return *this;
 }
 
+//%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+
 FGConfigFile& FGConfigFile::operator>>(string& str)
 {
   unsigned int pos, end;
@@ -237,9 +260,17 @@ FGConfigFile& FGConfigFile::operator>>(string& str)
   return *this;
 }
 
+//%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 
 void FGConfigFile::ResetLineIndexToZero(void)
 {
   CurrentIndex = 0;
 }
 
+//%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+
+void FGConfigFile::Debug(void)
+{
+    //TODO: Add your source code here
+}
+
index 60e2d57e59429e9d9c291fd996f3cc8e307640cc..e5064cbcbc957f974d72025597c0333d829b347e 100644 (file)
@@ -40,7 +40,7 @@ INCLUDES
 
 #ifdef FGFS
 #  include <simgear/compiler.h>
-#  ifdef SG_HAVE_STD_INCLUDES
+#  ifdef FG_HAVE_STD_INCLUDES
 #    include <fstream>
 #  else
 #    include <fstream.h>
@@ -56,7 +56,7 @@ INCLUDES
 DEFINITIONS
 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%*/
 
-#define ID_CONFIGFILE "$Header"
+#define ID_CONFIGFILE "$Id$"
 
 using std::string;
 using std::ifstream;
@@ -91,7 +91,7 @@ public:
       @param Filename the name of the config file to be read. */
   FGConfigFile(string Filename);
   /// Destructor
-  ~FGConfigFile(void);
+  ~FGConfigFile();
 
   string GetLine(void);
   string GetNextConfigLine(void);
@@ -106,15 +106,15 @@ public:
   FGConfigFile& operator>>(eParam&);
   void ResetLineIndexToZero(void);
 
-protected:
-
 private:
   ifstream cfgfile;
   string   CurrentLine;
   bool     CommentsOn;
   bool     Opened;
   unsigned int      CurrentIndex;
+  void Debug(void);
 };
 
 //%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 #endif
+
index d1206f92101caeed4ed1a96ffc62cf95208d9538..5866515380e97a5b4928deddb9064419253c4485 100644 (file)
@@ -24,7 +24,7 @@
 
 #include "FGControls.h"
 
-static const char *IdSrc = "$Header$";
+static const char *IdSrc = "$Id$";
 static const char *IdHdr = "ID_CONTROLS";
 
 FGControls controls;
@@ -53,8 +53,17 @@ FGControls::~FGControls() {
 
 
 // $Log$
-// Revision 1.21  2000/11/14 19:32:03  curt
-// Nov. 14, 2000 JSBSim updates
+// Revision 1.22  2001/03/29 23:04:51  curt
+// Latest round of JSBSim updates.
+//
+// Revision 1.7  2001/03/22 14:10:24  jberndt
+// Fixed ID comment
+//
+// Revision 1.6  2001/02/04 13:16:13  jsb
+// ** JSB ** Got rid of extra carriage return in code
+//
+// Revision 1.5  2001/02/02 01:16:57  jsb
+// ** JSB ** trim, prop, gear changes
 //
 // Revision 1.4  2000/10/13 19:21:02  jsb
 // ** JSB ** Added version identifiers for all files
index 52a5a557f4f2c44b88ec9720f5e9b59133f0d8fe..ea9078356e3dd4a8cdd1b4002eacac76b16ceeaf 100644 (file)
@@ -29,7 +29,7 @@
 # error This library requires C++
 #endif                                   
 
-#define ID_CONTROLS "$Header"
+#define ID_CONTROLS "$Id"
 
 // Define a structure containing the control parameters
 
@@ -178,8 +178,17 @@ extern FGControls controls;
 
 
 // $Log$
-// Revision 1.20  2000/11/14 19:32:03  curt
-// Nov. 14, 2000 JSBSim updates
+// Revision 1.21  2001/03/29 23:04:51  curt
+// Latest round of JSBSim updates.
+//
+// Revision 1.10  2001/03/22 14:10:24  jberndt
+// Fixed ID comment
+//
+// Revision 1.9  2001/02/04 13:16:13  jsb
+// ** JSB ** Got rid of extra carriage return in code
+//
+// Revision 1.8  2001/02/02 01:16:57  jsb
+// ** JSB ** trim, prop, gear changes
 //
 // Revision 1.7  2000/10/13 19:21:02  jsb
 // ** JSB ** Added version identifiers for all files
index 07c86c0b0c3e79c6918eabb797e5f28b3d21703f..1de1ba3db7f356cfc2c89bd4c9cb975e370f7843 100644 (file)
@@ -54,13 +54,15 @@ SENTRY
 #define FPSTOKTS        0.592484
 #define INCHTOFT        0.08333333
 #define OMEGA_EARTH .00007272205217  
-#define NEEDED_CFG_VERSION "1.36"
+#define NEEDED_CFG_VERSION "1.38"
+#define JSBSIM_VERSION  "0.8.2"
 
 #define HPTOFTLBSSEC 550
 #define METERS_TO_FEET 3.2808
 
 enum eParam {
   FG_UNDEF = 0,
+  FG_TIME,
   FG_QBAR,
   FG_WINGAREA,
   FG_WINGSPAN,
@@ -69,7 +71,7 @@ enum eParam {
   FG_ALPHADOT,
   FG_BETA,
   FG_BETADOT,
-  SGD_PITCHRATE,
+  FG_PITCHRATE,
   FG_ROLLRATE,
   FG_YAWRATE,
   FG_MACH,
@@ -90,8 +92,21 @@ enum eParam {
   FG_FLAPS_CMD,
   FG_THROTTLE_CMD,
   FG_THROTTLE_POS,
+  FG_ACTIVE_ENGINE,
   FG_HOVERB,
-  SGD_PITCH_TRIM_CMD
+  FG_PITCH_TRIM_CMD
+};
+
+enum eAction {
+  FG_RAMP  = 1,
+  FG_STEP  = 2,
+  FG_EXP   = 3
+};
+
+enum eType {
+  FG_VALUE = 1,
+  FG_DELTA = 2,
+  FG_BOOL  = 3
 };
 
 /******************************************************************************/
index 38b16a9097c6e7877ebdcd16a4b9f21adb858e8c..7e94a01a747abdde80e8a38a235f454adcb8d6d2 100644 (file)
@@ -40,7 +40,7 @@ INCLUDES
 
 #ifdef FGFS
 #  include <simgear/compiler.h>
-#  ifdef SG_HAVE_STD_INCLUDES
+#  ifdef FG_HAVE_STD_INCLUDES
 #    include <fstream>
 #  else
 #    include <fstream.h>
@@ -50,35 +50,24 @@ INCLUDES
 #endif
 
 #include "FGEngine.h"
-#include "FGState.h"
-#include "FGFDMExec.h"
-#include "FGAtmosphere.h"
-#include "FGFCS.h"
-#include "FGAircraft.h"
-#include "FGTranslation.h"
-#include "FGRotation.h"
-#include "FGPosition.h"
-#include "FGAuxiliary.h"
-#include "FGOutput.h"
-#include "FGDefs.h"
-
-static const char *IdSrc = "$Header$";
+#include "FGTank.h"
+
+static const char *IdSrc = "$Id$";
 static const char *IdHdr = "ID_ENGINE";
 
+extern short debug_lvl;
+
 /*%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 CLASS IMPLEMENTATION
 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%*/
 
 
-FGEngine::FGEngine(FGFDMExec* fdex, string enginePath, string engineName, int num) {
-  string fullpath;
-  string tag;
-
-  FDMExec = fdex;
-
+FGEngine::FGEngine(FGFDMExec* exec) {
+  FDMExec     = exec;
   State       = FDMExec->GetState();
   Atmosphere  = FDMExec->GetAtmosphere();
   FCS         = FDMExec->GetFCS();
+  Propulsion  = FDMExec->GetPropulsion();
   Aircraft    = FDMExec->GetAircraft();
   Translation = FDMExec->GetTranslation();
   Rotation    = FDMExec->GetRotation();
@@ -86,152 +75,82 @@ FGEngine::FGEngine(FGFDMExec* fdex, string enginePath, string engineName, int nu
   Auxiliary   = FDMExec->GetAuxiliary();
   Output      = FDMExec->GetOutput();
 
-  Name = engineName;
-
-# ifndef macintosh  
-    fullpath = enginePath + "/" + engineName + ".xml";
-# else
-    fullpath = enginePath + ";" + engineName + ".xml";
-# endif
-      
-  cout << "    Reading engine: " << engineName << " from file: " << fullpath << endl;
-  ifstream enginefile(fullpath.c_str());
-
-  if (enginefile) {
-    enginefile >> tag;
-
-    if      (tag == "ROCKET")    Type = etRocket;
-    else if (tag == "PISTON")    Type = etPiston;
-    else if (tag == "TURBOPROP") Type = etTurboProp;
-    else if (tag == "TURBOJET")  Type = etTurboJet;
-    else                         Type = etUnknown;
-
-    switch(Type) {
-    case etTurboProp:
-    case etTurboJet: 
-      cerr << "Unsupported Engine type" << tag << endl;
-      break;
-    case etUnknown:
-      cerr << "Unknown engine type: " << tag << endl;
-      break;
-    case etPiston:
-      enginefile >> X;
-      enginefile >> Y;
-      enginefile >> Z;
-      enginefile >> EnginePitch;
-      enginefile >> EngineYaw;
-      enginefile >> BrakeHorsePower;
-      enginefile >> MaxThrottle;
-      enginefile >> MinThrottle;
-      enginefile >> SLFuelFlowMax;
-      enginefile >> SpeedSlope;
-      enginefile >> SpeedIntercept;
-      enginefile >> AltitudeSlope;
-
-      break;
-    case etRocket:
-      enginefile >> X;
-      enginefile >> Y;
-      enginefile >> Z;
-      enginefile >> EnginePitch;
-      enginefile >> EngineYaw;
-      enginefile >> SLThrustMax;
-      enginefile >> VacThrustMax;
-      enginefile >> MaxThrottle;
-      enginefile >> MinThrottle;
-      enginefile >> SLFuelFlowMax;
-      enginefile >> SLOxiFlowMax;
-      break;
-    }
-
-    enginefile.close();
-  } else {
-    cerr << "Unable to open engine definition file " << fullpath.c_str() << endl;
-  }
-
-  EngineNumber = num;
   Thrust = PctPower = 0.0;
   Starved = Flameout = false;
   Running = true;
-}
-
-
-FGEngine::~FGEngine(void) {}
-
 
-float FGEngine::CalcRocketThrust(void) {
-  float lastThrust;
-
-  Throttle = FCS->GetThrottlePos(EngineNumber);
-  lastThrust = Thrust;                 // last actual thrust
+  if (debug_lvl & 2) cout << "Instantiated: FGEngine" << endl;
+  TrimMode = false;
+}
 
-  if (Throttle < MinThrottle || Starved) {
-    PctPower = Thrust = 0.0; // desired thrust
-    Flameout = true;
-  } else {
-    PctPower = Throttle / MaxThrottle;
-    Thrust = PctPower*((1.0 - Atmosphere->GetDensityRatio())*(VacThrustMax - SLThrustMax) +
-                       SLThrustMax); // desired thrust
-    Flameout = false;
-  }
+//%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 
+FGEngine::~FGEngine()
+{
+  if (debug_lvl & 2) cout << "Destroyed:    FGEngine" << endl;
+}
 
-  if(State->Getdt() > 0.0) {
-    Thrust -= 0.8*(Thrust - lastThrust); // actual thrust
+//%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+// This base class function should be called from within the
+// derived class' Calculate() function before any other calculations are done.
+// This base class method removes fuel from the fuel tanks as appropriate,
+// and sets the starved flag if necessary.
+
+void FGEngine::ConsumeFuel(void) {
+  float Fshortage, Oshortage;
+  FGTank* Tank;
+
+  if (TrimMode) return;
+
+  Fshortage = Oshortage = 0.0;
+  for (unsigned int i=0; i<SourceTanks.size(); i++) {
+    Tank = Propulsion->GetTank(i);
+    if (Tank->GetType() == FGTank::ttFUEL) {
+      Fshortage += Tank->Reduce(CalcFuelNeed()/Propulsion->GetnumSelectedFuelTanks());
+    } else {
+      Oshortage += Tank->Reduce(CalcOxidizerNeed()/Propulsion->GetnumSelectedOxiTanks());
+    }
   }
 
-  return Thrust;
+  if (Fshortage < 0.00 || Oshortage < 0.00) Starved = true;
+  else Starved = false;
 }
 
+//%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 
-float FGEngine::CalcPistonThrust(void) {
-  float v,h,pa;
-
-  Throttle = FCS->GetThrottlePos(EngineNumber);
-  Throttle /= 100;
-
-  v = Translation->GetVt();
-  h = Position->Geth();
-
-  if (v < 10)
-    v = 10;
-  if (h < 0)
-    h = 0;
-
-  pa=(SpeedSlope*v + SpeedIntercept)*(1 +AltitudeSlope*h)*BrakeHorsePower;
+float FGEngine::CalcFuelNeed(void) {
+  FuelNeed = SLFuelFlowMax*PctPower*State->Getdt()*Propulsion->GetRate();
+  return FuelNeed;
+}
 
-  Thrust = Throttle*(pa*HPTOFTLBSSEC)/v;
+//%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 
-  return Thrust;
+float FGEngine::CalcOxidizerNeed(void) {
+  OxidizerNeed = SLOxiFlowMax*PctPower*State->Getdt()*Propulsion->GetRate();
+  return OxidizerNeed;
 }
 
+//%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 
-float FGEngine::CalcThrust(void) {
-  if(Running) {
-    switch(Type) {
-    case etRocket:
-      return CalcRocketThrust();
-      // break;
-    case etPiston:
-      return CalcPistonThrust();
-      // break;
-    default:
-      return 9999.0;
-      // break;
-    }
-  } else {
-    return 0;
-  }
+void FGEngine::SetPlacement(float x, float y, float z, float pitch, float yaw) {
+  X = x;
+  Y = y;
+  Z = z;
+  EnginePitch = pitch;
+  EngineYaw = yaw;
 }
 
-float FGEngine::CalcFuelNeed() {
-  FuelNeed = SLFuelFlowMax*PctPower;
-  return FuelNeed;
+//%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+
+void FGEngine::AddFeedTank(int tkID)
+{
+  SourceTanks.push_back(tkID);
 }
 
+//%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 
-float FGEngine::CalcOxidizerNeed() {
-  OxidizerNeed = SLOxiFlowMax*PctPower;
-  return OxidizerNeed;
+void FGEngine::Debug(void)
+{
+    //TODO: Add your source code here
 }
 
index 8c86c2d85e6b3a08f1236f9a4e214d1523189215..fb23f9751c2e5d5287a50da7de5afd4e3d5cb91f 100644 (file)
@@ -1,44 +1,44 @@
 /*%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+
  Header:       FGEngine.h
  Author:       Jon S. Berndt
  Date started: 01/21/99
+
  ------------- Copyright (C) 1999  Jon S. Berndt (jsb@hal-pc.org) -------------
+
  This program is free software; you can redistribute it and/or modify it under
  the terms of the GNU General Public License as published by the Free Software
  Foundation; either version 2 of the License, or (at your option) any later
  version.
+
  This program is distributed in the hope that it will be useful, but WITHOUT
  ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
  FOR A PARTICULAR PURPOSE.  See the GNU General Public License for more
  details.
+
  You should have received a copy of the GNU General Public License along with
  this program; if not, write to the Free Software Foundation, Inc., 59 Temple
  Place - Suite 330, Boston, MA  02111-1307, USA.
+
  Further information about the GNU General Public License can also be found on
  the world wide web at http://www.gnu.org.
+
 FUNCTIONAL DESCRIPTION
 --------------------------------------------------------------------------------
+
 Based on Flightgear code, which is based on LaRCSim. This class simulates
 a generic engine.
+
 HISTORY
 --------------------------------------------------------------------------------
 01/21/99   JSB   Created
+
 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 SENTRY
 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%*/
 
-#ifndef FGEngine_H
-#define FGEngine_H
+#ifndef FGENGINE_H
+#define FGENGINE_H
 
 /*%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 INCLUDES
@@ -47,21 +47,27 @@ INCLUDES
 #ifdef FGFS
 #  include <simgear/compiler.h>
 #  include STL_STRING
-SG_USING_STD(string);
+   SG_USING_STD(string);
+#  ifdef FG_HAVE_STD_INCLUDES
+#    include <vector>
+#  else
+#    include <vector.h>
+#  endif
 #else
+#  include <vector>
 #  include <string>
 #endif
 
 /*%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
-DEFINES
+DEFINITIONS
 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%*/
 
-#define ID_ENGINE "$Header"
+#define ID_ENGINE "$Id$"
 
 using std::string;
 
 /*%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
-CLASS DECLARATION
+FORWARD DECLARATIONS
 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%*/
 
 class FGFDMExec;
@@ -71,58 +77,101 @@ class FGFCS;
 class FGAircraft;
 class FGTranslation;
 class FGRotation;
+class FGPropulsion;
 class FGPosition;
 class FGAuxiliary;
 class FGOutput;
 
+using std::vector;
+
+/*%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+COMMENTS, REFERENCES, and NOTES [use "class documentation" below for API docs]
+%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%*/
+
+/*%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+CLASS DOCUMENTATION
+%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%*/
+
+/** Base class for all engines.
+    This base class contains methods and members common to all engines, such as
+    logic to drain fuel from the appropriate tank, etc.
+    @author Jon S. Berndt
+    @version $Id$ 
+*/
+
+/*%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+CLASS DECLARATION
+%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%*/
+
 class FGEngine {
 public:
-  FGEngine(FGFDMExec*, string, string, int);
-  ~FGEngine(void);
+  FGEngine(FGFDMExec* exec);
+  virtual ~FGEngine();
 
   enum EngineType {etUnknown, etRocket, etPiston, etTurboProp, etTurboJet};
 
+  virtual float  GetThrottleMin(void) { return MinThrottle; }
+  virtual float  GetThrottleMax(void) { return MaxThrottle; }
   float  GetThrottle(void) { return Throttle; }
   float  GetThrust(void) { return Thrust; }
-  float  GetThrottleMin(void) { return MinThrottle; }
-  float  GetThrottleMax(void) { return MaxThrottle; }
   bool   GetStarved(void) { return Starved; }
   bool   GetFlameout(void) { return Flameout; }
   bool   GetRunning(void) { return Running; }
   int    GetType(void) { return Type; }
-  string GetName() { return Name; }
-
-  void SetStarved(bool tt) {
-    Starved = tt;
-  }
-  void SetStarved(void) {
-    Starved = true;
-  }
-  
+  string GetName(void) { return Name; }
+
+  void SetStarved(bool tt) {Starved = tt;}
+  void SetStarved(void)    {Starved = true;}
+
   void SetRunning(bool bb) { Running=bb; }
-  
-  float CalcThrust(void);
+  void SetName(string name) {Name = name;}
+  void AddFeedTank(int tkID);
+
+  /** Calculates the thrust of the engine, and other engine functions.
+      @param PowerRequired this is the power required to run the thrusting device
+             such as a propeller. This resisting effect must be provided to the 
+             engine model.
+      @return Thrust in pounds */
+  virtual float Calculate(float PowerRequired) {return 0.0;};
+
+  /** Reduces the fuel in the active tanks by the amount required.
+      This function should be called from within the
+      derived class' Calculate() function before any other calculations are
+      done. This base class method removes fuel from the fuel tanks as
+      appropriate, and sets the starved flag if necessary. */
+  void ConsumeFuel(void);
+
+  /** The fuel need is calculated based on power levels and flow rate for that
+      power level. It is also turned from a rate into an actual amount (pounds)
+      by multiplying it by the delta T and the rate.
+      @return Total fuel requirement for this engine in pounds. */
   float CalcFuelNeed(void);
+
+  /** The oxidizer need is calculated based on power levels and flow rate for that
+      power level. It is also turned from a rate into an actual amount (pounds)
+      by multiplying it by the delta T and the rate.
+      @return Total oxidizer requirement for this engine in pounds. */
   float CalcOxidizerNeed(void);
 
-private:
+  /// Sets engine placement information
+  void SetPlacement(float x, float y, float z, float pitch, float yaw);
+
+  virtual float GetPowerAvailable(void) {return 0.0;};
+
+  bool GetTrimMode(void) {return TrimMode;}
+  void SetTrimMode(bool state) {TrimMode = state;}
+
+protected:
   string Name;
   EngineType Type;
   float X, Y, Z;
   float EnginePitch;
   float EngineYaw;
-  float SLThrustMax;
-  float VacThrustMax;
   float SLFuelFlowMax;
   float SLOxiFlowMax;
   float MaxThrottle;
   float MinThrottle;
 
-  float BrakeHorsePower;
-  float SpeedSlope;
-  float SpeedIntercept;
-  float AltitudeSlope;
-
   float Thrust;
   float Throttle;
   float FuelNeed, OxidizerNeed;
@@ -131,11 +180,13 @@ private:
   bool  Running;
   float PctPower;
   int   EngineNumber;
+  bool  TrimMode;
 
   FGFDMExec*      FDMExec;
   FGState*        State;
   FGAtmosphere*   Atmosphere;
   FGFCS*          FCS;
+  FGPropulsion*   Propulsion;
   FGAircraft*     Aircraft;
   FGTranslation*  Translation;
   FGRotation*     Rotation;
@@ -143,11 +194,23 @@ private:
   FGAuxiliary*    Auxiliary;
   FGOutput*       Output;
 
-protected:
-  float CalcRocketThrust(void);
-  float CalcPistonThrust(void);
-
+  vector <int> SourceTanks;
+  void Debug(void);
 };
 
+#include "FGState.h"
+#include "FGFDMExec.h"
+#include "FGAtmosphere.h"
+#include "FGFCS.h"
+#include "FGAircraft.h"
+#include "FGTranslation.h"
+#include "FGRotation.h"
+#include "FGPropulsion.h"
+#include "FGPosition.h"
+#include "FGAuxiliary.h"
+#include "FGOutput.h"
+#include "FGDefs.h"
+
 //%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 #endif
+
index e434759fb14ce91d603bee58285b9e2d9ada11a6..21bb6b232c83215c52f7e968873c305d36471ba1 100644 (file)
@@ -56,43 +56,45 @@ INCLUDES
 #include "filtersjb/FGSummer.h"
 #include "filtersjb/FGFlaps.h"
 
-static const char *IdSrc = "$Header$";
+static const char *IdSrc = "$Id$";
 static const char *IdHdr = "ID_FCS";
 
+extern short debug_lvl;
+
 /*%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 CLASS IMPLEMENTATION
 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%*/
 
 FGFCS::FGFCS(FGFDMExec* fdmex) : FGModel(fdmex) {
   Name = "FGFCS";
-  for (int i=0; i < MAX_ENGINES; i++) {  // needs to be changed: no limit
-    ThrottleCmd[i] = 0.0;
-    ThrottlePos[i] = 0.0;
-  }
+
   DaCmd = DeCmd = DrCmd = DfCmd = DsbCmd = DspCmd = PTrimCmd = 0.0;
   DaPos = DePos = DrPos = DfPos = DsbPos = DspPos = 0.0;
+  LeftBrake = RightBrake = CenterBrake = 0.0;
+
+  if (debug_lvl & 2) cout << "Instantiated: " << Name << endl;
 }
 
 //%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 
-FGFCS::~FGFCS(void) {
-  for(unsigned int i=0;i<Components.size();i++)
-    delete Components[i];
+FGFCS::~FGFCS()
+{
+  ThrottleCmd.clear();
+  ThrottlePos.clear();
+
+  for(unsigned int i=0;i<Components.size();i++) delete Components[i];
+  if (debug_lvl & 2) cout << "Destroyed:    FGFCS" << endl;
 }
 
 //%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 
-bool FGFCS::Run(void) {
+bool FGFCS::Run(void)
+{
   if (!FGModel::Run()) {
-
-    for (unsigned int i=0; i<Aircraft->GetNumEngines(); i++) ThrottlePos[i]=ThrottleCmd[i];
-
-    for (unsigned int i=0; i<Components.size(); i++) {
-      Components[i]->Run();
-    }
-
-  } else {}
-
+    for (unsigned int i=0; i<ThrottlePos.size(); i++) ThrottlePos[i] = ThrottleCmd[i];
+    for (unsigned int i=0; i<Components.size(); i++)  Components[i]->Run();
+  } else {
+  }
 
   return false;
 }
@@ -101,7 +103,7 @@ bool FGFCS::Run(void) {
 
 void FGFCS::SetThrottleCmd(int engineNum, float setting) {
   if (engineNum < 0) {
-    for (unsigned int ctr=0;ctr<Aircraft->GetNumEngines();ctr++) ThrottleCmd[ctr] = setting;
+    for (unsigned int ctr=0;ctr<ThrottleCmd.size();ctr++) ThrottleCmd[ctr] = setting;
   } else {
     ThrottleCmd[engineNum] = setting;
   }
@@ -111,7 +113,7 @@ void FGFCS::SetThrottleCmd(int engineNum, float setting) {
 
 void FGFCS::SetThrottlePos(int engineNum, float setting) {
   if (engineNum < 0) {
-    for (unsigned int ctr=0;ctr<=Aircraft->GetNumEngines();ctr++) ThrottlePos[ctr] = ThrottleCmd[ctr];
+    for (unsigned int ctr=0;ctr<=ThrottleCmd.size();ctr++) ThrottlePos[ctr] = ThrottleCmd[ctr];
   } else {
     ThrottlePos[engineNum] = setting;
   }
@@ -130,7 +132,6 @@ bool FGFCS::LoadFCS(FGConfigFile* AC_cfg) {
       token = AC_cfg->GetValue("TYPE");
       cout << "    Loading Component \"" << AC_cfg->GetValue("NAME") << "\" of type: " << token << endl;
       if ((token == "LAG_FILTER") ||
-          (token == "RECT_LAG_FILTER") ||
           (token == "LEAD_LAG_FILTER") ||
           (token == "SECOND_ORDER_FILTER") ||
           (token == "WASHOUT_FILTER") ||
@@ -152,6 +153,9 @@ bool FGFCS::LoadFCS(FGConfigFile* AC_cfg) {
         Components.push_back(new FGSwitch(this, AC_cfg));
       } else if (token == "FLAPS") {
         Components.push_back(new FGFlaps(this, AC_cfg));
+      } else {
+        cerr << "Unknown token [" << token << "] in FCS portion of config file" << endl;
+        return false;
       }
       AC_cfg->GetNextConfigLine();
     }
@@ -173,7 +177,7 @@ string FGFCS::GetComponentName(int idx) {
 
 //%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 
-float FGFCS::GetBrake(FGLGear::eBrakeGroup bg) {
+float FGFCS::GetBrake(FGLGear::BrakeGroup bg) {
   switch (bg) {
   case FGLGear::bgLeft:
     return LeftBrake;
@@ -184,6 +188,7 @@ float FGFCS::GetBrake(FGLGear::eBrakeGroup bg) {
   default:
     cerr << "GetBrake asked to return a bogus brake value" << endl;
   }
+  return 0.0;
 }
 
 //%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
@@ -204,7 +209,8 @@ string FGFCS::GetComponentStrings(void){
 
 //%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 
-string FGFCS::GetComponentValues(void){
+string FGFCS::GetComponentValues(void)
+{
   string CompValues = "";
   char buffer[10];
   bool firstime = true;
@@ -219,3 +225,19 @@ string FGFCS::GetComponentValues(void){
 
   return CompValues;
 }
+
+//%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+
+void FGFCS::AddThrottle(void)
+{
+  ThrottleCmd.push_back(0.0);
+  ThrottlePos.push_back(0.0);
+}
+
+//%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+
+void FGFCS::Debug(void)
+{
+    //TODO: Add your source code here
+}
+
index 4643e1c357c2787ef2eb9e827017fd4a4e13d9fb..2b9899888bc567a66dbfd0481761a4d784c768d0 100644 (file)
@@ -40,7 +40,7 @@ INCLUDES
 
 #ifdef FGFS
 #  include <simgear/compiler.h>
-#  ifdef SG_HAVE_STD_INCLUDES
+#  ifdef FG_HAVE_STD_INCLUDES
 #    include <vector>
 #  else
 #    include <vector.h>
@@ -59,7 +59,7 @@ INCLUDES
 DEFINITIONS
 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%*/
 
-#define ID_FCS "$Header"
+#define ID_FCS "$Id$"
 
 /*%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 FORWARD DECLARATIONS
@@ -89,7 +89,7 @@ CLASS DOCUMENTATION
     &lt COMPONENT NAME="Pitch Trim Sum" TYPE="SUMMER"&gt
       ID            0
       INPUT        FG_ELEVATOR_CMD
-      INPUT        SGD_PITCH_TRIM_CMD
+      INPUT        FG_PITCH_TRIM_CMD
       CLIPTO       -1 1
     &lt/COMPONENT&gt
 
@@ -161,7 +161,7 @@ public:
       @param Executive a pointer to the parent executive object */
   FGFCS(FGFDMExec*);
   /// Destructor
-  ~FGFCS(void);
+  ~FGFCS();
 
   /** Runs the Flight Controls model; called by the Executive
       @return false if no error */
@@ -308,7 +308,7 @@ public:
   /** Gets the brake for a specified group.
       @param bg which brakegroup to retrieve the command for
       @return the brake setting for the supplied brake group argument */
-  float GetBrake(FGLGear::eBrakeGroup bg);
+  float GetBrake(FGLGear::BrakeGroup bg);
   //@}
 
   /** Loads the Flight Control System.
@@ -322,19 +322,22 @@ public:
   /** The name of the flight control laws for this aircraft.
       This is given in the config file, and is not used for anything currently.*/
   string FCSName;
-  
+
+  void AddThrottle(void);
+
 private:
   float DaCmd, DeCmd, DrCmd, DfCmd, DsbCmd, DspCmd;
   float DaPos, DePos, DrPos, DfPos, DsbPos, DspPos;
   float PTrimCmd;
-  float ThrottleCmd[MAX_ENGINES];       // Needs to be changed: s/b no limit
-  float ThrottlePos[MAX_ENGINES];       // Needs to be changed: s/b no limit
+  vector <float> ThrottleCmd;
+  vector <float> ThrottlePos;
   float LeftBrake, RightBrake, CenterBrake; // Brake settings
 
   vector <FGFCSComponent*> Components;
-
+  void Debug(void);
 };
 
 #include "FGState.h"
 
 #endif
+
index caf4b9d146d536db458105de57b1100a07593b65..d98f24038b1944d497c920a5a37587d90765d8b0 100644 (file)
@@ -34,42 +34,84 @@ HISTORY
 --------------------------------------------------------------------------------
 11/17/98   JSB   Created
 
+%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+COMMENTS, REFERENCES,  and NOTES
+%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+
 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 INCLUDES
 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%*/
 
 #ifdef FGFS
 #  include <simgear/compiler.h>
-#  ifdef SG_HAVE_STD_INCLUDES
+#  ifdef FG_HAVE_STD_INCLUDES
 #    include <iostream>
 #    include <ctime>
+#    include <iterator>
 #  else
 #    include <iostream.h>
 #    include <time.h>
+#    include <iterator.h>
 #  endif
 #else
 #  include <iostream>
 #  include <ctime>
+#  include <iterator>
 #endif
 
 #include "FGFDMExec.h"
 #include "FGState.h"
 #include "FGAtmosphere.h"
 #include "FGFCS.h"
+#include "FGPropulsion.h"
 #include "FGAircraft.h"
 #include "FGTranslation.h"
 #include "FGRotation.h"
 #include "FGPosition.h"
 #include "FGAuxiliary.h"
 #include "FGOutput.h"
+#include "FGConfigFile.h"
 
-static const char *IdSrc = "$Header$";
+static const char *IdSrc = "$Id$";
 static const char *IdHdr = "ID_FDMEXEC";
 
+char highint[5]  = {27, '[', '1', 'm', '\0'      };
+char halfint[5]  = {27, '[', '2', 'm', '\0'      };
+char normint[6]  = {27, '[', '2', '2', 'm', '\0' };
+char reset[5]    = {27, '[', '0', 'm', '\0'      };
+char underon[5]  = {27, '[', '4', 'm', '\0'      };
+char underoff[6] = {27, '[', '2', '4', 'm', '\0' };
+char fgblue[6]   = {27, '[', '3', '4', 'm', '\0' };
+char fgcyan[6]   = {27, '[', '3', '6', 'm', '\0' };
+char fgred[6]    = {27, '[', '3', '1', 'm', '\0' };
+char fggreen[6]  = {27, '[', '3', '2', 'm', '\0' };
+char fgdef[6]    = {27, '[', '3', '9', 'm', '\0' };
+
 /*%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
-CLASS IMPLEMENTATION
+GLOBAL DECLARATIONS
 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%*/
 
+short debug_lvl;  // This describes to any interested entity the debug level
+                  // requested by setting the JSBSIM_DEBUG environment variable.
+                  // The bitmasked value choices are as follows:
+                  // a) unset: In this case (the default) JSBSim would only print
+                  //    out the normally expected messages, essentially echoing
+                  //    the config files as they are read. If the environment
+                  //    variable is not set, debug_lvl is set to 1 internally
+                  // b) 0: This requests JSBSim not to output any messages
+                  //    whatsoever.
+                  // c) 1: This value explicity requests the normal JSBSim
+                  //    startup messages
+                  // d) 2: This value asks for a message to be printed out when
+                  //    a class is instantiated
+                  // e) 4: When this value is set, a message is displayed when a
+                  //    FGModel object executes its Run() method
+                  // f) 8: When this value is set, various runtime state variables
+                  //    are printed out periodically
+
+/*%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+CLASS IMPLEMENTATION
+%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%*/
 
 // Constructor
 
@@ -80,6 +122,7 @@ FGFDMExec::FGFDMExec(void)
   State       = 0;
   Atmosphere  = 0;
   FCS         = 0;
+  Propulsion  = 0;
   Aircraft    = 0;
   Translation = 0;
   Rotation    = 0;
@@ -90,23 +133,42 @@ FGFDMExec::FGFDMExec(void)
   terminate = false;
   frozen = false;
   modelLoaded = false;
-  
+  Scripted = false;
+
+  cout << "\n\n     " << highint << underon << "JSBSim Flight Dynamics Model v"
+                                 << JSBSIM_VERSION << underoff << normint << endl;
+  cout << halfint << "            [cfg file spec v" << NEEDED_CFG_VERSION << "]\n\n";
+  cout << normint << "JSBSim startup beginning ...\n\n";
+
+  try {
+    char* num = getenv("JSBSIM_DEBUG");
+    if (!num) debug_lvl = 1;
+    else debug_lvl = atoi(num); // set debug level
+  } catch (...) {               // if error set to 1
+    debug_lvl = 1;
+  }
+
+  if (debug_lvl & 2) cout << "Instantiated: FGFDMExec" << endl;
+
   Allocate();
-  
 }
 
-FGFDMExec::~FGFDMExec(void){
-  
-  DeAllocate();
+//%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 
+FGFDMExec::~FGFDMExec() {
+  DeAllocate();
+  if (debug_lvl & 2) cout << "Destroyed:    FGFDMExec" << endl;
 }
 
+//%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+
 bool FGFDMExec::Allocate(void) {
-  
+
   bool result=true;
-  
+
   Atmosphere  = new FGAtmosphere(this);
   FCS         = new FGFCS(this);
+  Propulsion  = new FGPropulsion(this);
   Aircraft    = new FGAircraft(this);
   Translation = new FGTranslation(this);
   Rotation    = new FGRotation(this);
@@ -118,39 +180,62 @@ bool FGFDMExec::Allocate(void) {
 
   // Initialize models so they can communicate with each other
 
-  if (!Atmosphere->InitModel()) {cerr << "Atmosphere model init failed"; Error+=1;}
-  if (!FCS->InitModel())        {cerr << "FCS model init failed"; Error+=2;}
-  if (!Aircraft->InitModel())   {cerr << "Aircraft model init failed"; Error+=4;}
-  if (!Translation->InitModel()){cerr << "Translation model init failed"; Error+=8;}
-  if (!Rotation->InitModel())   {cerr << "Rotation model init failed"; Error+=16;}
-  if (!Position->InitModel())   {cerr << "Position model init failed"; Error+=32;}
-  if (!Auxiliary->InitModel())  {cerr << "Auxiliary model init failed"; Error+=64;}
-  if (!Output->InitModel())     {cerr << "Output model init failed"; Error+=128;}
-  
-  if(Error > 0) result=false;
-  
+  if (!Atmosphere->InitModel()) {
+    cerr << fgred << "Atmosphere model init failed" << fgdef << endl;
+    Error+=1;}
+  if (!FCS->InitModel())        {
+    cerr << fgred << "FCS model init failed" << fgdef << endl;
+    Error+=2;}
+  if (!Propulsion->InitModel()) {
+    cerr << fgred << "FGPropulsion model init failed" << fgdef << endl;
+    Error+=4;}
+  if (!Aircraft->InitModel())   {
+    cerr << fgred << "Aircraft model init failed" << fgdef << endl;
+    Error+=8;}
+  if (!Translation->InitModel()){
+    cerr << fgred << "Translation model init failed" << fgdef << endl;
+    Error+=16;}
+  if (!Rotation->InitModel())   {
+    cerr << fgred << "Rotation model init failed" << fgdef << endl;
+    Error+=32;}
+  if (!Position->InitModel())   {
+    cerr << fgred << "Position model init failed" << fgdef << endl;
+    Error+=64;}
+  if (!Auxiliary->InitModel())  {
+    cerr << fgred << "Auxiliary model init failed" << fgdef << endl;
+    Error+=128;}
+  if (!Output->InitModel())     {
+    cerr << fgred << "Output model init failed" << fgdef << endl;
+    Error+=256;}
+
+  if (Error > 0) result = false;
+
   // Schedule a model. The second arg (the integer) is the pass number. For
   // instance, the atmosphere model gets executed every fifth pass it is called
   // by the executive. Everything else here gets executed each pass.
 
   Schedule(Atmosphere,  1);
   Schedule(FCS,         1);
+  Schedule(Propulsion,  1);
   Schedule(Aircraft,    1);
   Schedule(Rotation,    1);
   Schedule(Translation, 1);
   Schedule(Position,    1);
   Schedule(Auxiliary,   1);
   Schedule(Output,     1);
-  
+
   modelLoaded = false;
-  return result;
 
+  return result;
 }
 
+//%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+
 bool FGFDMExec::DeAllocate(void) {
+
   if ( Atmosphere != 0 )  delete Atmosphere;
   if ( FCS != 0 )         delete FCS;
+  if ( Propulsion != 0)   delete Propulsion;
   if ( Aircraft != 0 )    delete Aircraft;
   if ( Translation != 0 ) delete Translation;
   if ( Rotation != 0 )    delete Rotation;
@@ -165,6 +250,7 @@ bool FGFDMExec::DeAllocate(void) {
   State       = 0;
   Atmosphere  = 0;
   FCS         = 0;
+  Propulsion  = 0;
   Aircraft    = 0;
   Translation = 0;
   Rotation    = 0;
@@ -173,9 +259,10 @@ bool FGFDMExec::DeAllocate(void) {
   Output      = 0;
 
   modelLoaded = false;
-  
+  return modelLoaded;
 }
 
+//%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 
 int FGFDMExec::Schedule(FGModel* model, int rate)
 {
@@ -201,6 +288,7 @@ int FGFDMExec::Schedule(FGModel* model, int rate)
   return 0;
 }
 
+//%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 
 bool FGFDMExec::Run(void)
 {
@@ -211,8 +299,14 @@ bool FGFDMExec::Run(void)
   model_iterator = FirstModel;
   if (model_iterator == 0L) return false;
 
-  while (!model_iterator->Run())
-  {
+  if (Scripted) {                                              
+    RunScript();
+    if (State->Getsim_time() >= EndTime) return false;
+  }
+
+  if (debug_lvl & 4) cout << "=========================" << endl;
+
+  while (!model_iterator->Run()) {
     model_iterator = model_iterator->NextModel;
     if (model_iterator == 0L) break;
   }
@@ -222,6 +316,7 @@ bool FGFDMExec::Run(void)
   return true;
 }
 
+//%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 
 bool FGFDMExec::RunIC(FGInitialCondition *fgic)
 {
@@ -231,29 +326,305 @@ bool FGFDMExec::RunIC(FGInitialCondition *fgic)
   State->Resume();
   return true;
 }
-  
+
+//%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 
 bool FGFDMExec::LoadModel(string APath, string EPath, string model)
 {
-       bool result=false;
-  if(modelLoaded) {
-     DeAllocate();
-     Allocate();
-  }   
+  bool result = false;
+  
+  if (modelLoaded) {
+    DeAllocate();
+    Allocate();
+  }
+  
   AircraftPath = APath;
-       EnginePath = EPath;
+  EnginePath   = EPath;
   result = Aircraft->LoadAircraft(AircraftPath, EnginePath, model);
 
   if (result) {
     modelLoaded = true;
   } else {
-    cerr << "FGFDMExec: Failed to load aircraft and/or engine model" << endl;
+    cerr << fgred
+         << "FGFDMExec: Failed to load aircraft and/or engine model"
+         << fgdef << endl;
   }
 
+  cout << "\n\nJSBSim startup complete\n\n";
   return result;
 }
 
+//%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+
+bool FGFDMExec::LoadScript(string script)
+{
+  FGConfigFile Script(script);
+  string token="";
+  string aircraft="";
+  string initialize="";
+  bool result=false;
+  float dt=0.0;
+  struct condition *newCondition;
+
+  if (!Script.IsOpen()) return false;
+
+  Script.GetNextConfigLine();
+  ScriptName = Script.GetValue("name");
+  Scripted = true;
+  cout << "Reading Script File " << ScriptName << endl;
+
+  while (Script.GetNextConfigLine() != "EOF" && Script.GetValue() != "/runscript") {
+    token = Script.GetValue();
+    if (token == "use") {
+      if ((token = Script.GetValue("aircraft")) != "") {
+        aircraft = token;
+        cout << "  Use aircraft: " << token << endl;
+      } else if ((token = Script.GetValue("initialize")) != "") {
+        initialize = token;
+        cout << "  Use reset file: " << token << endl;
+      } else {
+        cerr << "Unknown 'use' keyword: \"" << token << "\"" << endl;
+      }
+    } else if (token == "run") {
+      StartTime = strtod(Script.GetValue("start").c_str(), NULL);
+      State->Setsim_time(StartTime);
+      EndTime   = strtod(Script.GetValue("end").c_str(), NULL);
+      dt        = strtod(Script.GetValue("dt").c_str(), NULL);
+      State->Setdt(dt);
+      Script.GetNextConfigLine();
+      token = Script.GetValue();
+      while (token != "/run") {
+
+        if (token == "when") {
+          Script.GetNextConfigLine();
+          token = Script.GetValue();
+          newCondition = new struct condition();
+          while (token != "/when") {
+            if (token == "parameter") {
+              newCondition->TestParam.push_back(State->GetParameterIndex(Script.GetValue("name")));
+              newCondition->TestValue.push_back(strtod(Script.GetValue("value").c_str(), NULL));
+              newCondition->Comparison.push_back(Script.GetValue("comparison"));
+            } else if (token == "set") {
+              newCondition->SetParam.push_back(State->GetParameterIndex(Script.GetValue("name")));
+              newCondition->SetValue.push_back(strtod(Script.GetValue("value").c_str(), NULL));
+              newCondition->Triggered.push_back(false);
+              newCondition->OriginalValue.push_back(0.0);
+              newCondition->newValue.push_back(0.0);
+              newCondition->StartTime.push_back(0.0);
+              newCondition->EndTime.push_back(0.0);
+              string tempCompare = Script.GetValue("type");
+              if      (tempCompare == "FG_DELTA") newCondition->Type.push_back(FG_DELTA);
+              else if (tempCompare == "FG_BOOL")  newCondition->Type.push_back(FG_BOOL);
+              else if (tempCompare == "FG_VALUE") newCondition->Type.push_back(FG_VALUE);
+              else                                newCondition->Type.push_back((eType)0);
+              tempCompare = Script.GetValue("action");
+              if      (tempCompare == "FG_RAMP") newCondition->Action.push_back(FG_RAMP);
+              else if (tempCompare == "FG_STEP") newCondition->Action.push_back(FG_STEP);
+              else if (tempCompare == "FG_EXP")  newCondition->Action.push_back(FG_EXP);
+              else                               newCondition->Action.push_back((eAction)0);
+              
+              if (Script.GetValue("persistent") == "true")
+                newCondition->Persistent.push_back(true);
+              else
+                newCondition->Persistent.push_back(false);
+               
+              newCondition->TC.push_back(strtod(Script.GetValue("tc").c_str(), NULL));
+             
+            } else {
+              cerr << "Unrecognized keyword in script file: \" [when] " << token << "\"" << endl;
+            }
+            Script.GetNextConfigLine();
+            token = Script.GetValue();
+          }
+          Conditions.push_back(*newCondition);
+          Script.GetNextConfigLine();
+          token = Script.GetValue();
+
+        } else {
+          cerr << "Error reading script file: expected \"when\", got \"" << token << "\"" << endl;
+        }
+
+      }
+    } else {
+      cerr << "Unrecognized keyword in script file: \"" << token << "\" [runscript] " << endl;
+    }
+  }
+
+  if (aircraft == "") {
+    cerr << "Aircraft file not loaded in script" << endl;
+    exit(-1);
+  }
+
+  // print out conditions for double-checking
+
+  vector <struct condition>::iterator iterConditions = Conditions.begin();
+
+  int count=0;
+
+  cout << "\n  Script goes from " << StartTime << " to " << EndTime
+       << " with dt = " << dt << endl << endl;
+
+  while (iterConditions < Conditions.end()) {
+    cout << "  Condition: " << count++ << endl;
+    cout << "    if (";
+
+    for (int i=0; i<iterConditions->TestValue.size(); i++) {
+      if (i>0) cout << " and" << endl << "        ";
+      cout << "(" << State->paramdef[iterConditions->TestParam[i]]
+                  << iterConditions->Comparison[i] << " "
+                  << iterConditions->TestValue[i] << ")";
+    }
+    cout << ") then {" << endl;
+
+    for (int i=0; i<iterConditions->SetValue.size(); i++) {
+      cout << "      set" << State->paramdef[iterConditions->SetParam[i]]
+           << "to " << iterConditions->SetValue[i];
+
+      switch (iterConditions->Type[i]) {
+      case FG_VALUE:
+        cout << " (constant";
+        break;
+      case FG_DELTA:
+        cout << " (delta";
+        break;
+      case FG_BOOL:
+        cout << " (boolean";
+        break;
+      default:
+        cout << " (unspecified type";
+      }
+
+      switch (iterConditions->Action[i]) {
+      case FG_RAMP:
+        cout << " via ramp";
+        break;
+      case FG_STEP:
+        cout << " via step";
+        break;
+      case FG_EXP:
+        cout << " via exponential approach";
+        break;
+      default:
+        cout << " via unspecified action";
+      }
+
+      if (!iterConditions->Persistent[i]) cout << endl
+                         << "                              once";
+      else cout << endl
+                         << "                              repeatedly";
+
+      if (iterConditions->Action[i] == FG_RAMP ||
+          iterConditions->Action[i] == FG_EXP) cout << endl
+                         << "                              with time constant "
+                         << iterConditions->TC[i];
+    }
+    cout << ")" << endl << "    }" << endl << endl;
+
+    iterConditions++;
+  }
+
+  cout << endl;
+
+  result = LoadModel("aircraft", "engine", aircraft);
+  if (!result) {
+    cerr << "Aircraft file " << aircraft << " was not found" << endl;
+         exit(-1);
+  }
+  if ( ! State->Reset("aircraft", aircraft, initialize))
+                 State->Initialize(2000,0,0,0,0,0,0.5,0.5,40000);
+
+  return true;
+}
+
+//%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 
-bool FGFDMExec::RunScript(string script)
+void FGFDMExec::RunScript(void)
 {
+  vector <struct condition>::iterator iC = Conditions.begin();
+  bool truth;
+  bool WholeTruth;
+
+  int count=0;
+
+  float currentTime = State->Getsim_time();
+  float newSetValue;
+
+  while (iC < Conditions.end()) {
+    // determine whether the set of conditional tests for this condition equate
+    // to true
+    for (int i=0; i<iC->TestValue.size(); i++) {
+           if (iC->Comparison[i] == "lt")
+              truth = State->GetParameter(iC->TestParam[i]) <  iC->TestValue[i];
+      else if (iC->Comparison[i] == "le")
+              truth = State->GetParameter(iC->TestParam[i]) <= iC->TestValue[i];
+      else if (iC->Comparison[i] == "eq")
+              truth = State->GetParameter(iC->TestParam[i]) == iC->TestValue[i];
+      else if (iC->Comparison[i] == "ge")
+              truth = State->GetParameter(iC->TestParam[i]) >= iC->TestValue[i];
+      else if (iC->Comparison[i] == "gt")
+              truth = State->GetParameter(iC->TestParam[i]) >  iC->TestValue[i];
+      else if (iC->Comparison[i] == "ne")
+              truth = State->GetParameter(iC->TestParam[i]) != iC->TestValue[i];
+      else
+              cerr << "Bad comparison" << endl;
+
+      if (i == 0) WholeTruth = truth;
+      else        WholeTruth = WholeTruth && truth;
+
+      if (!truth && iC->Persistent[i] && iC->Triggered[i]) iC->Triggered[i] = false;
+    }
+
+    // if the conditions are true, do the setting of the desired parameters
+
+    if (WholeTruth) {
+      for (int i=0; i<iC->SetValue.size(); i++) {
+        if ( ! iC->Triggered[i]) {
+          iC->OriginalValue[i] = State->GetParameter(iC->SetParam[i]);
+          switch (iC->Type[i]) {
+          case FG_VALUE:
+            iC->newValue[i] = iC->SetValue[i];
+            break;
+          case FG_DELTA:
+            iC->newValue[i] = iC->OriginalValue[i] + iC->SetValue[i];
+            break;
+          case FG_BOOL:
+            break;
+          default:
+            cerr << "Invalid Type specified" << endl;
+            break;
+          }
+          iC->Triggered[i] = true;
+          iC->StartTime[i] = currentTime;
+        }
+
+        switch (iC->Action[i]) {
+        case FG_RAMP:
+          newSetValue = (currentTime - iC->StartTime[i])/(iC->TC[i])
+                      * (iC->newValue[i] - iC->OriginalValue[i]) + iC->OriginalValue[i];
+          if (newSetValue > iC->newValue[i]) newSetValue = iC->newValue[i];
+          break;
+        case FG_STEP:
+          newSetValue = iC->newValue[i];
+          break;
+        case FG_EXP:
+          newSetValue = (1 - exp(-(currentTime - iC->StartTime[i])/(iC->TC[i])))
+              * (iC->newValue[i] - iC->OriginalValue[i]) + iC->OriginalValue[i];
+          break;
+        default:
+          cerr << "Invalid Action specified" << endl;
+          break;
+        }
+        State->SetParameter(iC->SetParam[i], newSetValue);
+      }
+    }
+    iC++;
+  }
 }
+
+//%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+
+void FGFDMExec::Debug(void)
+{
+    //TODO: Add your source code here
+}
+
index 7d36c4027174ee4d907abe0cd42a5ec834f65bb6..046b2403f0a367697c787e6b56bed3598145f1f9 100644 (file)
-/*%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
-
- Header:       FGFDMExec.h
- Author:       Jon Berndt
- Date started: 11/17/98
-
- ------------- Copyright (C) 1999  Jon S. Berndt (jsb@hal-pc.org) -------------
-
- This program is free software; you can redistribute it and/or modify it under
- the terms of the GNU General Public License as published by the Free Software
- Foundation; either version 2 of the License, or (at your option) any later
- version.
-
- This program is distributed in the hope that it will be useful, but WITHOUT
- ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
- FOR A PARTICULAR PURPOSE.  See the GNU General Public License for more
- details.
-
- You should have received a copy of the GNU General Public License along with
- this program; if not, write to the Free Software Foundation, Inc., 59 Temple
- Place - Suite 330, Boston, MA  02111-1307, USA.
-
- Further information about the GNU General Public License can also be found on
- the world wide web at http://www.gnu.org.
-
-HISTORY
---------------------------------------------------------------------------------
-11/17/98   JSB   Created
-7/31/99     TP   Added RunIC function that runs the sim so that every frame
-                 begins with the IC values from the given FGInitialCondition 
-                                  object and dt=0. 
-
-%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
-SENTRY
-%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%*/
-
-#ifndef FGFDMEXEC_HEADER_H
-#define FGFDMEXEC_HEADER_H
-
-/*%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
-INCLUDES
-%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%*/
-
-#define ID_FDMEXEC "$Header"
-
-#include "FGModel.h"
-#include "FGInitialCondition.h"
-
-/*%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
-CLASS DECLARATION
-%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%*/
-
-class FGState;
-class FGAtmosphere;
-class FGFCS;
-class FGAircraft;
-class FGTranslation;
-class FGRotation;
-class FGPosition;
-class FGAuxiliary;
-class FGOutput;
-class FGInitialCondition;
-
-class FGFDMExec
-{
-public:
-  FGFDMExec(void);
-  ~FGFDMExec(void);
-
-  FGModel* FirstModel;
-
-  bool Initialize(void);
-  int  Schedule(FGModel* model, int rate);
-  bool Run(void);
-  bool RunIC(FGInitialCondition *fgic);
-  void Freeze(void) {frozen = true;}
-  void Resume(void) {frozen = false;}
-
-  bool SetEnginePath(string path)   {EnginePath = path;}
-  bool SetAircraftPath(string path) {AircraftPath = path;}
-  bool SetScriptPath(string path)   {ScriptPath = path;}
-
-  bool LoadModel(string AircraftPath, string EnginePath, string model);
-  bool RunScript(string script);
-
-  inline FGState* GetState(void)             {return State;}
-  inline FGAtmosphere* GetAtmosphere(void)   {return Atmosphere;}
-  inline FGFCS* GetFCS(void)                 {return FCS;}
-  inline FGAircraft* GetAircraft(void)       {return Aircraft;}
-  inline FGTranslation* GetTranslation(void) {return Translation;}
-  inline FGRotation* GetRotation(void)       {return Rotation;}
-  inline FGPosition* GetPosition(void)       {return Position;}
-  inline FGAuxiliary* GetAuxiliary(void)     {return Auxiliary;}
-  inline FGOutput* GetOutput(void)           {return Output;}
-  inline string GetEnginePath(void)          {return EnginePath;}
-  inline string GetAircraftPath(void)        {return AircraftPath;}
-
-private:
-  bool frozen;
-  bool terminate;
-  int Error;
-  bool modelLoaded;
-
-  string AircraftPath;
-  string EnginePath;
-  string ScriptPath;
-
-  FGState*       State;
-  FGAtmosphere*  Atmosphere;
-  FGFCS*         FCS;
-  FGAircraft*    Aircraft;
-  FGTranslation* Translation;
-  FGRotation*    Rotation;
-  FGPosition*    Position;
-  FGAuxiliary*   Auxiliary;
-  FGOutput*      Output;
-  
-  bool Allocate(void);
-  bool DeAllocate(void);
-
-protected:
-};
-
-//%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
-#endif
+/*%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%\r
+ Header:       FGFDMExec.h\r
+ Author:       Jon Berndt\r
+ Date started: 11/17/98\r
+\r
+ ------------- Copyright (C) 1999  Jon S. Berndt (jsb@hal-pc.org) -------------\r
+\r
+ This program is free software; you can redistribute it and/or modify it under\r
+ the terms of the GNU General Public License as published by the Free Software\r
+ Foundation; either version 2 of the License, or (at your option) any later\r
+ version.\r
+\r
+ This program is distributed in the hope that it will be useful, but WITHOUT\r
+ ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS\r
+ FOR A PARTICULAR PURPOSE.  See the GNU General Public License for more\r
+ details.\r
+\r
+ You should have received a copy of the GNU General Public License along with\r
+ this program; if not, write to the Free Software Foundation, Inc., 59 Temple\r
+ Place - Suite 330, Boston, MA  02111-1307, USA.\r
+\r
+ Further information about the GNU General Public License can also be found on\r
+ the world wide web at http://www.gnu.org.\r
+\r
+HISTORY\r
+--------------------------------------------------------------------------------\r
+11/17/98   JSB   Created\r
+7/31/99     TP   Added RunIC function that runs the sim so that every frame\r
+                 begins with the IC values from the given FGInitialCondition\r
+                                  object and dt=0.\r
+\r
+%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%\r
+SENTRY\r
+%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%*/\r
+\r
+#ifndef FGFDMEXEC_HEADER_H\r
+#define FGFDMEXEC_HEADER_H\r
+\r
+/*%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%\r
+INCLUDES\r
+%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%*/\r
+\r
+#ifdef FGFS\r
+#  include <simgear/compiler.h>\r
+#  ifdef FG_HAVE_STD_INCLUDES\r
+#    include <vector>\r
+#  else\r
+#    include <vector.h>\r
+#  endif\r
+#else\r
+#  include <vector>\r
+#endif\r
+\r
+#include "FGModel.h"\r
+#include "FGInitialCondition.h"\r
+\r
+/*%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%\r
+DEFINITIONS\r
+%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%*/\r
+\r
+#define ID_FDMEXEC "$Id$"\r
+\r
+/*%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%\r
+FORWARD DECLARATIONS\r
+%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%*/\r
+\r
+class FGState;\r
+class FGAtmosphere;\r
+class FGFCS;\r
+class FGPropulsion;\r
+class FGAircraft;\r
+class FGTranslation;\r
+class FGRotation;\r
+class FGPosition;\r
+class FGAuxiliary;\r
+class FGOutput;\r
+class FGInitialCondition;\r
+\r
+struct condition {\r
+  vector <eParam>  TestParam;\r
+  vector <eParam>  SetParam;\r
+  vector <float>   TestValue;\r
+  vector <float>   SetValue;\r
+  vector <string>  Comparison;\r
+  vector <float>   TC;\r
+  vector <bool>    Persistent;\r
+  vector <eAction> Action;\r
+  vector <eType>   Type;\r
+  vector <bool>    Triggered;\r
+  vector <float>   newValue;\r
+  vector <float>   OriginalValue;\r
+  vector <float>   StartTime;\r
+  vector <float>   EndTime;\r
+\r
+  condition() {\r
+  }\r
+};\r
+\r
+/*%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%\r
+COMMENTS, REFERENCES, and NOTES [use "class documentation" below for API docs]\r
+%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%*/\r
+\r
+/*%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%\r
+CLASS DOCUMENTATION\r
+%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%*/\r
+\r
+/** Encapsulates the JSBSim simulation executive.\r
+    @author Jon S. Berndt\r
+    @version $Id$\r
+\r
+    @doc This class is the interface class through which all other simulation classes\r
+    are instantiated, initialized, and run. When integrated with FlightGear (or\r
+    other flight simulator) this class is typically instantiated by an interface\r
+    class on the simulator side.\r
+\r
+    <h4>Scripting support provided in the Executive</h4>\r
+\r
+    <p>There is simple scripting support provided in the FGFDMExec\r
+    class. Commands are specified using the <u>Simple Scripting\r
+    Directives for JSBSim</u> (SSDJ). The script file is in XML\r
+    format. A test condition (or conditions) can be set up in the\r
+    script and when the condition evaluates to true, the specified\r
+    action[s] is/are taken. A test condition can be <em>persistent</em>,\r
+    meaning that if a test condition evaluates to true, then passes\r
+    and evaluates to false, the condition is reset and may again be\r
+    triggered. When the set of tests evaluates to true for a given\r
+    condition, an item may be set to another value. This value might\r
+    be a boolean, a value, or a delta value, and the change from the\r
+    current value to the new value can be either via a step function,\r
+    a ramp, or an exponential approach. The speed of a ramp or\r
+    approach is specified via the time constant. Here is the format\r
+    of the script file:</p>\r
+\r
+    <pre><strong>&lt;?xml version=&quot;1.0&quot;?&gt;\r
+    &lt;runscript name=&quot;C172-01A&quot;&gt;\r
+\r
+    &lt;!--\r
+    This run is for testing C172 runs\r
+    --&gt;\r
+\r
+    &lt;use aircraft=&quot;c172&quot;&gt;\r
+    &lt;use initialize=&quot;reset00&quot;&gt;\r
+\r
+    &lt;run start=&quot;0.0&quot; end=&quot;4.5&quot; dt=&quot;0.05&quot;&gt;\r
+      &lt;when&gt;\r
+        &lt;parameter name=&quot;FG_TIME&quot; comparison=&quot;ge&quot; value=&quot;0.25&quot;&gt;\r
+        &lt;parameter name=&quot;FG_TIME&quot; comparison=&quot;le&quot; value=&quot;0.50&quot;&gt;\r
+        &lt;set name=&quot;FG_AILERON_CMD&quot; type=&quot;FG_VALUE&quot; value=&quot;0.25&quot;\r
+        action=&quot;FG_STEP&quot; persistent=&quot;false&quot; tc =&quot;0.25&quot;&gt;\r
+      &lt;/when&gt;\r
+      &lt;when&gt;\r
+        &lt;parameter name=&quot;FG_TIME&quot; comparison=&quot;ge&quot; value=&quot;0.5&quot;&gt;\r
+        &lt;parameter name=&quot;FG_TIME&quot; comparison=&quot;le&quot; value=&quot;1.5&quot;&gt;\r
+        &lt;set name=&quot;FG_AILERON_CMD&quot; type=&quot;FG_DELTA&quot; value=&quot;0.5&quot;\r
+        action=&quot;FG_EXP&quot; persistent=&quot;false&quot; tc =&quot;0.5&quot;&gt;\r
+      &lt;/when&gt;\r
+      &lt;when&gt;\r
+        &lt;parameter name=&quot;FG_TIME&quot; comparison=&quot;ge&quot; value=&quot;1.5&quot;&gt;\r
+        &lt;parameter name=&quot;FG_TIME&quot; comparison=&quot;le&quot; value=&quot;2.5&quot;&gt;\r
+        &lt;set name=&quot;FG_RUDDER_CMD&quot; type=&quot;FG_DELTA&quot; value=&quot;0.5&quot;\r
+        action=&quot;FG_RAMP&quot; persistent=&quot;false&quot; tc =&quot;0.5&quot;&gt;\r
+      &lt;/when&gt;\r
+    &lt;/run&gt;\r
+\r
+    &lt;/runscript&gt;</strong></pre>\r
+\r
+    <p>The first line must always be present. The second line\r
+    identifies this file as a script file, and gives a descriptive\r
+    name to the script file. Comments are next, delineated by the\r
+    &lt;!-- and --&gt; symbols. The aircraft and initialization files\r
+    to be used are specified in the &quot;use&quot; lines. Next,\r
+    comes the &quot;run&quot; section, where the conditions are\r
+    described in &quot;when&quot; clauses.</p>\r
+\r
+    <h4>JSBSim Debugging Directives</h4>\r
+\r
+    This describes to any interested entity the debug level\r
+    requested by setting the JSBSIM_DEBUG environment variable.\r
+    The bitmasked value choices are as follows:<ol>\r
+    <li><b>unset</b>: In this case (the default) JSBSim would only print\r
+       out the normally expected messages, essentially echoing\r
+       the config files as they are read. If the environment\r
+       variable is not set, debug_lvl is set to 1 internally</li>\r
+    <li><b>0</b>: This requests JSBSim not to output any messages\r
+       whatsoever.</li>\r
+    <li><b>1</b>: This value explicity requests the normal JSBSim\r
+       startup messages</li>\r
+    <li><b>2</b>: This value asks for a message to be printed out when\r
+       a class is instantiated</li>\r
+    <li><b>4</b>: When this value is set, a message is displayed when a\r
+       FGModel object executes its Run() method</li>\r
+    <li><b>8</b>: When this value is set, various runtime state variables\r
+       are printed out periodically</li>\r
+    </ol>\r
+\r
+*/\r
+\r
+/*%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%\r
+CLASS DECLARATION\r
+%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%*/\r
+\r
+class FGFDMExec\r
+{\r
+public:\r
+  /// Default constructor\r
+  FGFDMExec(void);\r
+\r
+  /// Default destructor\r
+  ~FGFDMExec();\r
+\r
+  /** This routine places a model into the runlist at the specified rate. The\r
+      "rate" is not really a clock rate. It represents how many calls to the\r
+      FGFDMExec::Run() method must be made before the model is executed. A\r
+      value of 1 means that the model will be executed for each call to the\r
+      exec's Run() method. A value of 5 means that the model will only be\r
+      executed every 5th call to the exec's Run() method.\r
+      @param model A pointer to the model being scheduled.\r
+      @param rate The rate at which to execute the model as described above.\r
+      @return Currently returns 0 always. */\r
+  int  Schedule(FGModel* model, int rate);\r
+\r
+  /** This executes each scheduled model in succession, as well as running any\r
+      scripts which are loaded.\r
+      @return true if successful, false if sim should be ended  */\r
+  bool Run(void);\r
+\r
+  /** Initializes the sim with a set of initial conditions.\r
+      @param fgic A pointer to a filled out initial conditions class which\r
+      describes the desired initial conditions.\r
+      @return true if successful\r
+       */\r
+  bool RunIC(FGInitialCondition *fgic);\r
+\r
+  /// Freezes the sim\r
+  void Freeze(void) {frozen = true;}\r
+\r
+  /// Resumes the sim\r
+  void Resume(void) {frozen = false;}\r
+\r
+  /** Loads an aircraft model.\r
+      @param AircraftPath path to the aircraft directory. For instance:\r
+      "aircraft". Under aircraft, then, would be directories for various\r
+      modeled aircraft such as C172/, x15/, etc.\r
+      @param EnginePath path to the directory under which engine config\r
+      files are kept, for instance "engine"\r
+      @param model the name of the aircraft model itself. This file will\r
+      be looked for in the directory specified in the AircraftPath variable,\r
+      and in turn under the directory with the same name as the model. For\r
+      instance: "aircraft/x15/x15.xml"\r
+      @return true if successful*/\r
+  bool LoadModel(string AircraftPath, string EnginePath, string model);\r
+\r
+  /** Loads a script to drive JSBSim (usually in standalone mode).\r
+      The language is the Simple Script Directives for JSBSim (SSDJ).\r
+      @param script the filename (including path name, if any) for the script.\r
+      @return true if successful */\r
+  bool LoadScript(string script);\r
+\r
+  /** This function is called each pass through the executive Run() method IF\r
+      scripting is enabled. */\r
+  void RunScript(void);\r
+\r
+  bool SetEnginePath(string path)   {EnginePath = path; return true;}\r
+  bool SetAircraftPath(string path) {AircraftPath = path; return true;}\r
+  bool SetScriptPath(string path)   {ScriptPath = path; return true;}\r
+\r
+  /// @name Top-level executive State and Model retrieval mechanism\r
+  //@{\r
+  /// Returns the FGState pointer.\r
+  inline FGState* GetState(void)              {return State;}\r
+  /// Returns the FGAtmosphere pointer.\r
+  inline FGAtmosphere* GetAtmosphere(void)    {return Atmosphere;}\r
+  /// Returns the FGFCS pointer.\r
+  inline FGFCS* GetFCS(void)                  {return FCS;}\r
+  /// Returns the FGPropulsion pointer.\r
+  inline FGPropulsion* GetPropulsion(void)    {return Propulsion;}\r
+  /// Returns the FGAircraft pointer.\r
+  inline FGAircraft* GetAircraft(void)        {return Aircraft;}\r
+  /// Returns the FGTranslation pointer.\r
+  inline FGTranslation* GetTranslation(void)  {return Translation;}\r
+  /// Returns the FGRotation pointer.\r
+  inline FGRotation* GetRotation(void)        {return Rotation;}\r
+  /// Returns the FGPosition pointer.\r
+  inline FGPosition* GetPosition(void)        {return Position;}\r
+  /// Returns the FGAuxiliary pointer.\r
+  inline FGAuxiliary* GetAuxiliary(void)      {return Auxiliary;}\r
+  /// Returns the FGOutput pointer.\r
+  inline FGOutput* GetOutput(void)            {return Output;}\r
+  //@}\r
+\r
+  /// Retrieves the engine path.\r
+  inline string GetEnginePath(void)          {return EnginePath;}\r
+  /// Retrieves the aircraft path.\r
+  inline string GetAircraftPath(void)        {return AircraftPath;}\r
+\r
+private:\r
+  FGModel* FirstModel;\r
+\r
+  bool frozen;\r
+  bool terminate;\r
+  int  Error;\r
+  bool modelLoaded;\r
+  bool Scripted;\r
+\r
+  string AircraftPath;\r
+  string EnginePath;\r
+  string ScriptPath;\r
+  string ScriptName;\r
+  float  StartTime;\r
+  float  EndTime;\r
+  vector <struct condition> Conditions;\r
+\r
+  FGState*       State;\r
+  FGAtmosphere*  Atmosphere;\r
+  FGFCS*         FCS;\r
+  FGPropulsion*  Propulsion;\r
+  FGAircraft*    Aircraft;\r
+  FGTranslation* Translation;\r
+  FGRotation*    Rotation;\r
+  FGPosition*    Position;\r
+  FGAuxiliary*   Auxiliary;\r
+  FGOutput*      Output;\r
+\r
+  bool Allocate(void);\r
+  bool DeAllocate(void);\r
+  void Debug(void);\r
+};\r
+\r
+//%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%\r
+#endif\r
+\r
index c73edd805e5eb058daafb4dfd1d343aa01ac50ab..903bbeea62f0deaf1f02b48b726dcc91aa0ef281 100644 (file)
@@ -1,43 +1,43 @@
 /*%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+
  Source:       FGForce.cpp
  Author:       Tony Peden
  Date started: 6/10/00
+
  ------------- Copyright (C) 1999  Anthony K. Peden (apeden@earthlink.net) -------------
+
  This program is free software; you can redistribute it and/or modify it under
  the terms of the GNU General Public License as published by the Free Software
  Foundation; either version 2 of the License, or (at your option) any later
  version.
+
  This program is distributed in the hope that it will be useful, but WITHOUT
  ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
  FOR A PARTICULAR PURPOSE.  See the GNU General Public License for more
  details.
+
  You should have received a copy of the GNU General Public License along with
  this program; if not, write to the Free Software Foundation, Inc., 59 Temple
  Place - Suite 330, Boston, MA  02111-1307, USA.
+
  Further information about the GNU General Public License can also be found on
  the world wide web at http://www.gnu.org.
+
+
  HISTORY
 --------------------------------------------------------------------------------
 6/10/00  TP   Created
+
+
 FUNCTIONAL DESCRIPTION
 --------------------------------------------------------------------------------
+
 The purpose of this class is to provide storage for computed forces and
-encapsulate all the functionality associated with transforming those 
+encapsulate all the functionality associated with transforming those
 forces from their native coord system to the body system.  This includes
 computing the moments due to the difference between the point of application
 and the cg.
+
 */
 
 #include "FGFDMExec.h"
@@ -47,32 +47,43 @@ and the cg.
 #include "FGDefs.h"
 #include "FGForce.h"
 
-static const char *IdSrc = "$Header$";
+static const char *IdSrc = "$Id$";
 static const char *IdHdr = "ID_FORCE";
 
+extern short debug_lvl;
+
+//%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+
 FGForce::FGForce(FGFDMExec *FDMExec) :
     vFn(3),
     vMn(3),
+    fdmex(FDMExec),
     vFb(3),
     vM(3),
     vXYZn(3),
     vDXYZ(3),
     mT(3,3),
     vSense(3),
-    fdmex(FDMExec),
-    ttype(tNone) 
+    ttype(tNone)
 {
   mT(1,1)=1; //identity matrix
   mT(2,2)=1;
   mT(3,3)=1;
   vSense.InitMatrix(1);
+  if (debug_lvl & 2) cout << "Instantiated: FGForce" << endl;
 }
 
-FGForce::~FGForce(void) {}
+//%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+
+FGForce::~FGForce()
+{
+  if (debug_lvl & 2) cout << "Destroyed:    FGForce" << endl;
+}
+
+//%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 
 FGColumnVector FGForce::GetBodyForces(void) {
-  
-  
+
   vFb=Transform()*(vFn.multElementWise(vSense));
 
   //find the distance from this vector's location to the cg
@@ -82,11 +93,11 @@ FGColumnVector FGForce::GetBodyForces(void) {
   vDXYZ(3) = -(vXYZn(3) - fdmex->GetAircraft()->GetXYZcg()(3))*INCHTOFT;
 
   vM=vMn +vDXYZ*vFb;
-  
+
   return vFb;
 }
 
-
+//%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 
 FGMatrix FGForce::Transform(void) {
   switch(ttype) {
@@ -95,15 +106,17 @@ FGMatrix FGForce::Transform(void) {
   case tLocalBody:
     return fdmex->GetState()->GetTl2b();
   case tCustom:
-    
+
   case tNone:
-    return mT; 
+    return mT;
   default:
     cout << "Unrecognized tranform requested from FGForce::Transform()" << endl;
     exit(1);
   }
 }
 
+//%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+
 void FGForce::SetAnglesToBody(float broll, float bpitch, float byaw) {
 
   if(ttype == tCustom) {
@@ -128,4 +141,10 @@ void FGForce::SetAnglesToBody(float broll, float bpitch, float byaw) {
 
 }
 
+//%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+
+void FGForce::Debug(void)
+{
+    //TODO: Add your source code here
+}
 
index 6a765876f3236e13d42d16c63ca89c8a86748bb4..5046496c7b4e9f8274a842121afa6458358f954d 100644 (file)
@@ -57,7 +57,7 @@ SENTRY
 INCLUDES
 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%*/
 
-#define ID_FORCE "$Header"
+#define ID_FORCE "$Id$"
 
 #include "FGFDMExec.h"
 #include "FGMatrix.h"
@@ -66,14 +66,15 @@ INCLUDES
 CLASS DECLARATION
 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%*/
 
-typedef enum { tNone, tWindBody, tLocalBody, tCustom } TransformType;
 
 class FGForce {
 
 public:
 
   FGForce(FGFDMExec *FDMExec);
-  ~FGForce(void);
+  ~FGForce();
+
+  enum TransformType { tNone, tWindBody, tLocalBody, tCustom } ttype;
 
   inline void SetNativeForces(float Fnx, float Fny, float Fnz) {
     vFn(1)=Fnx;
@@ -130,6 +131,8 @@ public:
 protected:
   FGColumnVector vFn;
   FGColumnVector vMn;
+  FGFDMExec *fdmex;
+  void Debug(void);
 
 private:
   FGColumnVector vFb;
@@ -139,10 +142,6 @@ private:
   FGColumnVector vSense;
 
   FGMatrix mT;
-
-  FGFDMExec *fdmex;
-  TransformType ttype;
-
 };
 
 #endif
index 69520b6eadcad48b79a463595a219bd6a3951e78..f215f247eafca87a2a2653a90ed9c5712c10144a 100644 (file)
@@ -37,9 +37,11 @@ INCLUDES
 
 #include "FGGroundReactions.h"
 
-static const char *IdSrc = "$Header$";
+static const char *IdSrc = "$Id$";
 static const char *IdHdr = ID_GROUNDREACTIONS;
 
+extern short debug_lvl;
+
 /*%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 CLASS IMPLEMENTATION
 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%*/
@@ -47,9 +49,10 @@ CLASS IMPLEMENTATION
 
 FGGroundReactions::FGGroundReactions(FGFDMExec* fgex) : FGModel(fgex)
 {
-
+  if (debug_lvl & 2) cout << "Instantiated: FGGroundReactions" << endl;
 }
 
+//%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 
 bool FGGroundReactions:: Run(void) {
 
@@ -61,8 +64,17 @@ bool FGGroundReactions:: Run(void) {
   }
 }
 
+//%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+
 bool FGGroundReactions::LoadGroundReactions(FGConfigFile* AC_cfg)
 {
 //
 }
 
+//%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+
+void FGGroundReactions::Debug(void)
+{
+    //TODO: Add your source code here
+}
+
index 8d53309ade0a1172e02ed021f83de35ff7eb4cd2..29cafc5745dc809f32993318135135e156d86063 100644 (file)
@@ -44,7 +44,7 @@ INCLUDES
 
 #ifdef FGFS
 #  include <simgear/compiler.h>
-#  ifdef SG_HAVE_STD_INCLUDES
+#  ifdef FG_HAVE_STD_INCLUDES
 #    include <vector>
 #  else
 #    include <vector.h>
@@ -56,7 +56,7 @@ INCLUDES
 #include "FGModel.h"
 #include "FGConfigFile.h"
 
-#define ID_GROUNDREACTIONS "$Header"
+#define ID_GROUNDREACTIONS "$Id$"
 
 /*%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 CLASS DECLARATION
@@ -66,10 +66,13 @@ class FGGroundReactions : public FGModel {
 
 public:
   FGGroundReactions(FGFDMExec*);
-  ~FGGroundReactions(void);
+  ~FGGroundReactions();
 
   bool Run(void);
   bool LoadGroundReactions(FGConfigFile* AC_cfg);
+
+private:
+  void Debug(void);
 };
 
 //%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
index e72aa64ed334d562cee0b08e388afb31f9b6e7c2..026c9ca6bb7f8c788d3a2b10003f4d75754679d3 100644 (file)
@@ -37,9 +37,11 @@ INCLUDES
 
 #include "FGInertial.h"
 
-static const char *IdSrc = "$Header$";
+static const char *IdSrc = "$Id$";
 static const char *IdHdr = ID_INERTIAL;
 
+extern short debug_lvl;
+
 /*%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 CLASS IMPLEMENTATION
 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%*/
@@ -47,9 +49,10 @@ CLASS IMPLEMENTATION
 
 FGInertial::FGInertial(FGFDMExec* fgex) : FGModel(fgex)
 {
-
+  if (debug_lvl & 2) cout << "Instantiated: FGInertial" << endl;
 }
 
+//%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 
 bool FGInertial:: Run(void) {
 
@@ -61,8 +64,17 @@ bool FGInertial:: Run(void) {
   }
 }
 
+//%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+
 bool FGInertial::LoadInertial(FGConfigFile* AC_cfg)
 {
 //
 }
 
+//%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+
+void FGInertial::Debug(void)
+{
+    //TODO: Add your source code here
+}
+
index d025b6e08134f0d5a170fd0564f6bfb697c6cfe4..d24d17ca8284643570ec07d32b1035ba0f40e4c4 100644 (file)
@@ -44,7 +44,7 @@ INCLUDES
 
 #ifdef FGFS
 #  include <simgear/compiler.h>
-#  ifdef SG_HAVE_STD_INCLUDES
+#  ifdef FG_HAVE_STD_INCLUDES
 #    include <vector>
 #  else
 #    include <vector.h>
@@ -56,19 +56,18 @@ INCLUDES
 #include "FGModel.h"
 #include "FGConfigFile.h"
 
-#define ID_INERTIAL "$Header"
+#define ID_INERTIAL "$Id$"
 
 /*%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 CLASS DECLARATION
 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%*/
 
-const char *Id_Inertial = "JSBSim $Header$";
 
 class FGInertial : public FGModel {
 
 public:
   FGInertial(FGFDMExec*);
-  ~FGInertial(void);
+  ~FGInertial();
 
   bool Run(void);
   bool LoadInertial(FGConfigFile* AC_cfg);
index 14ea2ae0cb086fe5a31395655ce3938f1c758cb3..2982bc970f67315a390e3f9ded8a1f14dbdba571 100644 (file)
@@ -55,23 +55,32 @@ INCLUDES
 #include "FGOutput.h"
 #include "FGDefs.h"
 
-static const char *IdSrc = "$Header$";
+static const char *IdSrc = "$Id$";
 static const char *IdHdr = ID_INITIALCONDITION;
 
+extern short debug_lvl;
 
-FGInitialCondition::FGInitialCondition(FGFDMExec *FDMExec) {
-  vt=vc=ve=0;
+//******************************************************************************
+
+FGInitialCondition::FGInitialCondition(FGFDMExec *FDMExec){
+
+  vt=vc=ve=vg=0;
   mach=0;
   alpha=beta=gamma=0;
   theta=phi=psi=0;
   altitude=hdot=0;
   latitude=longitude=0;
-  u=v=w=0;  
+  u=v=w=0;
+  vw=vw=ww=0;
   vnorth=veast=vdown=0;
   lastSpeedSet=setvt;
   sea_level_radius = EARTHRAD;
   radius_to_vehicle = EARTHRAD;
   terrain_altitude = 0;
+
+  salpha=sbeta=stheta=sphi=spsi=sgamma=0;
+  calpha=cbeta=ctheta=cphi=cpsi=cgamma=1;
+
   if(FDMExec != NULL ) {
     fdmex=FDMExec;
     fdmex->GetPosition()->Seth(altitude);
@@ -80,11 +89,17 @@ FGInitialCondition::FGInitialCondition(FGFDMExec *FDMExec) {
     cout << "FGInitialCondition: This class requires a pointer to a valid FGFDMExec object" << endl;
   }
 
+  if (debug_lvl & 2) cout << "Instantiated: FGInitialCondition" << endl;
 }
 
+//******************************************************************************
 
-FGInitialCondition::~FGInitialCondition(void) {}
+FGInitialCondition::~FGInitialCondition()
+{
+  if (debug_lvl & 2) cout << "Destroyed:    FGInitialCondition" << endl;
+}
 
+//******************************************************************************
 
 void FGInitialCondition::SetVcalibratedKtsIC(float tt) {
 
@@ -102,6 +117,8 @@ void FGInitialCondition::SetVcalibratedKtsIC(float tt) {
   }
 }
 
+//******************************************************************************
+
 void FGInitialCondition::SetVequivalentKtsIC(float tt) {
   ve=tt*jsbKTSTOFPS;
   lastSpeedSet=setve;
@@ -110,6 +127,37 @@ void FGInitialCondition::SetVequivalentKtsIC(float tt) {
   vc=calcVcas(mach);
 }
 
+//******************************************************************************
+
+void FGInitialCondition::SetVgroundFpsIC(float tt) {
+  //float ua,va,wa;
+  float vxz;
+
+  //cout << "FGInitialCondition::SetVgroundFpsIC" << endl;
+  vg=tt;
+  lastSpeedSet=setvg;
+  vnorth = vg*cos(psi); veast = vg*sin(psi); vdown = 0;
+  calcUVWfromNED();
+  //cout << "\tu,v,w: " << u << ", " << v << ", " << w << endl;
+  calcWindUVW();
+  //cout << "\tuw,vw,ww: " << uw << ", " << vw << ", " << ww << endl;
+  u = -uw; v = -vw; w = -ww;
+  //ua = u - uw; va = v - vw; wa = w - ww;
+  //cout << "\tua,va,wa: " << ua << ", " << va << ", " << wa << endl;
+  vt = sqrt( u*u + v*v + w*w );
+  alpha = beta = 0;
+  vxz = sqrt( u*u + w*w );
+  if( w != 0 ) alpha = atan2( w, u );
+  if( vxz != 0 ) beta = atan2( v, vxz );
+  //cout << "\tvt,alpha,beta: " << vt << ", " << alpha*RADTODEG << ", "
+  //          << beta*RADTODEG << endl;
+  mach=vt/fdmex->GetAtmosphere()->GetSoundSpeed();
+  vc=calcVcas(mach);
+  ve=vt*sqrt(fdmex->GetAtmosphere()->GetDensityRatio());
+}
+
+//******************************************************************************
+
 void FGInitialCondition::SetVtrueFpsIC(float tt) {
   vt=tt;
   lastSpeedSet=setvt;
@@ -118,6 +166,8 @@ void FGInitialCondition::SetVtrueFpsIC(float tt) {
   ve=vt*sqrt(fdmex->GetAtmosphere()->GetDensityRatio());
 }
 
+//******************************************************************************
+
 void FGInitialCondition::SetMachIC(float tt) {
   mach=tt;
   lastSpeedSet=setmach;
@@ -127,44 +177,162 @@ void FGInitialCondition::SetMachIC(float tt) {
   //cout << "Vt: " << vt*jsbFPSTOKTS << " Vc: " << vc*jsbFPSTOKTS << endl;
 }
 
+//******************************************************************************
+
 void FGInitialCondition::SetClimbRateFpmIC(float tt) {
   SetClimbRateFpsIC(tt/60.0);
 }
 
+//******************************************************************************
+
 void FGInitialCondition::SetClimbRateFpsIC(float tt) {
 
   if(vt > 0.1) {
     hdot=tt;
     gamma=asin(hdot/vt);
+    sgamma=sin(gamma); cgamma=cos(gamma);
   }
 }
 
+//******************************************************************************
+
 void FGInitialCondition::SetFlightPathAngleRadIC(float tt) {
   gamma=tt;
+  sgamma=sin(gamma); cgamma=cos(gamma);
+  getTheta();
+  hdot=vt*sgamma;
+}
+
+//******************************************************************************
+
+void FGInitialCondition::SetAlphaRadIC(float tt) {
+  alpha=tt;
+  salpha=sin(alpha); calpha=cos(alpha);
+  getTheta();
+}
+
+//******************************************************************************
+
+void FGInitialCondition::SetPitchAngleRadIC(float tt) {
+  theta=tt;
+  stheta=sin(theta); ctheta=cos(theta);
+  calcWindUVW();
+  getAlpha();
+}
+
+//******************************************************************************
+
+void FGInitialCondition::SetBetaRadIC(float tt) {
+  beta=tt;
+  sbeta=sin(beta); cbeta=cos(beta);
   getTheta();
-  hdot=vt*sin(tt);
 }
 
+//******************************************************************************
+
+void FGInitialCondition::SetRollAngleRadIC(float tt) {
+  phi=tt;
+  sphi=sin(phi); cphi=cos(phi);
+  getTheta();
+}
+
+//******************************************************************************
+
+void FGInitialCondition::SetTrueHeadingRadIC(float tt) {
+    psi=tt;
+    spsi=sin(psi); cpsi=cos(psi);
+    calcWindUVW();
+}
+
+//******************************************************************************
 
 void FGInitialCondition::SetUBodyFpsIC(float tt) {
   u=tt;
-  vt=sqrt(u*u+v*v+w*w);
+  vt=sqrt(u*u + v*v + w*w);
   lastSpeedSet=setuvw;
 }
 
-  
+//******************************************************************************
+
 void FGInitialCondition::SetVBodyFpsIC(float tt) {
   v=tt;
-  vt=sqrt(u*u+v*v+w*w);
+  vt=sqrt(u*u + v*v + w*w);
   lastSpeedSet=setuvw;
 }
 
+//******************************************************************************
+
 void FGInitialCondition::SetWBodyFpsIC(float tt) {
   w=tt;
-  vt=sqrt(u*u+v*v+w*w);
+  vt=sqrt( u*u + v*v + w*w );
   lastSpeedSet=setuvw;
 }
 
+//******************************************************************************
+
+float FGInitialCondition::GetUBodyFpsIC(void) {
+    if(lastSpeedSet == setvg )
+      return u;
+    else
+      return vt*calpha*cbeta;
+}
+
+//******************************************************************************
+
+float FGInitialCondition::GetVBodyFpsIC(void) {
+    if( lastSpeedSet == setvg )
+      return v;
+    else
+      return vt*sbeta;
+}
+
+//******************************************************************************
+
+float FGInitialCondition::GetWBodyFpsIC(void) {
+    if( lastSpeedSet == setvg )
+      return w;
+    else {
+      return vt*salpha*cbeta;
+   }
+}
+
+//******************************************************************************
+
+void FGInitialCondition::SetWindNEDFpsIC(float wN, float wE, float wD ) {
+  wnorth = wN; weast = wE; wdown = wD;
+  if(lastSpeedSet == setvg)
+    SetVgroundFpsIC(vg);
+
+
+}
+
+//******************************************************************************
+
+void FGInitialCondition::calcWindUVW(void) {
+  if(lastSpeedSet == setvg ) {
+
+    uw=wnorth*ctheta*cpsi +
+       weast*ctheta*spsi -
+       wdown*stheta;
+    vw=wnorth*( sphi*stheta*cpsi - cphi*spsi ) +
+        weast*( sphi*stheta*spsi + cphi*cpsi ) +
+       wdown*sphi*ctheta;
+    ww=wnorth*(cphi*stheta*cpsi + sphi*spsi) +
+       weast*(cphi*stheta*spsi - sphi*cpsi) +
+       wdown*cphi*ctheta;
+    /* cout << "FGInitialCondition::calcWindUVW: wnorth, weast, wdown "
+         << wnorth << ", " << weast << ", " << wdown << endl;
+    cout << "FGInitialCondition::calcWindUVW: theta, phi, psi "
+          << theta << ", " << phi << ", " << psi << endl;
+    cout << "FGInitialCondition::calcWindUVW: uw, vw, ww "
+          << uw << ", " << vw << ", " << ww << endl;   */
+
+  } else {
+    uw=vw=ww=0;
+  }
+}
+
+//******************************************************************************
 
 void FGInitialCondition::SetAltitudeFtIC(float tt) {
   altitude=tt;
@@ -188,49 +356,67 @@ void FGInitialCondition::SetAltitudeFtIC(float tt) {
   case setmach:
     SetMachIC(mach);
     break;
+  case setvg:
+    SetVgroundFpsIC(vg);
+    break;
   }
 }
 
+//******************************************************************************
+
 void FGInitialCondition::SetAltitudeAGLFtIC(float tt) {
   fdmex->GetPosition()->SetDistanceAGL(tt);
   altitude=fdmex->GetPosition()->Geth();
   SetAltitudeFtIC(altitude);
-} 
+}
+
+//******************************************************************************
+
 void FGInitialCondition::SetSeaLevelRadiusFtIC(double tt) {
   sea_level_radius = tt;
 }
-   
+
+//******************************************************************************
+
 void FGInitialCondition::SetTerrainAltitudeFtIC(double tt) {
   terrain_altitude=tt;
   fdmex->GetPosition()->SetDistanceAGL(altitude-terrain_altitude);
   fdmex->GetPosition()->SetRunwayRadius(sea_level_radius + terrain_altitude);
-}  
+}
+
+//******************************************************************************
 
 void FGInitialCondition::calcUVWfromNED(void) {
-  u=vnorth*cos(theta)*cos(psi) + 
-     veast*cos(theta)*sin(psi) - 
-     vdown*sin(theta);
-  v=vnorth*(sin(phi)*sin(theta)*cos(psi) - cos(phi)*sin(psi)) +
-     veast*(sin(phi)*sin(theta)*sin(psi) + cos(phi)*cos(psi)) +
-     vdown*sin(phi)*cos(theta);
-  w=vnorth*(cos(phi)*sin(theta)*cos(psi) + sin(phi)*sin(psi)) +
-     veast*(cos(phi)*sin(theta)*sin(psi) - sin(phi)*cos(psi)) +
-     vdown*cos(phi)*cos(theta);
-}     
+  u=vnorth*ctheta*cpsi +
+     veast*ctheta*spsi -
+     vdown*stheta;
+  v=vnorth*( sphi*stheta*cpsi - cphi*spsi ) +
+     veast*( sphi*stheta*spsi + cphi*cpsi ) +
+     vdown*sphi*ctheta;
+  w=vnorth*( cphi*stheta*cpsi + sphi*spsi ) +
+     veast*( cphi*stheta*spsi - sphi*cpsi ) +
+     vdown*cphi*ctheta;
+}
+
+//******************************************************************************
+
 void FGInitialCondition::SetVnorthFpsIC(float tt) {
   vnorth=tt;
   calcUVWfromNED();
   vt=sqrt(u*u + v*v + w*w);
   lastSpeedSet=setned;
-}        
-  
+}
+
+//******************************************************************************
+
 void FGInitialCondition::SetVeastFpsIC(float tt) {
   veast=tt;
   calcUVWfromNED();
   vt=sqrt(u*u + v*v + w*w);
   lastSpeedSet=setned;
-} 
+}
+
+//******************************************************************************
 
 void FGInitialCondition::SetVdownFpsIC(float tt) {
   vdown=tt;
@@ -238,10 +424,12 @@ void FGInitialCondition::SetVdownFpsIC(float tt) {
   vt=sqrt(u*u + v*v + w*w);
   SetClimbRateFpsIC(-1*vdown);
   lastSpeedSet=setned;
-} 
+}
+
+//******************************************************************************
 
 bool FGInitialCondition::getMachFromVcas(float *Mach,float vcas) {
+
   bool result=false;
   float guess=1.5;
   xlo=xhi=0;
@@ -250,10 +438,12 @@ bool FGInitialCondition::getMachFromVcas(float *Mach,float vcas) {
   if(findInterval(vcas,guess)) {
     if(solve(&mach,vcas))
       result=true;
-  }    
+  }
   return result;
 }
 
+//******************************************************************************
+
 bool FGInitialCondition::getAlpha(void) {
   bool result=false;
   float guess=theta-gamma;
@@ -264,11 +454,15 @@ bool FGInitialCondition::getAlpha(void) {
   if(findInterval(0,guess)){
     if(solve(&alpha,0)){
       result=true;
+      salpha=sin(alpha);
+      calpha=cos(alpha);
     }
   }
   return result;
-}      
-    
+}
+
+//******************************************************************************
+
 bool FGInitialCondition::getTheta(void) {
   bool result=false;
   float guess=alpha+gamma;
@@ -278,32 +472,44 @@ bool FGInitialCondition::getTheta(void) {
   if(findInterval(0,guess)){
     if(solve(&theta,0)){
       result=true;
+      stheta=sin(theta);
+      ctheta=cos(theta);
     }
   }
   return result;
-}      
-  
+}
 
+//******************************************************************************
 
 float FGInitialCondition::GammaEqOfTheta(float Theta) {
-  float a,b,c;
-  
-  a=cos(alpha)*cos(beta)*sin(Theta);
-  b=sin(beta)*sin(phi);
-  c=sin(alpha)*cos(beta)*cos(phi);
-  return sin(gamma)-a+(b+c)*cos(Theta);
+  float a,b,c,d;
+  float sTheta,cTheta;
+
+  //theta=Theta; stheta=sin(theta); ctheta=cos(theta);
+  sTheta=sin(Theta); cTheta=cos(Theta);
+  calcWindUVW();
+  a=wdown + vt*calpha*cbeta + uw;
+  b=vt*sphi*sbeta + vw*sphi;
+  c=vt*cphi*salpha*cbeta + ww*cphi;
+  return vt*sgamma - ( a*sTheta - (b+c)*cTheta);
 }
 
+//******************************************************************************
+
 float FGInitialCondition::GammaEqOfAlpha(float Alpha) {
-  float a,b,c;
-  
-  a=cos(Alpha)*cos(beta)*sin(theta);
-  b=sin(beta)*sin(phi);
-  c=sin(Alpha)*cos(beta)*cos(phi);
-  return sin(gamma)-a+(b+c)*cos(theta);
+  float a,b,c,d;
+  float sAlpha,cAlpha;
+
+  sAlpha=sin(Alpha); cAlpha=cos(Alpha);
+  a=wdown + vt*cAlpha*cbeta + uw;
+  b=vt*sphi*sbeta + vw*sphi;
+  c=vt*cphi*sAlpha*cbeta + ww*cphi;
+
+  return vt*sgamma - ( a*stheta - (b+c)*ctheta );
 }
 
-  
+//******************************************************************************
+
 float FGInitialCondition::calcVcas(float Mach) {
 
   float p=fdmex->GetAtmosphere()->GetPressure();
@@ -343,6 +549,8 @@ float FGInitialCondition::calcVcas(float Mach) {
   return vcas;
 }
 
+//******************************************************************************
+
 bool FGInitialCondition::findInterval(float x,float guess) {
   //void find_interval(inter_params &ip,eqfunc f,float y,float constant, int &flag){
 
@@ -380,30 +588,29 @@ bool FGInitialCondition::findInterval(float x,float guess) {
   return found;
 }
 
+//******************************************************************************
 
-
-
-bool FGInitialCondition::solve(float *y,float x) {  
+bool FGInitialCondition::solve(float *y,float x) {
   float x1,x2,x3,f1,f2,f3,d,d0;
   float eps=1E-5;
   float const relax =0.9;
   int i;
   bool success=false;
-  
+
    //initializations
   d=1;
-  
+
     x1=xlo;x3=xhi;
     f1=(this->*sfunc)(x1)-x;
     f3=(this->*sfunc)(x3)-x;
     d0=fabs(x3-x1);
-  
+
     //iterations
     i=0;
     while ((fabs(d) > eps) && (i < 100)) {
       d=(x3-x1)/d0;
       x2=x1-d*d0*f1/(f3-f1);
-      
+
       f2=(this->*sfunc)(x2)-x;
       //cout << "solve x1,x2,x3: " << x1 << "," << x2 << "," << x3 << endl;
       //cout << "                " << f1 << "," << f2 << "," << f3 << endl;
@@ -430,3 +637,11 @@ bool FGInitialCondition::solve(float *y,float x) {
   //cout << "Success= " << success << " Vcas: " << vcas*jsbFPSTOKTS << " Mach: " << x2 << endl;
   return success;
 }
+
+//******************************************************************************
+
+void FGInitialCondition::Debug(void)
+{
+    //TODO: Add your source code here
+}
+
index a461bccb933b0cde3b715929e1e09b153edbd1b9..cee99ad8ce135e73fc6e2956c15a12db793dd978 100644 (file)
@@ -53,13 +53,13 @@ INCLUDES
 #include "FGAtmosphere.h"
 #include "FGMatrix.h"
 
-#define ID_INITIALCONDITION "$Header"
+#define ID_INITIALCONDITION "$Id$"
 
 /*******************************************************************************
 CLASS DECLARATION
 *******************************************************************************/
 
-typedef enum { setvt, setvc, setve, setmach, setuvw, setned } speedset;
+typedef enum { setvt, setvc, setve, setmach, setuvw, setned, setvg } speedset;
 
 #define jsbFPSTOKTS 0.5924838
 #define jsbKTSTOFPS 1.6878099
@@ -81,8 +81,6 @@ typedef enum { setvt, setvc, setve, setmach, setuvw, setned } speedset;
    //or to loop the sim w/o integrating
    FDMExec->RunIC(fgic)
    
-   
-   
    Speed:
         Since vc, ve, vt, and mach all represent speed, the remaining
         three are recalculated each time one of them is set (using the
@@ -112,141 +110,143 @@ class FGInitialCondition {
 public:
 
   FGInitialCondition(FGFDMExec *fdmex);
-  ~FGInitialCondition(void);
-  
-  inline speedset GetSpeedSet(void) { return lastSpeedSet; }
+  ~FGInitialCondition();
 
   void SetVcalibratedKtsIC(float tt);
   void SetVequivalentKtsIC(float tt);
-  inline void SetVtrueKtsIC(float tt) { SetVtrueFpsIC(tt*jsbKTSTOFPS); }
-  void SetVtrueFpsIC(float tt);
+  inline void SetVtrueKtsIC(float tt)   { SetVtrueFpsIC(tt*jsbKTSTOFPS);   }
+  inline void SetVgroundKtsIC(float tt) { SetVgroundFpsIC(tt*jsbKTSTOFPS); }
   void SetMachIC(float tt);
-
-  void SetUBodyFpsIC(float tt);
-  void SetVBodyFpsIC(float tt);
-  void SetWBodyFpsIC(float tt);
   
-  void SetVnorthFpsIC(float tt);
-  void SetVeastFpsIC(float tt);
-  void SetVdownFpsIC(float tt);
+  inline void SetAlphaDegIC(float tt)      { SetAlphaRadIC(tt*DEGTORAD); }
+  inline void SetBetaDegIC(float tt)       { SetBetaRadIC(tt*DEGTORAD);}
   
+  inline void SetPitchAngleDegIC(float tt) { SetPitchAngleRadIC(tt*DEGTORAD); }
+  inline void SetRollAngleDegIC(float tt)  { SetRollAngleRadIC(tt*DEGTORAD);}
+  inline void SetTrueHeadingDegIC(float tt){ SetTrueHeadingRadIC(tt*DEGTORAD); }
+  
+  void SetClimbRateFpmIC(float tt);
+  inline void SetFlightPathAngleDegIC(float tt) { SetFlightPathAngleRadIC(tt*DEGTORAD); }
+
   void SetAltitudeFtIC(float tt);
   void SetAltitudeAGLFtIC(float tt);
   
   void SetSeaLevelRadiusFtIC(double tt);
   void SetTerrainAltitudeFtIC(double tt);
-  
-  //"vertical" flight path, recalculate theta
-  inline void SetFlightPathAngleDegIC(float tt) { SetFlightPathAngleRadIC(tt*DEGTORAD); }
-  void SetFlightPathAngleRadIC(float tt);
-  //set speed first
-  void SetClimbRateFpmIC(float tt);
-  void SetClimbRateFpsIC(float tt);
-  //use currently stored gamma, recalcualte theta
-  inline void SetAlphaDegIC(float tt)      { alpha=tt*DEGTORAD; getTheta(); }
-  inline void SetAlphaRadIC(float tt)      { alpha=tt; getTheta(); }
-  //use currently stored gamma, recalcualte alpha
-  inline void SetPitchAngleDegIC(float tt) { theta=tt*DEGTORAD; getAlpha(); }
-  inline void SetPitchAngleRadIC(float tt) { theta=tt; getAlpha(); }
-
-  inline void SetBetaDegIC(float tt)       { beta=tt*DEGTORAD; getTheta();}
-  inline void SetBetaRadIC(float tt)       { beta=tt; getTheta(); }
-  
-  inline void SetRollAngleDegIC(float tt) { phi=tt*DEGTORAD; getTheta(); }
-  inline void SetRollAngleRadIC(float tt) { phi=tt; getTheta(); }
-
-  inline void SetTrueHeadingDegIC(float tt)   { psi=tt*DEGTORAD; }
-  inline void SetTrueHeadingRadIC(float tt)   { psi=tt; }
 
   inline void SetLatitudeDegIC(float tt)  { latitude=tt*DEGTORAD; }
-  inline void SetLatitudeRadIC(float tt)  { latitude=tt; }
-
   inline void SetLongitudeDegIC(float tt) { longitude=tt*DEGTORAD; }
-  inline void SetLongitudeRadIC(float tt) { longitude=tt; }
 
+  
   inline float GetVcalibratedKtsIC(void) { return vc*jsbFPSTOKTS; }
   inline float GetVequivalentKtsIC(void) { return ve*jsbFPSTOKTS; }
+  inline float GetVgroundKtsIC(void) { return vg*jsbFPSTOKTS; }
   inline float GetVtrueKtsIC(void) { return vt*jsbFPSTOKTS; }
-  inline float GetVtrueFpsIC(void) { return vt; }
   inline float GetMachIC(void) { return mach; }
+  
+  inline float GetClimbRateFpmIC(void) { return hdot*60; }
+  inline float GetFlightPathAngleDegIC(void) { return gamma*RADTODEG; }
+  
+  inline float GetAlphaDegIC(void)      { return alpha*RADTODEG; }
+  inline float GetBetaDegIC(void)       { return beta*RADTODEG; }
+  
+  inline float GetPitchAngleDegIC(void) { return theta*RADTODEG; }
+  inline float GetRollAngleDegIC(void) { return phi*RADTODEG; }
+  inline float GetHeadingDegIC(void)   { return psi*RADTODEG; }
 
+  inline float GetLatitudeDegIC(void)  { return latitude*RADTODEG; }
+  inline float GetLongitudeDegIC(void) { return longitude*RADTODEG; }
+  
   inline float GetAltitudeFtIC(void) { return altitude; }
   inline float GetAltitudeAGLFtIC(void) { return altitude - terrain_altitude; }
   
-  inline float GetFlightPathAngleDegIC(void) { return gamma*RADTODEG; }
-  inline float GetFlightPathAngleRadIC(void) { return gamma; }
+  inline float GetSeaLevelRadiusFtIC(void)  { return sea_level_radius; }
+  inline float GetTerrainAltitudeFtIC(void) { return terrain_altitude; }
 
-  inline float GetClimbRateFpmIC(void) { return hdot*60; }
+  void SetVgroundFpsIC(float tt);
+  void SetVtrueFpsIC(float tt);
+  void SetUBodyFpsIC(float tt);
+  void SetVBodyFpsIC(float tt);
+  void SetWBodyFpsIC(float tt);
+  void SetVnorthFpsIC(float tt);
+  void SetVeastFpsIC(float tt);
+  void SetVdownFpsIC(float tt);
+  void SetWindNEDFpsIC(float wN, float wE, float wD);
+  void SetClimbRateFpsIC(float tt);
+  inline float GetVgroundFpsIC(void) { return vg; }
+  inline float GetVtrueFpsIC(void) { return vt; }
+  inline float GetWindUFpsIC(void) { return uw; }
+  inline float GetWindVFpsIC(void) { return vw; }
+  inline float GetWindWFpsIC(void) { return ww; }
+  inline float GetWindNFpsIC(void) { return wnorth; }
+  inline float GetWindEFpsIC(void) { return weast; }
+  inline float GetWindDFpsIC(void) { return wdown; }
   inline float GetClimbRateFpsIC(void) { return hdot; }
-
-  inline float GetAlphaDegIC(void)      { return alpha*RADTODEG; }
+  float GetUBodyFpsIC(void);
+  float GetVBodyFpsIC(void);
+  float GetWBodyFpsIC(void);
+  void SetFlightPathAngleRadIC(float tt);
+  void SetAlphaRadIC(float tt);
+  void SetPitchAngleRadIC(float tt);
+  void SetBetaRadIC(float tt);
+  void SetRollAngleRadIC(float tt);
+  void SetTrueHeadingRadIC(float tt);
+  inline void SetLatitudeRadIC(float tt)  { latitude=tt; }
+  inline void SetLongitudeRadIC(float tt) { longitude=tt; }
+  inline float GetFlightPathAngleRadIC(void) { return gamma; }
   inline float GetAlphaRadIC(void)      { return alpha; }
-
-  inline float GetPitchAngleDegIC(void) { return theta*RADTODEG; }
   inline float GetPitchAngleRadIC(void) { return theta; }
-
-
-  inline float GetBetaDegIC(void)       { return beta*RADTODEG; }
-  inline float GetBetaRadIC(void)       { return beta*RADTODEG; }
-
-  inline float GetRollAngleDegIC(void) { return phi*RADTODEG; }
+  inline float GetBetaRadIC(void)       { return beta; }
   inline float GetRollAngleRadIC(void) { return phi; }
-
-  inline float GetHeadingDegIC(void)   { return psi*RADTODEG; }
   inline float GetHeadingRadIC(void)   { return psi; }
-
-  inline float GetLatitudeDegIC(void)  { return latitude*RADTODEG; }
   inline float GetLatitudeRadIC(void) { return latitude; }
-
-  inline float GetLongitudeDegIC(void) { return longitude*RADTODEG; }
   inline float GetLongitudeRadIC(void) { return longitude; }
-
-  inline float GetUBodyFpsIC(void) { return vt*cos(alpha)*cos(beta); }
-  inline float GetVBodyFpsIC(void) { return vt*sin(beta); }
-  inline float GetWBodyFpsIC(void) { return vt*sin(alpha)*cos(beta); }
-
   inline float GetThetaRadIC(void) { return theta; }
   inline float GetPhiRadIC(void)   { return phi; }
   inline float GetPsiRadIC(void)   { return psi; }
-  
-  inline float GetSeaLevelRadiusFtIC(void)  { return sea_level_radius; }
-  inline float GetTerrainAltitudeFtIC(void) { return terrain_altitude; }
-
 
+  inline speedset GetSpeedSet(void) { return lastSpeedSet; }
 
 private:
-  float vt,vc,ve;
-  float alpha,beta,gamma,theta,phi,psi;
+  float vt,vc,ve,vg;
   float mach;
   float altitude,hdot;
   float latitude,longitude;
   float u,v,w;
+  float uw,vw,ww;
   float vnorth,veast,vdown;
+  float wnorth,weast,wdown;
   double sea_level_radius;
   double terrain_altitude;
   double radius_to_vehicle;
-  
+
+  float  alpha, beta, theta, phi, psi, gamma;
+  float salpha,sbeta,stheta,sphi,spsi,sgamma;
+  float calpha,cbeta,ctheta,cphi,cpsi,cgamma;
+
   float xlo, xhi,xmin,xmax;
-  
+
   typedef float (FGInitialCondition::*fp)(float x);
   fp sfunc;
 
   speedset lastSpeedSet;
 
   FGFDMExec *fdmex;
-  
-  
+
   bool getAlpha(void);
   bool getTheta(void);
   bool getMachFromVcas(float *Mach,float vcas);
-  
+
   float GammaEqOfTheta(float Theta);
   float GammaEqOfAlpha(float Alpha);
   float calcVcas(float Mach);
   void calcUVWfromNED(void);
-  
+  void calcWindUVW(void);
+
   bool findInterval(float x,float guess);
   bool solve(float *y, float x);
+  void Debug(void);
 };
 
 #endif
+
index 6dc659162b56d20d8ddb016a545c61494952304a..1f044a5483825a7d7c5824cfad7e90b9c6bfe8e3 100644 (file)
@@ -31,6 +31,7 @@ FUNCTIONAL DESCRIPTION
 HISTORY
 --------------------------------------------------------------------------------
 11/18/99   JSB   Created
+01/30/01   NHP   Extended gear model to properly simulate steering and braking
 
 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 INCLUDES
@@ -47,9 +48,12 @@ DEFINITIONS
 GLOBAL DATA
 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%*/
 
-static const char *IdSrc = "$Header$";
+
+static const char *IdSrc = "$Id$";
 static const char *IdHdr = ID_LGEAR;
 
+extern short debug_lvl;
+
 /*%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 CLASS IMPLEMENTATION
 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%*/
@@ -62,7 +66,7 @@ FGLGear::FGLGear(FGConfigFile* AC_cfg, FGFDMExec* fdmex) : vXYZ(3),
   string tmp;
   *AC_cfg >> tmp >> name >> vXYZ(1) >> vXYZ(2) >> vXYZ(3)  
             >> kSpring >> bDamp>> dynamicFCoeff >> staticFCoeff
-                 >> SteerType >> BrakeGroup >> maxSteerAngle;
+                  >> rollingFCoeff >> sSteerType >> sBrakeGroup >> maxSteerAngle;
     
   cout << "    Name: " << name << endl;
   cout << "      Location: " << vXYZ << endl;
@@ -70,31 +74,41 @@ FGLGear::FGLGear(FGConfigFile* AC_cfg, FGFDMExec* fdmex) : vXYZ(3),
   cout << "      Damping Constant: " << bDamp << endl;
   cout << "      Dynamic Friction: " << dynamicFCoeff << endl;
   cout << "      Static Friction:  " << staticFCoeff << endl;
-  cout << "      Grouping:         " << BrakeGroup << endl;
-  cout << "      Steering Type:    " << SteerType << endl;
+  cout << "      Rolling Friction: " << rollingFCoeff << endl;
+  cout << "      Steering Type:    " << sSteerType << endl;
+  cout << "      Grouping:         " << sBrakeGroup << endl;
   cout << "      Max Steer Angle:  " << maxSteerAngle << endl;
 
-  if      (BrakeGroup == "LEFT"  ) eBrakeGrp = bgLeft;
-  else if (BrakeGroup == "RIGHT" ) eBrakeGrp = bgRight;
-  else if (BrakeGroup == "CENTER") eBrakeGrp = bgCenter;
-  else if (BrakeGroup == "NOSE"  ) eBrakeGrp = bgNose;
-  else if (BrakeGroup == "TAIL"  ) eBrakeGrp = bgTail;
-  else if (BrakeGroup == "NONE"  ) eBrakeGrp = bgNone;
+  if      (sBrakeGroup == "LEFT"  ) eBrakeGrp = bgLeft;
+  else if (sBrakeGroup == "RIGHT" ) eBrakeGrp = bgRight;
+  else if (sBrakeGroup == "CENTER") eBrakeGrp = bgCenter;
+  else if (sBrakeGroup == "NOSE"  ) eBrakeGrp = bgNose;
+  else if (sBrakeGroup == "TAIL"  ) eBrakeGrp = bgTail;
+  else if (sBrakeGroup == "NONE"  ) eBrakeGrp = bgNone;
   else {
     cerr << "Improper braking group specification in config file: "
-         << BrakeGroup << " is undefined." << endl;
+         << sBrakeGroup << " is undefined." << endl;
+  }
+
+  if      (sSteerType == "STEERABLE") eSteerType = stSteer;
+  else if (sSteerType == "FIXED"    ) eSteerType = stFixed;
+  else if (sSteerType == "CASTERED" ) eSteerType = stCaster;
+  else {
+    cerr << "Improper steering type specification in config file: "
+         << sSteerType << " is undefined." << endl;
   }
 
-// add some AI here to determine if gear is located properly according to its
-// brake group type
+// Add some AI here to determine if gear is located properly according to its
+// brake group type ??
 
   State       = Exec->GetState();
   Aircraft    = Exec->GetAircraft();
   Position    = Exec->GetPosition();
   Rotation    = Exec->GetRotation();
+  FCS         = Exec->GetFCS();
   
   WOW = false;
-  ReportEnable=true;
+  ReportEnable = true;
   FirstContact = false;
   Reported = false;
   DistanceTraveled = 0.0;
@@ -105,6 +119,8 @@ FGLGear::FGLGear(FGConfigFile* AC_cfg, FGFDMExec* fdmex) : vXYZ(3),
   vWhlBodyVec(eZ) = -vWhlBodyVec(eZ);
 
   vLocalGear = State->GetTb2l() * vWhlBodyVec;
+
+  if (debug_lvl & 2) cout << "Instantiated: FGLGear" << endl;
 }
 
 //%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
@@ -116,6 +132,7 @@ FGLGear::FGLGear(const FGLGear& lgear)
   Position = lgear.Position;
   Rotation = lgear.Rotation;
   Exec     = lgear.Exec;
+  FCS      = lgear.FCS;
 
   vXYZ = lgear.vXYZ;
   vMoment = lgear.vMoment;
@@ -135,26 +152,36 @@ FGLGear::FGLGear(const FGLGear& lgear)
   compressSpeed   = lgear.compressSpeed;
   staticFCoeff    = lgear.staticFCoeff;
   dynamicFCoeff   = lgear.dynamicFCoeff;
+  rollingFCoeff   = lgear.rollingFCoeff;
   brakePct        = lgear.brakePct;
   maxCompLen      = lgear.maxCompLen;
   SinkRate        = lgear.SinkRate;
   GroundSpeed     = lgear.GroundSpeed;
   Reported        = lgear.Reported;
   name            = lgear.name;
-  SteerType       = lgear.SteerType;
-  BrakeGroup      = lgear.BrakeGroup;
+  sSteerType      = lgear.sSteerType;
+  eSteerType      = lgear.eSteerType;
+  sBrakeGroup     = lgear.sBrakeGroup;
   eBrakeGrp       = lgear.eBrakeGrp;
   maxSteerAngle   = lgear.maxSteerAngle;
 }
 
 //%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 
-FGLGear::~FGLGear(void) {}
+FGLGear::~FGLGear()
+{
+  if (debug_lvl & 2) cout << "Destroyed:    FGLGear" << endl;
+}
 
 //%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 
 FGColumnVector FGLGear::Force(void)
 {
+  float SteerGain, SteerAngle, BrakeFCoeff;
+  float SinWheel, CosWheel, SideWhlVel, RollingWhlVel;
+  float RudderPedal, RollingForce, SideForce, FCoeff;
+  float WheelSlip;
+
   FGColumnVector vForce(3);
   FGColumnVector vLocalForce(3);
   //FGColumnVector vLocalGear(3);     // Vector: CG to this wheel (Local)
@@ -166,11 +193,18 @@ FGColumnVector FGLGear::Force(void)
 
   vLocalGear = State->GetTb2l() * vWhlBodyVec;
   
+// For now, gear compression is assumed to happen in the Local Z axis,
+// not the strut axis as it should be.  Will fix this later.
+
   compressLength = vLocalGear(eZ) - Position->GetDistanceAGL();
 
   if (compressLength > 0.00) {
      
     WOW = true;
+
+// The next equation should really use the vector to the contact patch of the tire
+// including the strut compression and not vWhlBodyVec.  Will fix this later.
+
     vWhlVelVec      =  State->GetTb2l() * (Rotation->GetPQR() * vWhlBodyVec);
     vWhlVelVec     +=  Position->GetVel();
 
@@ -182,45 +216,132 @@ FGColumnVector FGLGear::Force(void)
       GroundSpeed   =  Position->GetVel().Magnitude();
     }
 
-    // The following code normalizes the wheel velocity vector, reverses it, and zeroes out
-    // the z component of the velocity. The question is, should the Z axis velocity be zeroed
-    // out first before the normalization takes place or not? Subsequent to that, the Wheel
-    // Velocity vector now points as a unit vector backwards and parallel to the wheel
-    // velocity vector. It acts AT the wheel.
-
-    vWhlVelVec      = -1.0 * vWhlVelVec.Normalize();
-    vWhlVelVec(eZ)  =  0.00;
-
-// the following needs work regarding friction coefficients and braking and steering
+// The following needs work regarding friction coefficients and braking and
+// steering The BrakeFCoeff formula assumes that an anti-skid system is used.
+// It also assumes that we won't be turning and braking at the same time.
+// Will fix this later.
 
     switch (eBrakeGrp) {
     case bgLeft:
-
+        SteerGain = -maxSteerAngle;
+        BrakeFCoeff = rollingFCoeff*(1.0 - FCS->GetBrake(bgLeft)) +
+                                            staticFCoeff*FCS->GetBrake(bgLeft);
       break;
     case bgRight:
+        SteerGain = -maxSteerAngle;
+        BrakeFCoeff = rollingFCoeff*(1.0 - FCS->GetBrake(bgRight)) +
+                                            staticFCoeff*FCS->GetBrake(bgRight);
       break;
     case bgCenter:
+        SteerGain = -maxSteerAngle;
+        BrakeFCoeff = rollingFCoeff*(1.0 - FCS->GetBrake(bgCenter)) +
+                                            staticFCoeff*FCS->GetBrake(bgCenter);
       break;
     case bgNose:
+        SteerGain = maxSteerAngle;
+        BrakeFCoeff = rollingFCoeff;
       break;
     case bgTail:
+        SteerGain = -maxSteerAngle;
+        BrakeFCoeff = rollingFCoeff;
       break;
     case bgNone:
+        SteerGain = -maxSteerAngle;
+        BrakeFCoeff = rollingFCoeff;
       break;
     default:
       cerr << "Improper brake group membership detected for this gear." << endl;
       break;
     }
-//
+
+// Note to Jon: Need to substitute the correct variable for RudderPedal.
+// It is assumed that rudder pedal has a range of -1.0 to 1.0.
+
+    switch (eSteerType) {
+    case stSteer:
+      SteerAngle = SteerGain*RudderPedal;
+      break;
+    case stFixed:
+      SteerAngle = 0.0;
+      break;
+    case stCaster:
+
+    // Note to Jon: This is not correct for castering gear.  I'll fix it later.
+      SteerAngle = 0.0;
+      break;
+    default:
+      cerr << "Improper steering type membership detected for this gear." << endl;
+      break;
+    }
+
+// Transform the wheel velocities from the local axis system to the wheel axis system.
+// For now, steering angle is assumed to happen in the Local Z axis,
+// not the strut axis as it should be.  Will fix this later.
+// Note to Jon: Please substitute the correct variable for Deg2Rad conversion.
+
+    SinWheel      = sin(Rotation->Getpsi() + SteerAngle*DEGTORAD);
+    CosWheel      = cos(Rotation->Getpsi() + SteerAngle*DEGTORAD);
+    RollingWhlVel = vWhlVelVec(eX)*CosWheel + vWhlVelVec(eY)*SinWheel;
+    SideWhlVel    = vWhlVelVec(eY)*CosWheel - vWhlVelVec(eX)*SinWheel;
+
+// Calculate tire slip angle.
+
+    if (RollingWhlVel == 0.0 && SideWhlVel == 0.0) {
+      WheelSlip = 0.0;
+    } else {
+      WheelSlip = RADTODEG*atan2(SideWhlVel, RollingWhlVel);
+    }
+
+    // The following code normalizes the wheel velocity vector, reverses it, and zeroes out
+    // the z component of the velocity. The question is, should the Z axis velocity be zeroed
+    // out first before the normalization takes place or not? Subsequent to that, the Wheel
+    // Velocity vector now points as a unit vector backwards and parallel to the wheel
+    // velocity vector. It acts AT the wheel.
+
+// Note to Jon: I commented out this line because I wasn't sure we want to do this.
+//    vWhlVelVec      = -1.0 * vWhlVelVec.Normalize();
+//    vWhlVelVec(eZ)  =  0.00;
+
+// Compute the sideforce coefficients using similar assumptions to LaRCSim for now.
+// Allow a maximum of 10 degrees tire slip angle before wheel slides.  At that point,
+// transition from static to dynamic friction.  There are more complicated formulations
+// of this that avoid the discrete jump.  Will fix this later.
+
+    if (fabs(WheelSlip) <= 10.0) {
+      FCoeff = staticFCoeff*WheelSlip/10.0;
+    } else {
+      FCoeff = dynamicFCoeff*fabs(WheelSlip)/WheelSlip;
+    }
+
+// Compute the vertical force on the wheel.
 
     vLocalForce(eZ) =  min(-compressLength * kSpring - compressSpeed * bDamp, (float)0.0);
-    vLocalForce(eX) =  fabs(vLocalForce(eZ) * staticFCoeff) * vWhlVelVec(eX);
-    vLocalForce(eY) =  fabs(vLocalForce(eZ) * staticFCoeff) * vWhlVelVec(eY);
 
     MaximumStrutForce = max(MaximumStrutForce, fabs(vLocalForce(eZ)));
     MaximumStrutTravel = max(MaximumStrutTravel, fabs(compressLength));
 
-    vForce  = State->GetTl2b() * vLocalForce ;
+// Compute the forces in the wheel ground plane.
+
+    RollingForce = vLocalForce(eZ) * BrakeFCoeff * fabs(RollingWhlVel)/RollingWhlVel;
+    SideForce    = vLocalForce(eZ) * FCoeff;
+
+// Transform these forces back to the local reference frame.
+
+    vLocalForce(eX) = RollingForce*CosWheel - SideForce*SinWheel;
+    vLocalForce(eY) = SideForce*CosWheel    + RollingForce*SinWheel;
+
+// Note to Jon: At this point the forces will be too big when the airplane is stopped or
+// rolling to a stop.  We need to make sure that the gear forces just balance out the non-gear forces
+// when the airplane is stopped.  That way the airplane won't start to accelerate until the non-gear
+// forces are larger than the gear forces.  I think that the proper fix should go into FGAircraft::FMGear.
+// This routine would only compute the local strut forces and return them to FMGear.  All of the gear
+// forces would get adjusted in FMGear using the total non-gear forces.  Then the gear moments would be
+// calculated.  If strange things start happening to the airplane during testing as it rolls to a stop,
+// then we need to implement this change.  I ran out of time to do it now but have the equations.
+
+// Transform the forces back to the body frame and compute the moment.
+
+    vForce  = State->GetTl2b() * vLocalForce;
     vMoment = vWhlBodyVec * vForce;
 
   } else {
@@ -245,6 +366,7 @@ FGColumnVector FGLGear::Force(void)
   if (ReportEnable && Position->GetVel().Magnitude() <= 0.05 && !Reported) {
     Report();
   }
+  
   return vForce;
 }
 
@@ -266,3 +388,10 @@ void FGLGear::Report(void)
   Reported = true;
 }
 
+//%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+
+void FGLGear::Debug(void)
+{
+  // TODO: Add user code here
+}
+
index 0b2536a187e002f21c3492eb1499e4a784ee005a..8f1a1867228f430e7901b984a1df9a098b223c64 100644 (file)
@@ -52,7 +52,7 @@ INCLUDES
 DEFINITIONS
 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%*/
 
-#define ID_LGEAR "$Header"
+#define ID_LGEAR "$Id$"
 
 /*%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 FORWARD DECLARATIONS
@@ -61,6 +61,7 @@ FORWARD DECLARATIONS
 class FGAircraft;
 class FGPosition;
 class FGRotation;
+class FGFCS;
 
 /*%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 COMMENTS, REFERENCES, and NOTES [use "class documentation" below for API docs]
@@ -143,6 +144,7 @@ CLASS DOCUMENTATION
     length times the spring coefficient and the gear velocity times the damping
     coefficient.</li>
     <li>The lateral/directional force acting on the aircraft through the landing
+
     gear (along the local frame X and Y axes) is calculated next. First, the
     friction coefficient is multiplied by the recently calculated Z-force. This
     is the friction force. It must be given direction in addition to magnitude.
@@ -171,7 +173,9 @@ class FGLGear
 {
 public:
   /// Brake grouping enumerators
-  enum eBrakeGroup {bgNone=0, bgLeft, bgRight, bgCenter, bgNose, bgTail };
+  enum BrakeGroup {bgNone=0, bgLeft, bgRight, bgCenter, bgNose, bgTail };
+  /// Steering group membership enumerators
+  enum SteerType {stSteer, stFixed, stCaster};
   /** Constructor
       @param Executive a pointer to the parent executive object
       @param File a pointer to the config file instance */
@@ -180,13 +184,14 @@ public:
       @param lgear a reference to an existing FGLGear object     */
   FGLGear(const FGLGear& lgear);
   /// Destructor
-  ~FGLGear(void);
+  ~FGLGear();
 
 
   /// The Force vector for this gear
   FGColumnVector Force(void);
   /// The Moment vector for this gear
   FGColumnVector Moment(void) {return vMoment;}
+
   /// Gets the location of the gear in Body axes
   FGColumnVector GetBodyLocation(void) { return vWhlBodyVec; }
   
@@ -223,7 +228,7 @@ private:
   float bDamp;
   float compressLength;
   float compressSpeed;
-  float staticFCoeff, dynamicFCoeff;
+  float staticFCoeff, dynamicFCoeff, rollingFCoeff;
   float brakePct;
   float maxCompLen;
   double SinkRate;
@@ -236,23 +241,27 @@ private:
   bool Reported;
   bool ReportEnable;
   string name;
-  string SteerType;
-  string BrakeGroup;
-  eBrakeGroup eBrakeGrp;
+  string sSteerType;
+  string sBrakeGroup;
+  BrakeGroup eBrakeGrp;
+  SteerType  eSteerType;
   float  maxSteerAngle;
 
-  FGFDMExec*     Exec;
-  FGState*       State;
-  FGAircraft*    Aircraft;
-  FGPosition*    Position;
-  FGRotation*    Rotation;
+  FGFDMExec*  Exec;
+  FGState*    State;
+  FGAircraft* Aircraft;
+  FGPosition* Position;
+  FGRotation* Rotation;
+  FGFCS*      FCS;
 
   void Report(void);
+  void Debug(void);
 };
 
 #include "FGAircraft.h"
 #include "FGPosition.h"
 #include "FGRotation.h"
+#include "FGFCS.h"
 
 //%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 #endif
index 3004964540142cbdcb9e9d973e807bf87ac035bc..dc380b128f0f5618caef65ddbab2b27f893bd769 100644 (file)
@@ -40,9 +40,11 @@ INCLUDES
 
 #include "FGMassBalance.h"
 
-static const char *IdSrc = "$Header$";
+static const char *IdSrc = "$Id$";
 static const char *IdHdr = ID_MASSBALANCE;
 
+extern short debug_lvl;
+
 /*%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 CLASS IMPLEMENTATION
 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%*/
@@ -50,11 +52,12 @@ CLASS IMPLEMENTATION
 
 FGMassBalance::FGMassBalance(FGFDMExec* fdmex) : FGModel(fdmex)
 {
-  //
+  if (debug_lvl & 2) cout << "Instantiated: FGMassBalance" << endl;
 }
 
+//%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 
-bool FGMassBalance:: Run(void) {
+bool FGMassBalance::Run(void) {
 
   if (!FGModel::Run()) {
 
@@ -64,3 +67,10 @@ bool FGMassBalance:: Run(void) {
   }
 }
 
+//%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+
+void FGMassBalance::Debug(void)
+{
+  // TODO: Add user code here
+}
+
index 1e69fd502696e0915c568dfee56d3982bf302f2f..b182fb2e51537865c573f90084e798786a8ca0b5 100644 (file)
@@ -44,7 +44,7 @@ INCLUDES
 
 #include "FGModel.h"
 
-#define ID_MASSBALANCE "$Header"
+#define ID_MASSBALANCE "$Id$"
 
 /*%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 CLASS DECLARATION
@@ -58,6 +58,9 @@ public:
   ~FGMassBalance();
 
   bool Run(void);
+  
+private:  
+  void Debug(void);
 };
 
 //%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
index 5660020fdb2ca6414acdcad581395b7fbb23c06b..a7e0687835764ed8a60a2d9e2f3fa9001dd4a5dc 100644 (file)
@@ -20,9 +20,11 @@ INCLUDES
 
 #include "FGMatrix.h"
 
-static const char *IdSrc = "$Header$";
+static const char *IdSrc = "$Id$";
 static const char *IdHdr = ID_MATRIX;
 
+extern short debug_lvl;
+
 /*%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 CLASS IMPLEMENTATION
 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%*/
@@ -45,7 +47,7 @@ double** FGalloc(int rows, int cols)
 
 void dealloc(double **A, int rows)
 {
-  for(int i=0;i<= rows;i++) delete[] A[i];
+  for (int i=0; i <= rows; i++) delete[] A[i];
   delete[] A;
 }
 
@@ -56,6 +58,8 @@ FGMatrix::FGMatrix(const unsigned int r, const unsigned int c) : rows(r), cols(c
   data = FGalloc(rows,cols);
   InitMatrix();
   rowCtr = colCtr = 1;
+  
+  if (debug_lvl & 2) cout << "Instantiated: FGMatrix" << endl;
 }
 
 //%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
@@ -65,6 +69,8 @@ FGMatrix::FGMatrix(const FGMatrix& M)
   data  = NULL;
   rowCtr = colCtr = 1;
   *this = M;
+
+  if (debug_lvl & 2) cout << "Instantiated: FGMatrix" << endl;
 }
 
 //%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
@@ -74,6 +80,8 @@ FGMatrix::~FGMatrix(void)
   dealloc(data,rows);
   rowCtr = colCtr = 1;
   rows = cols = 0;
+
+  if (debug_lvl & 2) cout << "Destroyed:    FGMatrix" << endl;
 }
 
 //%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
@@ -190,14 +198,14 @@ void FGMatrix::InitMatrix(void)
 
 FGMatrix FGMatrix::operator-(const FGMatrix& M)
 {
+  FGMatrix Diff(Rows(), Cols());
+
   if ((Rows() != M.Rows()) || (Cols() != M.Cols())) {
     MatrixException mE;
     mE.Message = "Invalid row/column match in Matrix operator -";
     throw mE;
   }
 
-  FGMatrix Diff(Rows(), Cols());
-
   for (unsigned int i=1; i<=Rows(); i++) {
     for (unsigned int j=1; j<=Cols(); j++) {
       Diff(i,j) = data[i][j] - M(i,j);
@@ -227,14 +235,14 @@ void FGMatrix::operator-=(const FGMatrix &M)
 
 FGMatrix FGMatrix::operator+(const FGMatrix& M)
 {
+  FGMatrix Sum(Rows(), Cols());
+
   if ((Rows() != M.Rows()) || (Cols() != M.Cols())) {
     MatrixException mE;
     mE.Message = "Invalid row/column match in Matrix operator +";
     throw mE;
   }
 
-  FGMatrix Sum(Rows(), Cols());
-
   for (unsigned int i=1; i<=Rows(); i++) {
     for (unsigned int j=1; j<=Cols(); j++) {
       Sum(i,j) = data[i][j] + M(i,j);
@@ -289,14 +297,14 @@ void FGMatrix::operator*=(const double scalar)
 
 FGMatrix FGMatrix::operator*(const FGMatrix& M)
 {
+  FGMatrix Product(Rows(), M.Cols());
+
   if (Cols() != M.Rows()) {
     MatrixException mE;
     mE.Message = "Invalid row/column match in Matrix operator *";
     throw mE;
   }
 
-  FGMatrix Product(Rows(), M.Cols());
-
   for (unsigned int i=1; i<=Rows(); i++) {
     for (unsigned int j=1; j<=M.Cols(); j++)  {
       Product(i,j) = 0;
@@ -340,15 +348,16 @@ FGMatrix FGMatrix::operator/(const double scalar)
 {
   FGMatrix Quot(Rows(), Cols());
 
-  if(scalar != 0) {
+  if (scalar != 0) {
     for (unsigned int i=1; i<=Rows(); i++) {
       for (unsigned int j=1; j<=Cols(); j++)  {
          Quot(i,j) = data[i][j]/scalar;
       }
     }
     
-  } else
+  } else {
     cerr << "Attempt to divide by zero in method FGMatrix::operator/(const double scalar), object at " << this << endl; 
+  }
   return Quot;  
 }
 
@@ -435,10 +444,26 @@ void FGMatrix::TransposeNonSquare(void)
 
 //%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 
-FGColumnVector::FGColumnVector(void):FGMatrix(3,1) { }
+void FGMatrix::Debug(void)
+{
+    //TODO: Add your source code here
+}
+
+//%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+
+FGColumnVector::FGColumnVector(void):FGMatrix(3,1)
+{
+  if (debug_lvl & 2) cout << "Instantiated: FGColumnVector" << endl;
+}
+
 FGColumnVector::FGColumnVector(int m):FGMatrix(m,1) { }
 FGColumnVector::FGColumnVector(const FGColumnVector& b):FGMatrix(b) { }
-FGColumnVector::~FGColumnVector() { }
+
+FGColumnVector::~FGColumnVector(void)
+{
+//  dealloc(data,rows);
+  if (debug_lvl & 2) cout << "Destroyed:    FGColumnVector" << endl;
+}
 
 //%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 
@@ -473,17 +498,16 @@ FGColumnVector operator*(const FGMatrix& Mat, const FGColumnVector& Col)
 
 FGColumnVector FGColumnVector::operator+(const FGColumnVector& C)
 {
+  FGColumnVector Sum(C.Rows()); // This must be created dynamically
+                                // because we don't know the size of "C",
+                                // it could be 3 or 4 or ...
   if (Rows() != C.Rows()) {
     MatrixException mE;
     mE.Message = "Invalid row/column match in Column Vector operator *";
     throw mE;
   }
 
-  FGColumnVector Sum(C.Rows());
-
-  for (unsigned int i=1; i<=C.Rows(); i++) {
-    Sum(i) = C(i) + data[i][1];
-  }
+  for (unsigned int i=1; i<=C.Rows(); i++) Sum(i) = C(i) + data[i][1];
 
   return Sum;
 }
@@ -503,14 +527,14 @@ FGColumnVector FGColumnVector::operator*(const double scalar)
 
 FGColumnVector FGColumnVector::operator-(const FGColumnVector& V)
 {
+  FGColumnVector Diff(Rows());
+
   if ((Rows() != V.Rows()) || (Cols() != V.Cols())) {
     MatrixException mE;
     mE.Message = "Invalid row/column match in Column Vector operator -";
     throw mE;
   }
 
-  FGColumnVector Diff(Rows());
-
   for (unsigned int i=1; i<=Rows(); i++) {
     Diff(i) = data[i][1] - V(i);
   }
@@ -523,16 +547,13 @@ FGColumnVector FGColumnVector::operator-(const FGColumnVector& V)
 FGColumnVector FGColumnVector::operator/(const double scalar)
 {
   FGColumnVector Quotient(Rows());
-  if(scalar != 0) {
-    
 
+  if (scalar != 0) {
     for (unsigned int i=1; i<=Rows(); i++) Quotient(i) = data[i][1] / scalar;
-
-  } else 
+  } else {
     cerr << "Attempt to divide by zero in method FGColumnVector::operator/(const double scalar), object " << this << endl; 
+  }
   return Quotient;
-  
-    
 }
 
 //%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
@@ -582,16 +603,16 @@ FGColumnVector FGColumnVector::Normalize(void)
 
 //%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 
-FGColumnVector FGColumnVector::operator*(const FGColumnVector& V)
+FGColumnVector& FGColumnVector::operator*(const FGColumnVector& V)
 {
+  static FGColumnVector Product(3);
+
   if (Rows() != 3 || V.Rows() != 3) {
     MatrixException mE;
     mE.Message = "Invalid row count in vector cross product function";
     throw mE;
   }
 
-  FGColumnVector Product(3);
-
   Product(1) = data[2][1] * V(3) - data[3][1] * V(2);
   Product(2) = data[3][1] * V(1) - data[1][1] * V(3);
   Product(3) = data[1][1] * V(2) - data[2][1] * V(1);
@@ -601,16 +622,16 @@ FGColumnVector FGColumnVector::operator*(const FGColumnVector& V)
 
 //%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 
-FGColumnVector FGColumnVector::multElementWise(const FGColumnVector& V)
+FGColumnVector& FGColumnVector::multElementWise(const FGColumnVector& V)
 {
+  static FGColumnVector Product(3);
+
   if (Rows() != 3 || V.Rows() != 3) {
     MatrixException mE;
     mE.Message = "Invalid row count in vector cross product function";
     throw mE;
   }
 
-  FGColumnVector Product(3);
-
   Product(1) = data[1][1] * V(1);
   Product(2) = data[2][1] * V(2);
   Product(3) = data[3][1] * V(3);
@@ -619,3 +640,11 @@ FGColumnVector FGColumnVector::multElementWise(const FGColumnVector& V)
 }
 
 //%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+
+void FGColumnVector::Debug(void)
+{
+    //TODO: Add your source code here
+}
+
+//%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+
index 1acb572e408efd6905a5cad7bd0693e77754fa18..068be0fff8a3e0566db3820bbb4abc5278f74227 100644 (file)
@@ -23,7 +23,7 @@ INCLUDES
 #include <stdlib.h>
 #ifdef FGFS
 #  include <simgear/compiler.h>
-#  ifdef SG_HAVE_STD_INCLUDES
+#  ifdef FG_HAVE_STD_INCLUDES
 #    include <fstream>
 #    include <cmath>
 #    include <iostream>
@@ -44,7 +44,7 @@ INCLUDES
 DEFINITIONS
 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%*/
 
-#define ID_MATRIX "$Header"
+#define ID_MATRIX "$Id$"
 
 using std::string;
 using std::ostream;
@@ -74,20 +74,10 @@ DECLARATION: FGMatrix
 
 class FGMatrix
 {
-protected:
-  double **data;
-
-private:
-  unsigned int rows,cols;
-  char delim;
-  int width,prec,origin;
-  void TransposeSquare(void);
-  void TransposeNonSquare(void);
-  unsigned int rowCtr, colCtr;
-
 public:
   FGMatrix(unsigned int r, unsigned int c);
   FGMatrix(const FGMatrix& A);
+  FGMatrix(void) {};
   ~FGMatrix(void);
 
   FGMatrix& operator=(const FGMatrix& A);
@@ -120,6 +110,18 @@ public:
   friend FGMatrix operator*(double scalar,FGMatrix& A);
 
   void SetOParams(char delim,int width,int prec, int origin=0);
+
+protected:
+  double **data;
+  unsigned int rows,cols;
+
+private:
+  char delim;
+  int width,prec,origin;
+  void TransposeSquare(void);
+  void TransposeNonSquare(void);
+  unsigned int rowCtr, colCtr;
+  void Debug(void);
 };
 
 /*%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
@@ -132,12 +134,12 @@ public:
   FGColumnVector(void);
   FGColumnVector(int m);
   FGColumnVector(const FGColumnVector& b);
-  ~FGColumnVector();
+  ~FGColumnVector(void);
 
   FGColumnVector operator*(const double scalar);
-  FGColumnVector operator*(const FGColumnVector& V);   // Cross product operator
+  FGColumnVector& operator*(const FGColumnVector& V);   // Cross product operator
   FGColumnVector operator/(const double scalar);
-  FGColumnVector operator+(const FGColumnVector& B);
+  FGColumnVector operator+(const FGColumnVector& B); // must not return reference
   FGColumnVector operator-(const FGColumnVector& B);
   float Magnitude(void);
   FGColumnVector Normalize(void);
@@ -147,7 +149,43 @@ public:
 
   double& operator()(int m) const;
   
-  FGColumnVector multElementWise(const FGColumnVector& V);
+  FGColumnVector& multElementWise(const FGColumnVector& V);
+
+private:
+  void Debug(void);
+};
+
+/*%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+DECLARATION: FGMatrix3x3
+%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%*/
+
+class FGMatrix3x3 : public FGMatrix
+{
+public:
+  FGMatrix3x3(void) {FGMatrix(3,3);}
+//  ~FGMatrix3x3(void) {~FGMatrix();}
+};
+
+/*%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+DECLARATION: FGColumnVector4
+%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%*/
+
+class FGColumnVector4 : public FGColumnVector
+{
+public:
+  FGColumnVector4(void) {FGColumnVector(4);}
+//  ~FGColumnVector4(void) {~FGColumnVector();}
+};
+
+/*%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+DECLARATION: FGColumnVector3
+%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%*/
+
+class FGColumnVector3 : public FGColumnVector
+{
+public:
+  FGColumnVector3(void) {FGColumnVector(3);}
+//  ~FGColumnVector3(void) {~FGColumnVector();}
 };
 
 //%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
index dc0a9d998a14b077283cff852aaa44c992dc25b7..5a0fc8412c42e39f94d6deee63ce7c27c44868a6 100644 (file)
@@ -50,9 +50,15 @@ INCLUDES
 #include "FGAuxiliary.h"
 #include "FGOutput.h"
 
-static const char *IdSrc = "$Header$";
+static const char *IdSrc = "$Id$";
 static const char *IdHdr = ID_MODEL;
 
+/*%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+GLOBAL DECLARATIONS
+%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%*/
+
+extern short debug_lvl;
+
 /*%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 CLASS IMPLEMENTATION
 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%*/
@@ -61,10 +67,11 @@ FGModel::FGModel(FGFDMExec* fdmex)
 {
   FDMExec     = fdmex;
   NextModel   = 0L;
-  
+
   State       = 0;
   Atmosphere  = 0;
   FCS         = 0;
+  Propulsion  = 0;
   Aircraft    = 0;
   Translation = 0;
   Rotation    = 0;
@@ -73,19 +80,25 @@ FGModel::FGModel(FGFDMExec* fdmex)
   Output      = 0;
 
   exe_ctr     = 1;
+
+  if (debug_lvl & 2) cout << "              FGModel Base Class" << endl;
 }
 
+//%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 
 FGModel::~FGModel()
 {
+  if (debug_lvl & 2) cout << "Destroyed:    FGModel" << endl;
 }
 
+//%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 
 bool FGModel::InitModel(void)
 {
   State       = FDMExec->GetState();
   Atmosphere  = FDMExec->GetAtmosphere();
   FCS         = FDMExec->GetFCS();
+  Propulsion  = FDMExec->GetPropulsion();
   Aircraft    = FDMExec->GetAircraft();
   Translation = FDMExec->GetTranslation();
   Rotation    = FDMExec->GetRotation();
@@ -96,6 +109,7 @@ bool FGModel::InitModel(void)
   if (!State ||
       !Atmosphere ||
       !FCS ||
+      !Propulsion ||
       !Aircraft ||
       !Translation ||
       !Rotation ||
@@ -105,9 +119,12 @@ bool FGModel::InitModel(void)
   else return(true);
 }
 
+//%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 
 bool FGModel::Run()
 {
+  if (debug_lvl & 4) cout << "Entering Run() for model " << Name << endl;
+
   if (exe_ctr == 1) {
     if (exe_ctr++ >= rate) exe_ctr = 1;
     return false;
@@ -117,4 +134,10 @@ bool FGModel::Run()
   }
 }
 
+//%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+
+void FGModel::Debug(void)
+{
+    //TODO: Add your source code here
+}
 
index 9c8de946f4268ee648b01f653a8ef754b54c096f..d8bc729c0ca10034843d6ab0ac5204f79d78bb7d 100644 (file)
@@ -42,7 +42,7 @@ INCLUDES
 
 #ifdef FGFS
 #  include <simgear/compiler.h>
-#  ifdef SG_HAVE_STD_INCLUDES
+#  ifdef FG_HAVE_STD_INCLUDES
 #    include <iostream>
 #  else
 #    include <iostream.h>
@@ -53,7 +53,7 @@ INCLUDES
 
 #include <string>
 
-#define ID_MODEL "$Header$"
+#define ID_MODEL "$Id$"
 
 /*%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 DEFINITIONS
@@ -69,6 +69,7 @@ class FGFDMExec;
 class FGState;
 class FGAtmosphere;
 class FGFCS;
+class FGPropulsion;
 class FGAircraft;
 class FGTranslation;
 class FGRotation;
@@ -99,7 +100,7 @@ public:
   /// Constructor
   FGModel(FGFDMExec*);
   /// Destructor
-  virtual ~FGModel(void);
+  virtual ~FGModel();
 
   FGModel* NextModel;
   string Name;
@@ -122,20 +123,21 @@ protected:
 
   int exe_ctr;
   int rate;
-  
+
   FGFDMExec*      FDMExec;
   FGState*        State;
   FGAtmosphere*   Atmosphere;
   FGFCS*          FCS;
+  FGPropulsion*   Propulsion;
   FGAircraft*     Aircraft;
   FGTranslation*  Translation;
   FGRotation*     Rotation;
   FGPosition*     Position;
   FGAuxiliary*    Auxiliary;
   FGOutput*       Output;
-
-private:
+  virtual void Debug(void);
 };
 
 //%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 #endif
+
index 69141ceeab5b0c8df373b13455587be3cde7f6a3..c5faef38b9514efaf0525e4019008664e64d33ef 100644 (file)
@@ -37,22 +37,75 @@ INCLUDES
 
 #include "FGNozzle.h"
 
-static const char *IdSrc = "$Header$";
+static const char *IdSrc = "$Id$";
 static const char *IdHdr = ID_NOZZLE;
 
+extern short debug_lvl;
+
 /*%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 CLASS IMPLEMENTATION
 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%*/
 
 
-FGNozzle::FGNozzle(FGFDMExec *FDMExec) : FGThruster(FDMExec)
+FGNozzle::FGNozzle(FGFDMExec* FDMExec, FGConfigFile* Nzl_cfg) : FGThruster(FDMExec)
 {
+  string token;
+
+  Name = Nzl_cfg->GetValue("NAME");
+  cout << "      Nozzle Name: " << Name << endl;
+  Nzl_cfg->GetNextConfigLine();
+  while (Nzl_cfg->GetValue() != "/FG_NOZZLE") {
+    *Nzl_cfg >> token;
+    if (token == "PE") {
+      *Nzl_cfg >> PE;
+      cout << "      Nozzle Exit Pressure = " << PE << endl;
+    } else if (token == "EXPR") {
+      *Nzl_cfg >> ExpR;
+      cout << "      Nozzle Expansion Ratio = " << ExpR << endl;
+    } else if (token == "NZL_EFF") {
+      *Nzl_cfg >> nzlEff;
+      cout << "      Nozzle Efficiency = " << nzlEff << endl;
+    } else if (token == "DIAM") {
+      *Nzl_cfg >> Diameter;
+      cout << "      Nozzle Diameter = " << Diameter << endl;
+    } else {
+      cout << "Unhandled token in Nozzle config file: " << token << endl;
+    }
+  }
+
+  if (debug_lvl & 2) cout << "Instantiated: FGNozzle" << endl;
+}
 
+//%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+
+FGNozzle::~FGNozzle()
+{
+  if (debug_lvl & 2) cout << "Destroyed:    FGNozzle" << endl;
 }
 
+//%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 
-void FGNozzle::Calculate(void)
+float FGNozzle::Calculate(float CfPc)
 {
-  FGThruster::Calculate();
+  float Thrust;
+  float pAtm = fdmex->GetAtmosphere()->GetPressure();
+  
+  Thrust = (CfPc + (PE - pAtm)*ExpR) * (Diameter / ExpR) * nzlEff;
 
+  return Thrust;
 }
+
+//%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+
+float FGNozzle::GetPowerRequired(void)
+{
+  return PE;
+}
+
+//%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+
+void FGNozzle::Debug(void)
+{
+    //TODO: Add your source code here
+}
+
index cf3d14c632c164fbca5d137f8481ca3f9cf7d9a1..78dfb1e466ab8583f7ec9793a530e06afc6eac2e 100644 (file)
@@ -44,7 +44,7 @@ INCLUDES
 
 #include "FGThruster.h"
 
-#define ID_NOZZLE "$Header$";
+#define ID_NOZZLE "$Id$";
 
 /*%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 CLASS DECLARATION
@@ -53,11 +53,20 @@ CLASS DECLARATION
 class FGNozzle : public FGThruster {
 
 public:
-  FGNozzle(FGFDMExec *FDMExec);
-  ~FGNozzle(void);
-
-  void Calculate(void);
+  FGNozzle(FGFDMExec* exec, FGConfigFile* AC_cfg);
+  ~FGNozzle();
+
+  float Calculate(float CfPc);
+  float GetPowerRequired(void);
+  
+private:
+  float PE;
+  float ExpR;
+  float nzlEff;
+  float Diameter;
+  void Debug(void);
 };
 
 //%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 #endif
+
index b85c0e574a285e6ad278fb20c44305823157eea8..21d95e9d5e7643ebfa0de8e738f20b202268a57c 100644 (file)
@@ -49,9 +49,11 @@ INCLUDES
 #include "FGPosition.h"
 #include "FGAuxiliary.h"
 
-static const char *IdSrc = "$Header$";
+static const char *IdSrc = "$Id$";
 static const char *IdHdr = ID_OUTPUT;
 
+extern short debug_lvl;
+
 /*%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 CLASS IMPLEMENTATION
 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%*/
@@ -69,13 +71,15 @@ FGOutput::FGOutput(FGFDMExec* fdmex) : FGModel(fdmex)
 #ifdef FG_WITH_JSBSIM_SOCKET
   socket = new FGfdmSocket("localhost",1138);
 #endif
+  if (debug_lvl & 2) cout << "Instantiated: " << Name << endl;
 }
 
 //%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 
-FGOutput::~FGOutput(void)
+FGOutput::~FGOutput()
 {
   if (socket) delete socket;
+  if (debug_lvl & 2) cout << "Destroyed:    FGOutput" << endl;
 }
 
 //%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
@@ -525,3 +529,8 @@ void FGOutput::SocketStatusOutput(string out_str)
 
 //%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 
+void FGOutput::Debug(void)
+{
+    //TODO: Add your source code here
+}
+
index 603fd77b256e9d69c7c764b91a0e1e8105ae73cb..5d5c91c27e99b767bafb87702937ab316f86640f 100644 (file)
@@ -42,7 +42,7 @@ INCLUDES
 
 #ifdef FGFS
 #  include <simgear/compiler.h>
-#  ifdef SG_HAVE_STD_INCLUDES
+#  ifdef FG_HAVE_STD_INCLUDES
 #    include <iostream>
 #    include <fstream>
 #  else
@@ -56,7 +56,7 @@ INCLUDES
 
 #include "FGfdmSocket.h"
 
-#define ID_OUTPUT "$Header$"
+#define ID_OUTPUT "$Id$"
 
 /*%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 CLASS DECLARATION
@@ -66,7 +66,7 @@ class FGOutput : public FGModel
 {
 public:
   FGOutput(FGFDMExec*);
-  ~FGOutput(void);
+  ~FGOutput();
 
   bool Run(void);
 
@@ -89,6 +89,7 @@ private:
   enum {otNone, otCSV, otTab, otSocket, otTerminal, otUnknown} Type;
   ofstream datafile;
   FGfdmSocket* socket;
+  void Debug(void);
 };
 
 //%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
index 9acbf502ae4b0a682afc0900bd5d686bf88c3d47..914d7fa1b7b0bee7f457eed2fe8fd57b24bbb21b 100644 (file)
@@ -40,17 +40,86 @@ INCLUDES
 
 #include "FGPiston.h"
 
-static const char *IdSrc = "$Header$";
+static const char *IdSrc = "$Id$";
 static const char *IdHdr = ID_PISTON;
 
+extern short debug_lvl;
+
 /*%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 CLASS IMPLEMENTATION
 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%*/
 
+FGPiston::FGPiston(FGFDMExec* exec, FGConfigFile* Eng_cfg) : FGEngine(exec)
+{
+  string token;
+
+  Name = Eng_cfg->GetValue("NAME");
+  cout << "\n    Engine Name: " << Name << endl;
+  Eng_cfg->GetNextConfigLine();
+  while (Eng_cfg->GetValue() != "/FG_PISTON") {
+    *Eng_cfg >> token;
+    if (token == "BRAKEHORSEPOWER") {
+      *Eng_cfg >> BrakeHorsePower;
+      cout << "      BrakeHorsePower = " << BrakeHorsePower << endl;
+    } else if (token == "MAXTHROTTLE") {
+      *Eng_cfg >> MaxThrottle;
+      cout << "      MaxThrottle = " << MaxThrottle << endl;
+    } else if (token == "MINTHROTTLE") {
+      *Eng_cfg >> MinThrottle;
+      cout << "      MinThrottle = " << MinThrottle << endl;
+    } else if (token == "SLFUELFLOWMAX") {
+      *Eng_cfg >> SLFuelFlowMax;
+      cout << "      SLFuelFlowMax = " << SLFuelFlowMax << endl;
+    } else if (token == "SPEEDSLOPE") {
+      *Eng_cfg >> SpeedSlope;
+      cout << "      SpeedSlope = " << SpeedSlope << endl;
+    } else if (token == "SPEEDINTERCEPT") {
+      *Eng_cfg >> SpeedIntercept;
+      cout << "      SpeedIntercept = " << SpeedIntercept << endl;
+    } else if (token == "ALTITUDESLOPE") {
+      *Eng_cfg >> AltitudeSlope;
+      cout << "      AltitudeSlope = " << AltitudeSlope << endl;
+    } else {
+      cout << "Unhandled token in Engine config file: " << token << endl;
+    }
+  }
+
+  EngineNumber = 0;
+
+  if (debug_lvl & 2) cout << "Instantiated: FGPiston" << endl;
+}
+
+//%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+
+FGPiston::~FGPiston()
+{
+  if (debug_lvl & 2) cout << "Destroyed:    FGPiston" << endl;
+}
+
+//%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+
+float FGPiston::Calculate(float PowerRequired)
+{
+  float h,EngineMaxPower;
+
+  ConsumeFuel();
+
+  Throttle = FCS->GetThrottlePos(EngineNumber);
+
+  h = Position->Geth();
+
+  if (h < 0) h = 0;
+
+  EngineMaxPower = (1 + AltitudeSlope*h)*BrakeHorsePower;
+  PowerAvailable = Throttle*EngineMaxPower*HPTOFTLBSSEC - PowerRequired;
+  
+  return PowerAvailable;
+}
+
+//%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 
-FGPiston::FGPiston(FGFDMExec* fdex, string enginePath, string engineName, int num) :
-                                 FGEngine(fdex, enginePath, engineName, num)
+void FGPiston::Debug(void)
 {
-  //
+    //TODO: Add your source code here
 }
 
index 579eb82de4f39588ec4c80af79e0470d637046a4..a71197c3b0dbd0081d533ee3009779ebd01c32e4 100644 (file)
@@ -43,8 +43,9 @@ INCLUDES
 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%*/
 
 #include "FGEngine.h"
+#include "FGConfigFile.h"
 
-#define ID_PISTON "$Header$";
+#define ID_PISTON "$Id$";
 
 /*%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 CLASS DECLARATION
@@ -52,12 +53,22 @@ CLASS DECLARATION
 
 class FGPiston : public FGEngine
 {
-
 public:
-  FGPiston(FGFDMExec*, string, string, int);
+  FGPiston(FGFDMExec* exec, FGConfigFile* Eng_cfg);
   ~FGPiston();
 
+  float Calculate(float PowerRequired);
+  float GetPowerAvailable(void) {return PowerAvailable;}
+
+private:
+  float BrakeHorsePower;
+  float SpeedSlope;
+  float SpeedIntercept;
+  float AltitudeSlope;
+  float PowerAvailable;
+  void Debug(void);
 };
 
 //%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 #endif
+
index 2a895b4c551b4403abe9e9dd173a2b55820a43b4..984e1bc7b5b690616eb261900c51e2a651a1f3dd 100644 (file)
@@ -29,11 +29,11 @@ FUNCTIONAL DESCRIPTION
 --------------------------------------------------------------------------------
 This class encapsulates the integration of rates and accelerations to get the
 current position of the aircraft.
+
 HISTORY
 --------------------------------------------------------------------------------
 01/05/99   JSB   Created
+
 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 COMMENTS, REFERENCES,  and NOTES
 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
@@ -48,14 +48,14 @@ COMMENTS, REFERENCES,  and NOTES
     Wiley & Sons, 1979 ISBN 0-471-03032-5
 [5] Bernard Etkin, "Dynamics of Flight, Stability and Control", Wiley & Sons,
     1982 ISBN 0-471-08936-2
+
 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 INCLUDES
 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%*/
 
 #ifdef FGFS
 #  include <simgear/compiler.h>
-#  ifdef SG_HAVE_STD_INCLUDES
+#  ifdef FG_HAVE_STD_INCLUDES
 #    include <cmath>
 #    include <iomanip>
 #  else
@@ -78,9 +78,11 @@ INCLUDES
 #include "FGAuxiliary.h"
 #include "FGOutput.h"
 
-static const char *IdSrc = "$Header$";
+static const char *IdSrc = "$Id$";
 static const char *IdHdr = ID_POSITION;
 
+extern short debug_lvl;
+
 /*%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 CLASS IMPLEMENTATION
 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%*/
@@ -106,13 +108,19 @@ FGPosition::FGPosition(FGFDMExec* fdmex) : FGModel(fdmex),
   RunwayRadius   = SeaLevelRadius;
   DistanceAGL    = Radius - RunwayRadius;  // Geocentric
   vRunwayNormal(3) = -1.0;                 // Initialized for standalone mode
+
+  if (debug_lvl & 2) cout << "Instantiated: " << Name << endl;
 }
 
 //%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 
-FGPosition::~FGPosition(void) {}
+FGPosition::~FGPosition()
+{
+  if (debug_lvl & 2) cout << "Destroyed:    FGPosition" << endl;
+}
 
-/*************************************************************************** Run
+//%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+/*
 Purpose: Called on a schedule to perform Positioning algorithms
 Notes:   [TP] Make sure that -Vt <= hdot <= Vt, which, of course, should always
          be the case
@@ -128,7 +136,10 @@ bool FGPosition:: Run(void) {
     GetState();
 
     Vground = sqrt( vVel(eNorth)*vVel(eNorth) + vVel(eEast)*vVel(eEast) );
-    
+    psigt =  atan2(vVel(eEast), vVel(eNorth));
+    if(psigt < 0.0)
+      psigt += 2*M_PI;
+
     invMass   = 1.0 / Aircraft->GetMass();
     Radius    = h + SeaLevelRadius;
     invRadius = 1.0 / Radius;
@@ -174,21 +185,32 @@ void FGPosition::GetState(void) {
 
   vUVW      = Translation->GetUVW();
   Vt        = Translation->GetVt();
-  vVel      = State->GetTb2l()*vUVW;
+  vVel      = State->GetTb2l()*vUVW + Atmosphere->GetWindNED();
   vVelDot   = State->GetTb2l() * Translation->GetUVWdot();
 
   b = Aircraft->GetWingSpan();
-  
 }
 
-void FGPosition::Seth(double tt) { 
- h=tt;
+//%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+
+void FGPosition::Seth(double tt) {
+ h = tt;
  Radius    = h + SeaLevelRadius;
- DistanceAGL = Radius - RunwayRadius;   // Geocentric 
-}  
+ DistanceAGL = Radius - RunwayRadius;   // Geocentric
+}
+
+//%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 
 void FGPosition::SetDistanceAGL(double tt) {
   DistanceAGL=tt;
   Radius = RunwayRadius + DistanceAGL;
   h = Radius - SeaLevelRadius;
-}  
+}
+
+//%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+
+void FGPosition::Debug(void)
+{
+    //TODO: Add your source code here
+}
+
index 0051817b2a2b32082f33b4a0aa62542f2ff8a521..8d2d45e85e0e24f313e65d8cac429719f9142d51 100644 (file)
@@ -45,7 +45,7 @@ INCLUDES
 DEFINITIONS
 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%*/
 
-#define ID_POSITION "$Header$"
+#define ID_POSITION "$Id$"
 
 /*%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 FORWARD DECLARATIONS
@@ -74,7 +74,7 @@ public:
       @param Executive a pointer to the parent executive object */
   FGPosition(FGFDMExec*);
   /// Destructor
-  ~FGPosition(void);
+  ~FGPosition();
 
   /** Runs the Position model; called by the Executive
       @see JSBSim.cpp documentation
@@ -88,6 +88,7 @@ public:
   inline double GetVe(void)  { return vVel(eY); }
   inline double GetVd(void)  { return vVel(eZ); }
   inline double GetVground(void) { return Vground; }
+  inline double GetGroundTrack(void) { return psigt; }
   inline double Geth(void)  { return h; }
   inline double Gethdot(void) { return RadiusDot; }
   inline double GetLatitude(void) { return Latitude; }
@@ -131,10 +132,12 @@ private:
   double Vt, Vground;
   double hoverb,b;
 
-  void GetState(void);
+  double psigt;
 
-  
+  void GetState(void);
+  void Debug(void);
 };
 
 //%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 #endif
+
index 5eefe09ff897bbcface12e5b55eca981b4e857d3..96176e0f52e0bec526cb712123e34fdb27067af7 100644 (file)
@@ -37,22 +37,148 @@ INCLUDES
 
 #include "FGPropeller.h"
 
-static const char *IdSrc = "$Header$";
+static const char *IdSrc = "$Id$";
 static const char *IdHdr = ID_PROPELLER;
 
+extern short debug_lvl;
+
 /*%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 CLASS IMPLEMENTATION
 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%*/
 
 
-FGPropeller::FGPropeller(FGFDMExec *FDMExec) : FGThruster(FDMExec)
+FGPropeller::FGPropeller(FGFDMExec* exec, FGConfigFile* Prop_cfg) : FGThruster(exec)
+{
+  string token;
+  int rows, cols;
+
+  PropName = Prop_cfg->GetValue("NAME");
+  cout << "\n    Propeller Name: " << PropName << endl;
+  Prop_cfg->GetNextConfigLine();
+  while (Prop_cfg->GetValue() != "/FG_PROPELLER") {
+    *Prop_cfg >> token;
+    if (token == "IXX") {
+      *Prop_cfg >> Ixx;
+      cout << "      IXX = " << Ixx << endl;
+    } else if (token == "DIAMETER") {
+      *Prop_cfg >> Diameter;
+      Diameter /= 12.0;
+      cout << "      Diameter = " << Diameter << " ft." << endl;
+    } else if (token == "NUMBLADES") {
+      *Prop_cfg >> numBlades;
+      cout << "      Number of Blades  = " << numBlades << endl;
+    } else if (token == "EFFICIENCY") {
+       *Prop_cfg >> rows >> cols;
+       if (cols == 1) Efficiency = new FGTable(rows);
+            else           Efficiency = new FGTable(rows, cols);
+       *Efficiency << *Prop_cfg;
+       cout << "      Efficiency: " <<  endl;
+       Efficiency->Print();
+    } else if (token == "C_THRUST") {
+       *Prop_cfg >> rows >> cols;
+       if (cols == 1) cThrust = new FGTable(rows);
+            else           cThrust = new FGTable(rows, cols);
+       *cThrust << *Prop_cfg;
+       cout << "      Thrust Coefficient: " <<  endl;
+       cThrust->Print();
+    } else if (token == "C_POWER") {
+       *Prop_cfg >> rows >> cols;
+       if (cols == 1) cPower = new FGTable(rows);
+            else           cPower = new FGTable(rows, cols);
+       *cPower << *Prop_cfg;
+       cout << "      Power Coefficient: " <<  endl;
+       cPower->Print();
+    } else if (token == "EOF") {
+       cout << "      End of file reached" <<  endl;
+       break;
+    } else {
+      cout << "Unhandled token in Propeller config file: " << token << endl;
+    }
+  }
+
+  if (debug_lvl & 2) cout << "Instantiated: FGPropeller" << endl;
+}
+
+//%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+
+FGPropeller::~FGPropeller()
 {
+  if (Efficiency) delete Efficiency;
+  if (cThrust)    delete cThrust;
+  if (cPower)     delete cPower;
+  if (debug_lvl & 2) cout << "Destroyed:    FGPropeller" << endl;
+}
 
+//%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+//
+// We must be getting the aerodynamic velocity here, NOT the inertial velocity.
+// We need the velocity with respect to the wind.
+//
+// Note that PowerAvailable is the excess power available after the drag of the
+// propeller has been subtracted. At equilibrium, PowerAvailable will be zero -
+// indicating that the propeller will not accelerate or decelerate.
+// Remembering that Torque * omega = Power, we can derive the torque on the
+// propeller and its acceleration to give a new RPM. The current RPM will be
+// used to calculate thrust.
+//
+// Because RPM could be zero, we need to be creative about what RPM is stated as.
+
+float FGPropeller::Calculate(float PowerAvailable)
+{
+  float J, C_Thrust, omega;
+  float Vel = (fdmex->GetTranslation()->GetUVW())(1);
+  float rho = fdmex->GetAtmosphere()->GetDensity();
+  float RPS = RPM/60.0;
+
+  if (RPM > 0.10) {
+    J = Vel / (Diameter * RPM / 60.0);
+  } else {
+    J = 0.0;
+  }
+
+  if (MaxPitch == MinPitch) { // Fixed pitch prop
+    C_Thrust = cThrust->GetValue(J);
+  } else {                    // Variable pitch prop
+    C_Thrust = cThrust->GetValue(J, Pitch);
+  }
+
+  Thrust = C_Thrust*RPS*RPS*Diameter*Diameter*Diameter*Diameter*rho;
+  vFn(1) = Thrust;
+  omega = RPS*2.0*M_PI;
+
+  if (omega <= 500) omega = 1.0;
+
+  Torque = PowerAvailable / omega;
+  RPM = (RPS + ((Torque / Ixx) / (2.0 * M_PI)) * deltaT) * 60.0;
+  return Thrust; // return thrust in pounds
 }
 
+//%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 
-void FGPropeller::Calculate(void)
+float FGPropeller::GetPowerRequired(void)
 {
-  FGThruster::Calculate();
+  if (RPM <= 0.10) return 0.0; // If the prop ain't turnin', the fuel ain't burnin'.
+
+  float cPReq, RPS = RPM / 60.0;
 
+  float J = (fdmex->GetTranslation()->GetUVW())(1) / (Diameter * RPS);
+  float rho = fdmex->GetAtmosphere()->GetDensity();
+
+  if (MaxPitch == MinPitch) { // Fixed pitch prop
+    cPReq = cPower->GetValue(J);
+  } else {                    // Variable pitch prop
+    cPReq = cPower->GetValue(J, Pitch);
+  }
+
+  PowerRequired = cPReq*RPS*RPS*RPS*Diameter*Diameter*Diameter*Diameter
+                                                       *Diameter*rho;
+  return PowerRequired;
 }
+
+//%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+
+void FGPropeller::Debug(void)
+{
+    //TODO: Add your source code here
+}
+
index 5c2010eb0991789fe44799d36a23638e26a116cc..aaabfea56a0134f6d5dfe7444cf099af856221b6 100644 (file)
@@ -27,10 +27,6 @@ HISTORY
 --------------------------------------------------------------------------------
 08/24/00  JSB  Created
 
-%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
-COMMENTS, REFERENCES,  and NOTES
-%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
-
 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 SENTRY
 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%*/
@@ -43,8 +39,48 @@ INCLUDES
 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%*/
 
 #include "FGThruster.h"
+#include "FGTable.h"
+#include "FGTranslation.h"
+
+/*%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+DEFINITIONS
+%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%*/
+
+#define ID_PROPELLER "$Id$"
+
+/*%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+FORWARD DECLARATIONS
+%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%*/
 
-#define ID_PROPELLER "$Header$"
+/*%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+COMMENTS, REFERENCES, and NOTES [use "class documentation" below for API docs]
+%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%*/
+
+/*%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+CLASS DOCUMENTATION
+%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%*/
+
+/** Propeller modeling class.
+    FGPropeller models a propeller given the tabular data for Ct, Cp, and
+    efficiency indexed by advance ratio "J". The data for the propeller is
+    stored in a config file named "prop_name.xml". The propeller config file
+    is referenced from the main aircraft config file in the "Propulsion" section.
+    See the constructor for FGPropeller to see what is read in and what should
+    be stored in the config file.<br>
+    Several references were helpful, here:<ul>
+    <li>Barnes W. McCormick, "Aerodynamics, Aeronautics, and Flight Mechanics",
+     Wiley & Sons, 1979 ISBN 0-471-03032-5</li>
+    <li>Edwin Hartman, David Biermann, "The Aerodynamic Characteristics of
+    Full Scale Propellers Having 2, 3, and 4 Blades of Clark Y and R.A.F. 6
+    Airfoil Sections", NACA Report TN-640, 1938 (?)</li>
+    <li>Various NACA Technical Notes and Reports</li>
+    <ul>
+    @author Jon S. Berndt
+    @version $Id$
+    @see FGEngine
+    @see FGThruster
+    @see FGTable
+*/
 
 /*%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 CLASS DECLARATION
@@ -53,11 +89,80 @@ CLASS DECLARATION
 class FGPropeller : public FGThruster {
 
 public:
-  FGPropeller(FGFDMExec *FDMExec);
-  ~FGPropeller(void);
-
-  void Calculate(void);
+  /** Constructor for FGPropeller.
+      @param exec a pointer to the main executive object
+      @param AC_cfg a pointer to the main aircraft config file object */
+  FGPropeller(FGFDMExec* exec, FGConfigFile* AC_cfg);
+
+  /// Destructor for FGPropeller - deletes the FGTable objects
+  ~FGPropeller();
+
+  /** Sets the Revolutions Per Minute for the propeller. Normally the propeller
+      instance will calculate its own rotational velocity, given the Torque
+      produced by the engine and integrating over time using the standard
+      equation for rotational acceleration "a": a = Q/I , where Q is Torque and
+      I is moment of inertia for the propeller.
+      @param rpm the rotational velocity of the propeller */
+  void SetRPM(float rpm) {RPM = rpm;}
+
+  /** This commands the pitch of the blade to change to the value supplied.
+      This call is meant to be issued either from the cockpit or by the flight
+      control system (perhaps to maintain constant RPM for a constant-speed
+      propeller). This value will be limited to be within whatever is specified
+      in the config file for Max and Min pitch. It is also one of the lookup
+      indices to the power, thrust, and efficiency tables for variable-pitch
+      propellers.
+      @param pitch the pitch of the blade in degrees. */
+  void SetPitch(float pitch) {Pitch = pitch;}
+
+  /// Retrieves the pitch of the propeller in degrees.
+  float GetPitch(void)         { return Pitch;         }
+  
+  /// Retrieves the RPMs of the propeller
+  float GetRPM(void)           { return RPM;           }
+  
+  /// Retrieves the propeller moment of inertia
+  float GetIxx(void)           { return Ixx;           }
+  
+  /// Retrieves the Thrust in pounds
+  float GetThrust(void)        { return Thrust;        }
+  
+  /// Retrieves the Torque in foot-pounds (Don't you love the English system?)
+  float GetTorque(void)        { return Torque;        }
+  
+  /** Retrieves the power required (or "absorbed") by the propeller -
+      i.e. the power required to keep spinning the propeller at the current
+      velocity, air density,  and rotational rate. */
+  float GetPowerRequired(void);
+  
+  /** Calculates and returns the thrust produced by this propeller.
+      Given the excess power available from the engine (in foot-pounds), the thrust is
+      calculated, as well as the current RPM. The RPM is calculated by integrating
+      the torque provided by the engine over what the propeller "absorbs"
+      (essentially the "drag" of the propeller).
+      @param PowerAvailable this is the excess power provided by the engine to
+      accelerate the prop. It could be negative, dictating that the propeller
+      would be slowed.
+                 @return the thrust in pounds */
+  float Calculate(float PowerAvailable);
+
+private:
+  string PropName;
+  int   numBlades;
+  float RPM;
+  float Ixx;
+  float Diameter;
+  float MaxPitch;
+  float MinPitch;
+  float Pitch;
+  float Thrust;
+  float Torque;
+  FGTable *Efficiency;
+  FGTable *cThrust;
+  FGTable *cPower;
+  void Debug(void);
 };
 
 //%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 #endif
+
index 4536b5ed44e018b9c9768f1090c3954fb39efe38..2530429a3d79d09ff04100e1b120b06644a79822 100644 (file)
@@ -34,13 +34,9 @@ propeller). Once the Propulsion class gets the config file, it reads in
 information which is specific to a type of engine. Then:
 
 1) The appropriate engine type instance is created
-2) At least one thruster object is instantiated, and is linked to the engine
+2) A thruster object is instantiated, and is linked to the engine
 3) At least one tank object is created, and is linked to an engine.
 
-Note: Thusters can be linked to more than one engine and engines can be linked
-to more than one thruster. It is the same with tanks - a many to many
-relationship can be established.
-
 At Run time each engines Calculate() method is called to return the excess power
 generated during that iteration. The drag from the previous iteration is sub-
 tracted to give the excess power available for thrust this pass. That quantity
@@ -58,23 +54,56 @@ INCLUDES
 
 #include "FGPropulsion.h"
 
-static const char *IdSrc = "$Header$";
+static const char *IdSrc = "$Id$";
 static const char *IdHdr = ID_PROPULSION;
 
+extern short debug_lvl;
+
 /*%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 CLASS IMPLEMENTATION
 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%*/
 
 
-FGPropulsion::FGPropulsion(FGFDMExec* fgex) : FGModel(fgex)
+FGPropulsion::FGPropulsion(FGFDMExec* exec) : FGModel(exec)
 {
+  Name = "FGPropulsion";
+  numSelectedFuelTanks = numSelectedOxiTanks = 0;
+  numTanks = numEngines = numThrusters = 0;
+  numOxiTanks = numFuelTanks = 0;
+  Forces  = new FGColumnVector(3);
+  Moments = new FGColumnVector(3);
+
+  if (debug_lvl & 2) cout << "Instantiated: " << Name << endl;
+}
+
+//%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 
+FGPropulsion::~FGPropulsion()
+{
+  for (unsigned int i=0; i<Engines.size(); i++) delete Engines[i];
+  Engines.clear();
+  if (Forces) delete Forces;
+  if (Moments) delete Moments;
+  if (debug_lvl & 2) cout << "Destroyed:    FGPropulsion" << endl;
 }
 
+//%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 
-bool FGPropulsion:: Run(void) {
+bool FGPropulsion::Run(void) {
+  float PowerAvailable;
+  dt = State->Getdt();
+
+  Forces->InitMatrix();
+  Moments->InitMatrix();
 
   if (!FGModel::Run()) {
+    for (unsigned int i=0; i<numEngines; i++) {
+      Thrusters[i]->SetdeltaT(dt*rate);
+      PowerAvailable = Engines[i]->Calculate(Thrusters[i]->GetPowerRequired());
+      Thrusters[i]->Calculate(PowerAvailable);
+      *Forces  += Thrusters[i]->GetBodyForces();  // sum body frame forces
+      *Moments += Thrusters[i]->GetMoments();     // sum body frame moments
+    }
 
     return false;
   } else {
@@ -82,38 +111,182 @@ bool FGPropulsion:: Run(void) {
   }
 }
 
+//%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+
+bool FGPropulsion::GetSteadyState(void) {
+  float PowerAvailable;
+  float currentThrust = 0, lastThrust=-1;
+  dt = State->Getdt();
+
+  Forces->InitMatrix();
+  Moments->InitMatrix();
+
+  if (!FGModel::Run()) {
+    for (unsigned int i=0; i<numEngines; i++) {
+      Engines[i]->SetTrimMode(true);
+      Thrusters[i]->SetdeltaT(dt*rate);
+      while (pow(currentThrust - lastThrust, 2.0) > currentThrust*0.00010) {
+        PowerAvailable = Engines[i]->Calculate(Thrusters[i]->GetPowerRequired());
+        lastThrust = currentThrust;
+        currentThrust = Thrusters[i]->Calculate(PowerAvailable);
+      }
+      *Forces  += Thrusters[i]->GetBodyForces();  // sum body frame forces
+      *Moments += Thrusters[i]->GetMoments();     // sum body frame moments
+      Engines[i]->SetTrimMode(false);
+    }
+
+    return false;
+  } else {
+    return true;
+  }
+}
+
+//%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 
 bool FGPropulsion::LoadPropulsion(FGConfigFile* AC_cfg)
 {
-  string token;
-  string engine_name;
+  string token, fullpath;
+  string engineFileName, engType;
+  string thrusterFileName, thrType;
   string parameter;
-  int numEngines=0, numTanks=0;
+  string enginePath = FDMExec->GetEnginePath();
+  float xLoc, yLoc, zLoc, Pitch, Yaw;
+  int Feed;
+
+# ifndef macintosh
+      fullpath = enginePath + "/";
+# else
+      fullpath = enginePath + ";";
+# endif
 
   AC_cfg->GetNextConfigLine();
 
   while ((token = AC_cfg->GetValue()) != "/PROPULSION") {
-    *AC_cfg >> parameter;
 
-    if (parameter == "AC_ENGINE") {
+    if (token == "AC_ENGINE") {                   // ============ READING ENGINES
+
+      engineFileName = AC_cfg->GetValue("FILE");
 
-      *AC_cfg >> engine_name;
-      Engines[numEngines] = *(new FGEngine(FDMExec, FDMExec->GetEnginePath(), engine_name, numEngines));
-      numEngines++;
+      cout << "\n    Reading engine from file: " << fullpath
+                                                   + engineFileName + ".xml"<< endl;
+      FGConfigFile Eng_cfg(fullpath + engineFileName + ".xml");
 
-    } else if (parameter == "AC_TANK") {
+      if (Eng_cfg.IsOpen()) {
+        Eng_cfg.GetNextConfigLine();
+        engType = Eng_cfg.GetValue();
 
-      Tanks[numTanks] = *(new FGTank(AC_cfg));
-      switch(Tanks[numTanks].GetType()) {
+        FCS->AddThrottle();
+
+        if (engType == "FG_ROCKET") {
+          Engines.push_back(new FGRocket(FDMExec, &Eng_cfg));
+        } else if (engType == "FG_PISTON") {
+          Engines.push_back(new FGPiston(FDMExec, &Eng_cfg));
+        } else if (engType == "FG_TURBOJET") {
+          Engines.push_back(new FGTurboJet(FDMExec, &Eng_cfg));
+        } else if (engType == "FG_TURBOSHAFT") {
+          Engines.push_back(new FGTurboShaft(FDMExec, &Eng_cfg));
+        } else if (engType == "FG_TURBOPROP") {
+          Engines.push_back(new FGTurboProp(FDMExec, &Eng_cfg));
+        } else {
+          cerr << "    Unrecognized engine type: " << engType << " found in config file.\n";
+        }
+
+        AC_cfg->GetNextConfigLine();
+        while ((token = AC_cfg->GetValue()) != "/AC_ENGINE") {
+          *AC_cfg >> token;
+          if (token == "XLOC") { *AC_cfg >> xLoc; cout << "      X = " << xLoc << endl;}
+          else if (token == "YLOC") { *AC_cfg >> yLoc; cout << "      Y = " << yLoc << endl;}
+          else if (token == "ZLOC") { *AC_cfg >> zLoc; cout << "      Z = " << zLoc << endl;}
+          else if (token == "PITCH") { *AC_cfg >> Pitch; cout << "      Pitch = " << Pitch << endl;}
+          else if (token == "YAW") { *AC_cfg >> Yaw; cout << "      Yaw = " << Yaw << endl;}
+          else if (token == "FEED") {
+            *AC_cfg >> Feed;
+            Engines[numEngines]->AddFeedTank(Feed);
+            cout << "      Feed tank: " << Feed << endl;
+          } else cerr << "Unknown identifier: " << token << " in engine file: "
+                                                        << engineFileName << endl;
+        }
+        
+        Engines[numEngines]->SetPlacement(xLoc, yLoc, zLoc, Pitch, Yaw);
+        numEngines++;
+
+      } else {
+      
+        cerr << "Could not read engine config file: " << fullpath
+                                                  + engineFileName + ".xml" << endl;
+        return false;
+      }
+
+    } else if (token == "AC_TANK") {              // ============== READING TANKS
+
+      cout << "\n    Reading tank definition" << endl;
+      Tanks.push_back(new FGTank(AC_cfg));
+      switch(Tanks[numTanks]->GetType()) {
       case FGTank::ttFUEL:
-//        numSelectedFuelTanks++;
+        numSelectedFuelTanks++;
+        numFuelTanks++;
         break;
       case FGTank::ttOXIDIZER:
-//        numSelectedOxiTanks++;
+        numSelectedOxiTanks++;
+        numOxiTanks++;
         break;
       }
+      
       numTanks++;
+
+    } else if (token == "AC_THRUSTER") {          // ========== READING THRUSTERS
+
+      thrusterFileName = AC_cfg->GetValue("FILE");
+
+      cout << "\n    Reading thruster from file: " <<
+                                       fullpath + thrusterFileName + ".xml" << endl;
+      FGConfigFile Thruster_cfg(fullpath + thrusterFileName + ".xml");
+
+      if (Thruster_cfg.IsOpen()) {
+        Thruster_cfg.GetNextConfigLine();
+        thrType = Thruster_cfg.GetValue();
+
+        if (thrType == "FG_PROPELLER") {
+          Thrusters.push_back(new FGPropeller(FDMExec, &Thruster_cfg));
+        } else if (thrType == "FG_NOZZLE") {
+          Thrusters.push_back(new FGNozzle(FDMExec, &Thruster_cfg));
+        }
+
+        AC_cfg->GetNextConfigLine();
+        while ((token = AC_cfg->GetValue()) != "/AC_THRUSTER") {
+          *AC_cfg >> token;
+          if (token == "XLOC") *AC_cfg >> xLoc;
+          else if (token == "YLOC") *AC_cfg >> yLoc;
+          else if (token == "ZLOC") *AC_cfg >> zLoc;
+          else if (token == "PITCH") *AC_cfg >> Pitch;
+          else if (token == "YAW") *AC_cfg >> Yaw;
+          else cerr << "Unknown identifier: " << token << " in engine file: "
+                                                        << engineFileName << endl;
+        }
+
+        Thrusters[numThrusters]->SetLocation(xLoc, yLoc, zLoc);
+        Thrusters[numThrusters]->SetAnglesToBody(0, Pitch, Yaw);
+        Thrusters[numThrusters]->SetdeltaT(dt*rate);
+
+        numThrusters++;
+
+      } else {
+        cerr << "Could not read thruster config file: " << fullpath
+                                                + thrusterFileName + ".xml" << endl;
+        return false;
+      }
+
     }
+    AC_cfg->GetNextConfigLine();
   }
+
+  return true;
+}
+
+//%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+
+void FGPropulsion::Debug(void)
+{
+    //TODO: Add your source code here
 }
 
index c67c6a4328a201e4e290d35614c21027a7e22d51..bd2e667d6adfa847af587bc793f3e9e25c1f82bd 100644 (file)
@@ -27,10 +27,6 @@ HISTORY
 --------------------------------------------------------------------------------
 08/20/00   JSB   Created
  
-%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
-COMMENTS, REFERENCES,  and NOTES
-%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 SENTRY
 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%*/
@@ -38,15 +34,13 @@ SENTRY
 #ifndef FGPROPULSION_H
 #define FGPROPULSION_H
 
-#define ID_PROPULSION "$Header$"
-
 /*%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 INCLUDES
 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%*/
 
 #ifdef FGFS
 #  include <simgear/compiler.h>
-#  ifdef SG_HAVE_STD_INCLUDES
+#  ifdef FG_HAVE_STD_INCLUDES
 #    include <vector>
 #  else
 #    include <vector.h>
@@ -57,24 +51,131 @@ INCLUDES
 
 #include "FGModel.h"
 
-#include "FGEngine.h"
+#include "FGRocket.h"
+#include "FGPiston.h"
+#include "FGTurboShaft.h"
+#include "FGTurboJet.h"
+#include "FGTurboProp.h"
 #include "FGTank.h"
-#include "FGThruster.h"
-#include "FGConfigFile.h"
+#include "FGPropeller.h"
+#include "FGNozzle.h"
+
+/*%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+DEFINITIONS
+%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%*/
+
+#define ID_PROPULSION "$Id$"
+
+/*%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+FORWARD DECLARATIONS
+%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%*/
+
+/*%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+COMMENTS, REFERENCES, and NOTES [use "class documentation" below for API docs]
+%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%*/
+
+/*%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+CLASS DOCUMENTATION
+%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%*/
+
+/** Propulsion management class.
+    FGPropulsion manages all aspects of propulsive force generation, including
+    containment of engines, tanks, and thruster class instances in STL vectors,
+    and the interaction and communication between them.
+    @author Jon S. Berndt
+    @version $Id$
+    @see FGEngine
+    @see FGTank
+    @see FGThruster
+*/
 
 /*%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 CLASS DECLARATION
 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%*/
 
 class FGPropulsion : public FGModel {
-  vector <FGEngine>   Engines;
-  vector <FGTank>     Tanks;
-  vector <FGThruster> Thrusters;
 public:
   FGPropulsion(FGFDMExec*);
+  ~FGPropulsion();
+
+  /** Executes the propulsion model.
+      The initial plan for the FGPropulsion class calls for Run() to be executed,
+      performing the following tasks:
+      <ol>
+  <li>Determine the drag - or power required - for the attached thrust effector
+      for this engine so that any feedback to the engine can be performed. This
+      is done by calling FGThruster::CalculatePReq()</li>
+  <li>Given 1, above, calculate the power available from the engine. This is
+      done by calling FGEngine::CalculatePAvail()</li>
+  <li>Next, calculate the thrust output from the thruster model given the power
+      available and the power required. This may also result in new performance
+      numbers for the thruster in the case of the propeller, at least. This
+      result is returned from a call to Calculate().</li></ol>
 
+      [Note: Should we be checking the Starved flag here?] */
   bool Run(void);
+
+  /** Loads the propulsion system (engine[s], tank[s], thruster[s]).
+      Characteristics of the propulsion system are read in from the config file.
+      @param AC_cfg pointer to the config file instance that describes the
+             aircraft being modeled.
+      @return true if successfully loaded, otherwise false */
   bool LoadPropulsion(FGConfigFile* AC_cfg);
+
+  /// Retrieves the number of engines defined for the aircraft.
+  inline unsigned int GetNumEngines(void) {return Engines.size();}
+
+  /** Retrieves an engine object pointer from the list of engines.
+      @param index the engine index within the vector container
+      @return the address of the specific engine, or zero if no such engine is
+              available */
+  inline FGEngine* GetEngine(unsigned int index) {
+                      if (index <= Engines.size()-1) return Engines[index];
+                      else                           return 0L;      }
+
+  /** Retrieves a tank object pointer from the list of tanks.
+      @param index the tank index within the vector container
+      @return the address of the specific tank, or zero if no such tank is
+              available */
+  inline FGTank* GetTank(unsigned int index) {
+                      if (index <= Tanks.size()-1) return Tanks[index];
+                      else                         return 0L;        }
+
+  /** Retrieves a thruster object pointer from the list of thrusters.
+      @param index the thruster index within the vector container
+      @return the address of the specific thruster, or zero if no such thruster is
+              available */
+  inline FGThruster* GetThruster(unsigned int index) {
+                      if (index <= Thrusters.size()-1) return Thrusters[index];
+                      else                             return 0L;    }
+
+  /** Returns the number of fuel tanks currently actively supplying fuel */
+  inline int GetnumSelectedFuelTanks(void) {return numSelectedFuelTanks;}
+
+  /** Returns the number of oxidizer tanks currently actively supplying oxidizer */
+  inline int GetnumSelectedOxiTanks(void)  {return numSelectedOxiTanks;}
+
+  bool GetSteadyState(void);
+
+
+  inline FGColumnVector& GetForces(void)  {return *Forces; }
+  inline FGColumnVector& GetMoments(void) {return *Moments;}
+
+private:
+  vector <FGEngine*>   Engines;
+  vector <FGTank*>     Tanks;
+  vector <FGThruster*> Thrusters;
+  unsigned int numSelectedFuelTanks;
+  unsigned int numSelectedOxiTanks;
+  unsigned int numFuelTanks;
+  unsigned int numOxiTanks;
+  unsigned int numEngines;
+  unsigned int numTanks;
+  unsigned int numThrusters;
+  float dt;
+  FGColumnVector *Forces;
+  FGColumnVector *Moments;
+  void Debug(void);
 };
 
 //%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
index 962b5bb3829f98a44d628ea1aa7d8b831c0dba94..3b38c0d495a0b55d9b0da6ef0253f7c0128a0fc5 100644 (file)
@@ -40,17 +40,101 @@ INCLUDES
 
 #include "FGRocket.h"
 
-static const char *IdSrc = "$Header$";
+static const char *IdSrc = "$Id$";
 static const char *IdHdr = ID_ROCKET;
 
+extern short debug_lvl;
+
 /*%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 CLASS IMPLEMENTATION
 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%*/
 
+FGRocket::FGRocket(FGFDMExec* exec, FGConfigFile* Eng_cfg) : FGEngine(exec)
+{
+  string token;
+
+  Name = Eng_cfg->GetValue("NAME");
+  cout << "      Engine Name: " << Name << endl;
+  Eng_cfg->GetNextConfigLine();
+  while (Eng_cfg->GetValue() != "/FG_ROCKET") {
+    *Eng_cfg >> token;
+    if (token == "SHR") {
+      *Eng_cfg >> SHR;
+      cout << "      Specific Heat Ratio = " << SHR << endl;
+    } else if (token == "MAX_PC") {
+      *Eng_cfg >> maxPC;
+      cout << "      Maximum Chamber Pressure = " << maxPC << endl;
+    } else if (token == "PROP_EFF") {
+      *Eng_cfg >> propEff;
+      cout << "      Propulsive Efficiency = " << propEff << endl;
+    } else if (token == "MAXTHROTTLE") {
+      *Eng_cfg >> MaxThrottle;
+      cout << "      MaxThrottle = " << MaxThrottle << endl;
+    } else if (token == "MINTHROTTLE") {
+      *Eng_cfg >> MinThrottle;
+      cout << "      MinThrottle = " << MinThrottle << endl;
+    } else if (token == "SLFUELFLOWMAX") {
+      *Eng_cfg >> SLFuelFlowMax;
+      cout << "      FuelFlowMax = " << SLFuelFlowMax << endl;
+    } else if (token == "SLOXIFLOWMAX") {
+      *Eng_cfg >> SLOxiFlowMax;
+      cout << "      OxiFlowMax = " << SLOxiFlowMax << endl;
+    } else if (token == "VARIANCE") {
+      *Eng_cfg >> Variance;
+      cout << "      Variance = " << Variance << endl;
+    } else {
+      cout << "Unhandled token in Engine config file: " << token << endl;
+    }
+  }
+
+  EngineNumber = 0;
+
+  kFactor = (2.0*SHR*SHR/(SHR-1.0))*pow(2.0/(SHR+1), (SHR+1)/(SHR-1));
+
+  if (debug_lvl & 2) cout << "Instantiated: FGRocket" << endl;
+}
+
+//%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+
+FGRocket::~FGRocket()
+{
+  if (debug_lvl & 2) cout << "Destroyed:    FGRocket" << endl;
+}
+
+//%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+
+float FGRocket::Calculate(float pe)
+{
+  float lastThrust;
+  float Cf;
+  float chamberPress;
+
+  ConsumeFuel();
+
+  Throttle = FCS->GetThrottlePos(EngineNumber);
+  lastThrust = Thrust;                 // last actual thrust
+
+  if (Throttle < MinThrottle || Starved) {
+    PctPower = Thrust = 0.0; // desired thrust
+    Flameout = true;
+  } else {
+    PctPower = Throttle / MaxThrottle;
+    chamberPress = maxPC*PctPower * (1.0 + Variance * ((float)rand()/(float)RAND_MAX - 0.5));
+    Cf = sqrt(kFactor*(1 - pow(pe/(chamberPress), (SHR-1)/SHR)));
+    Flameout = false;
+  }
+
+  if (State->Getdt() > 0.0) {  // actual thrust - if not in freeze
+    Thrust -= 0.8*(Thrust - lastThrust);
+  }
+
+  return Cf*maxPC*PctPower;
+}
+
+//%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 
-FGRocket::FGRocket(FGFDMExec* fdex, string enginePath, string engineName, int num) :
-                                 FGEngine(fdex, enginePath, engineName, num)
+void FGRocket::Debug(void)
 {
-  //
+    //TODO: Add your source code here
 }
 
index 436971ea92ec6d282acc806ed129d035dc74abbc..c99446c55e35864c3c20a33e1eb2b356405b6c98 100644 (file)
@@ -27,10 +27,6 @@ HISTORY
 --------------------------------------------------------------------------------
 09/12/2000  JSB  Created
 
-%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
-COMMENTS, REFERENCES,  and NOTES
-%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
-
 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 SENTRY
 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%*/
@@ -43,8 +39,62 @@ INCLUDES
 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%*/
 
 #include "FGEngine.h"
+#include "FGConfigFile.h"
+
+/*%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+DEFINITIONS
+%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%*/
 
-#define ID_ROCKET "$Header$"
+#define ID_ROCKET "$Id$"
+
+/*%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+FORWARD DECLARATIONS
+%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%*/
+
+/*%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+COMMENTS, REFERENCES, and NOTES [use "class documentation" below for API docs]
+%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%*/
+
+/*%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+CLASS DOCUMENTATION
+%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%*/
+
+/** Models a generic rocket engine.
+    The rocket engine is modeled given the following parameters:
+    <ul>
+        <li>Chamber pressure (in psf)</li>
+        <li>Specific heat ratio (usually about 1.2 for hydrocarbon fuel and LOX)</li>
+        <li>Propulsive efficiency (in percent, from 0 to 1.0)</li>
+        <li>Variance (in percent, from 0 to 1.0, nominally 0.05)</li>
+    </ul>
+    Additionally, the following control inputs, operating characteristics, and
+    location are required, as with all other engine types:</font>
+    <ul>
+        <li>Throttle setting (in percent, from 0 to 1.0)</font></li>
+        <li>Maximum allowable throttle setting</li>
+        <li>Minimum working throttle setting</li>
+        <li>Sea level fuel flow at maximum thrust</li>
+        <li>Sea level oxidizer flow at maximum thrust</li>
+        <li>X, Y, Z location in structural coordinate frame</li>
+        <li>Pitch and Yaw</li>
+    </ul>
+    The nozzle exit pressure (p2) is returned via a
+    call to FGNozzle::GetPowerRequired(). This exit pressure is used,
+    along with chamber pressure and specific heat ratio, to get the
+    thrust coefficient for the throttle setting. This thrust
+    coefficient is multiplied by the chamber pressure and then passed
+    to the nozzle Calculate() routine, where the thrust force is
+    determined.
+
+    @author Jon S. Berndt
+    @version $Id$
+    @see FGNozzle
+    @see FGThruster
+    @see FGForce
+    @see FGEngine
+    @see FGPropulsion
+    @see FGTank
+*/
 
 /*%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 CLASS DECLARATION
@@ -52,12 +102,31 @@ CLASS DECLARATION
 
 class FGRocket : public FGEngine
 {
-
 public:
-  FGRocket(FGFDMExec*, string, string, int);
+  /** Constructor.
+      @param exec pointer to JSBSim parent object, the FDM Executive.
+      @param Eng_cfg pointer to the config file object. */
+  FGRocket(FGFDMExec* exec, FGConfigFile* Eng_cfg);
+
+  /** Destructor */
   ~FGRocket();
 
+  /** Determines the thrust coefficient.
+      This routine takes the nozzle exit pressure and calculates the thrust
+      coefficient times the chamber pressure.
+      @param pe nozzle exit pressure
+      @return thrust coefficient times chamber pressure */
+  float Calculate(float pe);
+
+private:
+  float SHR;
+  float maxPC;
+  float propEff;
+  float kFactor;
+  float Variance;
+  void Debug(void);
 };
 
 //%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 #endif
+
index 5a4f4c13ba5b1251e2e5802f6bb9b9f9b67b139c..e96acb1a0853f99e653f2b1cbd81558fd96a03f3 100644 (file)
@@ -66,9 +66,11 @@ INCLUDES
 #include "FGAuxiliary.h"
 #include "FGOutput.h"
 
-static const char *IdSrc = "$Header$";
+static const char *IdSrc = "$Id$";
 static const char *IdHdr = ID_ROTATION;
 
+extern short debug_lvl;
+
 /*%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 CLASS IMPLEMENTATION
 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%*/
@@ -81,15 +83,18 @@ FGRotation::FGRotation(FGFDMExec* fdmex) : FGModel(fdmex),
         vEuler(3),
         vEulerRates(3)
 {
-    Name = "FGRotation";
-    cTht=cPhi=cPsi=1.0;
-    sTht=sPhi=sPsi=0.0;
+  Name = "FGRotation";
+  cTht=cPhi=cPsi=1.0;
+  sTht=sPhi=sPsi=0.0;
+
+  if (debug_lvl & 2) cout << "Instantiated: " << Name << endl;
 }
 
 //%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 
-FGRotation::~FGRotation(void)
+FGRotation::~FGRotation()
 {
+  if (debug_lvl & 2) cout << "Destroyed:    FGRotation" << endl;
 }
 
 //%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
@@ -116,12 +121,10 @@ bool FGRotation::Run(void)
         State->CalcMatrices();
         vEuler = State->CalcEuler();
         
-        
         cTht = cos(vEuler(eTht));   sTht = sin(vEuler(eTht));
         cPhi = cos(vEuler(ePhi));   sPhi = sin(vEuler(ePhi));
         cPsi = cos(vEuler(ePsi));   sPsi = sin(vEuler(ePsi));
 
-
         vEulerRates(eTht) = vPQR(2)*cPhi - vPQR(3)*sPhi;
         if (cTht != 0.0) {
           tTheta = sTht/cTht;       // what's cheaper: / or tan() ?
@@ -141,7 +144,6 @@ bool FGRotation::Run(void)
 void FGRotation::GetState(void)
 {
     dt = State->Getdt();
-
     vMoments = Aircraft->GetMoments();
 
     Ixx = Aircraft->GetIxx();
@@ -152,3 +154,8 @@ void FGRotation::GetState(void)
 
 //%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 
+void FGRotation::Debug(void)
+{
+    //TODO: Add your source code here
+}
+
index c6741290eae9ce4d5b45451f29af4909afe8d4cb..d072bda1e1a46c677f3b081da1896b9e40cd9820 100644 (file)
@@ -58,7 +58,7 @@ INCLUDES
 
 #ifdef FGFS
 #  include <simgear/compiler.h>
-#  ifdef SG_HAVE_STD_INCLUDES
+#  ifdef FG_HAVE_STD_INCLUDES
 #    include <cmath>
 #  else
 #    include <math.h>
@@ -69,13 +69,13 @@ INCLUDES
 
 #ifndef M_PI
 #  include <simgear/constants.h>
-#  define M_PI SGD_PI
+#  define M_PI FG_PI
 #endif
 
 #include "FGModel.h"
 #include "FGMatrix.h"
 
-#define ID_ROTATION "$Header$"
+#define ID_ROTATION "$Id$"
 
 /*%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 CLASS DECLARATION
@@ -83,24 +83,9 @@ CLASS DECLARATION
 
 class FGRotation : public FGModel
 {
-  FGColumnVector vPQR;
-  FGColumnVector vPQRdot;
-  FGColumnVector vMoments;
-  FGColumnVector vEuler;
-  FGColumnVector vEulerRates;
-  
-  float cTht,sTht;
-  float cPhi,sPhi;
-  float cPsi,sPsi;
-  
-  float Ixx, Iyy, Izz, Ixz;
-  float dt;
-
-  void GetState(void);
-
 public:
   FGRotation(FGFDMExec*);
-  ~FGRotation(void);
+  ~FGRotation();
 
   bool Run(void);
 
@@ -123,9 +108,25 @@ public:
   inline float GetSintht(void) {return sTht;}
   inline float GetSinpsi(void) {return sPsi;}
 
+private:
+  FGColumnVector vPQR;
+  FGColumnVector vPQRdot;
+  FGColumnVector vMoments;
+  FGColumnVector vEuler;
+  FGColumnVector vEulerRates;
+  
+  float cTht,sTht;
+  float cPhi,sPhi;
+  float cPsi,sPsi;
+  
+  float Ixx, Iyy, Izz, Ixz;
+  float dt;
 
+  void GetState(void);
 
+  void Debug(void);
 };
 
 //%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 #endif
+
index de5ee60ba9020d3affc01ad4f18417371f55a532..3bfd7e5d009a0ff705ad93873422cf2025bb1e1d 100644 (file)
@@ -37,9 +37,11 @@ INCLUDES
 
 #include "FGRotor.h"
 
-static const char *IdSrc = "$Header$";
+static const char *IdSrc = "$Id$";
 static const char *IdHdr = ID_ROTOR;
 
+extern short debug_lvl;
+
 /*%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 CLASS IMPLEMENTATION
 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%*/
@@ -47,12 +49,28 @@ CLASS IMPLEMENTATION
 
 FGRotor::FGRotor(FGFDMExec *FDMExec) : FGThruster(FDMExec)
 {
+  if (debug_lvl & 2) cout << "Instantiated: FGRotor" << endl;
+}
+
+//%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 
+FGRotor::~FGRotor()
+{
+  if (debug_lvl & 2) cout << "Destroyed:    FGRotor" << endl;
 }
 
+//%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 
-void FGRotor::Calculate(void)
+float FGRotor::Calculate(float PowerAvailable)
 {
-  FGThruster::Calculate();
+  return 0.0;
+}
 
+//%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+
+void FGRotor::Debug(void)
+{
+    //TODO: Add your source code here
 }
+
+
index 9d22743f34ba1882ab85f48362e8a8ab228045f8..e86d11c1783504c250e3628d63ec2ecf7ba00019 100644 (file)
@@ -44,7 +44,7 @@ INCLUDES
 
 #include "FGThruster.h"
 
-#define ID_ROTOR "$Header$"
+#define ID_ROTOR "$Id$"
 
 /*%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 CLASS DECLARATION
@@ -54,9 +54,12 @@ class FGRotor : public FGThruster {
 
 public:
   FGRotor(FGFDMExec *FDMExec);
-  ~FGRotor(void);
+  ~FGRotor();
 
-  void Calculate(void);
+  float Calculate(float);
+
+private:
+  void Debug(void);
 };
 
 //%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
index d0ab74ab7af0ab69c3576d75658473f063173cbc..7422e86acd972ae5775eb704d8fc5eaee9c55bae 100644 (file)
@@ -38,7 +38,7 @@ INCLUDES
 
 #ifdef FGFS
 #  include <simgear/compiler.h>
-#  ifdef SG_HAVE_STD_INCLUDES
+#  ifdef FG_HAVE_STD_INCLUDES
 #    include <cmath>
 #  else
 #    include <math.h>
@@ -49,7 +49,7 @@ INCLUDES
 
 #ifndef M_PI 
 #  include <simgear/constants.h>
-#  define M_PI SGD_PI
+#  define M_PI FG_PI
 #endif
 
 #include "FGState.h"
@@ -63,9 +63,11 @@ INCLUDES
 #include "FGAuxiliary.h"
 #include "FGOutput.h"
 
-static const char *IdSrc = "$Header$";
+static const char *IdSrc = "$Id$";
 static const char *IdHdr = ID_STATE;
 
+extern short debug_lvl;
+
 /*%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 MACROS
 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%*/
@@ -86,14 +88,17 @@ CLASS IMPLEMENTATION
 FGState::FGState(FGFDMExec* fdex) : mTb2l(3,3),
     mTl2b(3,3),
     mTs2b(3,3),
-    vQtrn(4)
+    vQtrn(4),
+    vlastQdot(4)
 {
   FDMExec = fdex;
 
   a = 1000.0;
   sim_time = 0.0;
   dt = 1.0/120.0;
-
+  ActiveEngine = -1;
+  
+  RegisterVariable(FG_TIME,           " time "           );
   RegisterVariable(FG_QBAR,           " qbar "           );
   RegisterVariable(FG_WINGAREA,       " wing_area "      );
   RegisterVariable(FG_WINGSPAN,       " wingspan "       );
@@ -102,7 +107,7 @@ FGState::FGState(FGFDMExec* fdex) : mTb2l(3,3),
   RegisterVariable(FG_ALPHADOT,       " alphadot "       );
   RegisterVariable(FG_BETA,           " beta "           );
   RegisterVariable(FG_BETADOT,        " betadot "        );
-  RegisterVariable(SGD_PITCHRATE,      " pitch_rate "     );
+  RegisterVariable(FG_PITCHRATE,      " pitch_rate "     );
   RegisterVariable(FG_ROLLRATE,       " roll_rate "      );
   RegisterVariable(FG_YAWRATE,        " yaw_rate "       );
   RegisterVariable(FG_MACH,           " mach "           );
@@ -123,18 +128,26 @@ FGState::FGState(FGFDMExec* fdex) : mTb2l(3,3),
   RegisterVariable(FG_FLAPS_CMD,      " flaps_cmd "      );
   RegisterVariable(FG_THROTTLE_CMD,   " throttle_cmd "   );
   RegisterVariable(FG_THROTTLE_POS,   " throttle_pos "   );
+  RegisterVariable(FG_ACTIVE_ENGINE,  " active_engine "  );
   RegisterVariable(FG_HOVERB,         " height/span "    );
-  RegisterVariable(SGD_PITCH_TRIM_CMD, " pitch_trim_cmd " );
+  RegisterVariable(FG_PITCH_TRIM_CMD, " pitch_trim_cmd " );
+
+  if (debug_lvl & 2) cout << "Instantiated: FGState" << endl;
 }
 
 //%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 
-FGState::~FGState(void) {}
+FGState::~FGState()
+{
+  if (debug_lvl & 2) cout << "Destroyed:    FGState" << endl;
+}
 
 //%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 
 float FGState::GetParameter(eParam val_idx) {
   switch(val_idx) {
+  case FG_TIME:
+    return sim_time;
   case FG_QBAR:
     return FDMExec->GetTranslation()->Getqbar();
   case FG_WINGAREA:
@@ -151,7 +164,7 @@ float FGState::GetParameter(eParam val_idx) {
     return FDMExec->GetTranslation()->Getbeta();
   case FG_BETADOT:
     return FDMExec->GetTranslation()->Getbdot();
-  case SGD_PITCHRATE:
+  case FG_PITCHRATE:
     return (FDMExec->GetRotation()->GetPQR())(2);
   case FG_ROLLRATE:
     return (FDMExec->GetRotation()->GetPQR())(1);
@@ -201,7 +214,7 @@ float FGState::GetParameter(eParam val_idx) {
     return FDMExec->GetFCS()->GetThrottlePos(0);
   case FG_HOVERB:
     return FDMExec->GetPosition()->GetHOverB();
-  case SGD_PITCH_TRIM_CMD:
+  case FG_PITCH_TRIM_CMD:
     return FDMExec->GetFCS()->GetPitchTrimCmd();
   default:
     cerr << "FGState::GetParameter() - No handler for parameter " << val_idx << endl;
@@ -245,7 +258,37 @@ void FGState::SetParameter(eParam val_idx, float val) {
     FDMExec->GetFCS()->SetDfPos(val);
     break;
   case FG_THROTTLE_POS:
-    FDMExec->GetFCS()->SetThrottlePos(-1,val);
+    FDMExec->GetFCS()->SetThrottlePos(ActiveEngine,val);
+    break;
+
+  case FG_ELEVATOR_CMD:
+    FDMExec->GetFCS()->SetDeCmd(val);
+    break;
+  case FG_AILERON_CMD:
+    FDMExec->GetFCS()->SetDaCmd(val);
+    break;
+  case FG_RUDDER_CMD:
+    FDMExec->GetFCS()->SetDrCmd(val);
+    break;
+  case FG_SPDBRAKE_CMD:
+    FDMExec->GetFCS()->SetDsbCmd(val);
+    break;
+  case FG_SPOILERS_CMD:
+    FDMExec->GetFCS()->SetDspCmd(val);
+    break;
+  case FG_FLAPS_CMD:
+    FDMExec->GetFCS()->SetDfCmd(val);
+    break;
+  case FG_THROTTLE_CMD:
+    FDMExec->GetFCS()->SetThrottleCmd(ActiveEngine,val);
+    break;
+
+  case FG_ACTIVE_ENGINE:
+    ActiveEngine = (int)val;
+    break;
+
+  default:
+    cerr << "Parameter '" << val_idx << "' (" << paramdef[val_idx] << ") not handled" << endl;
   }
 }
 
@@ -461,14 +504,13 @@ void FGState::CalcMatrices(void) {
 //%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 
 void FGState::IntegrateQuat(FGColumnVector vPQR, int rate) {
-  static FGColumnVector vlastQdot(4);
   static FGColumnVector vQdot(4);
+  static FGColumnVector vTmp(4);
 
   vQdot(1) = -0.5*(vQtrn(2)*vPQR(eP) + vQtrn(3)*vPQR(eQ) + vQtrn(4)*vPQR(eR));
   vQdot(2) =  0.5*(vQtrn(1)*vPQR(eP) + vQtrn(3)*vPQR(eR) - vQtrn(4)*vPQR(eQ));
   vQdot(3) =  0.5*(vQtrn(1)*vPQR(eQ) + vQtrn(4)*vPQR(eP) - vQtrn(2)*vPQR(eR));
   vQdot(4) =  0.5*(vQtrn(1)*vPQR(eR) + vQtrn(2)*vPQR(eQ) - vQtrn(3)*vPQR(eP));
-
   vQtrn += 0.5*dt*rate*(vlastQdot + vQdot);
 
   vQtrn.Normalize();
@@ -518,3 +560,8 @@ FGMatrix FGState::GetTs2b(float alpha, float beta) {
 
 //%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 
+void FGState::Debug(void)
+{
+    //TODO: Add your source code here
+}
+
index 4e0fcf67fd3f80c6b729215174931c23fbb14b38..196b4035b08cb838b0289c1cfc7098ed615e48a2 100644 (file)
@@ -46,7 +46,7 @@ INCLUDES
 
 #ifdef FGFS
 #  include <simgear/compiler.h>
-#  ifdef SG_HAVE_STD_INCLUDES
+#  ifdef FG_HAVE_STD_INCLUDES
 #    include <fstream>
 #  else
 #    include <fstream.h>
@@ -65,7 +65,7 @@ INCLUDES
 DEFINES
 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%*/
 
-#define ID_STATE "$Header$"
+#define ID_STATE "$Id$"
 
 /*%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 CLASS DECLARATION
@@ -76,7 +76,7 @@ class FGFDMExec;
 class FGState {
 public:
   FGState(FGFDMExec*);
-  ~FGState(void);
+  ~FGState();
 
   bool Reset(string, string, string);
   void Initialize(float, float, float, float, float, float, float, float, float);
@@ -95,7 +95,6 @@ public:
   float GetParameter(string val_string);
   eParam GetParameterIndex(string val_string);
 
-
   inline void Seta(float tt) { a = tt; }
 
   inline float Setsim_time(float tt) {
@@ -131,9 +130,12 @@ private:
   FGMatrix mTl2b;
   FGMatrix mTs2b;
   FGColumnVector vQtrn;
+  FGColumnVector vlastQdot;
 
   typedef map<string, eParam> CoeffMap;
   CoeffMap coeffdef;
+  void Debug(void);
+  int ActiveEngine;
 
 protected:
   enum {ePhi=1, eTht, ePsi};
@@ -142,3 +144,4 @@ protected:
 
 //%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 #endif
+
index 52f592e460a0929e88bc40cfaa025eed482d9bf7..2559b38b16aa94bb8ccd2b75a63bc9f63192f34b 100644 (file)
@@ -38,29 +38,39 @@ INCLUDES
 
 #include "FGTank.h"
 
-static const char *IdSrc = "$Header$";
+static const char *IdSrc = "$Id$";
 static const char *IdHdr = ID_TANK;
 
+extern short debug_lvl;
+
 /*%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 CLASS IMPLEMENTATION
 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%*/
 
+using std::cerr;
+using std::endl;
+using std::cout;
 
 FGTank::FGTank(FGConfigFile* AC_cfg)
 {
-  string type;
-
-  *AC_cfg >> type;                              // Type = 0: fuel, 1: oxidizer
-
-  if (type == "FUEL") Type = ttFUEL;
+  string type = AC_cfg->GetValue("TYPE");
+  string token;
+  
+  if      (type == "FUEL")     Type = ttFUEL;
   else if (type == "OXIDIZER") Type = ttOXIDIZER;
-  else Type = ttUNKNOWN;
-  *AC_cfg >> X;                                 // inches
-  *AC_cfg >> Y;                                 // "
-  *AC_cfg >> Z;                                 // "
-  *AC_cfg >> Radius;                            // "
-  *AC_cfg >> Capacity;                          // pounds (amount it can hold)
-  *AC_cfg >> Contents;                          // pounds  (amount it is holding)
+  else                         Type = ttUNKNOWN;
+  
+  AC_cfg->GetNextConfigLine();
+  while ((token = AC_cfg->GetValue()) != "/AC_TANK") {
+    if (token == "XLOC") *AC_cfg >> X;
+    else if (token == "YLOC") *AC_cfg >> Y;
+    else if (token == "ZLOC") *AC_cfg >> Z;
+    else if (token == "RADIUS") *AC_cfg >> Radius;
+    else if (token == "CAPACITY") *AC_cfg >> Capacity;
+    else if (token == "CONTENTS") *AC_cfg >> Contents;
+    else cerr << "Unknown identifier: " << token << " in tank definition." << endl;
+  }
+  
   Selected = true;
 
   if (Capacity != 0) {
@@ -69,13 +79,23 @@ FGTank::FGTank(FGConfigFile* AC_cfg)
     Contents = 0;
     PctFull  = 0;
   }     
+
+  cout << "      " << type << " tank holds " << Capacity << " lbs. " << type << endl;
+  cout << "      currently at " << PctFull << "% of maximum capacity" << endl;
+  cout << "      Tank location (X, Y, Z): " << X << ", " << Y << ", " << Z << endl;
+  cout << "      Effective radius: " << Radius << " inches" << endl;
+
+  if (debug_lvl & 2) cout << "Instantiated: FGTank" << endl;
 }
 
+//%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 
-FGTank::~FGTank(void)
+FGTank::~FGTank()
 {
+  if (debug_lvl & 2) cout << "Destroyed:    FGTank" << endl;
 }
 
+//%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 
 float FGTank::Reduce(float used)
 {
@@ -84,7 +104,7 @@ float FGTank::Reduce(float used)
   if (used < Contents) {
     Contents -= used;
     PctFull = 100.0*Contents/Capacity;
-    return Contents;
+    return 0.0;
   } else {
     shortage = Contents - used;
     Contents = 0.0;
@@ -94,3 +114,10 @@ float FGTank::Reduce(float used)
   }
 }
 
+//%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+
+void FGTank::Debug(void)
+{
+    //TODO: Add your source code here
+}
+
index 5919c473badbadc1d975109ed8e3042c647cb8a9..cd7a2ecac6b4cef613ee3b887b7ea5f1fde956cd 100644 (file)
@@ -55,7 +55,7 @@ INCLUDES
 DEFINES
 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%*/
 
-#define ID_TANK "$Header"
+#define ID_TANK "$Id$"
 
 /*%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 CLASS DECLARATION
@@ -65,7 +65,7 @@ class FGTank
 {
 public:
   FGTank(FGConfigFile*);
-  ~FGTank(void);
+  ~FGTank();
 
   float Reduce(float);
   int GetType(void) {return Type;}
@@ -86,9 +86,9 @@ private:
   float PctFull;
   float Contents;
   bool  Selected;
-
-protected:
+  void Debug(void);
 };
 
 //%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 #endif
+
index 04c616625fdee93761966c1c2a21d3204565ee77..758c144947f59ebdfc7f93b2f2b13a56a2bbf5a5 100644 (file)
@@ -37,9 +37,11 @@ INCLUDES
 
 #include "FGThruster.h"
 
-static const char *IdSrc = "$Header$";
+static const char *IdSrc = "$Id$";
 static const char *IdHdr = ID_THRUSTER;
 
+extern short debug_lvl;
+
 /*%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 CLASS IMPLEMENTATION
 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%*/
@@ -47,12 +49,22 @@ CLASS IMPLEMENTATION
 
 FGThruster::FGThruster(FGFDMExec *FDMExec) : FGForce(FDMExec)
 {
+  SetTransformType(FGForce::tCustom);
 
+  if (debug_lvl & 2) cout << "Instantiated: FGThruster" << endl;
 }
 
+//%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 
-void FGThruster::Calculate(void)
+FGThruster::~FGThruster()
 {
+  if (debug_lvl & 2) cout << "Destroyed:    FGThruster" << endl;
+}
 
+//%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+
+void FGThruster::Debug(void)
+{
+    //TODO: Add your source code here
 }
 
index e340d2f06943f28ae3b3e63c37d26ed5aae7816f..d03e92ede6e36a21a93dc39ce26c817d56dd2a5a 100644 (file)
@@ -43,8 +43,9 @@ INCLUDES
 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%*/
 
 #include "FGForce.h"
+#include "FGConfigFile.h"
 
-#define ID_THRUSTER "$Header"
+#define ID_THRUSTER "$Id$"
 
 /*%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 CLASS DECLARATION
@@ -54,12 +55,23 @@ class FGThruster : public FGForce {
 
 public:
   FGThruster(FGFDMExec *FDMExec);
-  ~FGThruster(void);
+  virtual ~FGThruster();
 
   enum Type {ttNozzle, ttRotor, ttPropeller};
 
-  virtual void Calculate(void);
+  virtual float Calculate(float) {return 0.0;}
+  void SetName(string name) {Name = name;}
+  virtual float GetPowerRequired(void) {return 0.0;}
+  virtual void SetdeltaT(float dt) {deltaT = dt;}
+
+protected:
+  string Name;
+  float Thrust;
+  float PowerRequired;
+  float deltaT;
+  void Debug(void);
 };
 
 //%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 #endif
+
index aa706890ee6bb2847925d3fed1546da8e118f056..82407997f831a1a84865e9701af13f6564413b26 100644 (file)
@@ -1,40 +1,40 @@
 /*%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+
  Module:       FGTranslation.cpp
  Author:       Jon Berndt
  Date started: 12/02/98
  Purpose:      Integrates the translational EOM
  Called by:    FDMExec
+
  ------------- Copyright (C) 1999  Jon S. Berndt (jsb@hal-pc.org) -------------
+
  This program is free software; you can redistribute it and/or modify it under
  the terms of the GNU General Public License as published by the Free Software
  Foundation; either version 2 of the License, or (at your option) any later
  version.
+
  This program is distributed in the hope that it will be useful, but WITHOUT
  ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
  FOR A PARTICULAR PURPOSE.  See the GNU General Public License for more
  details.
+
  You should have received a copy of the GNU General Public License along with
  this program; if not, write to the Free Software Foundation, Inc., 59 Temple
  Place - Suite 330, Boston, MA  02111-1307, USA.
+
  Further information about the GNU General Public License can also be found on
  the world wide web at http://www.gnu.org.
+
 FUNCTIONAL DESCRIPTION
 --------------------------------------------------------------------------------
 This class integrates the translational EOM.
+
 HISTORY
 --------------------------------------------------------------------------------
 12/02/98   JSB   Created
- 7/23/99   TP    Added data member and modified Run and PutState to calcuate 
-                              Mach number
+ 7/23/99   TP    Added data member and modified Run and PutState to calcuate
+                 Mach number
+
 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 COMMENTS, REFERENCES,  and NOTES
 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
@@ -49,10 +49,10 @@ COMMENTS, REFERENCES,  and NOTES
     Wiley & Sons, 1979 ISBN 0-471-03032-5
 [5] Bernard Etkin, "Dynamics of Flight, Stability and Control", Wiley & Sons,
     1982 ISBN 0-471-08936-2
+
   The order of rotations used in this class corresponds to a 3-2-1 sequence,
   or Y-P-R, or Z-Y-X, if you prefer.
+
 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 INCLUDES
 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%*/
@@ -68,9 +68,11 @@ INCLUDES
 #include "FGAuxiliary.h"
 #include "FGOutput.h"
 
-static const char *IdSrc = "$Header$";
+static const char *IdSrc = "$Id$";
 static const char *IdHdr = ID_TRANSLATION;
 
+extern short debug_lvl;
+
 /*%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 CLASS IMPLEMENTATION
 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%*/
@@ -78,7 +80,6 @@ CLASS IMPLEMENTATION
 
 FGTranslation::FGTranslation(FGFDMExec* fdmex) : FGModel(fdmex),
     vUVW(3),
-    vWindUVW(3),
     vUVWdot(3),
     vNcg(3),
     vPQR(3),
@@ -92,11 +93,16 @@ FGTranslation::FGTranslation(FGFDMExec* fdmex) : FGModel(fdmex),
   alpha = beta = 0.0;
   adot = bdot = 0.0;
   rho = 0.002378;
+
+  if (debug_lvl & 2) cout << "Instantiated: " << Name << endl;
 }
 
 //%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 
-FGTranslation::~FGTranslation(void) {}
+FGTranslation::~FGTranslation()
+{
+  if (debug_lvl & 2) cout << "Destroyed:    FGTranslation" << endl;
+}
 
 //%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 
@@ -119,11 +125,11 @@ bool FGTranslation::Run(void) {
     mVel(3,3) =  0.0;
 
     vUVWdot = mVel*vPQR + vForces/Mass;
-    
-    vNcg=vUVWdot*INVGRAVITY;
 
-    vUVW += 0.5*dt*rate*(vlastUVWdot + vUVWdot) + vWindUVW;
-    
+    vNcg = vUVWdot*INVGRAVITY;
+
+    vUVW += 0.5*dt*rate*(vlastUVWdot + vUVWdot);
+
     Vt = vUVW.Magnitude();
 
     if (vUVW(eW) != 0.0)
@@ -131,27 +137,23 @@ bool FGTranslation::Run(void) {
     if (vUVW(eV) != 0.0)
       beta = vUVW(eU)*vUVW(eU)+vUVW(eW)*vUVW(eW) > 0.0 ? atan2(vUVW(eV),
              sqrt(vUVW(eU)*vUVW(eU) + vUVW(eW)*vUVW(eW))) : 0.0;
-    
-     
-       
-         // stolen, quite shamelessly, from LaRCsim
+
+    // stolen, quite shamelessly, from LaRCsim
     float mUW = (vUVW(eU)*vUVW(eU) + vUVW(eW)*vUVW(eW));
     float signU=1;
     if (vUVW(eU) != 0.0)
-                 signU = vUVW(eU)/fabs(vUVW(eU));
-
-         if( (mUW == 0.0) || (Vt == 0.0) ) {
-                 adot = 0.0;
-                 bdot = 0.0;
-         } else {
-                 adot = (vUVW(eU)*vUVWdot(eW) - vUVW(eW)*vUVWdot(eU))/mUW;
-                 bdot = (signU*mUW*vUVWdot(eV) - vUVW(eV)*(vUVW(eU)*vUVWdot(eU) 
+      signU = vUVW(eU)/fabs(vUVW(eU));
+
+    if ( (mUW == 0.0) || (Vt == 0.0) ) {
+      adot = 0.0;
+      bdot = 0.0;
+    } else {
+      adot = (vUVW(eU)*vUVWdot(eW) - vUVW(eW)*vUVWdot(eU))/mUW;
+      bdot = (signU*mUW*vUVWdot(eV) - vUVW(eV)*(vUVW(eU)*vUVWdot(eU)
               + vUVW(eW)*vUVWdot(eW)))/(Vt*Vt*sqrt(mUW));
-         }
-    //
-    
-    qbar = 0.5*rho*Vt*Vt;
+    }
 
+    qbar = 0.5*rho*Vt*Vt;
     Mach = Vt / State->Geta();
 
     vlastUVWdot = vUVWdot;
@@ -173,7 +175,12 @@ void FGTranslation::GetState(void) {
   rho = Atmosphere->GetDensity();
 
   vEuler = Rotation->GetEuler();
+}
 
-  vWindUVW = Atmosphere->GetWindUVW();
+//%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+
+void FGTranslation::Debug(void)
+{
+    //TODO: Add your source code here
 }
 
index 7eb04d6f4d0c38017379763013ba43e349711019..fff41ab0a96a06b7f9ad087f0e25f78679a1da1a 100644 (file)
@@ -58,7 +58,7 @@ INCLUDES
 
 #ifdef FGFS
 #  include <simgear/compiler.h>
-#  ifdef SG_HAVE_STD_INCLUDES
+#  ifdef FG_HAVE_STD_INCLUDES
 #    include <cmath>
 #  else
 #    include <math.h>
@@ -70,7 +70,7 @@ INCLUDES
 #include "FGModel.h"
 #include "FGMatrix.h"
 
-#define ID_TRANSLATION "$Header"
+#define ID_TRANSLATION "$Id$"
 
 /*%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 CLASS DECLARATION
@@ -79,7 +79,7 @@ CLASS DECLARATION
 class FGTranslation : public FGModel {
 public:
   FGTranslation(FGFDMExec*);
-  ~FGTranslation(void);
+  ~FGTranslation();
 
   inline FGColumnVector GetUVW(void) { return vUVW; }
   inline FGColumnVector GetUVWdot(void) { return vUVWdot; }
@@ -104,13 +104,13 @@ public:
   inline void Setbdot (float tt) { bdot = tt; }
 
   inline void SetAB(float t1, float t2) { alpha=t1; beta=t2; }
-
+  
   bool Run(void);
 
 protected:
 
 private:
-  FGColumnVector vUVW,vWindUVW;
+  FGColumnVector vUVW;
   FGColumnVector vUVWdot;
   FGColumnVector vNcg;
   FGColumnVector vPQR;
@@ -124,7 +124,9 @@ private:
   float rho;
 
   void GetState(void);
+  void Debug(void);
 };
 
 //%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 #endif
+
index 5bc3f407a09388641be90815fdbd1088be006664..67fd7d53f95443563a7ad08b669c8ac31900f799 100644 (file)
@@ -52,9 +52,15 @@ INCLUDES
 #include "FGTrim.h"
 #include "FGAircraft.h"
 
-static const char *IdSrc = "$Header$";
+#if _MSC_VER
+#pragma warning (disable : 4786 4788)
+#endif
+
+static const char *IdSrc = "$Id$";
 static const char *IdHdr = ID_TRIM;
 
+extern short debug_lvl;
+
 //%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 
 FGTrim::FGTrim(FGFDMExec *FDMExec,FGInitialCondition *FGIC, TrimMode tt ) {
@@ -76,44 +82,47 @@ FGTrim::FGTrim(FGFDMExec *FDMExec,FGInitialCondition *FGIC, TrimMode tt ) {
   xlo=xhi=alo=ahi;
   switch(mode) {
   case tFull:
-    cout << "  Full 6-DOF Trim" << endl;
-    TrimAxes.push_back(new FGTrimAxis(fdmex,fgic,tWdot,tAlpha,Tolerance));
-    TrimAxes.push_back(new FGTrimAxis(fdmex,fgic,tUdot,tThrottle,Tolerance));
-    TrimAxes.push_back(new FGTrimAxis(fdmex,fgic,tQdot,tPitchTrim,A_Tolerance));
-    TrimAxes.push_back(new FGTrimAxis(fdmex,fgic,tVdot,tPhi,Tolerance));
-    TrimAxes.push_back(new FGTrimAxis(fdmex,fgic,tPdot,tAileron,A_Tolerance));
-    TrimAxes.push_back(new FGTrimAxis(fdmex,fgic,tRdot,tRudder,A_Tolerance));
+    cout << "  Full Trim" << endl;
+    TrimAxes.push_back(new FGTrimAxis(fdmex,fgic,tWdot,tAlpha ));
+    TrimAxes.push_back(new FGTrimAxis(fdmex,fgic,tUdot,tThrottle ));
+    TrimAxes.push_back(new FGTrimAxis(fdmex,fgic,tQdot,tPitchTrim ));
+    TrimAxes.push_back(new FGTrimAxis(fdmex,fgic,tHmgt,tBeta ));
+    TrimAxes.push_back(new FGTrimAxis(fdmex,fgic,tVdot,tPhi ));
+    TrimAxes.push_back(new FGTrimAxis(fdmex,fgic,tPdot,tAileron ));
+    TrimAxes.push_back(new FGTrimAxis(fdmex,fgic,tRdot,tRudder ));
     break;
   case tLongitudinal:
     cout << "  Longitudinal Trim" << endl;
-    TrimAxes.push_back(new FGTrimAxis(fdmex,fgic,tWdot,tAlpha,Tolerance));
-    TrimAxes.push_back(new FGTrimAxis(fdmex,fgic,tUdot,tThrottle,Tolerance));
-    TrimAxes.push_back(new FGTrimAxis(fdmex,fgic,tQdot,tPitchTrim,A_Tolerance));
+    TrimAxes.push_back(new FGTrimAxis(fdmex,fgic,tWdot,tAlpha ));
+    TrimAxes.push_back(new FGTrimAxis(fdmex,fgic,tUdot,tThrottle ));
+    TrimAxes.push_back(new FGTrimAxis(fdmex,fgic,tQdot,tPitchTrim ));
     break;
   case tGround:
     cout << "  Ground Trim" << endl;
-    TrimAxes.push_back(new FGTrimAxis(fdmex,fgic,tWdot,tAltAGL,Tolerance));
-    TrimAxes.push_back(new FGTrimAxis(fdmex,fgic,tQdot,tTheta,A_Tolerance));
-    //TrimAxes.push_back(new FGTrimAxis(fdmex,fgic,tPdot,tPhi,A_Tolerance));
+    TrimAxes.push_back(new FGTrimAxis(fdmex,fgic,tWdot,tAltAGL ));
+    TrimAxes.push_back(new FGTrimAxis(fdmex,fgic,tQdot,tTheta ));
+    //TrimAxes.push_back(new FGTrimAxis(fdmex,fgic,tPdot,tPhi ));
     break;
   }
-  //cout << "NumAxes: " << TrimAxes.size() << endl;
-  NumAxes=TrimAxes.size();
-  sub_iterations=new float[NumAxes];
-  successful=new float[NumAxes];
-  solution=new bool[NumAxes];
+  //cout << "TrimAxes.size(): " << TrimAxes.size() << endl;
+  sub_iterations=new float[TrimAxes.size()];
+  successful=new float[TrimAxes.size()];
+  solution=new bool[TrimAxes.size()];
   current_axis=0;
+  
+  if (debug_lvl & 2) cout << "Instantiated: FGTrim" << endl;
 }
 
 //%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 
 FGTrim::~FGTrim(void) {
-  for(current_axis=0; current_axis<NumAxes; current_axis++) {
+  for(current_axis=0; current_axis<TrimAxes.size(); current_axis++) {
     delete TrimAxes[current_axis];
   }
   delete[] sub_iterations;
   delete[] successful;
   delete[] solution;
+  if (debug_lvl & 2) cout << "Destroyed:    FGTrim" << endl;
 }
 
 //%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
@@ -125,10 +134,10 @@ void FGTrim::TrimStats() {
   cout << "    Total Iterations: " << total_its << endl;
   if(total_its > 0) {
     cout << "    Sub-iterations:" << endl;
-    for(current_axis=0; current_axis<NumAxes; current_axis++) {
+    for(current_axis=0; current_axis<TrimAxes.size(); current_axis++) {
       run_sum+=TrimAxes[current_axis]->GetRunCount();
       sprintf(out,"   %5s: %3.0f average: %5.2f  successful: %3.0f  stability: %5.2f\n",
-                  TrimAxes[current_axis]->GetAccelName().c_str(),
+                  TrimAxes[current_axis]->GetStateName().c_str(),
                   sub_iterations[current_axis],
                   sub_iterations[current_axis]/float(total_its),
                   successful[current_axis],
@@ -143,7 +152,7 @@ void FGTrim::TrimStats() {
 
 void FGTrim::Report(void) {
   cout << "  Trim Results: " << endl;
-  for(current_axis=0; current_axis<NumAxes; current_axis++)
+  for(current_axis=0; current_axis<TrimAxes.size(); current_axis++)
     TrimAxes[current_axis]->AxisReport();
 
 }
@@ -189,7 +198,7 @@ void FGTrim::ReportState(void) {
   cout << out;                  
   sprintf(out, "    Normal Load Factor: %4.2f g's  Pitch Rate: %5.2f deg/s\n",
                     fdmex->GetAircraft()->GetNlf(),
-                    fdmex->GetState()->GetParameter(SGD_PITCHRATE)*RADTODEG );
+                    fdmex->GetState()->GetParameter(FG_PITCHRATE)*RADTODEG );
   cout << out;
   sprintf(out, "    Heading: %3.0f deg true  Sideslip: %5.2f deg\n",
                     fdmex->GetRotation()->Getpsi()*RADTODEG,
@@ -205,27 +214,134 @@ void FGTrim::ReportState(void) {
   cout << out;                  
   sprintf(out, "    Throttle: %5.2f%c\n",
                     fdmex->GetFCS()->GetThrottlePos(0),'%' );
-  cout << out;                                  
+  cout << out;
+  
+  sprintf(out, "    Wind Components: %5.2f kts head wind, %5.2f kts cross wind\n",
+                    fdmex->GetAuxiliary()->GetHeadWind()*jsbFPSTOKTS,
+                    fdmex->GetAuxiliary()->GetCrossWind()*jsbFPSTOKTS );
+  cout << out; 
+  
+  sprintf(out, "    Ground Speed: %4.0f knots , Ground Track: %3.0f deg true\n",
+                    fdmex->GetPosition()->GetVground()*jsbFPSTOKTS,
+                    fdmex->GetPosition()->GetGroundTrack()*RADTODEG );
+  cout << out;                                   
+
+}                  
+
+//%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+
+void FGTrim::ClearStates(void) {
+    FGTrimAxis* ta;
+    
+    mode=tCustom;
+    vector<FGTrimAxis*>::iterator iAxes;
+    iAxes = TrimAxes.begin();
+    while (iAxes != TrimAxes.end()) {
+      ta=*iAxes;
+      delete ta;
+      iAxes++;
+    }
+    TrimAxes.clear();
+    cout << "TrimAxes.size(): " << TrimAxes.size() << endl;
 }
+    
+//%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+
+bool FGTrim::AddState( State state, Control control ) {
+  FGTrimAxis* ta;
+  bool result=true;
+  
+  mode = tCustom;
+  vector <FGTrimAxis*>::iterator iAxes = TrimAxes.begin();
+  while (iAxes != TrimAxes.end()) {
+      ta=*iAxes;
+      if( ta->GetStateType() == state )
+        result=false;
+      iAxes++;
+  }
+  if(result) {
+    TrimAxes.push_back(new FGTrimAxis(fdmex,fgic,state,control));
+    delete[] sub_iterations;
+    delete[] successful;
+    delete[] solution;
+    sub_iterations=new float[TrimAxes.size()];
+    successful=new float[TrimAxes.size()];
+    solution=new bool[TrimAxes.size()];
+  }
+  return result;
+}  
+
+//%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+
+bool FGTrim::RemoveState( State state ) {
+  FGTrimAxis* ta;
+  bool result=false;
+  
+  mode = tCustom;
+  vector <FGTrimAxis*>::iterator iAxes = TrimAxes.begin();
+  while (iAxes != TrimAxes.end()) {
+      ta=*iAxes;
+      if( ta->GetStateType() == state ) {
+        delete ta;
+        TrimAxes.erase(iAxes);
+        result=true;
+        continue;
+      }
+      iAxes++;
+  }
+  if(result) {
+    delete[] sub_iterations;
+    delete[] successful;
+    delete[] solution;
+    sub_iterations=new float[TrimAxes.size()];
+    successful=new float[TrimAxes.size()];
+    solution=new bool[TrimAxes.size()];
+  }  
+  return result;
+}  
+
+//%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+
+bool FGTrim::EditState( State state, Control new_control ){       
+  FGTrimAxis* ta;
+  bool result=false;
+  
+  mode = tCustom;
+  vector <FGTrimAxis*>::iterator iAxes = TrimAxes.begin();
+  while (iAxes != TrimAxes.end()) {
+      ta=*iAxes;
+      if( ta->GetStateType() == state ) {
+        TrimAxes.insert(iAxes,1,new FGTrimAxis(fdmex,fgic,state,new_control));
+        delete ta;
+        TrimAxes.erase(iAxes+1);
+        result=true;
+        break;
+      }
+      iAxes++;
+  }
+  cout << "Exit FGTrim::EditState(...)" << endl;
+  return result;
+}  
+       
 
 //%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 
 bool FGTrim::DoTrim(void) {
   
   trim_failed=false;
+  int i;
 
-
-  for(int i=0;i < fdmex->GetAircraft()->GetNumGearUnits();i++){
+  for(i=0;i < fdmex->GetAircraft()->GetNumGearUnits();i++){
     fdmex->GetAircraft()->GetGearUnit(i)->SetReport(false);
   }
 
   fdmex->GetOutput()->Disable();
 
   //clear the sub iterations counts & zero out the controls
-  for(current_axis=0;current_axis<NumAxes;current_axis++) {
-    //cout << current_axis << "  " << TrimAxes[current_axis]->GetAccelName()
+  for(current_axis=0;current_axis<TrimAxes.size();current_axis++) {
+    //cout << current_axis << "  " << TrimAxes[current_axis]->GetStateName()
     //<< "  " << TrimAxes[current_axis]->GetControlName()<< endl;
-    if(TrimAxes[current_axis]->GetAccelType() == tQdot) {
+    if(TrimAxes[current_axis]->GetStateType() == tQdot) {
       if(mode == tGround) 
          TrimAxes[current_axis]->initTheta();
     }  
@@ -240,7 +356,7 @@ bool FGTrim::DoTrim(void) {
   }
   do {
     axis_count=0;
-    for(current_axis=0;current_axis<NumAxes;current_axis++) {
+    for(current_axis=0;current_axis<TrimAxes.size();current_axis++) {
       Nsub=0;
       if(!solution[current_axis]) {
         if(checkLimits()) { 
@@ -254,7 +370,7 @@ bool FGTrim::DoTrim(void) {
       }  
       sub_iterations[current_axis]+=Nsub;
     } 
-    for(current_axis=0;current_axis<NumAxes;current_axis++) {
+    for(current_axis=0;current_axis<TrimAxes.size();current_axis++) {
       //these checks need to be done after all the axes have run
       if(Debug > 0) TrimAxes[current_axis]->AxisReport();
       if(TrimAxes[current_axis]->InTolerance()) {
@@ -264,34 +380,34 @@ bool FGTrim::DoTrim(void) {
     }
     
 
-    if((axis_count == NumAxes-1) && (NumAxes > 1)) {
-      //cout << NumAxes-1 << " out of " << NumAxes << "!" << endl;
+    if((axis_count == TrimAxes.size()-1) && (TrimAxes.size() > 1)) {
+      //cout << TrimAxes.size()-1 << " out of " << TrimAxes.size() << "!" << endl;
       //At this point we can check the input limits of the failed axis
       //and declare the trim failed if there is no sign change. If there
       //is, keep going until success or max iteration count
 
       //Oh, well: two out of three ain't bad
-      for(current_axis=0;current_axis<NumAxes;current_axis++) {
+      for(current_axis=0;current_axis<TrimAxes.size();current_axis++) {
         //these checks need to be done after all the axes have run
         if(!TrimAxes[current_axis]->InTolerance()) {
           if(!checkLimits()) {
             // special case this for now -- if other cases arise proper
             // support can be added to FGTrimAxis
             if( (gamma_fallback) &&
-                (TrimAxes[current_axis]->GetAccelType() == tUdot) &&
+                (TrimAxes[current_axis]->GetStateType() == tUdot) &&
                 (TrimAxes[current_axis]->GetControlType() == tThrottle)) {
               cout << "  Can't trim udot with throttle, trying flight"
               << " path angle. (" << N << ")" << endl;
-              if(TrimAxes[current_axis]->GetAccel() > 0)
+              if(TrimAxes[current_axis]->GetState() > 0)
                 TrimAxes[current_axis]->SetControlToMin();
               else
                 TrimAxes[current_axis]->SetControlToMax();
               TrimAxes[current_axis]->Run();
               delete TrimAxes[current_axis];
               TrimAxes[current_axis]=new FGTrimAxis(fdmex,fgic,tUdot,
-                                                    tGamma,Tolerance);
+                                                    tGamma );
             } else {
-              cout << "  Sorry, " << TrimAxes[current_axis]->GetAccelName()
+              cout << "  Sorry, " << TrimAxes[current_axis]->GetStateName()
               << " doesn't appear to be trimmable" << endl;
               //total_its=k;
               trim_failed=true; //force the trim to fail
@@ -303,15 +419,15 @@ bool FGTrim::DoTrim(void) {
     N++;
     if(N > max_iterations)
       trim_failed=true;
-  } while((axis_count < NumAxes) && (!trim_failed));
-  if((!trim_failed) && (axis_count >= NumAxes)) {
+  } while((axis_count < TrimAxes.size()) && (!trim_failed));
+  if((!trim_failed) && (axis_count >= TrimAxes.size())) {
     total_its=N;
     cout << endl << "  Trim successful" << endl;
   } else {
     total_its=N;
     cout << endl << "  Trim failed" << endl;
   }
-  for(int i=0;i < fdmex->GetAircraft()->GetNumGearUnits();i++){
+  for(i=0;i < fdmex->GetAircraft()->GetNumGearUnits();i++){
     fdmex->GetAircraft()->GetGearUnit(i)->SetReport(true);
   }
   fdmex->GetOutput()->Enable();
@@ -349,7 +465,7 @@ bool FGTrim::solve(void) {
       x2=x1-d*d0*f1/(f3-f1);
       TrimAxes[current_axis]->SetControl(x2);
       TrimAxes[current_axis]->Run();
-      f2=TrimAxes[current_axis]->GetAccel();
+      f2=TrimAxes[current_axis]->GetState();
       if(Debug > 1) {
         cout << "FGTrim::solve Nsub,x1,x2,x3: " << Nsub << ", " << x1
         << ", " << x2 << ", " << x3 << endl;
@@ -406,7 +522,7 @@ bool FGTrim::findInterval(void) {
   bool found=false;
   float step;
   float current_control=TrimAxes[current_axis]->GetControl();
-  float current_accel=TrimAxes[current_axis]->GetAccel();;
+  float current_accel=TrimAxes[current_axis]->GetState();;
   float xmin=TrimAxes[current_axis]->GetControlMin();
   float xmax=TrimAxes[current_axis]->GetControlMax();
   float lastxlo,lastxhi,lastalo,lastahi;
@@ -426,10 +542,10 @@ bool FGTrim::findInterval(void) {
     if(xhi > xmax) xhi=xmax;
     TrimAxes[current_axis]->SetControl(xlo);
     TrimAxes[current_axis]->Run();
-    alo=TrimAxes[current_axis]->GetAccel();
+    alo=TrimAxes[current_axis]->GetState();
     TrimAxes[current_axis]->SetControl(xhi);
     TrimAxes[current_axis]->Run();
-    ahi=TrimAxes[current_axis]->GetAccel();
+    ahi=TrimAxes[current_axis]->GetState();
     if(fabs(ahi-alo) <= TrimAxes[current_axis]->GetTolerance()) continue;
     if(alo*ahi <=0) {  //found interval with root
       found=true;
@@ -475,16 +591,16 @@ bool FGTrim::findInterval(void) {
 bool FGTrim::checkLimits(void) {
   bool solutionExists;
   float current_control=TrimAxes[current_axis]->GetControl();
-  float current_accel=TrimAxes[current_axis]->GetAccel();
+  float current_accel=TrimAxes[current_axis]->GetState();
   xlo=TrimAxes[current_axis]->GetControlMin();
   xhi=TrimAxes[current_axis]->GetControlMax();
 
   TrimAxes[current_axis]->SetControl(xlo);
   TrimAxes[current_axis]->Run();
-  alo=TrimAxes[current_axis]->GetAccel();
+  alo=TrimAxes[current_axis]->GetState();
   TrimAxes[current_axis]->SetControl(xhi);
   TrimAxes[current_axis]->Run();
-  ahi=TrimAxes[current_axis]->GetAccel();
+  ahi=TrimAxes[current_axis]->GetState();
   if(Debug > 1)
     cout << "checkLimits() xlo,xhi,alo,ahi: " << xlo << ", " << xhi << ", "
                                               << alo << ", " << ahi << endl;
@@ -508,8 +624,5 @@ bool FGTrim::checkLimits(void) {
   return solutionExists;
 }
 
-
-
-
 //YOU WERE WARNED, BUT YOU DID IT ANYWAY.
 
index 6f17a81cbbbde9f1192b43b55684b84099e6c439..f8469f97d6409a1d0f7d67ce875f460884a9bffb 100644 (file)
@@ -37,8 +37,6 @@ and throttle setting required to fly steady level. This is currently for in-air
 conditions only.  It is implemented using an iterative, one-axis-at-a-time 
 scheme.  
  
 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 SENTRY
 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%*/
@@ -63,15 +61,79 @@ INCLUDES
 #include "FGTrim.h"
 #include "FGTrimAxis.h"
 
-#include <vector.h>
+#include <vector>
+
+/*%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+DEFINITIONS
+%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%*/
 
-#define ID_TRIM "$Header"
+#define ID_TRIM "$Id$"
 
 /*%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
-CLASS DECLARATION
+FORWARD DECLARATIONS
 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%*/
 
-typedef enum { tLongitudinal, tFull, tGround } TrimMode;
+typedef enum { tLongitudinal, tFull, tGround, tCustom, tNone } TrimMode;
+
+/*%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+COMMENTS, REFERENCES, and NOTES [use "class documentation" below for API docs]
+%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%*/
+
+/*%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+CLASS DOCUMENTATION
+%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%*/
+
+/** FGTrim -- the trimming routine for JSBSim.
+    FGTrim finds the aircraft attitude and control settings needed to maintain
+    the steady state described by the FGInitialCondition object .  It does this
+    iteratively by assigning a control to each state and adjusting that control
+    until the state is within a specified tolerance of zero. States include the
+    recti-linear accelerations udot, vdot, and wdot, the angular accelerations 
+    qdot, pdot, and rdot, and the difference between heading and ground track.
+    Controls include the usual flight deck controls available to the pilot plus
+    angle of attack (alpha), sideslip angle(beta), flight path angle (gamma), 
+    pitch attitude(theta), roll attitude(phi), and altitude above ground.  The
+    last three are used for on-ground trimming. The state-control pairs used in
+    a given trim are completely user configurable and several pre-defined modes
+    are provided as well. They are:
+    <ul>
+    <li> tLongitudinal: Trim wdot with alpha, udot with thrust, qdot with elevator</li>
+    <li> tFull: tLongitudinal + vdot with phi, pdot with aileron, rdot with rudder
+                and heading minus ground track (hmgt) with beta</li>
+    <li> tGround: wdot with altitude, qdot with theta, and pdot with phi</li>
+    The remaining modes include <b>tCustom</b>, which is completely user defined and
+    <b>tNone</b>.
+    </ul>
+    Currently, this class cannot trim a non-1g condition and is limited to 
+    trimming for constant true airspeed in climbs and descents.
+    
+    Note that trims can (and do) fail for reasons that are completely outside
+    the control of the trimming routine itself. The most common problem is the 
+    initial conditions: is the model capable of steady state flight
+    at those conditions?  Check the speed, altitude, configuration (flaps,
+    gear, etc.), weight, cg, and anything else that may be relevant.
+    
+    Example usage:
+    FGFDMExec* FDMExec = new FGFDMExec();
+    .
+    .
+    .
+    FGInitialCondition* fgic = new FGInitialCondition(FDMExec);
+    FGTrim *fgt(FDMExec,fgic,tFull);
+    fgic->SetVcaibratedKtsIC(100);
+    fgic->SetAltitudeFtIC(1000);
+    fgic->SetClimbRate(500);
+    if( !fgt->DoTrim() ) {
+      cout << "Trim Failed" << endl;
+    }
+    fgt->ReportState();  
+    @author Tony Peden
+    @version $Id$
+*/       
+  
+/*%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+CLASS DECLARATION
+%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%*/
 
 class FGTrim {
 private:
@@ -79,7 +141,6 @@ private:
   vector<FGTrimAxis*> TrimAxes;
   int current_axis;
   int N, Nsub;
-  int NumAxes;
   TrimMode mode;
   int Debug;
   float Tolerance, A_Tolerance;
@@ -98,42 +159,116 @@ private:
   int solutionDomain;
   float xlo,xhi,alo,ahi;
 
-
   FGFDMExec* fdmex;
   FGInitialCondition* fgic;
-
-  // returns false if there is no change in the current axis accel
-  // between accel(control_min) and accel(control_max). if there is a
-  // change, sets solutionDomain to:
-  // 0 for no sign change,
-  // -1 if sign change between accel(control_min) and accel(0)
-  // 1 if sign between accel(0) and accel(control_max)
-  bool solve(void);
+   
+   bool solve(void);
+  
+  /** @return false if there is no change in the current axis accel
+      between accel(control_min) and accel(control_max). If there is a
+      change, sets solutionDomain to:
+      0 for no sign change,
+     -1 if sign change between accel(control_min) and accel(0)
+      1 if sign between accel(0) and accel(control_max)
+  */
   bool findInterval(void);
+
   bool checkLimits(void);
 
 public:
+  /** Initializes the trimming class
+      @param FDMExec pointer to a JSBSim executive object.
+      @param FGIC pointer to a FGInitialCondition object
+      @param TrimMode the set of axes to trim. Can be:
+             tLongitudinal, tFull, tGround, tCustom, or tNone
+  */
   FGTrim(FGFDMExec *FDMExec, FGInitialCondition *FGIC, TrimMode tt);
-  ~FGTrim(void);
 
+    ~FGTrim(void);
+
+  /** Execute the trim
+  */
   bool DoTrim(void);
 
+  /** Print the results of the trim. For each axis trimmed, this 
+      includes the final state value, control value, and tolerance
+      used.
+      @return true if trim succeeds
+  */     
   void Report(void);
+  
+  /** Prints a summary of simulator state (speed, altitude, 
+      configuration, etc.)
+  */
   void ReportState(void);
+  
+  /** Iteration statistics
+  */
   void TrimStats();
 
-  inline void SetUdotTrim(bool bb) { trimudot=bb; }
-  inline bool GetUdotTrim(void) { return trimudot; }
+  /** Clear all state-control pairs from the current configuration.
+      The trimming routine must have at least one state-control pair
+      configured to be useful
+  */    
+  void ClearStates(void);
+
+  /** Add a state-control pair to the current configuration. See the enums
+      State and Control in FGTrimAxis.h for the available options.
+      Will fail if the given state is already configured.
+      @param state the accel or other condition to zero 
+      @param control the control used to zero the state
+      @return true if add is successful
+  */    
+  bool AddState( State state, Control control );
+  
+  /** Remove a specific state-control pair from the current configuration
+      @param state the state to remove
+      @return true if removal is successful
+  */    
+  bool RemoveState( State state );
+  
+  /** Change the control used to zero a state previously configured
+      @param state the accel or other condition to zero 
+      @param control the control used to zero the state
+  */
+  bool EditState( State state, Control new_control );
 
+  /** automatically switch to trimming longitudinal acceleration with
+      flight path angle (gamma) once it becomes apparent that there
+      is not enough/too much thrust.
+      @param gamma_fallback true to enable fallback
+  */     
   inline void SetGammaFallback(bool bb) { gamma_fallback=true; }
+  
+  /** query the fallback state
+      @return true if fallback is enabled.
+  */
   inline bool GetGammaFallback(void) { return gamma_fallback; }
 
+  /** Set the iteration limit. DoTrim() will return false if limit
+      iterations are reached before trim is achieved.  The default
+      is 60.  This does not ordinarily need to be changed.
+      @param ii integer iteration limit 
+  */
   inline void SetMaxCycles(int ii) { max_iterations = ii; }
+  
+  /** Set the per-axis iteration limit.  Attempt to zero each state
+      by iterating limit times before moving on to the next. The
+      default limit is 100 and also does not ordinarily need to
+      be changed.
+      @param ii integer iteration limit 
+  */    
   inline void SetMaxCyclesPerAxis(int ii) { max_sub_iterations = ii; }
+  
+  /** Set the tolerance for declaring a state trimmed. Angular accels are
+      held to a tolerance of 1/10th of the given.  The default is 
+      0.001 for the recti-linear accelerations and 0.0001 for the angular.
+  */         
   inline void SetTolerance(float tt) {
     Tolerance = tt;
     A_Tolerance = tt / 10;
   }
+  
   //Debug level 1 shows results of each top-level iteration
   //Debug level 2 shows level 1 & results of each per-axis iteration
   inline void SetDebug(int level) { Debug = level; }
index 292454f04ce68c944a5ccf22682a64d2496d12c3..692b82c5a0fcac7513768730fe8a72e78a80f69a 100644 (file)
@@ -40,29 +40,31 @@ INCLUDES
 #include "FGInitialCondition.h"
 #include "FGTrimAxis.h"
 #include "FGAircraft.h"
+#include "FGPropulsion.h"
 
-static const char *IdSrc = "$Header$";
+static const char *IdSrc = "$Id$";
 static const char *IdHdr = ID_TRIMAXIS;
 
+extern short debug_lvl;
+
 /*****************************************************************************/
 
-FGTrimAxis::FGTrimAxis(FGFDMExec* fdex, FGInitialCondition* ic, Accel acc,
-                       Control ctrl, float ff) {
+FGTrimAxis::FGTrimAxis(FGFDMExec* fdex, FGInitialCondition* ic, State st,
+                       Control ctrl) {
 
   fdmex=fdex;
   fgic=ic;
-  accel=acc;
+  state=st;
   control=ctrl;
-  tolerance=ff;
   solver_eps=tolerance;
   max_iterations=10;
   control_value=0;
   its_to_stable_value=0;
   total_iterations=0;
   total_stability_iterations=0;
-  accel_convert=1.0;
+  state_convert=1.0;
   control_convert=1.0;
-  accel_value=0;
+  state_value=0;
   switch(control) {
   case tThrottle:
     control_min=0;
@@ -93,7 +95,7 @@ FGTrimAxis::FGTrimAxis(FGFDMExec* fdex, FGInitialCondition* ic, Accel acc,
   case tRudder:
     control_min=-1;
     control_max=1;
-    accel_convert=RADTODEG;
+    state_convert=RADTODEG;
     solver_eps=tolerance/100;
     break;
   case tAltAGL:
@@ -105,12 +107,13 @@ FGTrimAxis::FGTrimAxis(FGFDMExec* fdex, FGInitialCondition* ic, Accel acc,
   case tTheta:
     control_min=fdmex->GetRotation()->Gettht() - 5*DEGTORAD;
     control_max=fdmex->GetRotation()->Gettht() + 5*DEGTORAD;
-    accel_convert=RADTODEG;
+    state_convert=RADTODEG;
     break;
   case tPhi:
-    control_min=fdmex->GetRotation()->Getphi() - 5*DEGTORAD;
-    control_max=fdmex->GetRotation()->Getphi() + 5*DEGTORAD;
-    accel_convert=RADTODEG;
+    control_min=fdmex->GetRotation()->Getphi() - 30*DEGTORAD;
+    control_max=fdmex->GetRotation()->Getphi() + 30*DEGTORAD;
+    state_convert=RADTODEG;
+    control_convert=RADTODEG;
     break;
   case tGamma:
     solver_eps=tolerance/100;
@@ -118,30 +121,50 @@ FGTrimAxis::FGTrimAxis(FGFDMExec* fdex, FGInitialCondition* ic, Accel acc,
     control_max=80*DEGTORAD;
     control_convert=RADTODEG;
     break;
+  case tHeading:
+    control_min=fdmex->GetRotation()->Getpsi() - 30*DEGTORAD;
+    control_max=fdmex->GetRotation()->Getpsi() + 30*DEGTORAD;
+    state_convert=RADTODEG;
+    break;
   }
   
+  switch(state) {
+    case tUdot: tolerance = DEFAULT_TOLERANCE; break;
+    case tVdot: tolerance = DEFAULT_TOLERANCE; break;
+    case tWdot: tolerance = DEFAULT_TOLERANCE; break;
+    case tQdot: tolerance = DEFAULT_TOLERANCE / 10; break;
+    case tPdot: tolerance = DEFAULT_TOLERANCE / 10; break;
+    case tRdot: tolerance = DEFAULT_TOLERANCE / 10; break;
+    case tHmgt: tolerance = 0.01; break;
+  }  
+  
+  if (debug_lvl & 2) cout << "Instantiated: FGTrimAxis" << endl;
 }
 
 /*****************************************************************************/
 
-FGTrimAxis::~FGTrimAxis() {}
+FGTrimAxis::~FGTrimAxis()
+{
+  if (debug_lvl & 2) cout << "Destroyed:    FGTrimAxis" << endl;
+}
 
 /*****************************************************************************/
 
-void FGTrimAxis::getAccel(void) {
-  switch(accel) {
-  case tUdot: accel_value=fdmex -> GetTranslation()->GetUVWdot()(1); break;
-  case tVdot: accel_value=fdmex -> GetTranslation()->GetUVWdot()(2); break;
-  case tWdot: accel_value=fdmex -> GetTranslation()->GetUVWdot()(3); break;
-  case tQdot: accel_value=fdmex -> GetRotation()->GetPQRdot()(2);break;
-  case tPdot: accel_value=fdmex -> GetRotation()->GetPQRdot()(1); break;
-  case tRdot: accel_value=fdmex -> GetRotation()->GetPQRdot()(3); break;
+void FGTrimAxis::getState(void) {
+  switch(state) {
+  case tUdot: state_value=fdmex->GetTranslation()->GetUVWdot()(1); break;
+  case tVdot: state_value=fdmex->GetTranslation()->GetUVWdot()(2); break;
+  case tWdot: state_value=fdmex->GetTranslation()->GetUVWdot()(3); break;
+  case tQdot: state_value=fdmex->GetRotation()->GetPQRdot()(2);break;
+  case tPdot: state_value=fdmex->GetRotation()->GetPQRdot()(1); break;
+  case tRdot: state_value=fdmex->GetRotation()->GetPQRdot()(3); break;
+  case tHmgt: state_value=computeHmgt(); break;
   }
 }
 
 /*****************************************************************************/
 
-//Accels are not settable
+//States are not settable
 
 void FGTrimAxis::getControl(void) {
   switch(control) {
@@ -158,27 +181,47 @@ void FGTrimAxis::getControl(void) {
   case tTheta:     control_value=fdmex->GetRotation()->Gettht(); break;
   case tPhi:       control_value=fdmex->GetRotation()->Getphi(); break;
   case tGamma:     control_value=fdmex->GetPosition()->GetGamma();break;
+  case tHeading:   control_value=fdmex->GetRotation()->Getpsi(); break;
   }
 }
 
 /*****************************************************************************/
 
+float FGTrimAxis::computeHmgt(void) {
+  float diff;
+  
+  diff   = fdmex->GetRotation()->Getpsi() - 
+             fdmex->GetPosition()->GetGroundTrack();
+  
+  if( diff < -M_PI ) {
+     return (diff + 2*M_PI);
+  } else if( diff > M_PI ) {
+     return (diff - 2*M_PI);
+  } else {
+     return diff;
+  }
+
+}
+       
+/*****************************************************************************/
+
 
 void FGTrimAxis::setControl(void) {
   switch(control) {
   case tThrottle:  setThrottlesPct(); break;
   case tBeta:      fgic->SetBetaRadIC(control_value); break;
   case tAlpha:     fgic->SetAlphaRadIC(control_value);  break;
-  case tPitchTrim: fdmex->GetFCS() -> SetPitchTrimCmd(control_value); break;
-  case tElevator:  fdmex-> GetFCS() -> SetDeCmd(control_value); break;
+  case tPitchTrim: fdmex->GetFCS()->SetPitchTrimCmd(control_value); break;
+  case tElevator:  fdmex->GetFCS()->SetDeCmd(control_value); break;
   case tRollTrim:
-  case tAileron:   fdmex-> GetFCS() -> SetDaCmd(control_value); break;
+  case tAileron:   fdmex->GetFCS()->SetDaCmd(control_value); break;
   case tYawTrim:
-  case tRudder:    fdmex-> GetFCS() -> SetDrCmd(control_value); break;
+  case tRudder:    fdmex->GetFCS()->SetDrCmd(control_value); break;
   case tAltAGL:    fgic->SetAltitudeAGLFtIC(control_value); break;
   case tTheta:     fgic->SetPitchAngleRadIC(control_value); break;
   case tPhi:       fgic->SetRollAngleRadIC(control_value); break;
   case tGamma:     fgic->SetFlightPathAngleRadIC(control_value); break;
+  case tHeading:   fgic->SetTrueHeadingRadIC(control_value); break;
   }
 }
 
@@ -326,7 +369,7 @@ void FGTrimAxis::SetPhiOnGround(float ff) {
 
 void FGTrimAxis::Run(void) {
 
-  float last_accel_value;
+  float last_state_value;
   int i;
   setControl();
   //cout << "FGTrimAxis::Run: " << control_value << endl;
@@ -334,11 +377,11 @@ void FGTrimAxis::Run(void) {
   bool stable=false;
   while(!stable) {
     i++;
-    last_accel_value=accel_value;
+    last_state_value=state_value;
     fdmex->RunIC(fgic);
-    getAccel();
+    getState();
     if(i > 1) {
-      if((fabs(last_accel_value - accel_value) < tolerance) || (i >= 100) )
+      if((fabs(last_state_value - state_value) < tolerance) || (i >= 100) )
         stable=true;
     }
   }
@@ -352,29 +395,26 @@ void FGTrimAxis::Run(void) {
 
 void FGTrimAxis::setThrottlesPct(void) {
   float tMin,tMax;
-  for(unsigned i=0;i<fdmex->GetAircraft()->GetNumEngines();i++) {
-      tMin=fdmex->GetAircraft()->GetEngine(i)->GetThrottleMin();
-      tMax=fdmex->GetAircraft()->GetEngine(i)->GetThrottleMax();
+  for(unsigned i=0;i<fdmex->GetPropulsion()->GetNumEngines();i++) {
+      tMin=fdmex->GetPropulsion()->GetEngine(i)->GetThrottleMin();
+      tMax=fdmex->GetPropulsion()->GetEngine(i)->GetThrottleMax();
       //cout << "setThrottlespct: " << i << ", " << control_min << ", " << control_max << ", " << control_value;
       fdmex -> GetFCS() -> SetThrottleCmd(i,tMin+control_value*(tMax-tMin));
   }
 }
 
-
 /*****************************************************************************/
 
-
 void FGTrimAxis::AxisReport(void) {
   
   char out[80];
   sprintf(out,"  %20s: %6.2f %5s: %9.2e Tolerance: %3.0e\n",
            GetControlName().c_str(), GetControl()*control_convert,
-           GetAccelName().c_str(), GetAccel(), GetTolerance()); 
+           GetStateName().c_str(), GetState(), GetTolerance()); 
   cout << out;
 
 }
 
-
 /*****************************************************************************/
 
 float FGTrimAxis::GetAvgStability( void ) {
@@ -384,3 +424,9 @@ float FGTrimAxis::GetAvgStability( void ) {
   return 0;
 }
 
+/*****************************************************************************/
+
+void FGTrimAxis::Debug(void)
+{
+}
+
index d03ac462bad5980f4d5b96952950414bbf276bce..969e89cda8b7e6c154c6575418a254cfe77403c7 100644 (file)
  Further information about the GNU General Public License can also be found on
  the world wide web at http://www.gnu.org.
  
  HISTORY
 --------------------------------------------------------------------------------
 7/3/00  TP   Created
  
 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 SENTRY
 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%*/
@@ -54,40 +51,44 @@ INCLUDES
 #include "FGAuxiliary.h"
 #include "FGOutput.h"
 
-#define ID_TRIMAXIS "$Header"
+#define ID_TRIMAXIS "$Id$"
+
+#define DEFAULT_TOLERANCE 0.001
 
-const string AccelNames[6]=   { "udot","vdot","wdot","qdot","pdot","rdot" };
-const string ControlNames[13]= { "Throttle","Sideslip","Angle of Attack",
+const string StateNames[7]=   { "udot","vdot","wdot","qdot","pdot","rdot","hmgt" };
+const string ControlNames[14]= { "Throttle","Sideslip","Angle of Attack",
                                  "Elevator","Ailerons","Rudder",
                                  "Altitude AGL", "Pitch Angle",
                                  "Roll Angle", "Flight Path Angle", 
-                                 "Pitch Trim", "Roll Trim", "Yaw Trim"
+                                 "Pitch Trim", "Roll Trim", "Yaw Trim",
+                                 "Heading"
                                };
+
 /*%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 CLASS DECLARATION
 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%*/
 
-enum Accel { tUdot,tVdot,tWdot,tQdot,tPdot,tRdot };
+enum State { tUdot,tVdot,tWdot,tQdot,tPdot,tRdot,tHmgt };
 enum Control { tThrottle, tBeta, tAlpha, tElevator, tAileron, tRudder, tAltAGL,
-               tTheta, tPhi, tGamma, tPitchTrim, tRollTrim, tYawTrim };
+               tTheta, tPhi, tGamma, tPitchTrim, tRollTrim, tYawTrim, tHeading };
 
 class FGTrimAxis {
 public:
-  FGTrimAxis(FGFDMExec* fdmex, FGInitialCondition *ic, Accel acc,
-             Control ctrl, float tolerance);
+  FGTrimAxis(FGFDMExec* fdmex, FGInitialCondition *ic, State st,
+             Control ctrl );
   ~FGTrimAxis();
 
   void Run(void);
  
-  float GetAccel(void) { getAccel(); return accel_value; }
+  float GetState(void) { getState(); return state_value; }
   //Accels are not settable
   inline void SetControl(float value ) { control_value=value; }
   inline float GetControl(void) { return control_value; }
 
-  inline Accel GetAccelType(void) { return accel; }
+  inline State GetStateType(void) { return state; }
   inline Control GetControlType(void) { return control; }
 
-  inline string GetAccelName(void) { return AccelNames[accel]; }
+  inline string GetStateName(void) { return StateNames[state]; }
   inline string GetControlName(void) { return ControlNames[control]; }
 
   inline float GetControlMin(void) { return control_min; }
@@ -121,17 +122,16 @@ public:
   
   void AxisReport(void);
   
-  bool InTolerance(void) { getAccel(); return (fabs(accel_value) <= tolerance); }
+  bool InTolerance(void) { getState(); return (fabs(state_value) <= tolerance); }
 
 private:
   FGFDMExec *fdmex;
   FGInitialCondition *fgic;
 
-
-  Accel   accel;
+  State   state;
   Control control;
 
-  float accel_value;
+  float state_value;
   float control_value;
 
   float control_min;
@@ -141,7 +141,7 @@ private:
 
   float solver_eps;
 
-  float accel_convert;
+  float state_convert;
   float control_convert;
 
   int max_iterations;
@@ -150,15 +150,15 @@ private:
   int total_stability_iterations;
   int total_iterations;
 
-
   void setThrottlesPct(void);
 
-  void getAccel(void);
+  void getState(void);
   void getControl(void);
   void setControl(void);
   
+  float computeHmgt(void);
   
-
+  void Debug(void);
 };
 
 #endif
index 6d04e394ad8e2e4589d03e5fd1839a5de85f721a..93c383dda4f7e9f29da8f85cde55f56db70ac70a 100644 (file)
@@ -40,17 +40,40 @@ INCLUDES
 
 #include "FGTurboJet.h"
 
-static const char *IdSrc = "$Header$";
+static const char *IdSrc = "$Id$";
 static const char *IdHdr = ID_TURBOJET;
 
+extern short debug_lvl;
+
 /*%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 CLASS IMPLEMENTATION
 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%*/
 
 
-FGTurboJet::FGTurboJet(FGFDMExec* fdex, string enginePath, string engineName, int num) :
-                                 FGEngine(fdex, enginePath, engineName, num)
+FGTurboJet::FGTurboJet(FGFDMExec* exec, FGConfigFile* cfg) : FGEngine(exec)
+{
+  if (debug_lvl & 2) cout << "Instantiated: FGTurboJet" << endl;
+}
+
+//%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+
+FGTurboJet::~FGTurboJet()
+{
+  if (debug_lvl & 2) cout << "Destroyed:    FGTurboJet" << endl;
+}
+
+//%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+
+float FGTurboJet::Calculate(float dummy)
+{
+  ConsumeFuel();
+  return 0.0;
+}
+
+//%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+
+void FGTurboJet::Debug(void)
 {
-  //
+    //TODO: Add your source code here
 }
 
index d109f33bb5690f3ea200e1c7e3b4b2f6a42eb767..8c3456eb1430a982420629b3c47efce9cd6607e5 100644 (file)
@@ -43,8 +43,9 @@ INCLUDES
 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%*/
 
 #include "FGEngine.h"
+#include "FGConfigFile.h"
 
-#define ID_TURBOJET "$Header"
+#define ID_TURBOJET "$Id$"
 
 /*%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 CLASS DECLARATION
@@ -52,12 +53,16 @@ CLASS DECLARATION
 
 class FGTurboJet : public FGEngine
 {
-
 public:
-  FGTurboJet(FGFDMExec*, string, string, int);
+  FGTurboJet(FGFDMExec* exec, FGConfigFile* Eng_cfg);
   ~FGTurboJet();
 
+  float Calculate(float);
+  
+private:
+  void Debug(void);
 };
 
 //%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 #endif
+
index f85d0a63727f5a39f12a20de4d27415ca32b1c32..86030771e8422e96d56513ab959485bf6e547352 100644 (file)
@@ -40,17 +40,37 @@ INCLUDES
 
 #include "FGTurboShaft.h"
 
-static const char *IdSrc = "$Header$";
+static const char *IdSrc = "$Id$";
 static const char *IdHdr = ID_TURBOSHAFT;
 
+extern short debug_lvl;
+
 /*%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 CLASS IMPLEMENTATION
 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%*/
 
+FGTurboShaft::FGTurboShaft(FGFDMExec* exec, FGConfigFile* cfg) : FGEngine(exec)
+{
+  if (debug_lvl & 2) cout << "Instantiated: FGTurboShaft" << endl;
+}
 
-FGTurboShaft::FGTurboShaft(FGFDMExec* fdex, string enginePath, string engineName, int num) :
-                                 FGEngine(fdex, enginePath, engineName, num)
+//%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+
+FGTurboShaft::~FGTurboShaft()
 {
-  //
+  if (debug_lvl & 2) cout << "Destroyed:    FGTurboShaft" << endl;
+}
+
+//%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+
+float FGTurboShaft::Calculate(float dummy) {
+  ConsumeFuel();
+  return 0.0;
 }
 
+//%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+
+void FGTurboShaft::Debug(void)
+{
+    //TODO: Add your source code here
+}
index 75f9b1d6ecb431d38a2de670565bdc8202e21769..278ed557eba5f8dc052f4b0238f0b5971aa3c957 100644 (file)
@@ -43,8 +43,9 @@ INCLUDES
 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%*/
 
 #include "FGEngine.h"
+#include "FGConfigFile.h"
 
-#define ID_TURBOSHAFT "$Header"
+#define ID_TURBOSHAFT "$Id$"
 
 /*%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 CLASS DECLARATION
@@ -52,12 +53,15 @@ CLASS DECLARATION
 
 class FGTurboShaft : public FGEngine
 {
-
 public:
-  FGTurboShaft(FGFDMExec*, string, string, int);
+  FGTurboShaft(FGFDMExec* exec, FGConfigFile* Eng_cfg);
   ~FGTurboShaft();
 
+  float Calculate(float);
+private:
+  void Debug(void);
 };
 
 //%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 #endif
+
index b837060d850dcd36e16a43adc478fbd0f55bf592..892db1cebb778ec427ee04bee227ce2f8de61290 100644 (file)
@@ -44,7 +44,7 @@ INCLUDES
 
 #ifdef FGFS
 #  include <simgear/compiler.h>
-#  ifdef SG_HAVE_STD_INCLUDES
+#  ifdef FG_HAVE_STD_INCLUDES
 #    include <cmath>
 #  else
 #    include <math.h>
@@ -57,19 +57,31 @@ INCLUDES
 #include "FGState.h"
 #include "FGFDMExec.h"
 
-static const char *IdSrc = "$Header$";
+static const char *IdSrc = "$Id$";
 static const char *IdHdr = ID_UTILITY;
 
+extern short debug_lvl;
+
 /*%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 CLASS IMPLEMENTATION
 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%*/
 
 FGUtility::FGUtility()
 {
+  if (debug_lvl & 2) cout << "Instantiated: FGUtility" << endl;
 }
 
+//%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 
 FGUtility::~FGUtility()
+{
+  if (debug_lvl & 2) cout << "Destroyed:    FGUtility" << endl;
+}
+
+//%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+
+void FGUtility::Debug(void)
 {
 }
 
+
index 5457ee1d7395d2a0583dfc416d3a972ee58d6f9b..824f87dde0951acbe4983e6ce62591129b76f1dd 100644 (file)
@@ -42,7 +42,7 @@ INCLUDES
 DEFINES
 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%*/
 
-#define ID_UTILITY "$Header"
+#define ID_UTILITY "$Id$"
 
 /*%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 CLASS DECLARATION
@@ -55,13 +55,12 @@ class FGUtility
 {
 public:
   FGUtility(void);
-  ~FGUtility(void);
-
-protected:
+  ~FGUtility();
 
 private:
   FGState* State;
   FGFDMExec* FDMExec;
+  void Debug(void);
 };
 
 //%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
index 19be402a7604ece6acbb4c424ca05e9ed383c397..105187102a87098b9dde7219af0a050d5fb08d47 100644 (file)
@@ -39,9 +39,11 @@ INCLUDES
 
 #include "FGfdmSocket.h"
 
-static const char *IdSrc = "$Header$";
+static const char *IdSrc = "$Id$";
 static const char *IdHdr = ID_FDMSOCKET;
 
+extern short debug_lvl;
+
 /*%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 CLASS IMPLEMENTATION
 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%*/
@@ -87,9 +89,11 @@ FGfdmSocket::FGfdmSocket(string address, int port)
       cout << "Could not create socket for FDM, error = " << errno << endl;
     }
   }
+
+  if (debug_lvl & 2) cout << "Instantiated: FGfdmSocket" << endl;
 }
 
-FGfdmSocket::~FGfdmSocket(void)
+FGfdmSocket::~FGfdmSocket()
 {
   #ifndef macintosh
   if (sckt) shutdown(sckt,2);
index f40429e83fce7e401147bfcd6dd60bb956af0a6a..e5064a519fa2d62e2815e3b82fd3f7ec1ad4563d 100644 (file)
@@ -45,9 +45,8 @@ INCLUDES
 #include <stdio.h>
 
 #ifdef FGFS
-#  pragma message("FGFS defined")
 #  include <simgear/compiler.h>
-#  ifdef SG_HAVE_STD_INCLUDES
+#  ifdef FG_HAVE_STD_INCLUDES
 #    include <iostream>
 #    include <fstream>
 #  else
@@ -55,7 +54,6 @@ INCLUDES
 #    include <fstream.h>
 #  endif
 #else
-#  pragma message("FGFS not defined")
 #  include <iostream>
 #  include <fstream>
 #endif
@@ -76,7 +74,7 @@ INCLUDES
 DEFINITIONS
 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%*/
 
-#define ID_FDMSOCKET "$Header"
+#define ID_FDMSOCKET "$Id$"
 
 using std::cout;
 using std::endl;
@@ -90,7 +88,7 @@ using std::string;
 class FGfdmSocket {
 public:
   FGfdmSocket(string, int);
-  ~FGfdmSocket(void);
+  ~FGfdmSocket();
   void Send(void);
   void Append(const char*);
   void Append(float);
index 3d2c84d6a01de8ff55658123e75efa66ed3e3d22..499be681732646519a6074bbfa9a4cce612ec18d 100644 (file)
@@ -39,58 +39,6 @@ HISTORY
 INCLUDES
 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%*/
 
-#if __BCPLUSPLUS__  == 0x0540   // If compiling under Borland C++Builder
-#pragma hdrstop
-#include <condefs.h>
-USEUNIT("FGUtility.cpp");
-USEUNIT("FGAtmosphere.cpp");
-USEUNIT("FGAuxiliary.cpp");
-USEUNIT("FGCoefficient.cpp");
-USEUNIT("FGConfigFile.cpp");
-USEUNIT("FGControls.cpp");
-USEUNIT("FGEngine.cpp");
-USEUNIT("FGFCS.cpp");
-USEUNIT("FGFDMExec.cpp");
-USEUNIT("FGfdmSocket.cpp");
-USEUNIT("FGInitialCondition.cpp");
-USEUNIT("FGLGear.cpp");
-USEUNIT("FGMatrix.cpp");
-USEUNIT("FGModel.cpp");
-USEUNIT("FGOutput.cpp");
-USEUNIT("FGPosition.cpp");
-USEUNIT("FGRotation.cpp");
-USEUNIT("FGState.cpp");
-USEUNIT("FGTank.cpp");
-USEUNIT("FGTranslation.cpp");
-USEUNIT("FGAircraft.cpp");
-USERES("JSBSim.res");
-USEUNIT("filtersjb\FGfcsComponent.cpp");
-USEUNIT("filtersjb\FGSwitch.cpp");
-USEUNIT("filtersjb\FGFilter.cpp");
-USEUNIT("filtersjb\FGGain.cpp");
-USEUNIT("filtersjb\FGGradient.cpp");
-USEUNIT("filtersjb\FGSummer.cpp");
-USEUNIT("filtersjb\FGDeadBand.cpp");
-USEUNIT("filtersjb\FGFlaps.cpp");
-USEFILE("JSBSim.cxx");
-USEUNIT("FGForce.cpp");
-USEUNIT("FGInertial.cpp");
-USEUNIT("FGNozzle.cpp");
-USEUNIT("FGPropeller.cpp");
-USEUNIT("FGRotor.cpp");
-USEUNIT("FGThruster.cpp");
-USEUNIT("FGMassBalance.cpp");
-USEUNIT("FGRocket.cpp");
-USEUNIT("FGTurboJet.cpp");
-USEUNIT("FGPiston.cpp");
-USEUNIT("FGTurboShaft.cpp");
-USEUNIT("FGPropulsion.cpp");
-USEUNIT("FGGroundReactions.cpp");
-USEUNIT("FGAerodynamics.cpp");
-
-#pragma argsused
-#endif
-
 #include "FGFDMExec.h"
 #include "FGRotation.h"
 #include "FGAtmosphere.h"
@@ -101,11 +49,12 @@ USEUNIT("FGAerodynamics.cpp");
 #include "FGPosition.h"
 #include "FGAuxiliary.h"
 #include "FGOutput.h"
+#include "FGConfigFile.h"
 
 #ifdef FGFS
 #include <simgear/compiler.h>
 #include STL_IOSTREAM
-#  ifdef SG_HAVE_STD_INCLUDES
+#  ifdef FG_HAVE_STD_INCLUDES
 #    include <ctime>
 #  else
 #    include <time.h>
@@ -123,7 +72,7 @@ DEFINITIONS
 GLOBAL DATA
 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%*/
 
-static const char *IdSrc = "$Header$";
+static const char *IdSrc = "$Id$";
 
 /*%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 COMMENTS, REFERENCES, and NOTES [use "class documentation" below for API docs]
@@ -136,8 +85,8 @@ DOCUMENTATION
 /** Standalone JSBSim main program
     This is the wrapper program used to instantiate the JSBSim system and control
     it. Use this program to build a version of JSBSim that can be run from the
-    command line. This program is also designed to be built using Borland C++
-    Builder, v4.0 or greater.
+    command line. To get any use out of this, you will have to create a script
+    to run a test case and specify what kind of output you would like.
     @author Jon S. Berndt
     @version $Id$
     @see -
@@ -150,56 +99,54 @@ IMPLEMENTATION
 int main(int argc, char** argv)
 {
   FGFDMExec* FDMExec;
+  float cmd = 0.0;
   bool result = false;
+  bool scripted = false;
+
+  if (argc == 2) {
+    FGConfigFile testFile(argv[1]);
 
-  if (argc != 3) {
+    if (!testFile.IsOpen()) {
+      cout << "Script file not opened" << endl;
+      exit(-1); 
+    }
+
+    testFile.GetNextConfigLine();
+    if (testFile.GetValue("runscript").length() <= 0) {
+      cout << "File: " << argv[1] << " is not a script file" << endl;
+      exit(-1); 
+    }
+    scripted = true;
+  } else if (argc != 3) {
     cout << endl
          << "  You must enter the name of a registered aircraft and reset point:"
          << endl << endl << "  FDM <aircraft name> <reset file>" << endl;
+    cout << endl << "  Alternatively, you may specify only the name of a script file:"
+         << endl << endl << "  FDM <script file>" << endl << endl;
     exit(0);
   }
 
   FDMExec = new FGFDMExec();
 
-  result = FDMExec->LoadModel("aircraft", "engine", string(argv[1]));
-  
-  if (!result) {
-       cerr << "Aircraft file " << argv[1] << " was not found" << endl;
-         exit(-1);
-  }
-  
-  if ( ! FDMExec->GetState()->Reset("aircraft", string(argv[1]), string(argv[2])))
-    FDMExec->GetState()->Initialize(2000,0,0,0,0,0,0.5,0.5,40000);
-
-  float cmd = 0.0;
-
-  while (FDMExec->GetState()->Getsim_time() <= 10.0)
-  {
-    // Fake an elevator ramp here after 1 second, hold for one second, ramp down
-    
-    if (FDMExec->GetState()->Getsim_time() >= 1.00 &&
-        FDMExec->GetState()->Getsim_time() < 2.0)
-    {
-      cmd = -(FDMExec->GetState()->Getsim_time() - 1.00)/4.0;
-    } else if (FDMExec->GetState()->Getsim_time() >= 2.00 &&
-        FDMExec->GetState()->Getsim_time() < 6.0)
-    {
-      cmd = -1.00/4.0;
-    } else if (FDMExec->GetState()->Getsim_time() >= 6.00 &&
-        FDMExec->GetState()->Getsim_time() < 7.0)
-    {
-      cmd = -(7.0 - FDMExec->GetState()->Getsim_time())/4.0;
-    } else {
-      cmd = 0.00;
+  if (scripted) {
+    result = FDMExec->LoadScript(argv[1]);
+    if (!result) {
+      cerr << "Script file " << argv[1] << " was not successfully loaded" << endl;
+      exit(-1);
+    }
+  } else {
+    result = FDMExec->LoadModel("aircraft", "engine", string(argv[1]));
+    if (!result) {
+       cerr << "Aircraft file " << argv[1] << " was not found" << endl;
+           exit(-1);
     }
-    FDMExec->GetFCS()->SetDeCmd(cmd);    // input between -1 and 1
-    
-    FDMExec->Run();
+    if ( ! FDMExec->GetState()->Reset("aircraft", string(argv[1]), string(argv[2])))
+                   FDMExec->GetState()->Initialize(2000,0,0,0,0,0,0.5,0.5,40000);
   }
 
+  while (FDMExec->Run()) {}
+
   delete FDMExec;
 
   return 0;
 }
-
-
index 53838094b885d8790b09c4285c070f95e17c495f..ce6d9dbc80c1e8e87b37b7f39dfd057718701241 100644 (file)
@@ -24,17 +24,28 @@ libJSBSim_a_SOURCES = \
        FGDefs.h \
        FGFCS.cpp FGFCS.h \
        FGFDMExec.cpp FGFDMExec.h \
+       FGForce.cpp FGForce.h \
        FGInitialCondition.cpp FGInitialCondition.h \
        FGLGear.cpp FGLGear.h \
        FGMatrix.cpp FGMatrix.h \
        FGModel.cpp FGModel.h \
+       FGNozzle.cpp FGNozzle.h \
        FGOutput.cpp FGOutput.h \
+        FGPiston.cpp FGPiston.h \
+        FGPropeller.cpp FGPropeller.h \
+        FGPropulsion.cpp FGPropulsion.h \
        FGPosition.cpp FGPosition.h \
        FGRotation.cpp FGRotation.h \
+       FGRocket.cpp FGRocket.h \
        FGState.cpp FGState.h \
+       FGTable.cpp FGTable.h \
+       FGThruster.cpp FGThruster.h \
        FGTranslation.cpp FGTranslation.h \
        FGTrim.cpp FGTrim.h \
        FGTrimAxis.cpp FGTrimAxis.h \
+       FGTurboJet.cpp FGTurboJet.h \
+       FGTurboProp.cpp FGTurboProp.h \
+       FGTurboShaft.cpp FGTurboShaft.h \
        FGUtility.cpp FGUtility.h \
        FGEngine.cpp FGEngine.h \
        FGTank.cpp FGTank.h \
index 2a4680673dc6ee5d38b017851de6e7fe355f60d1..f947c64144941f0d34a3b155307eac6f69441697 100644 (file)
@@ -175,52 +175,64 @@ FGInterface::bind ()
                        // Aircraft position
   fgTie("/position/latitude", this,
        &FGInterface::get_Latitude_deg,
-       &FGInterface::set_Latitude_deg);
+       &FGInterface::set_Latitude_deg,
+       false);
   fgTie("/position/longitude", this,
        &FGInterface::get_Longitude_deg,
-       &FGInterface::set_Longitude_deg);
+       &FGInterface::set_Longitude_deg,
+       false);
   fgTie("/position/altitude", this,
        &FGInterface::get_Altitude,
-       &FGInterface::set_Altitude);
+       &FGInterface::set_Altitude,
+       false);
   fgTie("/position/altitude-agl", this,
        &FGInterface::get_Altitude_AGL); // read-only
 
                                // Orientation
   fgTie("/orientation/roll", this,
        &FGInterface::get_Phi_deg,
-       &FGInterface::set_Phi_deg);
+       &FGInterface::set_Phi_deg,
+       false);
   fgTie("/orientation/pitch", this,
        &FGInterface::get_Theta_deg,
-       &FGInterface::set_Theta_deg);
+       &FGInterface::set_Theta_deg,
+       false);
   fgTie("/orientation/heading", this,
        &FGInterface::get_Psi_deg,
-       &FGInterface::set_Psi_deg);
+       &FGInterface::set_Psi_deg,
+       false);
 
                                // Calibrated airspeed
   fgTie("/velocities/airspeed", this,
        &FGInterface::get_V_calibrated_kts,
-       &FGInterface::set_V_calibrated_kts);
+       &FGInterface::set_V_calibrated_kts,
+       false);
 
                                // Local velocities
   fgTie("/velocities/speed-north", this,
-       &FGInterface::get_V_north);
+       &FGInterface::get_V_north); // read-only
   fgTie("/velocities/speed-east", this,
        &FGInterface::get_V_east,
-       &FGInterface::set_V_east);
+       &FGInterface::set_V_east,
+       false);
   fgTie("/velocities/speed-down", this,
        &FGInterface::get_V_down,
-       &FGInterface::set_V_down);
+       &FGInterface::set_V_down,
+       false);
 
                                // Relative wind
   fgTie("/velocities/uBody", this,
        &FGInterface::get_uBody,
-       &FGInterface::set_uBody);
+       &FGInterface::set_uBody,
+       false);
   fgTie("/velocities/vBody", this,
        &FGInterface::get_vBody,
-       &FGInterface::set_vBody);
+       &FGInterface::set_vBody,
+       false);
   fgTie("/velocities/wBody", this,
        &FGInterface::get_wBody,
-       &FGInterface::set_wBody);
+       &FGInterface::set_wBody,
+       false);
 
                                // Climb and slip (read-only)
   fgTie("/velocities/vertical-speed", this,
index 8f69cd5726b8ce899d1e9a55ec13b554bce74979..6f0823bc70cfabb7c92dc57a2a074dbdc7eb0e47 100644 (file)
@@ -1030,8 +1030,10 @@ static void fgMainLoop( void ) {
 #endif
 
     // see if we need to load any new scenery tiles
-    global_tile_mgr.update( cur_fdm_state->get_Longitude() * SGD_RADIANS_TO_DEGREES,
-                           cur_fdm_state->get_Latitude() * SGD_RADIANS_TO_DEGREES );
+    global_tile_mgr.update( cur_fdm_state->get_Longitude()
+                            * SGD_RADIANS_TO_DEGREES,
+                           cur_fdm_state->get_Latitude()
+                            * SGD_RADIANS_TO_DEGREES );
 
     // Process/manage pending events
     global_events.Process();