2 // Author: Phil Schubert
3 // Date started: 12/03/99
4 // Purpose: Models a Continental IO-520-M Engine
5 // Called by: FGSimExec
7 // Copyright (C) 1999 Philip L. Schubert (philings@ozemail.com.au)
9 // This program is free software; you can redistribute it and/or
10 // modify it under the terms of the GNU General Public License as
11 // published by the Free Software Foundation; either version 2 of the
12 // License, or (at your option) any later version.
14 // This program is distributed in the hope that it will be useful, but
15 // WITHOUT ANY WARRANTY; without even the implied warranty of
16 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
17 // General Public License for more details.
19 // You should have received a copy of the GNU General Public License
20 // along with this program; if not, write to the Free Software
21 // Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
24 // Further information about the GNU General Public License can also
25 // be found on the world wide web at http://www.gnu.org.
27 // FUNCTIONAL DESCRIPTION
28 // ------------------------------------------------------------------------
29 // Models a Continental IO-520-M engine. This engine is used in Cessna
30 // 210, 310, Beechcraft Bonaza and Baron C55. The equations used below
31 // were determined by a first and second order curve fits using Excel.
32 // The data is from the Cessna Aircraft Corporations Engine and Flight
33 // Computer for C310. Part Number D3500-13
36 // ------------------------------------------------------------------------
40 // ------------------------------------------------------------------------
41 // 12/03/99 PLS Created
42 // 07/03/99 PLS Added Calculation of Density, and Prop_Torque
43 // 07/03/99 PLS Restructered Variables to allow easier implementation
45 // 15/03/99 PLS Added Oil Pressure, Oil Temperature and CH Temp
46 // ------------------------------------------------------------------------
48 // ------------------------------------------------------------------------
62 // Control and environment inputs
64 // 0 = Closed, 100 = Fully Open
65 float Throttle_Lever_Pos;
66 // 0 = Full Course 100 = Full Fine
67 float Propeller_Lever_Pos;
68 // 0 = Idle Cut Off 100 = Full Rich
69 float Mixture_Lever_Pos;
71 // Engine Specific Variables used by this program that have limits.
72 // Will be set in a parameter file to be read in to create
73 // and instance for each engine.
74 float Max_Manifold_Pressure;
78 float Mag_Derate_Percent;
82 // Initialise Engine Variables used by this instance
83 float Percentage_Power;
84 float Manifold_Pressure; // Inches
86 float Fuel_Flow; // lbs/hour
90 float Oil_Pressure; // PSI
91 float Oil_Temp; // Deg C
94 float Torque_Imbalance;
97 // Initialise Propellor Variables used by this instance
98 float FGProp1_Angular_V;
99 float FGProp1_Coef_Drag;
100 float FGProp1_Torque;
101 float FGProp1_Thrust;
103 float FGProp1_Coef_Lift;
105 float FGProp1_Blade_Angle;
106 float FGProp_Fine_Pitch_Stop;
107 float FGProp_Course_Pitch_Stop;
109 // Other internal values
112 // Calculate Engine RPM based on Propellor Lever Position
113 float Calc_Engine_RPM (float Position);
117 // set initial default values
120 // update the engine model based on current control positions
123 inline void set_IAS( float value ) { IAS = value; }
124 inline void set_Throttle_Lever_Pos( float value ) {
125 Throttle_Lever_Pos = value;
127 inline void set_Propeller_Lever_Pos( float value ) {
128 Propeller_Lever_Pos = value;
130 inline void set_Mixture_Lever_Pos( float value ) {
131 Mixture_Lever_Pos = value;
135 inline float get_RPM() const { return RPM; }
136 inline float get_FGProp1_Thrust() const { return FGProp1_Thrust; }
138 inline float get_Rho() const { return Rho; }
142 #endif // _10520D_HXX_