Skip to content

Commit

Permalink
fix mc_att_control: re-add dropped acro parameters (PX4#8293)
Browse files Browse the repository at this point in the history
and make sure the vtol params are always initialized

This got lost in 4416c4d
  • Loading branch information
bkueng authored and dagar committed Nov 15, 2017
1 parent 44a71ad commit 3744cac
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions src/modules/mc_att_control/mc_att_control_main.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -450,6 +450,8 @@ MulticopterAttitudeControl::MulticopterAttitudeControl() :
_params_handles.acro_roll_max = param_find("MC_ACRO_R_MAX");
_params_handles.acro_pitch_max = param_find("MC_ACRO_P_MAX");
_params_handles.acro_yaw_max = param_find("MC_ACRO_Y_MAX");
_params_handles.acro_expo = param_find("MC_ACRO_EXPO");
_params_handles.acro_superexpo = param_find("MC_ACRO_SUPEXPO");

_params_handles.rattitude_thres = param_find("MC_RATT_TH");

Expand Down Expand Up @@ -602,6 +604,10 @@ MulticopterAttitudeControl::parameters_update()
_params.vtol_opt_recovery_enabled = (tmp == 1);

param_get(_params_handles.vtol_wv_yaw_rate_scale, &_params.vtol_wv_yaw_rate_scale);

} else {
_params.vtol_opt_recovery_enabled = false;
_params.vtol_wv_yaw_rate_scale = 0.f;
}

param_get(_params_handles.bat_scale_en, &_params.bat_scale_en);
Expand Down

0 comments on commit 3744cac

Please sign in to comment.