0

mavsdk.action.ActionError: COMMAND_DENIED: 'Command Denied': origin: arm(); param: ()

When I'm landing drone more than one time in a row, and then try to start mission again I get this error. Does anyone knows what happened?

Here is the connection:

    drone = System()
    await drone.connect(system_address="udp://:14540")

Here is the mission item:

    mission_plan = MissionPlan(mission_items)

    await drone.mission.set_return_to_launch_after_mission(True)

    print("-- Uploading mission")
    await drone.mission.upload_mission(mission_plan)

    print("Waiting for drone to have a global position estimate...")
    async for health in drone.telemetry.health():
        if health.is_global_position_ok and health.is_home_position_ok:
            print("-- Global position estimate OK")
            break

    print("-- Arming")
    await drone.action.arm()

    print("-- Starting mission")
    await drone.mission.start_mission()

    await termination_task

Here is the landing code:

await drone.action.land()
DevJava
  • 5
  • 2

0 Answers0