Fixes compiler warning related to this gcc message: This file includes at least one deprecated or antiquated header.
This commit is contained in:
parent
2606555bf6
commit
6ae39d57fa
26 changed files with 460 additions and 270 deletions
|
@ -18,10 +18,16 @@
|
||||||
----------------------------------------------------------------------
|
----------------------------------------------------------------------
|
||||||
|
|
||||||
HISTORY: 02/15/2000 initial release
|
HISTORY: 02/15/2000 initial release
|
||||||
|
09/01/2002 (RD) added second data file reader for
|
||||||
|
integer case
|
||||||
|
06/30/2003 (RD) replaced istrstream with istringstream
|
||||||
|
to get rid of the annoying warning about
|
||||||
|
using the strstream header
|
||||||
|
|
||||||
----------------------------------------------------------------------
|
----------------------------------------------------------------------
|
||||||
|
|
||||||
AUTHOR(S): Jeff Scott <jscott@mail.com>
|
AUTHOR(S): Jeff Scott <jscott@mail.com>
|
||||||
|
Robert Deters <rdeters@uiuc.edu>
|
||||||
|
|
||||||
----------------------------------------------------------------------
|
----------------------------------------------------------------------
|
||||||
|
|
||||||
|
@ -92,8 +98,8 @@ uiuc_1DdataFileReader( string file_name,
|
||||||
linetoken1 = matrix -> getToken(*command_line, 1); // gettoken(string,tokenNo);
|
linetoken1 = matrix -> getToken(*command_line, 1); // gettoken(string,tokenNo);
|
||||||
linetoken2 = matrix -> getToken(*command_line, 2); // 2 represents token No 2
|
linetoken2 = matrix -> getToken(*command_line, 2); // 2 represents token No 2
|
||||||
|
|
||||||
istrstream token1(linetoken1.c_str());
|
istringstream token1(linetoken1.c_str());
|
||||||
istrstream token2(linetoken2.c_str());
|
istringstream token2(linetoken2.c_str());
|
||||||
|
|
||||||
token1 >> token_value1;
|
token1 >> token_value1;
|
||||||
token2 >> token_value2;
|
token2 >> token_value2;
|
||||||
|
@ -136,8 +142,8 @@ uiuc_1DdataFileReader( string file_name,
|
||||||
linetoken1 = matrix -> getToken(*command_line, 1); // gettoken(string,tokenNo);
|
linetoken1 = matrix -> getToken(*command_line, 1); // gettoken(string,tokenNo);
|
||||||
linetoken2 = matrix -> getToken(*command_line, 2); // 2 represents token No 2
|
linetoken2 = matrix -> getToken(*command_line, 2); // 2 represents token No 2
|
||||||
|
|
||||||
istrstream token1(linetoken1.c_str());
|
istringstream token1(linetoken1.c_str());
|
||||||
istrstream token2(linetoken2.c_str());
|
istringstream token2(linetoken2.c_str());
|
||||||
|
|
||||||
token1 >> token_value1;
|
token1 >> token_value1;
|
||||||
token2 >> token_value2;
|
token2 >> token_value2;
|
||||||
|
|
|
@ -3,13 +3,14 @@
|
||||||
|
|
||||||
#include <simgear/compiler.h>
|
#include <simgear/compiler.h>
|
||||||
|
|
||||||
#include STL_STRSTREAM
|
//#include STL_STRSTREAM
|
||||||
|
#include <sstream>
|
||||||
|
|
||||||
#include "uiuc_parsefile.h"
|
#include "uiuc_parsefile.h"
|
||||||
#include "uiuc_aircraft.h"
|
#include "uiuc_aircraft.h"
|
||||||
#include "uiuc_warnings_errors.h"
|
#include "uiuc_warnings_errors.h"
|
||||||
|
|
||||||
SG_USING_STD(istrstream);
|
//SG_USING_STD(istrstream);
|
||||||
|
|
||||||
int uiuc_1DdataFileReader( string file_name,
|
int uiuc_1DdataFileReader( string file_name,
|
||||||
double x[],
|
double x[],
|
||||||
|
|
|
@ -23,10 +23,13 @@
|
||||||
----------------------------------------------------------------------
|
----------------------------------------------------------------------
|
||||||
|
|
||||||
HISTORY: 02/03/2000 initial release
|
HISTORY: 02/03/2000 initial release
|
||||||
|
09/01/2002 (RD) added second interpolation routine
|
||||||
|
for integer case
|
||||||
|
|
||||||
----------------------------------------------------------------------
|
----------------------------------------------------------------------
|
||||||
|
|
||||||
AUTHOR(S): Jeff Scott <jscott@mail.com>
|
AUTHOR(S): Jeff Scott <jscott@mail.com>
|
||||||
|
Robert Deters <rdeters@uiuc.edu>
|
||||||
|
|
||||||
----------------------------------------------------------------------
|
----------------------------------------------------------------------
|
||||||
|
|
||||||
|
|
|
@ -20,6 +20,9 @@
|
||||||
HISTORY: 02/29/2000 initial release
|
HISTORY: 02/29/2000 initial release
|
||||||
10/25/2001 (RD) Modified so that it recognizes a
|
10/25/2001 (RD) Modified so that it recognizes a
|
||||||
blank line
|
blank line
|
||||||
|
06/30/2003 (RD) replaced istrstream with istringstream
|
||||||
|
to get rid of the annoying warning about
|
||||||
|
using the strstream header
|
||||||
|
|
||||||
----------------------------------------------------------------------
|
----------------------------------------------------------------------
|
||||||
|
|
||||||
|
@ -101,8 +104,8 @@ void uiuc_2DdataFileReader( string file_name,
|
||||||
linetoken1 = matrix -> getToken(*command_line, 1); // gettoken(string,tokenNo);
|
linetoken1 = matrix -> getToken(*command_line, 1); // gettoken(string,tokenNo);
|
||||||
linetoken2 = matrix -> getToken(*command_line, 2); // 2 represents token No 2
|
linetoken2 = matrix -> getToken(*command_line, 2); // 2 represents token No 2
|
||||||
|
|
||||||
istrstream token1(linetoken1.c_str());
|
istringstream token1(linetoken1.c_str());
|
||||||
istrstream token2(linetoken2.c_str());
|
istringstream token2(linetoken2.c_str());
|
||||||
|
|
||||||
//reset token_value1 and token_value2 for first if statement
|
//reset token_value1 and token_value2 for first if statement
|
||||||
token_value1 = -999;
|
token_value1 = -999;
|
||||||
|
|
|
@ -3,12 +3,13 @@
|
||||||
|
|
||||||
#include <simgear/compiler.h>
|
#include <simgear/compiler.h>
|
||||||
|
|
||||||
#include STL_STRSTREAM
|
//#include STL_STRSTREAM
|
||||||
|
#include <sstream>
|
||||||
|
|
||||||
#include "uiuc_parsefile.h"
|
#include "uiuc_parsefile.h"
|
||||||
#include "uiuc_aircraft.h"
|
#include "uiuc_aircraft.h"
|
||||||
|
|
||||||
SG_USING_STD(istrstream);
|
//SG_USING_STD(istrstream);
|
||||||
|
|
||||||
void uiuc_2DdataFileReader( string file_name,
|
void uiuc_2DdataFileReader( string file_name,
|
||||||
double x[100][100],
|
double x[100][100],
|
||||||
|
|
|
@ -143,6 +143,12 @@ void uiuc_coef_roll()
|
||||||
/* Cl_p must be mulitplied by b/2U
|
/* Cl_p must be mulitplied by b/2U
|
||||||
(see Roskam Control book, Part 1, pg. 147) */
|
(see Roskam Control book, Part 1, pg. 147) */
|
||||||
Cl_p_save = Cl_p * P_body * b_2U;
|
Cl_p_save = Cl_p * P_body * b_2U;
|
||||||
|
// if (Cl_p_save > 0.1) {
|
||||||
|
// Cl_p_save = 0.1;
|
||||||
|
// }
|
||||||
|
// if (Cl_p_save < -0.1) {
|
||||||
|
// Cl_p_save = -0.1;
|
||||||
|
// }
|
||||||
if (eta_q_Cl_p_fac)
|
if (eta_q_Cl_p_fac)
|
||||||
{
|
{
|
||||||
Cl += Cl_p_save * eta_q_Cl_p_fac;
|
Cl += Cl_p_save * eta_q_Cl_p_fac;
|
||||||
|
|
|
@ -122,6 +122,11 @@ void uiuc_engine()
|
||||||
case simpleSingle_flag:
|
case simpleSingle_flag:
|
||||||
{
|
{
|
||||||
F_X_engine = Throttle[3] * simpleSingleMaxThrust;
|
F_X_engine = Throttle[3] * simpleSingleMaxThrust;
|
||||||
|
F_Y_engine = 0.0;
|
||||||
|
F_Z_engine = 0.0;
|
||||||
|
M_l_engine = 0.0;
|
||||||
|
M_m_engine = 0.0;
|
||||||
|
M_n_engine = 0.0;
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
case simpleSingleModel_flag:
|
case simpleSingleModel_flag:
|
||||||
|
@ -129,6 +134,11 @@ void uiuc_engine()
|
||||||
/* simple model based on Hepperle's equation
|
/* simple model based on Hepperle's equation
|
||||||
* exponent dtdvvt was computed in uiuc_menu.cpp */
|
* exponent dtdvvt was computed in uiuc_menu.cpp */
|
||||||
F_X_engine = Throttle[3] * t_v0 * (1 - pow((V_rel_wind/v_t0),dtdvvt));
|
F_X_engine = Throttle[3] * t_v0 * (1 - pow((V_rel_wind/v_t0),dtdvvt));
|
||||||
|
F_Y_engine = 0.0;
|
||||||
|
F_Z_engine = 0.0;
|
||||||
|
M_l_engine = 0.0;
|
||||||
|
M_m_engine = 0.0;
|
||||||
|
M_n_engine = 0.0;
|
||||||
if (b_slipstreamEffects) {
|
if (b_slipstreamEffects) {
|
||||||
tc = F_X_engine/(Dynamic_pressure * LS_PI * propDia * propDia / 4);
|
tc = F_X_engine/(Dynamic_pressure * LS_PI * propDia * propDia / 4);
|
||||||
w_induced = 0.5 * V_rel_wind * (-1 + pow((1+tc),.5));
|
w_induced = 0.5 * V_rel_wind * (-1 + pow((1+tc),.5));
|
||||||
|
|
|
@ -63,9 +63,14 @@
|
||||||
**********************************************************************/
|
**********************************************************************/
|
||||||
|
|
||||||
#include <simgear/compiler.h>
|
#include <simgear/compiler.h>
|
||||||
|
#include <simgear/misc/sg_path.hxx>
|
||||||
|
#include <Aircraft/aircraft.hxx>
|
||||||
|
#include <Main/fg_props.hxx>
|
||||||
|
|
||||||
#include "uiuc_gear.h"
|
#include "uiuc_gear.h"
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
SG_USING_STD(cerr);
|
SG_USING_STD(cerr);
|
||||||
|
|
||||||
|
|
||||||
|
@ -220,20 +225,19 @@ void uiuc_gear()
|
||||||
{
|
{
|
||||||
// Execute only if the gear has been defined
|
// Execute only if the gear has been defined
|
||||||
if (!gear_model[i])
|
if (!gear_model[i])
|
||||||
|
{
|
||||||
|
// do nothing
|
||||||
continue;
|
continue;
|
||||||
|
}
|
||||||
/* printf("%s:\n",gear_strings[i]); */
|
else
|
||||||
|
{
|
||||||
|
|
||||||
|
|
||||||
/*========================================*/
|
/*========================================*/
|
||||||
/* Calculate wheel position w.r.t. runway */
|
/* Calculate wheel position w.r.t. runway */
|
||||||
/*========================================*/
|
/*========================================*/
|
||||||
|
|
||||||
|
|
||||||
/* printf("\thgcg: %g, theta: %g,phi: %g\n",D_cg_above_rwy,Theta*RAD_TO_DEG,Phi*RAD_TO_DEG); */
|
/* printf("\thgcg: %g, theta: %g,phi: %g\n",D_cg_above_rwy,Theta*RAD_TO_DEG,Phi*RAD_TO_DEG); */
|
||||||
|
|
||||||
|
|
||||||
/* First calculate wheel location w.r.t. cg in body (X-Y-Z) axes... */
|
/* First calculate wheel location w.r.t. cg in body (X-Y-Z) axes... */
|
||||||
|
|
||||||
sub3( D_gear_v[i], D_cg_rp_body_v, d_wheel_cg_body_v );
|
sub3( D_gear_v[i], D_cg_rp_body_v, d_wheel_cg_body_v );
|
||||||
|
@ -273,10 +277,33 @@ void uiuc_gear()
|
||||||
|
|
||||||
clear3(f_wheel_local_v);
|
clear3(f_wheel_local_v);
|
||||||
reaction_normal_force=0;
|
reaction_normal_force=0;
|
||||||
|
static const SGPropertyNode * gear_wow
|
||||||
|
= fgGetNode("/gear/gear[0]/wow", false);
|
||||||
|
static const SGPropertyNode * gear_wow1
|
||||||
|
= fgGetNode("/gear/gear[1]/wow", false);
|
||||||
|
static const SGPropertyNode * gear_wow2
|
||||||
|
= fgGetNode("/gear/gear[2]/wow", false);
|
||||||
|
fgSetBool("/gear/gear[0]/wow", false);
|
||||||
|
fgSetBool("/gear/gear[1]/wow", false);
|
||||||
|
fgSetBool("/gear/gear[2]/wow", false);
|
||||||
if( HEIGHT_AGL_WHEEL < 0. )
|
if( HEIGHT_AGL_WHEEL < 0. )
|
||||||
/*the wheel is underground -- which implies ground contact
|
/*the wheel is underground -- which implies ground contact
|
||||||
so calculate reaction forces */
|
so calculate reaction forces */
|
||||||
{
|
{
|
||||||
|
//set the property - weight on wheels
|
||||||
|
// if (i==0)
|
||||||
|
// {
|
||||||
|
// fgSetBool("/gear/gear[0]/wow", true);
|
||||||
|
// }
|
||||||
|
// if (i==1)
|
||||||
|
// {
|
||||||
|
// fgSetBool("/gear/gear[1]/wow", true);
|
||||||
|
// }
|
||||||
|
// if (i==2)
|
||||||
|
// {
|
||||||
|
// fgSetBool("/gear/gear[2]/wow", true);
|
||||||
|
// }
|
||||||
|
|
||||||
/*===========================================*/
|
/*===========================================*/
|
||||||
/* Calculate forces & moments for this wheel */
|
/* Calculate forces & moments for this wheel */
|
||||||
/*===========================================*/
|
/*===========================================*/
|
||||||
|
@ -350,11 +377,14 @@ void uiuc_gear()
|
||||||
cross3( d_wheel_cg_body_v, tempF, tempM );
|
cross3( d_wheel_cg_body_v, tempF, tempM );
|
||||||
|
|
||||||
/* Sum forces and moments across all wheels */
|
/* Sum forces and moments across all wheels */
|
||||||
|
if (tempF) {
|
||||||
|
fgSetBool("/gear/gear[1]/wow", true);
|
||||||
|
}
|
||||||
|
|
||||||
add3( tempF, F_gear_v, F_gear_v );
|
add3( tempF, F_gear_v, F_gear_v );
|
||||||
add3( tempM, M_gear_v, M_gear_v );
|
add3( tempM, M_gear_v, M_gear_v );
|
||||||
|
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -18,6 +18,9 @@
|
||||||
----------------------------------------------------------------------
|
----------------------------------------------------------------------
|
||||||
|
|
||||||
HISTORY: 04/04/2003 initial release
|
HISTORY: 04/04/2003 initial release
|
||||||
|
06/30/2003 (RD) replaced istrstream with istringstream
|
||||||
|
to get rid of the annoying warning about
|
||||||
|
using the strstream header
|
||||||
|
|
||||||
----------------------------------------------------------------------
|
----------------------------------------------------------------------
|
||||||
|
|
||||||
|
@ -103,14 +106,14 @@ void parse_CD( const string& linetoken2, const string& linetoken3,
|
||||||
double datafile_zArray[100][100];
|
double datafile_zArray[100][100];
|
||||||
double convert_f;
|
double convert_f;
|
||||||
int datafile_nxArray[100], datafile_ny;
|
int datafile_nxArray[100], datafile_ny;
|
||||||
istrstream token3(linetoken3.c_str());
|
istringstream token3(linetoken3.c_str());
|
||||||
istrstream token4(linetoken4.c_str());
|
istringstream token4(linetoken4.c_str());
|
||||||
istrstream token5(linetoken5.c_str());
|
istringstream token5(linetoken5.c_str());
|
||||||
istrstream token6(linetoken6.c_str());
|
istringstream token6(linetoken6.c_str());
|
||||||
istrstream token7(linetoken7.c_str());
|
istringstream token7(linetoken7.c_str());
|
||||||
istrstream token8(linetoken8.c_str());
|
istringstream token8(linetoken8.c_str());
|
||||||
istrstream token9(linetoken9.c_str());
|
istringstream token9(linetoken9.c_str());
|
||||||
istrstream token10(linetoken10.c_str());
|
istringstream token10(linetoken10.c_str());
|
||||||
|
|
||||||
static bool CXfabetaf_first = true;
|
static bool CXfabetaf_first = true;
|
||||||
static bool CXfadef_first = true;
|
static bool CXfadef_first = true;
|
||||||
|
|
|
@ -18,6 +18,9 @@
|
||||||
----------------------------------------------------------------------
|
----------------------------------------------------------------------
|
||||||
|
|
||||||
HISTORY: 04/04/2003 initial release
|
HISTORY: 04/04/2003 initial release
|
||||||
|
06/30/2003 (RD) replaced istrstream with istringstream
|
||||||
|
to get rid of the annoying warning about
|
||||||
|
using the strstream header
|
||||||
|
|
||||||
----------------------------------------------------------------------
|
----------------------------------------------------------------------
|
||||||
|
|
||||||
|
@ -103,14 +106,14 @@ void parse_CL( const string& linetoken2, const string& linetoken3,
|
||||||
double datafile_zArray[100][100];
|
double datafile_zArray[100][100];
|
||||||
double convert_f;
|
double convert_f;
|
||||||
int datafile_nxArray[100], datafile_ny;
|
int datafile_nxArray[100], datafile_ny;
|
||||||
istrstream token3(linetoken3.c_str());
|
istringstream token3(linetoken3.c_str());
|
||||||
istrstream token4(linetoken4.c_str());
|
istringstream token4(linetoken4.c_str());
|
||||||
istrstream token5(linetoken5.c_str());
|
istringstream token5(linetoken5.c_str());
|
||||||
istrstream token6(linetoken6.c_str());
|
istringstream token6(linetoken6.c_str());
|
||||||
istrstream token7(linetoken7.c_str());
|
istringstream token7(linetoken7.c_str());
|
||||||
istrstream token8(linetoken8.c_str());
|
istringstream token8(linetoken8.c_str());
|
||||||
istrstream token9(linetoken9.c_str());
|
istringstream token9(linetoken9.c_str());
|
||||||
istrstream token10(linetoken10.c_str());
|
istringstream token10(linetoken10.c_str());
|
||||||
|
|
||||||
static bool CZfabetaf_first = true;
|
static bool CZfabetaf_first = true;
|
||||||
static bool CZfadef_first = true;
|
static bool CZfadef_first = true;
|
||||||
|
|
|
@ -18,6 +18,9 @@
|
||||||
----------------------------------------------------------------------
|
----------------------------------------------------------------------
|
||||||
|
|
||||||
HISTORY: 04/04/2003 initial release
|
HISTORY: 04/04/2003 initial release
|
||||||
|
06/30/2003 (RD) replaced istrstream with istringstream
|
||||||
|
to get rid of the annoying warning about
|
||||||
|
using the strstream header
|
||||||
|
|
||||||
----------------------------------------------------------------------
|
----------------------------------------------------------------------
|
||||||
|
|
||||||
|
@ -103,14 +106,14 @@ void parse_CY( const string& linetoken2, const string& linetoken3,
|
||||||
double datafile_zArray[100][100];
|
double datafile_zArray[100][100];
|
||||||
double convert_f;
|
double convert_f;
|
||||||
int datafile_nxArray[100], datafile_ny;
|
int datafile_nxArray[100], datafile_ny;
|
||||||
istrstream token3(linetoken3.c_str());
|
istringstream token3(linetoken3.c_str());
|
||||||
istrstream token4(linetoken4.c_str());
|
istringstream token4(linetoken4.c_str());
|
||||||
istrstream token5(linetoken5.c_str());
|
istringstream token5(linetoken5.c_str());
|
||||||
istrstream token6(linetoken6.c_str());
|
istringstream token6(linetoken6.c_str());
|
||||||
istrstream token7(linetoken7.c_str());
|
istringstream token7(linetoken7.c_str());
|
||||||
istrstream token8(linetoken8.c_str());
|
istringstream token8(linetoken8.c_str());
|
||||||
istrstream token9(linetoken9.c_str());
|
istringstream token9(linetoken9.c_str());
|
||||||
istrstream token10(linetoken10.c_str());
|
istringstream token10(linetoken10.c_str());
|
||||||
|
|
||||||
static bool CYfabetaf_first = true;
|
static bool CYfabetaf_first = true;
|
||||||
static bool CYfadaf_first = true;
|
static bool CYfadaf_first = true;
|
||||||
|
|
|
@ -18,6 +18,9 @@
|
||||||
----------------------------------------------------------------------
|
----------------------------------------------------------------------
|
||||||
|
|
||||||
HISTORY: 04/04/2003 initial release
|
HISTORY: 04/04/2003 initial release
|
||||||
|
06/30/2003 (RD) replaced istrstream with istringstream
|
||||||
|
to get rid of the annoying warning about
|
||||||
|
using the strstream header
|
||||||
|
|
||||||
----------------------------------------------------------------------
|
----------------------------------------------------------------------
|
||||||
|
|
||||||
|
@ -103,14 +106,14 @@ void parse_Cm( const string& linetoken2, const string& linetoken3,
|
||||||
double datafile_zArray[100][100];
|
double datafile_zArray[100][100];
|
||||||
double convert_f;
|
double convert_f;
|
||||||
int datafile_nxArray[100], datafile_ny;
|
int datafile_nxArray[100], datafile_ny;
|
||||||
istrstream token3(linetoken3.c_str());
|
istringstream token3(linetoken3.c_str());
|
||||||
istrstream token4(linetoken4.c_str());
|
istringstream token4(linetoken4.c_str());
|
||||||
istrstream token5(linetoken5.c_str());
|
istringstream token5(linetoken5.c_str());
|
||||||
istrstream token6(linetoken6.c_str());
|
istringstream token6(linetoken6.c_str());
|
||||||
istrstream token7(linetoken7.c_str());
|
istringstream token7(linetoken7.c_str());
|
||||||
istrstream token8(linetoken8.c_str());
|
istringstream token8(linetoken8.c_str());
|
||||||
istrstream token9(linetoken9.c_str());
|
istringstream token9(linetoken9.c_str());
|
||||||
istrstream token10(linetoken10.c_str());
|
istringstream token10(linetoken10.c_str());
|
||||||
|
|
||||||
static bool Cmfabetaf_first = true;
|
static bool Cmfabetaf_first = true;
|
||||||
static bool Cmfadef_first = true;
|
static bool Cmfadef_first = true;
|
||||||
|
|
|
@ -18,6 +18,9 @@
|
||||||
----------------------------------------------------------------------
|
----------------------------------------------------------------------
|
||||||
|
|
||||||
HISTORY: 04/04/2003 initial release
|
HISTORY: 04/04/2003 initial release
|
||||||
|
06/30/2003 (RD) replaced istrstream with istringstream
|
||||||
|
to get rid of the annoying warning about
|
||||||
|
using the strstream header
|
||||||
|
|
||||||
----------------------------------------------------------------------
|
----------------------------------------------------------------------
|
||||||
|
|
||||||
|
@ -103,14 +106,14 @@ void parse_Cn( const string& linetoken2, const string& linetoken3,
|
||||||
double datafile_zArray[100][100];
|
double datafile_zArray[100][100];
|
||||||
double convert_f;
|
double convert_f;
|
||||||
int datafile_nxArray[100], datafile_ny;
|
int datafile_nxArray[100], datafile_ny;
|
||||||
istrstream token3(linetoken3.c_str());
|
istringstream token3(linetoken3.c_str());
|
||||||
istrstream token4(linetoken4.c_str());
|
istringstream token4(linetoken4.c_str());
|
||||||
istrstream token5(linetoken5.c_str());
|
istringstream token5(linetoken5.c_str());
|
||||||
istrstream token6(linetoken6.c_str());
|
istringstream token6(linetoken6.c_str());
|
||||||
istrstream token7(linetoken7.c_str());
|
istringstream token7(linetoken7.c_str());
|
||||||
istrstream token8(linetoken8.c_str());
|
istringstream token8(linetoken8.c_str());
|
||||||
istrstream token9(linetoken9.c_str());
|
istringstream token9(linetoken9.c_str());
|
||||||
istrstream token10(linetoken10.c_str());
|
istringstream token10(linetoken10.c_str());
|
||||||
|
|
||||||
static bool Cnfabetaf_first = true;
|
static bool Cnfabetaf_first = true;
|
||||||
static bool Cnfadaf_first = true;
|
static bool Cnfadaf_first = true;
|
||||||
|
|
|
@ -18,6 +18,9 @@
|
||||||
----------------------------------------------------------------------
|
----------------------------------------------------------------------
|
||||||
|
|
||||||
HISTORY: 04/04/2003 initial release
|
HISTORY: 04/04/2003 initial release
|
||||||
|
06/30/2003 (RD) replaced istrstream with istringstream
|
||||||
|
to get rid of the annoying warning about
|
||||||
|
using the strstream header
|
||||||
|
|
||||||
----------------------------------------------------------------------
|
----------------------------------------------------------------------
|
||||||
|
|
||||||
|
@ -103,14 +106,14 @@ void parse_Cl( const string& linetoken2, const string& linetoken3,
|
||||||
double datafile_zArray[100][100];
|
double datafile_zArray[100][100];
|
||||||
double convert_f;
|
double convert_f;
|
||||||
int datafile_nxArray[100], datafile_ny;
|
int datafile_nxArray[100], datafile_ny;
|
||||||
istrstream token3(linetoken3.c_str());
|
istringstream token3(linetoken3.c_str());
|
||||||
istrstream token4(linetoken4.c_str());
|
istringstream token4(linetoken4.c_str());
|
||||||
istrstream token5(linetoken5.c_str());
|
istringstream token5(linetoken5.c_str());
|
||||||
istrstream token6(linetoken6.c_str());
|
istringstream token6(linetoken6.c_str());
|
||||||
istrstream token7(linetoken7.c_str());
|
istringstream token7(linetoken7.c_str());
|
||||||
istrstream token8(linetoken8.c_str());
|
istringstream token8(linetoken8.c_str());
|
||||||
istrstream token9(linetoken9.c_str());
|
istringstream token9(linetoken9.c_str());
|
||||||
istrstream token10(linetoken10.c_str());
|
istringstream token10(linetoken10.c_str());
|
||||||
|
|
||||||
static bool Clfabetaf_first = true;
|
static bool Clfabetaf_first = true;
|
||||||
static bool Clfadaf_first = true;
|
static bool Clfadaf_first = true;
|
||||||
|
|
|
@ -18,6 +18,9 @@
|
||||||
----------------------------------------------------------------------
|
----------------------------------------------------------------------
|
||||||
|
|
||||||
HISTORY: 04/04/2003 initial release
|
HISTORY: 04/04/2003 initial release
|
||||||
|
06/30/2003 (RD) replaced istrstream with istringstream
|
||||||
|
to get rid of the annoying warning about
|
||||||
|
using the strstream header
|
||||||
|
|
||||||
----------------------------------------------------------------------
|
----------------------------------------------------------------------
|
||||||
|
|
||||||
|
@ -99,14 +102,14 @@ void parse_controlSurface( const string& linetoken2, const string& linetoken3,
|
||||||
LIST command_line ) {
|
LIST command_line ) {
|
||||||
double token_value;
|
double token_value;
|
||||||
int token_value_convert1, token_value_convert2;
|
int token_value_convert1, token_value_convert2;
|
||||||
istrstream token3(linetoken3.c_str());
|
istringstream token3(linetoken3.c_str());
|
||||||
istrstream token4(linetoken4.c_str());
|
istringstream token4(linetoken4.c_str());
|
||||||
istrstream token5(linetoken5.c_str());
|
istringstream token5(linetoken5.c_str());
|
||||||
istrstream token6(linetoken6.c_str());
|
istringstream token6(linetoken6.c_str());
|
||||||
istrstream token7(linetoken7.c_str());
|
istringstream token7(linetoken7.c_str());
|
||||||
istrstream token8(linetoken8.c_str());
|
istringstream token8(linetoken8.c_str());
|
||||||
istrstream token9(linetoken9.c_str());
|
istringstream token9(linetoken9.c_str());
|
||||||
istrstream token10(linetoken10.c_str());
|
istringstream token10(linetoken10.c_str());
|
||||||
|
|
||||||
switch(controlSurface_map[linetoken2])
|
switch(controlSurface_map[linetoken2])
|
||||||
{
|
{
|
||||||
|
|
|
@ -18,6 +18,9 @@
|
||||||
----------------------------------------------------------------------
|
----------------------------------------------------------------------
|
||||||
|
|
||||||
HISTORY: 04/04/2003 initial release
|
HISTORY: 04/04/2003 initial release
|
||||||
|
06/30/2003 (RD) replaced istrstream with istringstream
|
||||||
|
to get rid of the annoying warning about
|
||||||
|
using the strstream header
|
||||||
|
|
||||||
----------------------------------------------------------------------
|
----------------------------------------------------------------------
|
||||||
|
|
||||||
|
@ -98,14 +101,14 @@ void parse_engine( const string& linetoken2, const string& linetoken3,
|
||||||
LIST command_line ) {
|
LIST command_line ) {
|
||||||
double token_value;
|
double token_value;
|
||||||
int token_value_convert1, token_value_convert2;
|
int token_value_convert1, token_value_convert2;
|
||||||
istrstream token3(linetoken3.c_str());
|
istringstream token3(linetoken3.c_str());
|
||||||
istrstream token4(linetoken4.c_str());
|
istringstream token4(linetoken4.c_str());
|
||||||
istrstream token5(linetoken5.c_str());
|
istringstream token5(linetoken5.c_str());
|
||||||
istrstream token6(linetoken6.c_str());
|
istringstream token6(linetoken6.c_str());
|
||||||
istrstream token7(linetoken7.c_str());
|
istringstream token7(linetoken7.c_str());
|
||||||
istrstream token8(linetoken8.c_str());
|
istringstream token8(linetoken8.c_str());
|
||||||
istrstream token9(linetoken9.c_str());
|
istringstream token9(linetoken9.c_str());
|
||||||
istrstream token10(linetoken10.c_str());
|
istringstream token10(linetoken10.c_str());
|
||||||
|
|
||||||
switch(engine_map[linetoken2])
|
switch(engine_map[linetoken2])
|
||||||
{
|
{
|
||||||
|
|
|
@ -18,6 +18,9 @@
|
||||||
----------------------------------------------------------------------
|
----------------------------------------------------------------------
|
||||||
|
|
||||||
HISTORY: 04/04/2003 initial release
|
HISTORY: 04/04/2003 initial release
|
||||||
|
06/30/2003 (RD) replaced istrstream with istringstream
|
||||||
|
to get rid of the annoying warning about
|
||||||
|
using the strstream header
|
||||||
|
|
||||||
----------------------------------------------------------------------
|
----------------------------------------------------------------------
|
||||||
|
|
||||||
|
@ -98,14 +101,14 @@ void parse_fog( const string& linetoken2, const string& linetoken3,
|
||||||
LIST command_line ) {
|
LIST command_line ) {
|
||||||
double token_value;
|
double token_value;
|
||||||
int token_value_convert1;
|
int token_value_convert1;
|
||||||
istrstream token3(linetoken3.c_str());
|
istringstream token3(linetoken3.c_str());
|
||||||
istrstream token4(linetoken4.c_str());
|
istringstream token4(linetoken4.c_str());
|
||||||
istrstream token5(linetoken5.c_str());
|
istringstream token5(linetoken5.c_str());
|
||||||
istrstream token6(linetoken6.c_str());
|
istringstream token6(linetoken6.c_str());
|
||||||
istrstream token7(linetoken7.c_str());
|
istringstream token7(linetoken7.c_str());
|
||||||
istrstream token8(linetoken8.c_str());
|
istringstream token8(linetoken8.c_str());
|
||||||
istrstream token9(linetoken9.c_str());
|
istringstream token9(linetoken9.c_str());
|
||||||
istrstream token10(linetoken10.c_str());
|
istringstream token10(linetoken10.c_str());
|
||||||
|
|
||||||
switch(fog_map[linetoken2])
|
switch(fog_map[linetoken2])
|
||||||
{
|
{
|
||||||
|
|
|
@ -1,10 +1,78 @@
|
||||||
|
/**********************************************************************
|
||||||
|
|
||||||
|
FILENAME: uiuc_menu_functions.cpp
|
||||||
|
|
||||||
|
----------------------------------------------------------------------
|
||||||
|
|
||||||
|
DESCRIPTION: provides common functions used by different menu
|
||||||
|
routines
|
||||||
|
|
||||||
|
----------------------------------------------------------------------
|
||||||
|
|
||||||
|
STATUS: alpha version
|
||||||
|
|
||||||
|
----------------------------------------------------------------------
|
||||||
|
|
||||||
|
REFERENCES:
|
||||||
|
|
||||||
|
----------------------------------------------------------------------
|
||||||
|
|
||||||
|
HISTORY: 04/04/2003 initial release
|
||||||
|
06/30/2003 (RD) replaced istrstream with istringstream
|
||||||
|
to get rid of the annoying warning about
|
||||||
|
using the strstream header
|
||||||
|
|
||||||
|
----------------------------------------------------------------------
|
||||||
|
|
||||||
|
AUTHOR(S): Robert Deters <rdeters@uiuc.edu>
|
||||||
|
Michael Selig <m-selig@uiuc.edu>
|
||||||
|
|
||||||
|
----------------------------------------------------------------------
|
||||||
|
|
||||||
|
VARIABLES:
|
||||||
|
|
||||||
|
----------------------------------------------------------------------
|
||||||
|
|
||||||
|
INPUTS: n/a
|
||||||
|
|
||||||
|
----------------------------------------------------------------------
|
||||||
|
|
||||||
|
OUTPUTS: n/a
|
||||||
|
|
||||||
|
----------------------------------------------------------------------
|
||||||
|
|
||||||
|
CALLED BY: uiuc_menu_XX()
|
||||||
|
|
||||||
|
----------------------------------------------------------------------
|
||||||
|
|
||||||
|
CALLS TO:
|
||||||
|
|
||||||
|
----------------------------------------------------------------------
|
||||||
|
|
||||||
|
COPYRIGHT: (C) 2003 by Michael Selig
|
||||||
|
|
||||||
|
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.
|
||||||
|
|
||||||
|
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 or view http://www.gnu.org/copyleft/gpl.html.
|
||||||
|
|
||||||
|
**********************************************************************/
|
||||||
|
|
||||||
#include "uiuc_menu_functions.h"
|
#include "uiuc_menu_functions.h"
|
||||||
|
|
||||||
bool check_float( const string &token)
|
bool check_float( const string &token)
|
||||||
{
|
{
|
||||||
float value;
|
float value;
|
||||||
istrstream stream(token.c_str());
|
istringstream stream(token.c_str());
|
||||||
return (stream >> value);
|
return (stream >> value);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -7,9 +7,10 @@
|
||||||
|
|
||||||
#include <string>
|
#include <string>
|
||||||
#include STL_IOSTREAM
|
#include STL_IOSTREAM
|
||||||
#include STL_STRSTREAM
|
//#include STL_STRSTREAM
|
||||||
|
#include <sstream>
|
||||||
|
|
||||||
SG_USING_STD(istrstream);
|
//SG_USING_STD(istrstream);
|
||||||
|
|
||||||
void d_2_to_3( double array2D[100][100], double array3D[][100][100], int index3D);
|
void d_2_to_3( double array2D[100][100], double array3D[][100][100], int index3D);
|
||||||
void d_1_to_2( double array1D[100], double array2D[][100], int index2D);
|
void d_1_to_2( double array1D[100], double array2D[][100], int index2D);
|
||||||
|
|
|
@ -18,6 +18,9 @@
|
||||||
----------------------------------------------------------------------
|
----------------------------------------------------------------------
|
||||||
|
|
||||||
HISTORY: 04/04/2003 initial release
|
HISTORY: 04/04/2003 initial release
|
||||||
|
06/30/2003 (RD) replaced istrstream with istringstream
|
||||||
|
to get rid of the annoying warning about
|
||||||
|
using the strstream header
|
||||||
|
|
||||||
----------------------------------------------------------------------
|
----------------------------------------------------------------------
|
||||||
|
|
||||||
|
@ -97,14 +100,14 @@ void parse_gear( const string& linetoken2, const string& linetoken3,
|
||||||
const string& linetoken10, const string& aircraft_directory,
|
const string& linetoken10, const string& aircraft_directory,
|
||||||
LIST command_line ) {
|
LIST command_line ) {
|
||||||
double token_value;
|
double token_value;
|
||||||
istrstream token3(linetoken3.c_str());
|
istringstream token3(linetoken3.c_str());
|
||||||
istrstream token4(linetoken4.c_str());
|
istringstream token4(linetoken4.c_str());
|
||||||
istrstream token5(linetoken5.c_str());
|
istringstream token5(linetoken5.c_str());
|
||||||
istrstream token6(linetoken6.c_str());
|
istringstream token6(linetoken6.c_str());
|
||||||
istrstream token7(linetoken7.c_str());
|
istringstream token7(linetoken7.c_str());
|
||||||
istrstream token8(linetoken8.c_str());
|
istringstream token8(linetoken8.c_str());
|
||||||
istrstream token9(linetoken9.c_str());
|
istringstream token9(linetoken9.c_str());
|
||||||
istrstream token10(linetoken10.c_str());
|
istringstream token10(linetoken10.c_str());
|
||||||
|
|
||||||
switch(gear_map[linetoken2])
|
switch(gear_map[linetoken2])
|
||||||
{
|
{
|
||||||
|
|
|
@ -18,6 +18,9 @@
|
||||||
----------------------------------------------------------------------
|
----------------------------------------------------------------------
|
||||||
|
|
||||||
HISTORY: 04/04/2003 initial release
|
HISTORY: 04/04/2003 initial release
|
||||||
|
06/30/2003 (RD) replaced istrstream with istringstream
|
||||||
|
to get rid of the annoying warning about
|
||||||
|
using the strstream header
|
||||||
|
|
||||||
----------------------------------------------------------------------
|
----------------------------------------------------------------------
|
||||||
|
|
||||||
|
@ -97,14 +100,14 @@ void parse_geometry( const string& linetoken2, const string& linetoken3,
|
||||||
const string& linetoken10,
|
const string& linetoken10,
|
||||||
const string& aircraft_directory, LIST command_line ) {
|
const string& aircraft_directory, LIST command_line ) {
|
||||||
double token_value;
|
double token_value;
|
||||||
istrstream token3(linetoken3.c_str());
|
istringstream token3(linetoken3.c_str());
|
||||||
istrstream token4(linetoken4.c_str());
|
istringstream token4(linetoken4.c_str());
|
||||||
istrstream token5(linetoken5.c_str());
|
istringstream token5(linetoken5.c_str());
|
||||||
istrstream token6(linetoken6.c_str());
|
istringstream token6(linetoken6.c_str());
|
||||||
istrstream token7(linetoken7.c_str());
|
istringstream token7(linetoken7.c_str());
|
||||||
istrstream token8(linetoken8.c_str());
|
istringstream token8(linetoken8.c_str());
|
||||||
istrstream token9(linetoken9.c_str());
|
istringstream token9(linetoken9.c_str());
|
||||||
istrstream token10(linetoken10.c_str());
|
istringstream token10(linetoken10.c_str());
|
||||||
|
|
||||||
switch(geometry_map[linetoken2])
|
switch(geometry_map[linetoken2])
|
||||||
{
|
{
|
||||||
|
|
|
@ -18,6 +18,9 @@
|
||||||
----------------------------------------------------------------------
|
----------------------------------------------------------------------
|
||||||
|
|
||||||
HISTORY: 04/04/2003 initial release
|
HISTORY: 04/04/2003 initial release
|
||||||
|
06/30/2003 (RD) replaced istrstream with istringstream
|
||||||
|
to get rid of the annoying warning about
|
||||||
|
using the strstream header
|
||||||
|
|
||||||
----------------------------------------------------------------------
|
----------------------------------------------------------------------
|
||||||
|
|
||||||
|
@ -101,14 +104,14 @@ void parse_ice( const string& linetoken2, const string& linetoken3,
|
||||||
double datafile_xArray[100][100], datafile_yArray[100];
|
double datafile_xArray[100][100], datafile_yArray[100];
|
||||||
double datafile_zArray[100][100];
|
double datafile_zArray[100][100];
|
||||||
int datafile_nxArray[100], datafile_ny;
|
int datafile_nxArray[100], datafile_ny;
|
||||||
istrstream token3(linetoken3.c_str());
|
istringstream token3(linetoken3.c_str());
|
||||||
istrstream token4(linetoken4.c_str());
|
istringstream token4(linetoken4.c_str());
|
||||||
istrstream token5(linetoken5.c_str());
|
istringstream token5(linetoken5.c_str());
|
||||||
istrstream token6(linetoken6.c_str());
|
istringstream token6(linetoken6.c_str());
|
||||||
istrstream token7(linetoken7.c_str());
|
istringstream token7(linetoken7.c_str());
|
||||||
istrstream token8(linetoken8.c_str());
|
istringstream token8(linetoken8.c_str());
|
||||||
istrstream token9(linetoken9.c_str());
|
istringstream token9(linetoken9.c_str());
|
||||||
istrstream token10(linetoken10.c_str());
|
istringstream token10(linetoken10.c_str());
|
||||||
|
|
||||||
static bool tactilefadef_first = true;
|
static bool tactilefadef_first = true;
|
||||||
|
|
||||||
|
|
|
@ -18,6 +18,9 @@
|
||||||
----------------------------------------------------------------------
|
----------------------------------------------------------------------
|
||||||
|
|
||||||
HISTORY: 04/04/2003 initial release
|
HISTORY: 04/04/2003 initial release
|
||||||
|
06/30/2003 (RD) replaced istrstream with istringstream
|
||||||
|
to get rid of the annoying warning about
|
||||||
|
using the strstream header
|
||||||
|
|
||||||
----------------------------------------------------------------------
|
----------------------------------------------------------------------
|
||||||
|
|
||||||
|
@ -97,14 +100,14 @@ void parse_init( const string& linetoken2, const string& linetoken3,
|
||||||
const string& linetoken10, const string& aircraft_directory,
|
const string& linetoken10, const string& aircraft_directory,
|
||||||
LIST command_line ) {
|
LIST command_line ) {
|
||||||
double token_value;
|
double token_value;
|
||||||
istrstream token3(linetoken3.c_str());
|
istringstream token3(linetoken3.c_str());
|
||||||
istrstream token4(linetoken4.c_str());
|
istringstream token4(linetoken4.c_str());
|
||||||
istrstream token5(linetoken5.c_str());
|
istringstream token5(linetoken5.c_str());
|
||||||
istrstream token6(linetoken6.c_str());
|
istringstream token6(linetoken6.c_str());
|
||||||
istrstream token7(linetoken7.c_str());
|
istringstream token7(linetoken7.c_str());
|
||||||
istrstream token8(linetoken8.c_str());
|
istringstream token8(linetoken8.c_str());
|
||||||
istrstream token9(linetoken9.c_str());
|
istringstream token9(linetoken9.c_str());
|
||||||
istrstream token10(linetoken10.c_str());
|
istringstream token10(linetoken10.c_str());
|
||||||
int token_value_recordRate;
|
int token_value_recordRate;
|
||||||
|
|
||||||
switch(init_map[linetoken2])
|
switch(init_map[linetoken2])
|
||||||
|
|
|
@ -18,6 +18,9 @@
|
||||||
----------------------------------------------------------------------
|
----------------------------------------------------------------------
|
||||||
|
|
||||||
HISTORY: 04/04/2003 initial release
|
HISTORY: 04/04/2003 initial release
|
||||||
|
06/30/2003 (RD) replaced istrstream with istringstream
|
||||||
|
to get rid of the annoying warning about
|
||||||
|
using the strstream header
|
||||||
|
|
||||||
----------------------------------------------------------------------
|
----------------------------------------------------------------------
|
||||||
|
|
||||||
|
@ -97,14 +100,14 @@ void parse_mass( const string& linetoken2, const string& linetoken3,
|
||||||
const string& linetoken10, const string& aircraft_directory,
|
const string& linetoken10, const string& aircraft_directory,
|
||||||
LIST command_line ) {
|
LIST command_line ) {
|
||||||
double token_value;
|
double token_value;
|
||||||
istrstream token3(linetoken3.c_str());
|
istringstream token3(linetoken3.c_str());
|
||||||
istrstream token4(linetoken4.c_str());
|
istringstream token4(linetoken4.c_str());
|
||||||
istrstream token5(linetoken5.c_str());
|
istringstream token5(linetoken5.c_str());
|
||||||
istrstream token6(linetoken6.c_str());
|
istringstream token6(linetoken6.c_str());
|
||||||
istrstream token7(linetoken7.c_str());
|
istringstream token7(linetoken7.c_str());
|
||||||
istrstream token8(linetoken8.c_str());
|
istringstream token8(linetoken8.c_str());
|
||||||
istrstream token9(linetoken9.c_str());
|
istringstream token9(linetoken9.c_str());
|
||||||
istrstream token10(linetoken10.c_str());
|
istringstream token10(linetoken10.c_str());
|
||||||
|
|
||||||
switch(mass_map[linetoken2])
|
switch(mass_map[linetoken2])
|
||||||
{
|
{
|
||||||
|
|
|
@ -18,6 +18,9 @@
|
||||||
----------------------------------------------------------------------
|
----------------------------------------------------------------------
|
||||||
|
|
||||||
HISTORY: 04/04/2003 initial release
|
HISTORY: 04/04/2003 initial release
|
||||||
|
06/30/2003 (RD) replaced istrstream with istringstream
|
||||||
|
to get rid of the annoying warning about
|
||||||
|
using the strstream header
|
||||||
|
|
||||||
----------------------------------------------------------------------
|
----------------------------------------------------------------------
|
||||||
|
|
||||||
|
@ -97,14 +100,14 @@ void parse_misc( const string& linetoken2, const string& linetoken3,
|
||||||
const string& linetoken10, const string& aircraft_directory,
|
const string& linetoken10, const string& aircraft_directory,
|
||||||
LIST command_line ) {
|
LIST command_line ) {
|
||||||
double token_value;
|
double token_value;
|
||||||
istrstream token3(linetoken3.c_str());
|
istringstream token3(linetoken3.c_str());
|
||||||
istrstream token4(linetoken4.c_str());
|
istringstream token4(linetoken4.c_str());
|
||||||
istrstream token5(linetoken5.c_str());
|
istringstream token5(linetoken5.c_str());
|
||||||
istrstream token6(linetoken6.c_str());
|
istringstream token6(linetoken6.c_str());
|
||||||
istrstream token7(linetoken7.c_str());
|
istringstream token7(linetoken7.c_str());
|
||||||
istrstream token8(linetoken8.c_str());
|
istringstream token8(linetoken8.c_str());
|
||||||
istrstream token9(linetoken9.c_str());
|
istringstream token9(linetoken9.c_str());
|
||||||
istrstream token10(linetoken10.c_str());
|
istringstream token10(linetoken10.c_str());
|
||||||
|
|
||||||
switch(misc_map[linetoken2])
|
switch(misc_map[linetoken2])
|
||||||
{
|
{
|
||||||
|
|
|
@ -134,9 +134,11 @@ AIRCRAFTDIR *aircraftdir_ = new AIRCRAFTDIR;
|
||||||
|
|
||||||
void uiuc_initial_init ()
|
void uiuc_initial_init ()
|
||||||
{
|
{
|
||||||
// This function called from both ls_step and ls_model(uiuc model side).
|
// This function is called from uiuc_init_2_wrapper (uiuc_aero.c in LaRCsim)
|
||||||
// Apply brute force initializations, which override ls_step and ls_aux values
|
// which is called from ls_step and ls_model.
|
||||||
// for the first time step.
|
// Apply brute force initializations, which override unwanted changes
|
||||||
|
// performed by LaRCsim.
|
||||||
|
// Used during initialization (while Simtime=0).
|
||||||
if (P_body_init_true)
|
if (P_body_init_true)
|
||||||
P_body = P_body_init;
|
P_body = P_body_init;
|
||||||
if (Q_body_init_true)
|
if (Q_body_init_true)
|
||||||
|
@ -161,7 +163,7 @@ void uiuc_initial_init ()
|
||||||
|
|
||||||
void uiuc_defaults_inits ()
|
void uiuc_defaults_inits ()
|
||||||
{
|
{
|
||||||
// set defaults and initialize (called from ls_step.c at Simtime=0)
|
// set defaults and initialize (called once from uiuc_init_2_wrapper)
|
||||||
|
|
||||||
//fog inits
|
//fog inits
|
||||||
fog_field = 0;
|
fog_field = 0;
|
||||||
|
@ -276,7 +278,15 @@ void uiuc_defaults_inits ()
|
||||||
flapper_model = false;
|
flapper_model = false;
|
||||||
ignore_unknown_keywords = false;
|
ignore_unknown_keywords = false;
|
||||||
pilot_throttle_no = false;
|
pilot_throttle_no = false;
|
||||||
|
Dx_cg = 0.0;
|
||||||
|
Dy_cg = 0.0;
|
||||||
|
Dz_cg = 0.0;
|
||||||
|
|
||||||
|
|
||||||
|
// Calculates the local velocity (V_north, V_east, V_down) from the body
|
||||||
|
// velocities.
|
||||||
|
// Called from uiuc_local_vel_init which is called from ls_step.
|
||||||
|
// Used during initialization (while Simtime=0)
|
||||||
}
|
}
|
||||||
|
|
||||||
void uiuc_vel_init ()
|
void uiuc_vel_init ()
|
||||||
|
@ -302,6 +312,8 @@ void uiuc_vel_init ()
|
||||||
|
|
||||||
V_east = V_east_rel_ground + OMEGA_EARTH*Sea_level_radius*cos(Lat_geocentric);
|
V_east = V_east_rel_ground + OMEGA_EARTH*Sea_level_radius*cos(Lat_geocentric);
|
||||||
}
|
}
|
||||||
|
// Initializes the UIUC aircraft model.
|
||||||
|
// Called once from uiuc_init_2_wrapper
|
||||||
}
|
}
|
||||||
|
|
||||||
void uiuc_init_aeromodel ()
|
void uiuc_init_aeromodel ()
|
||||||
|
@ -367,6 +379,10 @@ void uiuc_force_moment(double dt)
|
||||||
if (I_zz_appMass_ratio)
|
if (I_zz_appMass_ratio)
|
||||||
M_n_aero += -(I_zz_appMass_ratio * I_zz) * R_dot_body;
|
M_n_aero += -(I_zz_appMass_ratio * I_zz) * R_dot_body;
|
||||||
|
|
||||||
|
// adding in apparent mass in body axis X direction
|
||||||
|
// F_X_aero += -(0.05 * Mass) * U_dot_body;
|
||||||
|
|
||||||
|
|
||||||
if (Mass_appMass)
|
if (Mass_appMass)
|
||||||
F_Z_aero += -Mass_appMass * W_dot_body;
|
F_Z_aero += -Mass_appMass * W_dot_body;
|
||||||
if (I_xx_appMass)
|
if (I_xx_appMass)
|
||||||
|
|
Loading…
Add table
Reference in a new issue