Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
40 commits
Select commit Hold shift + click to select a range
4ba4767
Add airbound 4.5.7.5 rc1 features (#102)
akshar-airbound Jun 12, 2026
043a1e0
Change version to 4.6.3.1 - rc7
Jun 12, 2026
b17d4e0
Add airbound 4575 rc2 features (#107)
akshar-airbound Jun 16, 2026
5d30000
Expose VTOL angles, rates and PID info in lua (#108)
vigneshm-debug Jun 16, 2026
da2336e
add controller desaturation on TV angles and add hard limit for desir…
Manuraj-PM Jun 16, 2026
9c4254d
Fix reduce disarm delay (#109)
vigneshm-debug Jun 16, 2026
9a7ad4d
Fix feedforward_scalar logic (#114)
akshar-airbound Jun 16, 2026
00f9d20
Add resume after autobailout (#112)
akshar-airbound Jun 17, 2026
e73c4de
Revert "Fix reduce disarm delay (#109)"
Jun 22, 2026
0a2d8b0
Revert the control desaturation
Jun 29, 2026
a24fd84
fixed lua bindings
vigneshm-debug Jul 3, 2026
10fbed4
fix Q_* parameter table
vigneshm-debug Jul 6, 2026
b4226d5
lua change for the new ec25e firmware
vigneshm-debug Jun 26, 2026
f5f4128
Fixed firmware-based direct-push routing, socket-reopen on data timeo…
vigneshm-debug Jul 1, 2026
e5f7944
fix(LTE): greptile review fixes for direct-push path (requeue, strict…
vigneshm-debug Jul 1, 2026
5387b50
speed up recovery from silent UDP socket failures after handovers
vigneshm-debug Jul 9, 2026
0148fd8
LTE_modem: route socket-dead recovery via CEREG check (reopen vs re-r…
vigneshm-debug Jul 11, 2026
a4f48d1
Add autobailout trigger based on pitch prediction
Jul 11, 2026
4aabc29
Update the version to AB ArduPlane V4.5.7.5 - rc6-fixes-rll-gain
Jul 11, 2026
37982ac
Fix door not closing in FW flight
Jul 11, 2026
4d047f3
autobailout.lua: limit number of autoresumes
Jul 11, 2026
9437a24
Update the Roll inner loop gains
Jul 14, 2026
56f51b5
Update the yaw rate and angle gains
Jul 14, 2026
d3118d0
updated version to 4.6.3.1-rc8
vigneshm-debug Jul 20, 2026
3acd22b
write logs to per-boot files instead of overwriting LTE_modem.log
vigneshm-debug Jul 21, 2026
4fd56f4
Removed time based check flight in vtol transition
Jul 17, 2026
b178ede
fix duplicate step-timing entry after watchdog reset in GCS messages
vigneshm-debug Jul 21, 2026
c61b2d0
EC25EFAR08A06 version of EC25-E added to known-good list
vigneshm-debug Jul 23, 2026
742e853
Fix EC25 known-good prefix match (table passed to string:find) and dr…
vigneshm-debug Jul 23, 2026
b3e7294
Remove debug LTE_QENG named-float broadcast that bypassed OPT.SIGNALS…
vigneshm-debug Jul 23, 2026
d97ef0b
Reduce the roll angular accelmax to half to existing value
Jul 22, 2026
9106c6f
autobailout.lua:disable autobailout in auto mode takeoff: NAV_VTOL_TA…
Jul 23, 2026
9df67eb
Revert roll parameters to 4575-rc6-D
Jul 24, 2026
ae549c9
version changed to 4.6.3.1 RC-9
vigneshm-debug Jul 24, 2026
217f2ef
LTE: match EC25EFAR02 family for broken CMUX; EC25-only CPIN fallback…
vigneshm-debug Jul 28, 2026
c2f1f22
HAL_LOGGING_ENABLED guard was added
vigneshm-debug Jul 29, 2026
ce39260
fixed ang_vel_body member/local mismatch
vigneshm-debug Jul 29, 2026
4510253
fix param index collision with LAND_*_MULT
vigneshm-debug Jul 29, 2026
76f7564
LTE_modem: fix CMUX hang and add retries for SIM-missing halt
vigneshm-debug Aug 1, 2026
8766636
Version changed to 4.6.3.1-rc9-lte_fixes
vigneshm-debug Aug 1, 2026
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
90 changes: 76 additions & 14 deletions ArduPlane/quadplane.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -564,6 +564,27 @@ const AP_Param::GroupInfo QuadPlane::var_info2[] = {
// @User: Advanced
AP_GROUPINFO("LND_FRZ_TIM", 40, QuadPlane, q_land_freeze_time, 7.0f),

// @Param: DARM_WDG_T
// @DisplayName: Disarm watchdog timeout
// @Description: Time in seconds after landing detection starts in LAND_FINAL before an emergency disarm warning is issued. Set to 0 to disable.
// @Units: s
// @Range: 0 30
// @Increment: 1
// @User: Standard

AP_GROUPINFO("DARM_WDG_T", 41, QuadPlane, landing_detect.wdg_timeout_s, 10.0),

// @Param: LND_DET_TIM
// @DisplayName: Qmode Land detection timeout
// @Description: The maximum time allowed for land detection in milliseconds
// @Units: ms
// @Range: 1000 4000
// @Increment: 100
// @User: Standard
AP_GROUPINFO("LND_DET_TIM", 42, QuadPlane, landing_detect.timeout_ms, 200),



AP_GROUPEND
};

Expand Down Expand Up @@ -1415,6 +1436,10 @@ void QuadPlane::set_armed(bool armed)
}
motors->armed(armed);

if (armed) {
landing_detect.wdg_start_ms = 0;
}

if (plane.control_mode == &plane.mode_guided) {
guided_wait_takeoff = armed;
}
Expand Down Expand Up @@ -2852,6 +2877,7 @@ void QuadPlane::vtol_position_controller(void)
if (tailsitter.enabled()){
set_climb_rate_cms(0);
last_pos2_ms = now_ms;
weathervane->set_gain(tailsitter.wvane_max_gain/3);
}else{
Location loc2 = loc;
loc2.change_alt_frame(Location::AltFrame::ABOVE_ORIGIN);
Expand All @@ -2862,6 +2888,7 @@ void QuadPlane::vtol_position_controller(void)
} else {
if(tailsitter.enabled()){
last_pos2_ms = now_ms;
weathervane->set_gain(tailsitter.wvane_max_gain/3);
}
set_climb_rate_cms(0);
}
Expand Down Expand Up @@ -3486,10 +3513,16 @@ bool QuadPlane::verify_vtol_takeoff(const AP_Mission::Mission_Command &cmd)
/*
a landing detector based on change in altitude over a timeout
*/
bool QuadPlane::land_detector(uint32_t timeout_ms)
bool QuadPlane::land_detector(void)
{
bool might_be_landed = should_relax() && !poscontrol.pilot_correction_active;
const bool relaxed = should_relax();
bool might_be_landed = relaxed && !poscontrol.pilot_correction_active;
if (!might_be_landed) {
if (landing_detect.land_start_ms != 0 && poscontrol.get_state() == QPOS_LAND_FINAL) {
gcs().send_text(MAV_SEVERITY_INFO, "LandDet: abort relax=%d pilot=%d",
(int)relaxed,
(int)poscontrol.pilot_correction_active);
}
landing_detect.land_start_ms = 0;
return false;
}
Expand All @@ -3498,23 +3531,24 @@ bool QuadPlane::land_detector(uint32_t timeout_ms)
if (landing_detect.land_start_ms == 0) {
landing_detect.land_start_ms = now;
landing_detect.vpos_start_m = height;
gcs().send_text(MAV_SEVERITY_INFO, "LandDet: start h=%.2f timeout=%u",
(double)height, (unsigned)landing_detect.timeout_ms);
}

// we only consider the vehicle landed when the motors have been
// at minimum for timeout_ms+1000 and the vertical position estimate has not
// changed by more than 20cm for timeout_ms
if (fabsf(height - landing_detect.vpos_start_m) > landing_detect.detect_alt_change) {
// height has changed, call off landing detection
gcs().send_text(MAV_SEVERITY_INFO, "LandDet: reset dh=%.2f",
(double)fabsf(height - landing_detect.vpos_start_m));
landing_detect.land_start_ms = 0;
return false;
}

if ((now - landing_detect.land_start_ms) < timeout_ms ||
(now - landing_detect.lower_limit_start_ms) < (timeout_ms+1000)) {
// not landed yet
if ((now - landing_detect.land_start_ms) < landing_detect.timeout_ms ||
(now - landing_detect.lower_limit_start_ms) < (landing_detect.timeout_ms+1000)) {
return false;
}

gcs().send_text(MAV_SEVERITY_INFO, "LandDet: done h=%.2f t=%u",
(double)height, (unsigned)(now - landing_detect.land_start_ms));
return true;
}

Expand All @@ -3527,7 +3561,29 @@ bool QuadPlane::check_land_complete(void)
// only apply to final landing phase
return false;
}
if (land_detector(4000)) {
if (!motors->armed()) {
return false;
}
Comment thread
greptile-apps[bot] marked this conversation as resolved.
// ---- disarm watchdog ----
const float wdg_t = landing_detect.wdg_timeout_s.get();
if (wdg_t > 0 && motors->armed() &&
landing_detect.lower_limit_start_ms != 0 &&
landing_detect.wdg_start_ms == 0)
{
landing_detect.wdg_start_ms = AP_HAL::millis();
gcs().send_text(MAV_SEVERITY_INFO,
"DISARM_WDG: timer started, %.0fs to disarm", (double)wdg_t);
}

if (wdg_t > 0 && landing_detect.wdg_start_ms != 0 && motors->armed()) {
const float elapsed = (AP_HAL::millis() - landing_detect.wdg_start_ms) * 0.001;
if (elapsed >= wdg_t) {
gcs().send_text(MAV_SEVERITY_EMERGENCY,
"DISARM_WDG: ARMED %.0fs AFTER LANDING! DISARM NOW", (double)elapsed);
landing_detect.wdg_start_ms = AP_HAL::millis();
}
}
if (land_detector()) {
poscontrol.set_state(QPOS_LAND_COMPLETE);
gcs().send_text(MAV_SEVERITY_INFO,"Land complete");

Expand Down Expand Up @@ -3571,7 +3627,7 @@ bool QuadPlane::check_land_final(void)
also apply landing detector, in case we have landed in descent
Comment thread
vigneshm-debug marked this conversation as resolved.
phase. Use a longer threshold
*/
return land_detector(6000);
return land_detector();
}

/*
Expand Down Expand Up @@ -3866,8 +3922,7 @@ float QuadPlane::forward_throttle_pct()
get weathervaning yaw rate in cd/s
*/
float QuadPlane::get_weathervane_yaw_rate_cds(void)
{
/*
{ /*
we only do weathervaning in modes where we are doing VTOL
position control.
*/
Expand All @@ -3879,7 +3934,8 @@ float QuadPlane::get_weathervane_yaw_rate_cds(void)
plane.control_mode == &plane.mode_qautotune ||
#endif
plane.control_mode == &plane.mode_qhover ||
should_relax()
should_relax() ||
landing_detect.wdg_start_ms != 0
) {
// Ensure the weathervane controller is reset to prevent weathervaning from happening outside of the timer
weathervane->reset();
Expand Down Expand Up @@ -4249,6 +4305,12 @@ bool QuadPlane::in_vtol_airbrake(void) const
return false;
}

//Check if tailsitter is in vtol transition
bool QuadPlane::tailsitter_in_vtol_transition()
{
return tailsitter.in_vtol_transition();
}

// return true if we should show VTOL view
bool QuadPlane::show_vtol_view() const
{
Expand Down
11 changes: 9 additions & 2 deletions ArduPlane/quadplane.h
Original file line number Diff line number Diff line change
Expand Up @@ -192,7 +192,7 @@ class QuadPlane
// Get pilot throttle input with deadzone, this will return 50% throttle in failsafe!
float get_throttle_input() const;

void Log_Write_AttRate();
bool tailsitter_in_vtol_transition();

private:
AP_AHRS &ahrs;
Expand Down Expand Up @@ -275,7 +275,7 @@ class QuadPlane
void relax_attitude_control();

bool check_land_complete(void);
bool land_detector(uint32_t timeout_ms);
bool land_detector(void);
bool check_land_final(void);

float assist_climb_rate_cms(void) const;
Expand All @@ -286,6 +286,7 @@ class QuadPlane
bool should_relax(void);
void motors_output(bool run_rate_controller = true);
void Log_Write_QControl_Tuning();
void Log_Write_AttRate();
void log_QPOS(void);
float landing_descent_rate_cms(float height_above_ground);

Expand Down Expand Up @@ -492,6 +493,10 @@ class QuadPlane

// landing detection threshold in meters
AP_Float detect_alt_change;
AP_Float timeout_ms;

AP_Float wdg_timeout_s;
uint32_t wdg_start_ms;
} landing_detect;

// throttle mix acceleration filter
Expand Down Expand Up @@ -742,6 +747,8 @@ class QuadPlane

public:
void motor_test_output();
AC_AttitudeControl_Multi *get_attitude_control() { return attitude_control; }
AP_AHRS_View *get_ahrs_view() { return ahrs_view; }
MAV_RESULT mavlink_motor_test_start(mavlink_channel_t chan, uint8_t motor_seq, uint8_t throttle_type,
uint16_t throttle_value, float timeout_sec,
uint8_t motor_count);
Expand Down
23 changes: 10 additions & 13 deletions ArduPlane/tailsitter.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -521,7 +521,7 @@ void Tailsitter::output(void)
tilt_left = 0.0f;
tilt_right = 0.0f;
float pitch_cd = 0.0f, weathervane_gain = 0.0f, gain_slope = 0.0f;

float extra_elevator = 0.0f;
float pitch_rate_effort = 0.0f, control_effort_gain_slope = 0.0f;

if (vectored_hover_gain > 0) {
Expand All @@ -537,7 +537,6 @@ void Tailsitter::output(void)
int32_t pitch_error_cd = (des_pitch_cd - quadplane.ahrs_view->pitch_sensor) * 0.5;
float extra_pitch = constrain_float(pitch_error_cd, -SERVO_MAX, SERVO_MAX) / SERVO_MAX;
float extra_sign = extra_pitch > 0?1:-1;
float extra_elevator = 0;
if (!is_zero(extra_pitch) && quadplane.in_vtol_mode()) {
extra_elevator = extra_sign * powf(fabsf(extra_pitch), vectored_hover_power) * SERVO_MAX;
}
Expand Down Expand Up @@ -586,16 +585,16 @@ void Tailsitter::output(void)
quadplane.attitude_control->get_tilt_motor_angle((constrain_float(tilt_left, -4500.0f, 4500.0f) + constrain_float(tilt_right, -4500.0f, 4500.0f)) / 2.0f);
SRV_Channels::set_output_scaled(SRV_Channel::k_tiltMotorLeft, tilt_left);
SRV_Channels::set_output_scaled(SRV_Channel::k_tiltMotorRight, tilt_right);

#if HAL_LOGGING_ENABLED
float position_pitch_sp = quadplane.pos_control->get_pitch_cd();
// Add logging for desired thrust vectoring angles
AP::logger().WriteStreaming("PHID", "TimeUS,DesL,DesR,AhrsPitch,WVGain,WVGainS",
"sddd--", // seconds, degrees
"F00000", // micro (1e-6), no mult (1e0)
"Qfffff", // uint64_t, float
AP_HAL::micros64(), tilt_left/100, tilt_right/100,pitch_cd/100,weathervane_gain,gain_slope);
#endif

#if HAL_LOGGING_ENABLED
AP::logger().WriteStreaming("PHID", "TimeUS,DesL,DesR,AhrsPit,WVGain,VHPwEe,PosPit",
"sddd--d",
"F000000",
"Qffffff",
AP_HAL::micros64(), tilt_left/100, tilt_right/100, pitch_cd/100,
weathervane_gain, extra_elevator/100, position_pitch_sp/100);
#endif
// Check for saturated limits
bool tilt_lim = _is_vectored && ((fabsf(SRV_Channels::get_output_scaled(SRV_Channel::Aux_servo_function_t::k_tiltMotorLeft)) >= SERVO_MAX) || (fabsf(SRV_Channels::get_output_scaled(SRV_Channel::Aux_servo_function_t::k_tiltMotorRight)) >= SERVO_MAX));
bool roll_lim = _have_rudder && (fabsf(SRV_Channels::get_output_scaled(SRV_Channel::Aux_servo_function_t::k_rudder)) >= SERVO_MAX);
Expand Down Expand Up @@ -1061,8 +1060,6 @@ void Tailsitter_Transition::VTOL_update()
if (!quadplane.tailsitter.transition_vtol_complete()) {
return;
}
// To inform the attitude controller that VTOL_DONE
quadplane.attitude_control->set_tailsitter_back_transition_done(true);
// transition to VTOL complete, if armed set vtol rate limit starting point
if (plane.arming.is_armed_and_safety_off()) {
vtol_limit_start_ms = now;
Expand Down
2 changes: 1 addition & 1 deletion ArduPlane/version.h
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@

#include "ap_version.h"

#define THISFIRMWARE "Airbound ArduPlane V4.6.3.1 - rc7"
#define THISFIRMWARE "AB ArduPlane V4.6.3.1 - rc9_lte_fix"

// the following line is parsed by the autotest scripts
#define FIRMWARE_VERSION 4,6,3,FIRMWARE_VERSION_TYPE_DEV
Expand Down
Loading
Loading