Mavlink XML Files

Hello, I don’t understand how to use XML files in Mavlink. I understand that i can define new message and enum. But how to use it ? Where do i need to put the xml file and do the Pixhawk will understand what i want or do i need to send something (i’m very new to xml files) ?

Also, can i define some mavlink command to send when an event happend ? For exemple a camera just plug to the PX4 and this event will send an xml file to the GCS ? Something like this is possible ?

Thank you.

Hello @BenaTipoFilthyYou

you typically use pymavlink to convert the XML files into C, C++, C#, javascript, python, or any of the other supported programing languages

And then use/link that generated code in your code.

No, there is no automated event handling. You need to do it yourself.

and do not confuse PX4 with ArduPilot. Those are two different firmwares, both supporting mavlink.
There is NO PX4 hardware. There are multiple hardwares capable of running PX4 but no hardware named PX4

1 Like