diff --git a/FlightGear.dsp b/FlightGear.dsp index 81baa8875..c4678a5c0 100644 --- a/FlightGear.dsp +++ b/FlightGear.dsp @@ -934,6 +934,36 @@ SOURCE=.\src\FDM\JSBSim\FGFDMExec.h # End Source File # Begin Source File +SOURCE=.\src\FDM\JSBSim\FGForce.cpp + +!IF "$(CFG)" == "FlightGear - Win32 Release" + +# PROP Intermediate_Dir "Release\Lib_JSBSim" + +!ELSEIF "$(CFG)" == "FlightGear - Win32 Debug" + +# PROP Intermediate_Dir "Debug\Lib_JSBSim" + +!ENDIF + +# End Source File +# Begin Source File + +SOURCE=.\src\FDM\JSBSim\FGForce.h + +!IF "$(CFG)" == "FlightGear - Win32 Release" + +# PROP Intermediate_Dir "Release\Lib_JSBSim" + +!ELSEIF "$(CFG)" == "FlightGear - Win32 Debug" + +# PROP Intermediate_Dir "Debug\Lib_JSBSim" + +!ENDIF + +# End Source File +# Begin Source File + SOURCE=.\src\FDM\JSBSim\FGInitialCondition.cpp !IF "$(CFG)" == "FlightGear - Win32 Release" @@ -1054,6 +1084,36 @@ SOURCE=.\src\FDM\JSBSim\FGModel.h # End Source File # Begin Source File +SOURCE=.\src\FDM\JSBSim\FGNozzle.cpp + +!IF "$(CFG)" == "FlightGear - Win32 Release" + +# PROP Intermediate_Dir "Release\Lib_JSBSim" + +!ELSEIF "$(CFG)" == "FlightGear - Win32 Debug" + +# PROP Intermediate_Dir "Debug\Lib_JSBSim" + +!ENDIF + +# End Source File +# Begin Source File + +SOURCE=.\src\FDM\JSBSim\FGNozzle.h + +!IF "$(CFG)" == "FlightGear - Win32 Release" + +# PROP Intermediate_Dir "Release\Lib_JSBSim" + +!ELSEIF "$(CFG)" == "FlightGear - Win32 Debug" + +# PROP Intermediate_Dir "Debug\Lib_JSBSim" + +!ENDIF + +# End Source File +# Begin Source File + SOURCE=.\src\FDM\JSBSim\FGOutput.cpp !IF "$(CFG)" == "FlightGear - Win32 Release" @@ -1084,6 +1144,96 @@ SOURCE=.\src\FDM\JSBSim\FGOutput.h # End Source File # Begin Source File +SOURCE=.\src\FDM\JSBSim\FGPiston.cpp + +!IF "$(CFG)" == "FlightGear - Win32 Release" + +# PROP Intermediate_Dir "Release\Lib_JSBSim" + +!ELSEIF "$(CFG)" == "FlightGear - Win32 Debug" + +# PROP Intermediate_Dir "Debug\Lib_JSBSim" + +!ENDIF + +# End Source File +# Begin Source File + +SOURCE=.\src\FDM\JSBSim\FGPiston.h + +!IF "$(CFG)" == "FlightGear - Win32 Release" + +# PROP Intermediate_Dir "Release\Lib_JSBSim" + +!ELSEIF "$(CFG)" == "FlightGear - Win32 Debug" + +# PROP Intermediate_Dir "Debug\Lib_JSBSim" + +!ENDIF + +# End Source File +# Begin Source File + +SOURCE=.\src\FDM\JSBSim\FGPropeller.cpp + +!IF "$(CFG)" == "FlightGear - Win32 Release" + +# PROP Intermediate_Dir "Release\Lib_JSBSim" + +!ELSEIF "$(CFG)" == "FlightGear - Win32 Debug" + +# PROP Intermediate_Dir "Debug\Lib_JSBSim" + +!ENDIF + +# End Source File +# Begin Source File + +SOURCE=.\src\FDM\JSBSim\FGPropeller.h + +!IF "$(CFG)" == "FlightGear - Win32 Release" + +# PROP Intermediate_Dir "Release\Lib_JSBSim" + +!ELSEIF "$(CFG)" == "FlightGear - Win32 Debug" + +# PROP Intermediate_Dir "Debug\Lib_JSBSim" + +!ENDIF + +# End Source File +# Begin Source File + +SOURCE=.\src\FDM\JSBSim\FGPropulsion.cpp + +!IF "$(CFG)" == "FlightGear - Win32 Release" + +# PROP Intermediate_Dir "Release\Lib_JSBSim" + +!ELSEIF "$(CFG)" == "FlightGear - Win32 Debug" + +# PROP Intermediate_Dir "Debug\Lib_JSBSim" + +!ENDIF + +# End Source File +# Begin Source File + +SOURCE=.\src\FDM\JSBSim\FGPropulsion.h + +!IF "$(CFG)" == "FlightGear - Win32 Release" + +# PROP Intermediate_Dir "Release\Lib_JSBSim" + +!ELSEIF "$(CFG)" == "FlightGear - Win32 Debug" + +# PROP Intermediate_Dir "Debug\Lib_JSBSim" + +!ENDIF + +# End Source File +# Begin Source File + SOURCE=.\src\FDM\JSBSim\FGPosition.cpp !IF "$(CFG)" == "FlightGear - Win32 Release" @@ -1144,6 +1294,36 @@ SOURCE=.\src\FDM\JSBSim\FGRotation.h # End Source File # Begin Source File +SOURCE=.\src\FDM\JSBSim\FGRocket.cpp + +!IF "$(CFG)" == "FlightGear - Win32 Release" + +# PROP Intermediate_Dir "Release\Lib_JSBSim" + +!ELSEIF "$(CFG)" == "FlightGear - Win32 Debug" + +# PROP Intermediate_Dir "Debug\Lib_JSBSim" + +!ENDIF + +# End Source File +# Begin Source File + +SOURCE=.\src\FDM\JSBSim\FGRocket.h + +!IF "$(CFG)" == "FlightGear - Win32 Release" + +# PROP Intermediate_Dir "Release\Lib_JSBSim" + +!ELSEIF "$(CFG)" == "FlightGear - Win32 Debug" + +# PROP Intermediate_Dir "Debug\Lib_JSBSim" + +!ENDIF + +# End Source File +# Begin Source File + SOURCE=.\src\FDM\JSBSim\FGState.cpp !IF "$(CFG)" == "FlightGear - Win32 Release" @@ -1174,6 +1354,66 @@ SOURCE=.\src\FDM\JSBSim\FGState.h # End Source File # Begin Source File +SOURCE=.\src\FDM\JSBSim\FGTable.cpp + +!IF "$(CFG)" == "FlightGear - Win32 Release" + +# PROP Intermediate_Dir "Release\Lib_JSBSim" + +!ELSEIF "$(CFG)" == "FlightGear - Win32 Debug" + +# PROP Intermediate_Dir "Debug\Lib_JSBSim" + +!ENDIF + +# End Source File +# Begin Source File + +SOURCE=.\src\FDM\JSBSim\FGTable.h + +!IF "$(CFG)" == "FlightGear - Win32 Release" + +# PROP Intermediate_Dir "Release\Lib_JSBSim" + +!ELSEIF "$(CFG)" == "FlightGear - Win32 Debug" + +# PROP Intermediate_Dir "Debug\Lib_JSBSim" + +!ENDIF + +# End Source File +# Begin Source File + +SOURCE=.\src\FDM\JSBSim\FGThruster.cpp + +!IF "$(CFG)" == "FlightGear - Win32 Release" + +# PROP Intermediate_Dir "Release\Lib_JSBSim" + +!ELSEIF "$(CFG)" == "FlightGear - Win32 Debug" + +# PROP Intermediate_Dir "Debug\Lib_JSBSim" + +!ENDIF + +# End Source File +# Begin Source File + +SOURCE=.\src\FDM\JSBSim\FGThruster.h + +!IF "$(CFG)" == "FlightGear - Win32 Release" + +# PROP Intermediate_Dir "Release\Lib_JSBSim" + +!ELSEIF "$(CFG)" == "FlightGear - Win32 Debug" + +# PROP Intermediate_Dir "Debug\Lib_JSBSim" + +!ENDIF + +# End Source File +# Begin Source File + SOURCE=.\src\FDM\JSBSim\FGTranslation.cpp !IF "$(CFG)" == "FlightGear - Win32 Release" @@ -1264,6 +1504,96 @@ SOURCE=.\src\FDM\JSBSim\FGTrimAxis.h # End Source File # Begin Source File +SOURCE=.\src\FDM\JSBSim\FGTurboJet.cpp + +!IF "$(CFG)" == "FlightGear - Win32 Release" + +# PROP Intermediate_Dir "Release\Lib_JSBSim" + +!ELSEIF "$(CFG)" == "FlightGear - Win32 Debug" + +# PROP Intermediate_Dir "Debug\Lib_JSBSim" + +!ENDIF + +# End Source File +# Begin Source File + +SOURCE=.\src\FDM\JSBSim\FGTurboJet.h + +!IF "$(CFG)" == "FlightGear - Win32 Release" + +# PROP Intermediate_Dir "Release\Lib_JSBSim" + +!ELSEIF "$(CFG)" == "FlightGear - Win32 Debug" + +# PROP Intermediate_Dir "Debug\Lib_JSBSim" + +!ENDIF + +# End Source File +# Begin Source File + +SOURCE=.\src\FDM\JSBSim\FGTurboProp.cpp + +!IF "$(CFG)" == "FlightGear - Win32 Release" + +# PROP Intermediate_Dir "Release\Lib_JSBSim" + +!ELSEIF "$(CFG)" == "FlightGear - Win32 Debug" + +# PROP Intermediate_Dir "Debug\Lib_JSBSim" + +!ENDIF + +# End Source File +# Begin Source File + +SOURCE=.\src\FDM\JSBSim\FGTurboProp.h + +!IF "$(CFG)" == "FlightGear - Win32 Release" + +# PROP Intermediate_Dir "Release\Lib_JSBSim" + +!ELSEIF "$(CFG)" == "FlightGear - Win32 Debug" + +# PROP Intermediate_Dir "Debug\Lib_JSBSim" + +!ENDIF + +# End Source File +# Begin Source File + +SOURCE=.\src\FDM\JSBSim\FGTurboShaft.cpp + +!IF "$(CFG)" == "FlightGear - Win32 Release" + +# PROP Intermediate_Dir "Release\Lib_JSBSim" + +!ELSEIF "$(CFG)" == "FlightGear - Win32 Debug" + +# PROP Intermediate_Dir "Debug\Lib_JSBSim" + +!ENDIF + +# End Source File +# Begin Source File + +SOURCE=.\src\FDM\JSBSim\FGTurboShaft.h + +!IF "$(CFG)" == "FlightGear - Win32 Release" + +# PROP Intermediate_Dir "Release\Lib_JSBSim" + +!ELSEIF "$(CFG)" == "FlightGear - Win32 Debug" + +# PROP Intermediate_Dir "Debug\Lib_JSBSim" + +!ENDIF + +# End Source File +# Begin Source File + SOURCE=.\src\FDM\JSBSim\FGUtility.cpp !IF "$(CFG)" == "FlightGear - Win32 Release" @@ -2791,6 +3121,36 @@ SOURCE=.\src\FDM\UIUCModel\uiuc_engine.h # End Source File # Begin Source File +SOURCE=.\src\FDM\UIUCModel\uiuc_gear.cpp + +!IF "$(CFG)" == "FlightGear - Win32 Release" + +# PROP Intermediate_Dir "Release\Lib_UIUCModel" + +!ELSEIF "$(CFG)" == "FlightGear - Win32 Debug" + +# PROP Intermediate_Dir "Debug\Lib_UIUCModel" + +!ENDIF + +# End Source File +# Begin Source File + +SOURCE=.\src\FDM\UIUCModel\uiuc_gear.h + +!IF "$(CFG)" == "FlightGear - Win32 Release" + +# PROP Intermediate_Dir "Release\Lib_UIUCModel" + +!ELSEIF "$(CFG)" == "FlightGear - Win32 Debug" + +# PROP Intermediate_Dir "Debug\Lib_UIUCModel" + +!ENDIF + +# End Source File +# Begin Source File + SOURCE=.\src\FDM\UIUCModel\uiuc_ice.cpp !IF "$(CFG)" == "FlightGear - Win32 Release" @@ -3151,6 +3511,36 @@ SOURCE=.\src\FDM\UIUCModel\uiuc_map_ice.h # End Source File # Begin Source File +SOURCE=.\src\FDM\UIUCModel\uiuc_map_gear.cpp + +!IF "$(CFG)" == "FlightGear - Win32 Release" + +# PROP Intermediate_Dir "Release\Lib_UIUCModel" + +!ELSEIF "$(CFG)" == "FlightGear - Win32 Debug" + +# PROP Intermediate_Dir "Debug\Lib_UIUCModel" + +!ENDIF + +# End Source File +# Begin Source File + +SOURCE=.\src\FDM\UIUCModel\uiuc_map_gear.h + +!IF "$(CFG)" == "FlightGear - Win32 Release" + +# PROP Intermediate_Dir "Release\Lib_UIUCModel" + +!ELSEIF "$(CFG)" == "FlightGear - Win32 Debug" + +# PROP Intermediate_Dir "Debug\Lib_UIUCModel" + +!ENDIF + +# End Source File +# Begin Source File + SOURCE=.\src\FDM\UIUCModel\uiuc_map_init.cpp !IF "$(CFG)" == "FlightGear - Win32 Release" diff --git a/src/FDM/flight.cxx b/src/FDM/flight.cxx index 3d98c9c15..7d7f97233 100644 --- a/src/FDM/flight.cxx +++ b/src/FDM/flight.cxx @@ -74,6 +74,25 @@ FGEngInterface::~FGEngInterface(void) { // Constructor FGInterface::FGInterface() { + init(); +} + +FGInterface::FGInterface( double dt ) { + + init(); + delta_t = dt; + remainder = elapsed = multi_loop = 0; +} + +// Destructor +FGInterface::~FGInterface() { +// unbind(); // FIXME: should be called explicitly +} + + +void +FGInterface::init () +{ init_vec( d_pilot_rp_body_v ); init_vec( d_cg_rp_body_v ); init_vec( f_body_total_v ); @@ -139,24 +158,6 @@ FGInterface::FGInterface() { sin_latitude=cos_latitude=0; sin_longitude=cos_longitude=0; altitude_agl=0; -} - -FGInterface::FGInterface( double dt ) { - FGInterface(); - - delta_t = dt; - remainder = elapsed = multi_loop = 0; -} - -// Destructor -FGInterface::~FGInterface() { -// unbind(); // FIXME: should be called explicitly -} - - -void -FGInterface::init () -{ } void @@ -206,7 +207,7 @@ FGInterface::bind () fgTie("/velocities/airspeed", this, &FGInterface::get_V_calibrated_kts, &FGInterface::set_V_calibrated_kts, - false); + true); // Local velocities fgTie("/velocities/speed-north", this, @@ -214,25 +215,25 @@ FGInterface::bind () fgTie("/velocities/speed-east", this, &FGInterface::get_V_east, &FGInterface::set_V_east, - false); + true); fgTie("/velocities/speed-down", this, &FGInterface::get_V_down, &FGInterface::set_V_down, - false); + true); // Relative wind fgTie("/velocities/uBody", this, &FGInterface::get_uBody, &FGInterface::set_uBody, - false); + true); fgTie("/velocities/vBody", this, &FGInterface::get_vBody, &FGInterface::set_vBody, - false); + true); fgTie("/velocities/wBody", this, &FGInterface::get_wBody, &FGInterface::set_wBody, - false); + true); // Climb and slip (read-only) fgTie("/velocities/vertical-speed", this,