1
0
Fork 0

Add support for /controls/parking-brake -- it effective overrides the

individual braking commands for the main gear.
This commit is contained in:
david 2002-04-11 17:11:22 +00:00
parent 4d7fda6e75
commit 9156544566

View file

@ -328,9 +328,14 @@ bool FGJSBsim::copy_to_JSBsim() {
FCS->SetDfCmd( globals->get_controls()->get_flaps() );
FCS->SetDsbCmd( 0.0 ); //speedbrakes
FCS->SetDspCmd( 0.0 ); //spoilers
FCS->SetLBrake( globals->get_controls()->get_brake( 0 ) );
FCS->SetRBrake( globals->get_controls()->get_brake( 1 ) );
// Parking brake sets minimum braking
// level for mains.
double parking_brake = globals->get_controls()->get_parking_brake();
FCS->SetLBrake(fmax(globals->get_controls()->get_brake(0), parking_brake));
FCS->SetRBrake(fmax(globals->get_controls()->get_brake(1), parking_brake));
FCS->SetCBrake( globals->get_controls()->get_brake( 2 ) );
FCS->SetGearCmd( globals->get_controls()->get_gear_down());
for (i = 0; i < Propulsion->GetNumEngines(); i++) {
FGEngine * eng = Propulsion->GetEngine(i);