Code Monkey home page Code Monkey logo

go-mavlink1's Introduction

Golang Mavlink1.0

This is a very stable mavlink message parsing library.It doesn't care how your data is transmitted. more see mavlink.io

How to use

go get github.com/mgr9525/go-mavlink1

Begin

mavchan := mavlink1.New()
mavchan.Start(getMsg)
mavchan.Puts(mavData)

getMsg(func): It's a function call when get message

mavData([]byte): It's data stream of mavlink.v1,it could receive from serialport or tcp socket.

More detail see folder test

Output

mav start!
getMsg from:1-1, msgid:6f
replyBytes: fe060001020b080000000101f1da
input any to exit!
getMsg from:1-2, msgid:1e
get ATTITUDE: 05000000000048413333834166669a4166a6a043333367429a99ad41
roll:12.500000,pitch:16.400000,yaw:19.299999
rollspeed:321.299988,pitchspeed:57.799999,yawspeed:21.700001

How to add message

More detail see folder "messages"

Set fly system mode message!!!

Notice the sizeof of the structure,it control with byte and []byte,con't use int32,float32...,see Struct sizeof

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.