Paparazzi UAS  v5.18.0_stable
Paparazzi is a free software Unmanned Aircraft System.
mateksys_3901_l0x.h File Reference

Driver for the mateksys_3901_l0x sensor via MSP protocol output. More...

#include "std.h"
#include "stdbool.h"
+ Include dependency graph for mateksys_3901_l0x.h:
+ This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Data Structures

struct  Mateksys3901l0X
 

Macros

#define MSP2_IS_SENSOR_MESSAGE(x)   ((x) >= 0x1F00 && (x) <= 0x1FFF)
 
#define MSP2_SENSOR_RANGEFINDER   0x1F01
 
#define MSP2_SENSOR_OPTIC_FLOW   0x1F02
 

Enumerations

enum  Mateksys3901l0XParseStatus {
  MATEKSYS_3901_L0X_INITIALIZE, MATEKSYS_3901_L0X_PARSE_HEAD, MATEKSYS_3901_L0X_PARSE_HEAD2, MATEKSYS_3901_L0X_PARSE_DIRECTION,
  MATEKSYS_3901_L0X_PARSE_LENGTH, MATEKSYS_3901_L0X_PARSE_FUNCTION_ID_B1, MATEKSYS_3901_L0X_PARSE_FUNCTION_ID_B2, MATEKSYS_3901_L0X_PARSE_SIZE,
  MATEKSYS_3901_L0X_PARSE_POINTER, MATEKSYS_3901_L0X_PARSE_DISTANCEQUALITY, MATEKSYS_3901_L0X_PARSE_DISTANCE_B1, MATEKSYS_3901_L0X_PARSE_DISTANCE_B2,
  MATEKSYS_3901_L0X_PARSE_DISTANCE_B3, MATEKSYS_3901_L0X_PARSE_DISTANCE_B4, MATEKSYS_3901_L0X_PARSE_MOTIONQUALITY, MATEKSYS_3901_L0X_PARSE_MOTIONY_B1,
  MATEKSYS_3901_L0X_PARSE_MOTIONY_B2, MATEKSYS_3901_L0X_PARSE_MOTIONY_B3, MATEKSYS_3901_L0X_PARSE_MOTIONY_B4, MATEKSYS_3901_L0X_PARSE_MOTIONX_B1,
  MATEKSYS_3901_L0X_PARSE_MOTIONX_B2, MATEKSYS_3901_L0X_PARSE_MOTIONX_B3, MATEKSYS_3901_L0X_PARSE_MOTIONX_B4, MATEKSYS_3901_L0X_PARSE_CHECKSUM
}
 

Functions

void mateksys3901l0x_init (void)
 Initialization function. More...
 
void mateksys3901l0x_event (void)
 Receive bytes from the UART port and parse them. More...
 
void mateksys3901l0x_downlink (void)
 

Variables

struct Mateksys3901l0X mateksys3901l0x
 

Detailed Description

Driver for the mateksys_3901_l0x sensor via MSP protocol output.

Driver for the mateksys_3901_l0x sensor via MSPx protocol output.

Definition in file mateksys_3901_l0x.h.


Data Structure Documentation

◆ Mateksys3901l0X

struct Mateksys3901l0X

Definition at line 74 of file mateksys_3901_l0x.h.

+ Collaboration diagram for Mateksys3901l0X:
Data Fields
struct link_device * device
float distance_clean
int32_t distancemm
uint8_t distancemm_quality
uint8_t motion_quality
int32_t motionX
int32_t motionX_clean
int32_t motionY
int32_t motionY_clean
uint8_t parse_crc
enum Mateksys3901l0XParseStatus parse_status
uint8_t sensor_id
float time_sec
float velocityX
float velocityY

Macro Definition Documentation

◆ MSP2_IS_SENSOR_MESSAGE

#define MSP2_IS_SENSOR_MESSAGE (   x)    ((x) >= 0x1F00 && (x) <= 0x1FFF)

Definition at line 42 of file mateksys_3901_l0x.h.

◆ MSP2_SENSOR_OPTIC_FLOW

#define MSP2_SENSOR_OPTIC_FLOW   0x1F02

Definition at line 45 of file mateksys_3901_l0x.h.

◆ MSP2_SENSOR_RANGEFINDER

#define MSP2_SENSOR_RANGEFINDER   0x1F01

Definition at line 44 of file mateksys_3901_l0x.h.

Enumeration Type Documentation

◆ Mateksys3901l0XParseStatus

Enumerator
MATEKSYS_3901_L0X_INITIALIZE 
MATEKSYS_3901_L0X_PARSE_HEAD 
MATEKSYS_3901_L0X_PARSE_HEAD2 
MATEKSYS_3901_L0X_PARSE_DIRECTION 
MATEKSYS_3901_L0X_PARSE_LENGTH 
MATEKSYS_3901_L0X_PARSE_FUNCTION_ID_B1 
MATEKSYS_3901_L0X_PARSE_FUNCTION_ID_B2 
MATEKSYS_3901_L0X_PARSE_SIZE 
MATEKSYS_3901_L0X_PARSE_POINTER 
MATEKSYS_3901_L0X_PARSE_DISTANCEQUALITY 
MATEKSYS_3901_L0X_PARSE_DISTANCE_B1 
MATEKSYS_3901_L0X_PARSE_DISTANCE_B2 
MATEKSYS_3901_L0X_PARSE_DISTANCE_B3 
MATEKSYS_3901_L0X_PARSE_DISTANCE_B4 
MATEKSYS_3901_L0X_PARSE_MOTIONQUALITY 
MATEKSYS_3901_L0X_PARSE_MOTIONY_B1 
MATEKSYS_3901_L0X_PARSE_MOTIONY_B2 
MATEKSYS_3901_L0X_PARSE_MOTIONY_B3 
MATEKSYS_3901_L0X_PARSE_MOTIONY_B4 
MATEKSYS_3901_L0X_PARSE_MOTIONX_B1 
MATEKSYS_3901_L0X_PARSE_MOTIONX_B2 
MATEKSYS_3901_L0X_PARSE_MOTIONX_B3 
MATEKSYS_3901_L0X_PARSE_MOTIONX_B4 
MATEKSYS_3901_L0X_PARSE_CHECKSUM 

Definition at line 47 of file mateksys_3901_l0x.h.

Function Documentation

◆ mateksys3901l0x_downlink()

void mateksys3901l0x_downlink ( void  )

◆ mateksys3901l0x_event()

void mateksys3901l0x_event ( void  )

Receive bytes from the UART port and parse them.

Definition at line 111 of file mateksys_3901_l0x.c.

References Mateksys3901l0X::device, mateksys3901l0x, mateksys3901l0x_parse(), MATEKSYS_3901_L0X_INITIALIZE, and Mateksys3901l0X::parse_status.

+ Here is the call graph for this function:

◆ mateksys3901l0x_init()

Variable Documentation

◆ mateksys3901l0x