Table of Contents

Class MavlinkDialect

Namespace
Pamoja.Mavlink
Assembly
Pamoja.Mavlink.dll

The CRC_EXTRA seeds of a dialect beyond the common one.

public sealed class MavlinkDialect : IDisposable
Inheritance
MavlinkDialect
Implements
Inherited Members

A receiver must know a message's CRC_EXTRA before it can check the frame carrying it. Entries added here are consulted before the built-in common-dialect registry, so a private dialect may also override an id the common one defines.

Constructors

Creates an empty dialect table.

public MavlinkDialect()

Methods

Adds or replaces the seed for a message id.

public void Add(uint msgid, byte crcExtra)

Parameters

msgid uint

The message id.

crcExtra byte

The seed.

Adds a message by its definition, deriving the seed.

public byte AddMessage(uint msgid, string name, IReadOnlyList<MavlinkField> fields)

Parameters

msgid uint

The message id.

name string

The message name.

fields IReadOnlyList<MavlinkField>

The base fields in wire order.

Returns

byte

The seed that was derived and added.

This is the whole path for a vendor dialect: describe the message once, and every frame carrying it checks from then on.

Adds a message shape, so frames carrying it check.

public void AddSchema(MavlinkSchema schema)

Parameters

schema MavlinkSchema

The shape whose id and seed to add.

This is the whole path for a dialect described field by field: build the shape once, register it, and every frame carrying that message checks from then on.

Returns the seed this dialect resolves a message id to.

public byte? CrcExtra(uint msgid)

Parameters

msgid uint

The message id to look up.

Returns

byte?

The seed, or null if neither this table nor the common dialect knows the id.

Performs application-defined tasks associated with freeing, releasing, or resetting unmanaged resources.

public void Dispose()