Paparazzi UAS v7.1_unstable
Paparazzi is a free software Unmanned Aircraft System.
Loading...
Searching...
No Matches
mavlink.h File Reference

Basic MAVLink datalink implementation. More...

#include <mavlink/mavlink_types.h>
#include "mcu_periph/uart.h"
#include <stdio.h>
Include dependency graph for mavlink.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Macros

#define MAVLINK_USE_CONVENIENCE_FUNCTIONS
#define MAVLINK_ALIGNED_FIELDS   0
#define MAVLINK_DEBUG(...)
#define MAVLINK_DEV   uart1
#define MAVLinkDev   (&(MAVLINK_DEV).device)
#define MAVLinkTransmit(c)
#define MAVLinkChAvailable()
#define MAVLinkGetch()
#define MAVLinkSendMessage()

Functions

void mavlink_init (void)
 Module functions.
void mavlink_periodic (void)
 Periodic MAVLink calls.
void mavlink_periodic_telemetry (void)
 Send periodic mavlink messages as defined in Mavlink process of telemetry xml file.
void mavlink_event (void)
 Event MAVLink calls.
static void comm_send_ch (mavlink_channel_t chan, uint8_t ch)
 Send one char (uint8_t) over a comm channel.

Variables

mavlink_system_t mavlink_system

Detailed Description

Basic MAVLink datalink implementation.

Definition in file mavlink.h.

Macro Definition Documentation

◆ MAVLINK_ALIGNED_FIELDS

#define MAVLINK_ALIGNED_FIELDS   0

Definition at line 31 of file mavlink.h.

◆ MAVLINK_DEBUG

◆ MAVLINK_DEV

#define MAVLINK_DEV   uart1

Definition at line 57 of file mavlink.h.

◆ MAVLINK_USE_CONVENIENCE_FUNCTIONS

#define MAVLINK_USE_CONVENIENCE_FUNCTIONS

Definition at line 30 of file mavlink.h.

◆ MAVLinkChAvailable

#define MAVLinkChAvailable ( )
Value:
MAVLinkDev->char_available(MAVLinkDev->periph)

Definition at line 65 of file mavlink.h.

Referenced by jevois_mavlink_event(), and mavlink_event().

◆ MAVLinkDev

#define MAVLinkDev   (&(MAVLINK_DEV).device)

Definition at line 63 of file mavlink.h.

◆ MAVLinkGetch

#define MAVLinkGetch ( )
Value:
MAVLinkDev->get_byte(MAVLinkDev->periph)

Definition at line 66 of file mavlink.h.

Referenced by jevois_mavlink_event(), and mavlink_event().

◆ MAVLinkSendMessage

◆ MAVLinkTransmit

#define MAVLinkTransmit ( c)
Value:
MAVLinkDev->put_byte(MAVLinkDev->periph, 0, c)

Definition at line 64 of file mavlink.h.

Referenced by comm_send_ch().

Function Documentation

◆ comm_send_ch()

void comm_send_ch ( mavlink_channel_t chan,
uint8_t ch )
inlinestatic

Send one char (uint8_t) over a comm channel.

Parameters
chanMAVLink channel to use, usually MAVLINK_COMM_0 = UART0
chCharacter to send

Definition at line 83 of file mavlink.h.

References MAVLinkTransmit.

◆ mavlink_event()

void mavlink_event ( void )

Event MAVLink calls.

Definition at line 217 of file mavlink.c.

References mavlink_common_message_handler(), mavlink_mission_message_handler(), MAVLinkChAvailable, MAVLinkGetch, and status.

Here is the call graph for this function:

◆ mavlink_init()

◆ mavlink_periodic()

◆ mavlink_periodic_telemetry()

void mavlink_periodic_telemetry ( void )

Send periodic mavlink messages as defined in Mavlink process of telemetry xml file.

Called at TELEMETRY_FREQUENCY

Definition at line 150 of file mavlink.c.

Variable Documentation

◆ mavlink_system

mavlink_system_t mavlink_system
extern

Definition at line 74 of file mavlink.c.