Sync. w. JSBSim CVS.
This commit is contained in:
parent
771fbd680a
commit
28eb9c81e9
8 changed files with 23 additions and 13 deletions
|
@ -982,12 +982,13 @@ void FGInitialCondition::bind(void){
|
|||
|
||||
//******************************************************************************
|
||||
|
||||
void FGInitialCondition::unbind(void){
|
||||
void FGInitialCondition::unbind(void)
|
||||
{
|
||||
PropertyManager->Untie("ic/vc-kts");
|
||||
PropertyManager->Untie("ic/ve-kts");
|
||||
PropertyManager->Untie("ic/vg-kts");
|
||||
PropertyManager->Untie("ic/vt-kts");
|
||||
PropertyManager->Untie("ic/mach-norm");
|
||||
PropertyManager->Untie("ic/mach");
|
||||
PropertyManager->Untie("ic/roc-fpm");
|
||||
PropertyManager->Untie("ic/gamma-deg");
|
||||
PropertyManager->Untie("ic/alpha-deg");
|
||||
|
@ -1010,13 +1011,13 @@ void FGInitialCondition::unbind(void){
|
|||
PropertyManager->Untie("ic/vw-east-fps");
|
||||
PropertyManager->Untie("ic/vw-down-fps");
|
||||
PropertyManager->Untie("ic/vw-mag-fps");
|
||||
/* PropertyManager->Untie("ic/vw-dir-deg"); */
|
||||
PropertyManager->Untie("ic/vw-dir-deg");
|
||||
|
||||
PropertyManager->Untie("ic/roc-fps");
|
||||
|
||||
/* PropertyManager->Untie("ic/u-fps");
|
||||
PropertyManager->Untie("ic/u-fps");
|
||||
PropertyManager->Untie("ic/v-fps");
|
||||
PropertyManager->Untie("ic/w-fps"); */
|
||||
PropertyManager->Untie("ic/w-fps");
|
||||
|
||||
PropertyManager->Untie("ic/gamma-rad");
|
||||
PropertyManager->Untie("ic/alpha-rad");
|
||||
|
|
|
@ -407,8 +407,13 @@ void Element::AddAttribute(string name, string value)
|
|||
|
||||
void Element::AddData(string d)
|
||||
{
|
||||
int string_start = d.find_first_not_of(" ");
|
||||
if (string_start > 0) d.erase(0,string_start-1);
|
||||
int string_end=-1;
|
||||
int string_start = d.find_first_not_of(" \t");
|
||||
if (string_start > 0) {
|
||||
d.erase(0,string_start);
|
||||
string_end = d.find_first_of(" \t");
|
||||
if (string_end > 0) d.erase(string_end,d.size()-string_end);
|
||||
}
|
||||
data_lines.push_back(d);
|
||||
}
|
||||
|
||||
|
|
|
@ -162,7 +162,7 @@ double FGFunction::GetValue(void) const
|
|||
temp = pow(temp,Parameters[1]->GetValue());
|
||||
break;
|
||||
case eAbs:
|
||||
temp = abs(temp);
|
||||
temp = fabs(temp);
|
||||
break;
|
||||
case eSin:
|
||||
temp = sin(temp);
|
||||
|
|
|
@ -156,6 +156,7 @@ FGTable::FGTable(FGPropertyManager* propMan, Element* el) : PropertyManager(prop
|
|||
|
||||
while (axisElement) {
|
||||
property_string = axisElement->GetDataLine();
|
||||
// The property string passed into GetNode() must have no spaces or tabs.
|
||||
node = PropertyManager->GetNode(property_string);
|
||||
|
||||
if (node == 0) {
|
||||
|
|
|
@ -169,6 +169,7 @@ FGLGear::FGLGear(Element* el, FGFDMExec* fdmex, int number) : Exec(fdmex),
|
|||
maxCompLen = 0.0;
|
||||
|
||||
WheelSlip = last_WheelSlip = 0.0;
|
||||
slipIn = last_SlipIn = 0;
|
||||
TirePressureNorm = 1.0;
|
||||
|
||||
Debug(0);
|
||||
|
|
|
@ -950,7 +950,7 @@ double MSIS::globe7(double *p, struct nrlmsise_input *input,
|
|||
/* parms not used: 82, 89, 99, 139-149 */
|
||||
tinf = p[30];
|
||||
for (i=0;i<14;i++)
|
||||
tinf = tinf + abs(flags->sw[i+1])*t[i];
|
||||
tinf = tinf + fabs(flags->sw[i+1])*t[i];
|
||||
return tinf;
|
||||
}
|
||||
|
||||
|
@ -1049,7 +1049,7 @@ double MSIS::glob7s(double *p, struct nrlmsise_input *input,
|
|||
}
|
||||
tt=0;
|
||||
for (i=0;i<14;i++)
|
||||
tt+=abs(flags->sw[i+1])*t[i];
|
||||
tt+=fabs(flags->sw[i+1])*t[i];
|
||||
return tt;
|
||||
}
|
||||
|
||||
|
|
|
@ -196,8 +196,8 @@ FGPiston::FGPiston(FGFDMExec* exec, Element* el, int engine_number)
|
|||
if (el->FindElement("ratedaltitude3"))
|
||||
RatedAltitude[2] = el->FindElementValueAsNumberConvertTo("ratedaltitude3", "FT");
|
||||
}
|
||||
minMAP = MinManifoldPressure_inHg * 3376.85; // inHg to Pa
|
||||
maxMAP = MaxManifoldPressure_inHg * 3376.85;
|
||||
minMAP = MinManifoldPressure_inHg * 3386.38; // inHg to Pa
|
||||
maxMAP = MaxManifoldPressure_inHg * 3386.38;
|
||||
|
||||
// Set up and sanity-check the turbo/supercharging configuration based on the input values.
|
||||
if (TakeoffBoost > RatedBoost[0]) bTakeoffBoost = true;
|
||||
|
@ -468,7 +468,7 @@ void FGPiston::doMAP(void)
|
|||
}
|
||||
|
||||
// And set the value in American units as well
|
||||
ManifoldPressure_inHg = MAP / 3376.85;
|
||||
ManifoldPressure_inHg = MAP / 3386.38;
|
||||
}
|
||||
|
||||
//%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
|
||||
|
|
|
@ -145,6 +145,8 @@ FGPropeller::~FGPropeller()
|
|||
PropertyManager->Untie( property_name );
|
||||
snprintf(property_name, 80, "propulsion/engine[%d]/blade-angle", EngineNum);
|
||||
PropertyManager->Untie( property_name );
|
||||
snprintf(property_name, 80, "propulsion/engine[%d]/thrust-coefficient", EngineNum);
|
||||
PropertyManager->Untie( property_name );
|
||||
|
||||
Debug(1);
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue