Skip to content

fix(mavlink): accept NAV_TAKEOFF param1 on multicopters#27853

Merged
MaEtUgR merged 1 commit into
PX4:mainfrom
datlt4:main
Jul 14, 2026
Merged

fix(mavlink): accept NAV_TAKEOFF param1 on multicopters#27853
MaEtUgR merged 1 commit into
PX4:mainfrom
datlt4:main

Conversation

@datlt4

@datlt4 datlt4 commented Jul 9, 2026

Copy link
Copy Markdown
Contributor

Strict command-parameter validation added in #27541 rejects MAV_CMD_NAV_TAKEOFF when an unsupported param is set. QGroundControl sends param1 (minimum pitch) = -1 on multicopter takeoff, which is non-zero/non-NaN, so commands were silently denied (MAV_RESULT_DENIED with no log) on MC airframes and QGC guided takeoff stopped working.

Extend the NAV_TAKEOFF override to include VEHICLE_MC so param1 is accepted and ignored on multicopters, matching FW/VTOL handling.

Screenshot from 2026-07-09 15-10-20

Strict command-parameter validation added in PX4#27541 rejects
MAV_CMD_NAV_TAKEOFF when an unsupported param is set. QGroundControl
sends param1 (minimum pitch) = -1 on multicopter takeoff, which is
non-zero/non-NaN, so commands were silently denied (MAV_RESULT_DENIED
with no log) on MC airframes and QGC guided takeoff stopped working.

Extend the NAV_TAKEOFF override to include VEHICLE_MC so param1 is
accepted and ignored on multicopters, matching FW/VTOL handling.
@github-actions github-actions Bot added kind:bug Something is broken or behaving incorrectly. scope:mavlink MAVLink module, streams, commands, or protocol handling. labels Jul 9, 2026
@github-actions

github-actions Bot commented Jul 9, 2026

Copy link
Copy Markdown
Contributor

🔎 FLASH Analysis

px4_fmu-v5x [Total VM Diff: -16 byte (-0 %)]
    FILE SIZE        VM SIZE    
 --------------  -------------- 
  +0.0%     +55  [ = ]       0    .debug_abbrev
  -0.0%      -2  [ = ]       0    .debug_info
  -0.0%      -5  [ = ]       0    .debug_line
    +100%      +2  [ = ]       0    [Unmapped]
    -0.0%      -7  [ = ]       0    [section .debug_line]
  +0.2%     +16  [ = ]       0    [Unmapped]
  -0.0%     -16  -0.0%     -16    .text
    -1.5%      -4  -1.5%      -4    MavlinkStreamAutopilotStateForGimbalDevice::send()
    -5.0%      -4  -5.0%      -4    mavlink_cmd_params::_find_mask()
    -0.0%      -8  -0.0%      -8    [section .text]
  +0.0%     +48  -0.0%     -16    TOTAL

px4_fmu-v6x [Total VM Diff: -16 byte (-0 %)]
    FILE SIZE        VM SIZE    
 --------------  -------------- 
  +0.0%     +55  [ = ]       0    .debug_abbrev
  -0.0%      -2  [ = ]       0    .debug_info
  -0.0%     -13  [ = ]       0    .debug_line
    [DEL]      -6  [ = ]       0    [Unmapped]
    -0.0%      -7  [ = ]       0    [section .debug_line]
  +0.3%     +16  [ = ]       0    [Unmapped]
  -0.0%     -16  -0.0%     -16    .text
    -1.5%      -4  -1.5%      -4    MavlinkStreamAutopilotStateForGimbalDevice::send()
    -5.0%      -4  -5.0%      -4    mavlink_cmd_params::_find_mask()
    -0.0%      -8  -0.0%      -8    [section .text]
  +0.0%     +40  -0.0%     -16    TOTAL

Updated: 2026-07-09T18:09:58

@MaEtUgR

MaEtUgR commented Jul 14, 2026

Copy link
Copy Markdown
Member

@datlt4 Ha, I haven't seen your pull request but we came to a similar conclusion, I just did a few more changes in #27899

I guess we can merge yours as a hotfix while mine gets reviewed.

@MaEtUgR MaEtUgR left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hotfix to have PX4 takeoff usable again with QGC.

@MaEtUgR MaEtUgR merged commit 785ede8 into PX4:main Jul 14, 2026
81 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

kind:bug Something is broken or behaving incorrectly. scope:mavlink MAVLink module, streams, commands, or protocol handling.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants