Mavros as ground control

Hello,

I am trying to connect gazebo with mavros without a QGroundControl present,
as the moment when I give a command to the aircraft for takeoff,
gazebo just write that its arming the aircraft, preform a takeoff without moving and land.

According to what I have read when gazeboo detects a ground control it will act normal I mean when a command to takeoff will be sent the aircraft will takeoff.

Is there a command that I need to send so that gazebo will recognize me as a ground control ?
Is there a change in the heartbeat message that I need to implement for the recognition to happen ?

Thanks.

  • attached below a screenshot of what I mean when gazebo doesn’t perform takeoff command

image

Can you try to leave MAVROS running, so that it continuously sends heartbeats? That way PX4 thinks that it is connected to a ground station.

Looking at the docs you can set the component_id param but I expect the default (240) to work.

You can also try to prevent the failsafe action by changing the params: