Trying to run the px4 SITL with Gazebo as per the instructions here: https://dev.px4.io/en/simulation/gazebo.html. Running
make posix_sitl_default gazebo
starts the Gazebo and the px4 fine. In adddition, I have MAVROS running and connected to the px4.However, running
Failsafe enabled: no datalink warning and the drone lands at home. I understand that you need some form of communication link but I thought having MAVROS connected and running would take care of this. Incidentally, this may or may not be related but I get a timeout if I try to set the controller in offboard mode by using
rosrun mavros mavsys mode -c offboard
Unexpected command 176, result 1. Does anybody know what could be wrong? B.t.w. if I start the simulator with the optical flow model i.e.
make posix gazebo_iris_opt_flow
I can take off and hover, but still cannot set the controller to offboard mode.