----------------------------------------------------------------------
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
----------------------------------------------------------------------
LIST command_line ) {
double token_value;
int token_value_convert1, token_value_convert2, token_value_convert3;
+ int token_value_convert4;
double datafile_xArray[100][100], datafile_yArray[100];
double datafile_zArray[100][100];
+ double convert_f;
int datafile_nxArray[100], datafile_ny;
- istrstream token3(linetoken3.c_str());
- istrstream token4(linetoken4.c_str());
- istrstream token5(linetoken5.c_str());
- istrstream token6(linetoken6.c_str());
- istrstream token7(linetoken7.c_str());
- istrstream token8(linetoken8.c_str());
- istrstream token9(linetoken9.c_str());
- istrstream token10(linetoken10.c_str());
+ istringstream token3(linetoken3.c_str());
+ istringstream token4(linetoken4.c_str());
+ istringstream token5(linetoken5.c_str());
+ istringstream token6(linetoken6.c_str());
+ istringstream token7(linetoken7.c_str());
+ istringstream token8(linetoken8.c_str());
+ istringstream token9(linetoken9.c_str());
+ istringstream token10(linetoken10.c_str());
static bool tactilefadef_first = true;
demo_eps_pitch_input_startTime = token_value;
break;
}
- case demo_ap_Theta_ref_deg_flag:
- {
- demo_ap_Theta_ref_deg = true;
- demo_ap_Theta_ref_deg_file = aircraft_directory + linetoken3;
- token4 >> token_value_convert1;
- token5 >> token_value_convert2;
- convert_y = uiuc_convert(token_value_convert1);
- convert_x = uiuc_convert(token_value_convert2);
- uiuc_1DdataFileReader(demo_ap_Theta_ref_deg_file,
- demo_ap_Theta_ref_deg_timeArray,
- demo_ap_Theta_ref_deg_daArray,
- demo_ap_Theta_ref_deg_ntime);
- token6 >> token_value;
- demo_ap_Theta_ref_deg_startTime = token_value;
- break;
- }
case demo_ap_pah_on_flag:
{
demo_ap_pah_on = true;
demo_ap_pah_on_startTime = token_value;
break;
}
+ case demo_ap_alh_on_flag:
+ {
+ demo_ap_alh_on = true;
+ demo_ap_alh_on_file = aircraft_directory + linetoken3;
+ token4 >> token_value_convert1;
+ token5 >> token_value_convert2;
+ convert_y = uiuc_convert(token_value_convert1);
+ convert_x = uiuc_convert(token_value_convert2);
+ uiuc_1DdataFileReader(demo_ap_alh_on_file,
+ demo_ap_alh_on_timeArray,
+ demo_ap_alh_on_daArray,
+ demo_ap_alh_on_ntime);
+ token6 >> token_value;
+ demo_ap_alh_on_startTime = token_value;
+ break;
+ }
+ case demo_ap_rah_on_flag:
+ {
+ demo_ap_rah_on = true;
+ demo_ap_rah_on_file = aircraft_directory + linetoken3;
+ token4 >> token_value_convert1;
+ token5 >> token_value_convert2;
+ convert_y = uiuc_convert(token_value_convert1);
+ convert_x = uiuc_convert(token_value_convert2);
+ uiuc_1DdataFileReader(demo_ap_rah_on_file,
+ demo_ap_rah_on_timeArray,
+ demo_ap_rah_on_daArray,
+ demo_ap_rah_on_ntime);
+ token6 >> token_value;
+ demo_ap_rah_on_startTime = token_value;
+ break;
+ }
+ case demo_ap_hh_on_flag:
+ {
+ demo_ap_hh_on = true;
+ demo_ap_hh_on_file = aircraft_directory + linetoken3;
+ token4 >> token_value_convert1;
+ token5 >> token_value_convert2;
+ convert_y = uiuc_convert(token_value_convert1);
+ convert_x = uiuc_convert(token_value_convert2);
+ uiuc_1DdataFileReader(demo_ap_hh_on_file,
+ demo_ap_hh_on_timeArray,
+ demo_ap_hh_on_daArray,
+ demo_ap_hh_on_ntime);
+ token6 >> token_value;
+ demo_ap_hh_on_startTime = token_value;
+ break;
+ }
+ case demo_ap_Theta_ref_flag:
+ {
+ demo_ap_Theta_ref = true;
+ demo_ap_Theta_ref_file = aircraft_directory + linetoken3;
+ token4 >> token_value_convert1;
+ token5 >> token_value_convert2;
+ convert_y = uiuc_convert(token_value_convert1);
+ convert_x = uiuc_convert(token_value_convert2);
+ uiuc_1DdataFileReader(demo_ap_Theta_ref_file,
+ demo_ap_Theta_ref_timeArray,
+ demo_ap_Theta_ref_daArray,
+ demo_ap_Theta_ref_ntime);
+ token6 >> token_value;
+ demo_ap_Theta_ref_startTime = token_value;
+ break;
+ }
+ case demo_ap_alt_ref_flag:
+ {
+ demo_ap_alt_ref = true;
+ demo_ap_alt_ref_file = aircraft_directory + linetoken3;
+ token4 >> token_value_convert1;
+ token5 >> token_value_convert2;
+ convert_y = uiuc_convert(token_value_convert1);
+ convert_x = uiuc_convert(token_value_convert2);
+ uiuc_1DdataFileReader(demo_ap_alt_ref_file,
+ demo_ap_alt_ref_timeArray,
+ demo_ap_alt_ref_daArray,
+ demo_ap_alt_ref_ntime);
+ token6 >> token_value;
+ demo_ap_alt_ref_startTime = token_value;
+ break;
+ }
+ case demo_ap_Phi_ref_flag:
+ {
+ demo_ap_Phi_ref = true;
+ demo_ap_Phi_ref_file = aircraft_directory + linetoken3;
+ token4 >> token_value_convert1;
+ token5 >> token_value_convert2;
+ convert_y = uiuc_convert(token_value_convert1);
+ convert_x = uiuc_convert(token_value_convert2);
+ uiuc_1DdataFileReader(demo_ap_Phi_ref_file,
+ demo_ap_Phi_ref_timeArray,
+ demo_ap_Phi_ref_daArray,
+ demo_ap_Phi_ref_ntime);
+ token6 >> token_value;
+ demo_ap_Phi_ref_startTime = token_value;
+ break;
+ }
+ case demo_ap_Psi_ref_flag:
+ {
+ demo_ap_Psi_ref = true;
+ demo_ap_Psi_ref_file = aircraft_directory + linetoken3;
+ token4 >> token_value_convert1;
+ token5 >> token_value_convert2;
+ convert_y = uiuc_convert(token_value_convert1);
+ convert_x = uiuc_convert(token_value_convert2);
+ uiuc_1DdataFileReader(demo_ap_Psi_ref_file,
+ demo_ap_Psi_ref_timeArray,
+ demo_ap_Psi_ref_daArray,
+ demo_ap_Psi_ref_ntime);
+ token6 >> token_value;
+ demo_ap_Psi_ref_startTime = token_value;
+ break;
+ }
case tactilefadef_flag:
{
int tactilefadef_index, i;
if (tactilefadef_index > tactilefadef_nf)
tactilefadef_nf = tactilefadef_index;
token5 >> flap_value;
- tactilefadef_fArray[tactilefadef_index] = flap_value;
token6 >> token_value_convert1;
token7 >> token_value_convert2;
token8 >> token_value_convert3;
- token9 >> tactilefadef_nice;
+ token9 >> token_value_convert4;
+ token10 >> tactilefadef_nice;
convert_z = uiuc_convert(token_value_convert1);
convert_x = uiuc_convert(token_value_convert2);
convert_y = uiuc_convert(token_value_convert3);
+ convert_f = uiuc_convert(token_value_convert4);
+ tactilefadef_fArray[tactilefadef_index] = flap_value * convert_f;
/* call 2D File Reader with file name (tactilefadef_file) and
conversion factors; function returns array of
elevator deflections (deArray) and corresponding