Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Plane follow script Applet #28546

Open
wants to merge 14 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 7 additions & 0 deletions ArduPlane/Parameters.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1319,6 +1319,13 @@ const AP_Param::GroupInfo ParametersG2::var_info[] = {
// @User: Standard
AP_GROUPINFO("FWD_BAT_THR_CUT", 37, ParametersG2, fwd_batt_cmp.batt_voltage_throttle_cutoff, 0.0f),

// @Param: GUIDED_UPD_LIM
// @DisplayName: Guided Update Limit
// @Description: The maximum frequency that an guided mode commands sent by external system such as lua or mavlink can update roll, pitch and throttle.
// @Units: ms
// @User: Standard
AP_GROUPINFO("GUIDED_UPD_LIM", 38, ParametersG2, guided_update_frequency_limit, 3000),

AP_GROUPEND
};

Expand Down
2 changes: 2 additions & 0 deletions ArduPlane/Parameters.h
Original file line number Diff line number Diff line change
Expand Up @@ -574,6 +574,8 @@ class ParametersG2 {
AP_Follow follow;
#endif

AP_Int32 guided_update_frequency_limit;

AP_Float fs_ekf_thresh;

// min initial climb in RTL
Expand Down
5 changes: 4 additions & 1 deletion ArduPlane/commands.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -86,8 +86,11 @@ void Plane::set_guided_WP(const Location &loc)
next_WP_loc = loc;

// used to control FBW and limit the rate of climb
// cannot be applied in Guided as this prevents the guided set altitude from working correctly
// -----------------------------------------------
set_target_altitude_current();
if (!control_mode->is_guided_mode()) {
set_target_altitude_current();
}

setup_glide_slope();
setup_turn_angle();
Expand Down
Loading
Loading