foxTox
foxTox

Reputation: 128

mavROS, SITL ArduPlane: commands in GUIDED mode are rejected

A simple python script publishes commands to the mavros node which is connected to an arduplane SITL instance. Succesfully publishing to change mode from AUTO to GUIDED (so no connection or other issues). After changing, the plane is loitering.

Publishing to the services ~cmd/command or ~cmd/command_int the commands are rejected (return code 3).

Publishing to the topic ~setpoint_raw/global has no effect whatsoever.

The published command is a simple 16 MAV_CMD_NAV_WAYPOINT

The question is: is there any way that I can use any of the topics/services of mavros in order to simply stream waypoints (pairs of global coordinates) for the UAV to follow (in GUIDED or in any other mode).

I think that clearing and continuously uploading a mission in AUTO is not exactly an option since it would delay significantly.

Please note that the solution is intendeed for a fixed wing (aka Plane).

Versions:

ROS: Kinetic

ArduPilot: 3.8.0beta5

The issue has also been raised in mavros and Ardupilot hubs.

Upvotes: 1

Views: 577

Answers (1)

Soubhi M. Hadri
Soubhi M. Hadri

Reputation: 143

Did you try to do that using GCS and it failed too? I also suggest to try dronekit . It is in python and simple to implement and send commands for the vehicle.

Upvotes: 1

Related Questions