Professional Documents
Culture Documents
Abstract—This paper details the development history and III. A IR -S IDE H ARDWARE
technical progress made by the University of North Dakota’s
joint computer science and electrical engineering senior de-
sign team #5. This team has been working with the Northern The hardware for the airside module is selected directly
Plains UAS Test Site to develop a small self-contained device in support of the requirements for the project. At its very
with a built-in GNSS receiver, radio, and logging hardware
core, the goal of the project is to provide a tracking mod-
to enable the test site to track a number of unmanned air-
craft remotely. The system must support multiple aircraft, ule for a small UAS. As the final design product will be
and streaming data in (near-)real-time to other networked placed on an aircraft, the goal should be to meet all the re-
equipment on the ground. quirements generated for the hardware, maximize the time
the module can stay on with one battery, and minimize the
overall mass of the final module.
I. I NDIVIDUAL & T EAM C ONTRIBUTION
There are a limited number of options available for
tracking over distance in general, and not all technologies
The following table shows the members of the team, compare evenly when it comes to accuracy and accessi-
and the section(s) of this document they were responsible bility. In this case, the main tracking capabilities of the
for. The actual work performed follows the information airside tracking system will be powered by a GPS receiver.
given in those sections. Given the accessibility of the hardware, specifications, and
integration instructions, the chosen GPS module for the
Bryce Gruber Air-side Hardware air unit design was the NEO-M9N chipset by the com-
Ground-side Hardware pany u-blox. This module can act as a receiver for up to
Michael Turnbull Embedded/Air-side Software 4 concurrent satellites at a single time with autonomous
Casey Martin Computer ground station S/W tracking for up to 5 minutes and horizontal position accu-
Mason Reck Computer ground station S/W racy within 2 meters. Overall, this chip provides location
Andrew Misiani Extended ground side S/W data to a degree that is encouraging for data collection,
as will be seen in the circumstance of the Northern Plain
UAS Test Site.
II. P ROBLEM S TATEMENT & R EQUIREMENTS
Another important measurement is the altitude at which
The problem at hand is one of data organization. The the aircraft is operating. For this reason, a barometer is
test site flies many different types of aircraft, each using included in the air module design. The BMP390 was cho-
their own telemetry system and are largely incompatible sen for a few reasons. The first and most significant is the
with each other. Therefore, no central real-time bank of accuracy that it brings to the mission at its price point. Ad-
information on the locations of every currently in-flight ditionally, another major benefit is the form factor that the
aircraft is available, making test coordination and safety integrated circuit is packed into. With only a 2-millimeter
much more difficult. The test site, therefore, requested that by 2-millimeter footprint, this device can essentially be
a small device that can be affixed to an aircraft be devel- invisible on a printed circuit board. The accuracy of this
oped and produced in enough quantity to equip their entire device is within 0.25 meters.
simultaneously-airborne fleet. The device will act entirely
independently of the aircraft avionics and power system; All of the data generated by the specialized chips would
determining its location through a self-contained GNSS be useless without a central processor to format the data
receiver, logging to a microSD card, and relaying data to into a single message readable by either machine or a hu-
the ground segment over a separate radio link. man. Originally, the alternate proposal for the project was
2
The user interface was one of the requested upgrades It is estimated that, while powered over a 18650 lithium-
that the design team was tasked with while most of the ion battery would be capable of providing power to the air
other upgrades to the devices were optional. On the current unit for an estimated hour and a half to two hours. These
model that is being used as a UAS tracker, operators are calculations were performed by taking the estimated max
unsure of several different states that the tracking device current draw from each of the ICs and comparing again
may be in. In this case, controllable LEDs will be used to the current hours of the battery. Although this may seem
indicate different statuses. Unlike most of the previously like a relatively short period, this amount of time is likely
mentioned modules, a simple High/Low signal will be long enough to endure the typical length of the flight of
used to turn on and off the LEDs as seen fit. In addition to the UAS used by the Northern Plains Test Site.
LEDs, a microSD card is added to quickly swap storage in
each device. The previous process included downloading
the data stored in the onboard flash data. This microSD IV. A IR -S IDE S OFTWARE
card solution allows the module to quickly switch data
storage instead of waiting to download and erase the previ-
The software running on the air segment is a custom
ous data. The read and write action between the microSD
development for the hardware selected for the project.
card and the ESP32-S3-WROOM can occur over SDA or
As previously discussed, the hardware is based around
MMC.
an ESP32-S3, which runs a real-time operating system
called FreeRTOS. The toolchain used is open-source and
Figure 1 shows the general data flow between all of the
distributed by Espressif, called ESP-IDF, and features a
main components on air side module.
cross-compiler, a multitude of static libraries and plat-
Nearly all of the components will need to be powered form drivers, flashing utility, and debugger. ESP-IDF al-
by a 5- or 3.3-volt source. Different power solutions may lows for making an extremely complex compilation pro-
cess (involving compilation of more than 800 C source
3
files) trivially easy and automatically handles static linkage • OLOGUSD: log to microSD card
between necessary components. It also provides access to
on-chip debugging capabilities, vastly improving the abil- As mentioned previously, all of these tasks reference a
ity to troubleshoot software issues with direct access to single shared data segment in memory intended to provide
memory and CPU registers. a single, undisputed source of truth information. Each task
only puts the most recent information it has into the shared
The primary compilation unit of an ESP-IDF project memory, and when a task reads from the shared truth data,
is a “component.” A component is analogous to a li- it always gets the most up-to-date information. This truth
brary, though often integrates with other components and data has been broken into several data structures, each one
must therefore be compiled in a certain order to allow protected by a mutual exclusion device (mutex), based on
for ESP-IDF to link it (which is always done statically). data access patterns. The access patterns mentioned are
The entire system uses the Kconfig language and menu to given in table I.
allow for ease of changing one value even across multiple
components; though the menu definition may only live in It should be noted that some of the tasks shown in this
one place, the #define-level option is available across the table do not appear to read or write any data. Those tasks
entire project. In this project, several components are de- (namely some of the LED indicator tasks) read the status
fined – generally, one for each type of task that must be of other tasks directly from the FreeRTOS kernel using
performed. builtin status checking functions, and act based on the in-
formation obtained from that source. As an example, the
Ten tasks are used in this project total to perform the indicator that shows whether the data broadcast is running
necessary functions described in the [REF] requirements or not will illuminate if and only if the ONRMLMAVH
section. There are ten overall tasks, each one performing task is not suspended or deleted; it can check this without
a function that runs the same task for a long duration. having to lock any of the shared truth data mutexes.
Generally, each task is implemented in its own component,
but tasks that perform similar functions (such as the four
LED indicators) are housed in one component for that V. G ROUND -S IDE H ARDWARE
group. This is the case for the LED indicators and the
MAVLink message output, which uses separate tasks for
The hardware used on the ground consists of two main
high- and low-rate periodic messages.
components, the receiving RFD900x, and the operator’s
computer. The telemetry network received can send data
At a general level, the order of tasks performed by the
through the serial protocol over USB to the operator’s
air segment software is as follows. After boot and ap-
computer for analysis. This connection will be through an
plication entry (handled by the ESP32-S3 bootloader and
FTDI cable.
FreeRTOS kernel), the module first allocates space for a
shared data segment that will be shared between all tasks.
The basic data flow can be shown in figure 2.
It then reads a static configuration file stored in SPI flash
memory for some necessary data points. Then, it sequen-
tially starts all the long-run tasks by calling the publicly
exposed functions from each of the components. Finally,
the main application entry point actually terminates, as it
is no longer needed.
E
ST
H
L
M
AV
AV
SS
O
BC
LO
SD
H
N
LM
LM
CH
G
X
PW
SD
U
EA
FI
IS
RO
RM
RM
G
AT
IS
IS
IS
IS
LO
M
PW
N
OV
OV
OV
OV
IN
IB
Data
O
Aircraft Latitude W R R R R
Aircraft Longitude W R R R R
GNSS HDOP W R R R R R
Aircraft course W R R R
Horizontal speed W R R R R
Horizontal accuracy W R R R R
Speed accuracy W R R
Altitude (MSL) R R W R R
Altitude (relative) R R W R R
Vertical speed R R W R R
Vertical accuracy W
Absolute pressure R R W
Outside air temp. R W
Home latitude R W
Home longitude R W
Home altitude R W
NMEA sentence hist. W
Time at takeoff R R W
Airborne status R R W
TABLE I: Read-write analysis of each task to determine data structure groupings. An ‘R’ denotes that the task will
read that data; a ‘W’ for writing. Groups of data bundled into structures are shown with horizontal lines.
development, the design for a more advanced ground sta- VI. G ROUND -S IDE S OFTWARE
tion mimics the air unit to a degree. This allows for the
re-use of custom drivers developed for the air unit.
The ground station software takes in MAVLink data
The upgraded ground station would consist of two more from a standard USB receiver. It reads and displays the
additional modules, a NEO-M92 and BMP390 would be data to the UAS operator before redirecting that data to a
added to give the location and relative altitude of the specified server for use. The ground station uses a map to
ground station. Unlike the air module, data would be flow- show UAS location and allows the operator to configure
ing inward instead of outward. With all of this data to man- where the data is redirected. As a backup the ground sta-
age, another ESP32 would be used to control and package tion also creates logs of the data in case the SD-card on
the data before forwarding it onto the ground station. the module malfunctions.
Figure 3 shows the data flow of a future iteration of the The technology stack used to implement the ground sta-
ground station. tion is Python and Qt. It uses the pymavlink library to
process MAVLink data. Licensed under (L)GPL V.3 and
used by many other UAS projects and ground stations,
it allows us to ensure all reading and processing of data
is standard compliant. The GUI is written in QML(Qt)
and uses the PySide2 library allowing the back end to use
Python instead of C++ like normal Qt based applications.
Both QML and Python are interpreted languages that al-
low us to quickly make changes without compiling. As
the ground station just reads and redirects data the trade
off in performance is worth it.