Accessing real-time MAVLink messages via pymavlink

Hi @toosat, welcome to the forum :slight_smile:

The Pixhawk will send a small set of vital messages by default, but other messages you’re interested in need to be requested. QGC requests a large set of messages automatically, whereas if you’re connecting directly to the Pixhawk with Pymavlink you’ll need to request those messages yourself. You can request a message to be sent regularly using MAV_CMD_SET_MESSAGE_INTERVAL, which we have a Pymavlink example for here :slight_smile:

There’s an alternative implementation here, as part of a broader full program example of controlling a vehicle (requires Python >= 3.8). The code is a bit more involved, but as a result it should be easier/simpler to use.

1 Like