The Ardupilot 4.5.6 version is unable to execute waypoint mission yaw operations in GUIDED mode!

“Hello experts, I am facing an issue where MAV_CMD_CONDITION_YAW cannot execute yaw operations, and CONDITION_YAW in the MP ground station flight plan also fails to work. Could anyone provide some guidance or suggestions? Thank you in advance!”
“I am executing tasks indoors using the pose provided by SLAM. The same code and settings work in version 4.1.0, but not in version 4.5.6.”

def condition_yaw(self, yaw):
“”"
设置无人机的相对航向角。

:param yaw: 相对航向角,正数为顺时针,负数为逆时针
"""
if self.connection is not None:
    if yaw != 0:
        direction = 1 if yaw > 0 else -1  # 顺时针旋转或逆时针旋转
        angle = abs(yaw)  # MAVLink命令中只需要角度的绝对值

        # 构建 MAVLink 命令
        msg = self.connection.mav.command_long_encode(
            self.connection.target_system,
            self.connection.target_component,
            mavutil.mavlink.MAV_CMD_CONDITION_YAW,
            0,          # 确认参数
            angle,      # Param 1: 目标航向角(相对旋转角度)
            10,         # Param 2: 旋转速度(度/秒)
            direction,  # Param 3: 旋转方向,1为顺时针,-1为逆时针
            1,          # Param 4: 相对航向角
            0, 0, 0     # Params 5-7: 保留,不使用
        )
        self.write_queue.put(msg)
        logger.info(f"设置相对航向角为 {angle} 度,方向 {'顺时针' if direction == 1 else '逆时针'}")
    else:
        logger.info("无需调整航向角。")
else:
    logger.info("MAVLink连接不可用,无法设置航向角。")