Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

In Fall 2022, the firmware team rebranded to be embedded flight software, and with that change, followed through on the proposed project LOS proposal from summer 2022. We count the changes from the 2022 season as a “2.0” revision, and so we are now working on the ZP 3.0 Architecture!

...

Table of Contents

List of Abbreviations & Links

Abbr.

Full Name

Link

PM

Path Manager

AM

Attitude Manager

TM

Telemetry Manager

LOS

Laminar OS

LOS_Core

Laminar OS Core Library

LOS_Driver

Laminar OS Drivers

LOS_Interface

Laminar OS Interfaces

ZP

Zeropilot as a whole

ZPHW

ZeroPilot Hardware

ZPSW

ZeroPilot Software (3.0)

Nucleo

Nucleo F401, L553, F7

FRTOS

freeRTOS

FSM

Finite State Machine

CV

Computer Vision

EFS

Embedded Flight Software

GS

Ground Station

General Introduction to ZPSW

ZP3-sw follows a structure loosely based off of the work done for the 2022 competition drone “Vanguard”, where more autonomy was given to Attitude Manager, and our codebase was expanded to support both fixed wing and multi rotor aircraft.

Understanding The Drone

The Drone Reference Frame

It’s important to understand the reference frame of the drone when we work between multiple modules. In our case, we have it defined as such:

+X = Forward

+Y = Right

+Z = Up

...

Understanding the Managers

There are a few main components that are independent from each other in design and code. These are:

  • [PM] Path Manager:

...

Path Manager

PM handles path generation and the vast majority of the autopilot function of the aircraft. It communicates with TM and AM using FRTOS MailQueues.

Attitude Manager

AM handles the attitude management of a quadcopter or a fixed wing aircraft, and allows either PM or a teleoperator to control the drone. It communicates with TM and PM, as well as with the user through LOS_Link.

Telemetry Manager

TM will read data from both AM and PM, and produce an output struct that can be sent to ground and CV. This will be done using <insert method>.
TM will also receive data from CV & Groundside, and prepare this for PM & AM.

Common Interface Structs & Methods

AM ↔︎ PM

Code Block
languagecpp
typedef struct CommandsForAM_t{
  WaypointType waypoint_type; 

  // heading unit vector and magnitude
  float heading_dist_x; 
  float heading_dist_y; 
  float heading_dist_z; 
  float heading_magnitude; // Magnitude distance to waypoint target
  double velocity_target; // Target velocity of drone approaching target
} CommandsForAM;

The heading distances form a unit vector with the combined magnitude such that:

The vector in XYZ space has a magnitude of 1.

The heading magnitude is the distance to the target waypoint. (For use in times such as coordinated turns, etc.)

The velocity target is the desired speed for the drone to approach the waypoint (For use notably in takeoff and landing)

AM ↔︎ TM

PM ↔︎ TM

TM ↔︎ CV

TM ↔︎ GS