-
Notifications
You must be signed in to change notification settings - Fork 5.7k
feat(inputs.mavlink): Add plugin #16780
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat(inputs.mavlink): Add plugin #16780
Conversation
d0c0e8b
to
888dad1
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for the update @chrisdalke! Some smaller comments and suggestions...
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@chrisdalke thanks for the update! I have one suggestion to move the whole metric handling into convertFrameToMetric
as this simplifies the code IMO. Other than that, please bring back the "large amout of metrics" warning and check the remaining comments... We are almost there.
plugins/inputs/mavlink/README.md
Outdated
For example, the message | ||
[ATTITUDE](https://mavlink.io/en/messages/common.html#ATTITUDE) will become an | ||
`attitude` metric, with all fields copied from its Mavlink message definition. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please use indirect links!
For example, the message | |
[ATTITUDE](https://mavlink.io/en/messages/common.html#ATTITUDE) will become an | |
`attitude` metric, with all fields copied from its Mavlink message definition. | |
For example, the message [ATTITUDE][attitude] will become an | |
`attitude` metric, with all fields copied from its Mavlink message definition. | |
[attitude]: https://mavlink.io/en/messages/common.html#ATTITUDE |
…to feature/mavlink-input-plugin
…mavlink-input-plugin
@srebhan Updated to address all the comments above! |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@chrisdalke awesome. Just some more formatting things and we are good from my side...
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks a lot @chrisdalke for this nice plugin!
Co-authored-by: Thomas Casteleyn <thomas.casteleyn@me.com>
Download PR build artifacts for linux_amd64.tar.gz, darwin_arm64.tar.gz, and windows_amd64.zip. 📦 Click here to get additional PR build artifactsArtifact URLs |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@chrisdalke Great work!
Sorry for some "off topic noise" now. Can I test this easily within the docker ecosystem? I tried:
Would love to beta test this! |
@booo Thanks for trying this. At the time you had tried it out, the nightly build hadn't succeeded yet. However it looks like now the nightly build is updated and you should be able to try again! If that does not work, try building from source. |
In the end I did build it from source. I created a small Dockerfile and Compose file: https://gitlab.com/searchwing/development/groundstation/antennagroundstation/mavlink-telegraf So far it works quite well! Well done. Looking forward to create some fancy dashboards for our test flights :) |
Thanks for sharing, but by having only two plugins activated, you could build yourself a much smaller binary with only those included. |
Summary
Add a Mavlink input plugin.
The
mavlink
plugin connects to a MavLink-compatible flight controller such as as ArduPilot or PX4. and translates all incoming messages into metrics.The purpose of this plugin is to allow Telegraf to be used to ingest live flight metrics from unmanned systems (drones, planes, boats, etc.)
Telegraf is already often used on flight computers (eg a Raspberry Pi) to collect system metrics for drones and it would be valuable to extend this to also provide a convenient way to record flight telemetry.
Checklist
Related issues
resolves #16220
superseeds #16221