From 0b55cbd9b98420f3f2a2b9cfd8d384824c9fd4dc Mon Sep 17 00:00:00 2001 From: lonkaars Date: Fri, 19 May 2023 16:06:40 +0200 Subject: protocol specs --- doc/dui.md | 93 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++-- 1 file changed, 91 insertions(+), 2 deletions(-) diff --git a/doc/dui.md b/doc/dui.md index ede73c8..65f242d 100644 --- a/doc/dui.md +++ b/doc/dui.md @@ -17,6 +17,95 @@ The following is the original project description (translated to English): # Architecture +## Nicla/Zumo communication protocol + +The communication protocol used to control the Zumo from the Nicla uses UART to +send ranged numbers in a single byte. Figure \ref{tab:protocol-ranges} shows +which number ranges correspond to which controls. + +\begin{figure}[h] +\centering +\begin{tabular}{rl} +\toprule +\textbf{Description} & \textbf{Range (inclusive)}\\ +\midrule +(unused) & \texttt{0x00}\\ +Signs & \texttt{0x01} - \texttt{0x0f}\\ +Speed & \texttt{0x10} - \texttt{0x1f}\\ +Steering & \texttt{0x20} - \texttt{0xff}\\ +\bottomrule +\end{tabular} +\caption{Protocol command ranges} +\label{tab:protocol-ranges} +\end{figure} + +### Signs + +The Zumo stores the last sign received, and displays it's name on the OLED +display using the lookup table in figure \ref{tab:protocol-signs}. The sign ID +is calculated by subtracting the start offset of the sign command range from +the command as shown in figure \ref{tab:protocol-ranges}. + +\begin{figure}[h] +\centering +\begin{tabular}{ll} +\toprule +\textbf{ID} & \textbf{Name}\\ +\midrule +\texttt{0x00} & (clear sign)\\ +\texttt{0x01} & Stop sign\\ +\texttt{0x02} & Turn left\\ +\texttt{0x03} & Turn right\\ +\texttt{0x04} & Low speed limit\\ +\texttt{0x05} & High speed limit\\ +\texttt{0x06} & Traffic light (red)\\ +\texttt{0x07} & Traffic light (orange)\\ +\texttt{0x08} & Traffic light (green)\\ +\bottomrule +\end{tabular} +\caption{Sign lookup table} +\label{tab:protocol-signs} +\end{figure} + +### Speed + +The speed value ranges from \num{0} to \num{1}, and is converted from the +command using the following formula: + +$$ v(n) = \frac{n - 16}{15} $$ + +### Steering + +The steering value is similar to the speed value, but ranges from \num{-1} +(left) to \num{1} (right). The zumo has a built in "influence" value, which +limits the smallest radius the robot can turn at. The steering value is +converted using the following formula: + +$$ s(n) = \frac{n - 32}{223}\cdot2-1 $$ + +## Zumo internal motor control functions + +The Zumo robot receives a speed and steering value. Because the protocol has a +limited precision due to the low amount of data sent, the following formula is +used to control motor speeds $M_1$ and $M_2$ from steering value $s$ and speed +value $v$. The constant $C_1$ is used to globally limit the speed the robot can +drive at. $C_2$ represents the amount of influence the steering value has on +the corner radius, where \num{0} is no steering at all and \num{1} completely +turns of one motor when steering fully left or right: + +$$ M_{1,2} = \frac{v(\pm s C_2 - C_2 + 2)}{2} C_1 $$ + +By default, $C_1 = \num{96}$ and $C_2 = \num{0.6}$ + +The Zumo firmware also smooths incoming values for $s$ and $v$ using a PID +controller. The default constants for the PID controller used are: + +\begin{align*} +K_p &= -0.02\\ +K_i &= +0.13\\ +K_d &= -300.0 +\end{align*} + # Research ## Communication between the Nicla and Zumo @@ -75,7 +164,7 @@ values without interpolation would lead to a garbage-in-garbage-out system. The simplest solution to motion blur is limiting the maximum speed the Zumo robot can drive at, which is the solution we're going to use as speed is not one of the criteria of the complete system\footnote{Problem statement -(\ref{problem-statement})}. +(section \ref{problem-statement})}. In the case the Nicla module crashes or fails to detect the road or roadsigns, it will stop sending commands. If the Zumo robot would naively continue at it's @@ -86,7 +175,7 @@ module is able to process at about 10 frames per second, so 2 seconds is a reasonable time-out period. \def\communicationConclusion{ -The complete protocol will consist of single byte commands. A byte can either +The complete protocol consists of single byte commands. A byte can either change the cart speed or steering direction, both will apply gradually. When no commands have been received for more than 2 seconds, the Zumo robot will gradually slow down until it is stopped. Exact specifications of commands are -- cgit v1.2.3 From 4d1d629ab7a3bd9d661ec5ed25fcf0b4837b946d Mon Sep 17 00:00:00 2001 From: lonkaars Date: Sun, 21 May 2023 14:05:59 +0200 Subject: more documentation --- assets/.gitignore | 1 + assets/architecture-level-0.pdf | Bin 0 -> 6094 bytes assets/figs.drawio | 47 ++++++++++++++ doc/.gitignore | 2 + doc/base.tex | 24 +++++-- doc/dui.md | 136 +++++++++++++++++++++++++++++++++++----- doc/makefile | 8 +-- doc/refs.bib | 0 8 files changed, 192 insertions(+), 26 deletions(-) create mode 100644 assets/.gitignore create mode 100644 assets/architecture-level-0.pdf create mode 100644 assets/figs.drawio create mode 100644 doc/refs.bib diff --git a/assets/.gitignore b/assets/.gitignore new file mode 100644 index 0000000..cac82ea --- /dev/null +++ b/assets/.gitignore @@ -0,0 +1 @@ +.$* diff --git a/assets/architecture-level-0.pdf b/assets/architecture-level-0.pdf new file mode 100644 index 0000000..48f00a6 Binary files /dev/null and b/assets/architecture-level-0.pdf differ diff --git a/assets/figs.drawio b/assets/figs.drawio new file mode 100644 index 0000000..e7c4c8e --- /dev/null +++ b/assets/figs.drawio @@ -0,0 +1,47 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/doc/.gitignore b/doc/.gitignore index 25dcb3b..e5139ef 100644 --- a/doc/.gitignore +++ b/doc/.gitignore @@ -12,6 +12,8 @@ *.toc *.synctex(busy) *.md.tex +*.lof +*.lot # ignore output files *.pdf diff --git a/doc/base.tex b/doc/base.tex index 9c1c908..edadce3 100644 --- a/doc/base.tex +++ b/doc/base.tex @@ -12,10 +12,13 @@ \usepackage{booktabs} \usepackage{needspace} \usepackage{hyperref} -% \usepackage[backend=biber, -% bibencoding=utf8, -% style=apa -% ]{biblatex} +\usepackage{graphicx} +\usepackage[toc]{glossaries} +\usepackage[backend=biber, + bibencoding=utf8, + style=apa +]{biblatex} +\addbibresource{refs.bib} \setmainfont{TeX Gyre Schola} \setmathfont{TeX Gyre Schola Math} @@ -42,6 +45,13 @@ Niels Stunnebrink\\2184532 } +\newcommand{\req}[1]{$^{\text{\ref{req:#1}}}$} +\newcommand{\up}[1]{$^{\text{#1}}$} +\newcommand{\sub}[1]{$_{\text{#1}}$} + +\floatplacement{figure}{H} +\floatplacement{table}{H} + \begin{document} \begin{titlepage} \maketitle @@ -52,5 +62,11 @@ \newpage \input{\jobname.md.tex} + +% \printbibliography[heading=bibintoc] +% \printglossaries +% \listoftables +% \listoffigures + \end{document} diff --git a/doc/dui.md b/doc/dui.md index 65f242d..f70f4ef 100644 --- a/doc/dui.md +++ b/doc/dui.md @@ -1,29 +1,105 @@ # Introduction -# Problem statement +\ -The following is the original project description (translated to English): +# Problem statement -> I would like to bring to market a vehicle that can drive independently from A -> to B. The vehicle must take into account traffic rules, road signs, traffic -> lights, etc. Research is being conducted using a small cart, the Pololu Zumo -> 32U4, on which a camera module Nicla Vision is mounted. The aim is to -> investigate the most appropriate method of recognizing the road, traffic -> signs and traffic lights. This should be demonstrated with a proof of -> concept. The cart does not need to drive fast, so the image processing does -> not need to be very fast. Assume one frame per second (or faster). +The following is the original project description (translated to English). +References have been added in superscript that link to requirements set in +section \ref{specifications}. + +> I would like to bring to market a vehicle that can drive +> independently\req{autonomous} from A to B. The vehicle must take into account +> traffic rules\req{traffic-rules}, road signs\req{signs}, traffic +> lights\req{traffic-lights}, etc. Research is being conducted using a small +> cart, the Pololu Zumo 32U4\req{zumo}, on which a camera module Nicla +> Vision\req{nicla} is mounted. The aim is to investigate the most appropriate +> method of recognizing the road, traffic signs and traffic lights. This should +> be demonstrated with a proof of concept. The cart does not need to drive +> fast\req{drspeed}, so the image processing\req{mvision} does not need to be +> very fast. Assume one frame per second (or faster)\req{imspeed}. # Specifications +The following is a list of specifications derived from the original project +description in section \ref{problem-statement}. + +\begin{enumerate} + \item \label{req:autonomous} + The vehicle is autonomous + \item + The vehicle can detect how its positioned and orientated relative to a road + \item \label{req:traffic-rules} + The vehicle conforms to the following set of traffic rules + \begin{enumerate} + \item Driving when not on a road is not allowed + \item The vehicle can follow a road by steering itself accordingly + \item Driving off the road is only allowed when necessary for the camera to + keep seeing the road + \end{enumerate} + \item \label{req:traffic-lights} + The vehicle handles traffic lights in the following way + \begin{enumerate} + \item Stop at a red traffic light + \item Speed up at an orange traffic light + \item Continue driving normally at a green traffic light + \end{enumerate} + \item \label{req:signs} + The vehicle acts on traffic signs in the following way + \begin{enumerate} + \item Stop at a stop sign, and continue driving after a few seconds + \item Turn left at a left sign + \item Turn right at a right sign + \item Slow down at a low speed limit sign + \item Speed up to normal speed at a high speed limit sign + \end{enumerate} + \item \label{req:zumo} + The vehicle used is a Pololu Zumo 32U4 + \item \label{req:nicla} + The camera module used is an Arduino Nicla Vision + \item \label{req:mvision} + Computer vision / image processing is used as the only input + \item \label{req:drspeed} + There is no minimum speed the car has to drive at + \item \label{req:imspeed} + The image processing pipeline runs at 1 frame per second or higher + \item + The Zumo displays the name of the last detected sign on it's OLED display +\end{enumerate} + # Architecture +## Overview + +![Architecture overview (level 0) +\label{fig:architecture-level-0}](../assets/architecture-level-0.pdf) + +Figure \ref{fig:architecture-level-0} shows the hardware used in this project. +Both the Pololu Zumo 32U4 (referred to as just "Zumo"), and the Arduino Nicla +Vision ("Nicla") have additional sensors and/or outputs on-board, but are +unused. + +## Distribution of features + +Because creating a software architecture that does all machine vision-related +tasks on the Nicla, and all driving related tasks on the Zumo would create +significant overhead, and because the microcontroller on the Zumo is +significantly harder to debug than the Nicla, a monolithic architecture was +chosen. In this architecture, both the detection of 'traffic objects' and the +decisionmaking on how to handle each object is done on the Nicla board. + +Figure \ref{fig:architecture-level-0} shows that a bidirectional communication +line exists between the Zumo and Nicla. This line is only used to send control +commands to the Zumo. Section \ref{niclazumo-communication-protocol} describes +which commands are sent over these lines. + ## Nicla/Zumo communication protocol The communication protocol used to control the Zumo from the Nicla uses UART to -send ranged numbers in a single byte. Figure \ref{tab:protocol-ranges} shows +send ranged numbers in a single byte. Table \ref{tab:protocol-ranges} shows which number ranges correspond to which controls. -\begin{figure}[h] +\begin{table} \centering \begin{tabular}{rl} \toprule @@ -37,16 +113,16 @@ Steering & \texttt{0x20} - \texttt{0xff}\\ \end{tabular} \caption{Protocol command ranges} \label{tab:protocol-ranges} -\end{figure} +\end{table} ### Signs The Zumo stores the last sign received, and displays it's name on the OLED -display using the lookup table in figure \ref{tab:protocol-signs}. The sign ID +display using the lookup table in table \ref{tab:protocol-signs}. The sign ID is calculated by subtracting the start offset of the sign command range from -the command as shown in figure \ref{tab:protocol-ranges}. +the command as shown in table \ref{tab:protocol-ranges}. -\begin{figure}[h] +\begin{table} \centering \begin{tabular}{ll} \toprule @@ -65,7 +141,7 @@ the command as shown in figure \ref{tab:protocol-ranges}. \end{tabular} \caption{Sign lookup table} \label{tab:protocol-signs} -\end{figure} +\end{table} ### Speed @@ -184,6 +260,32 @@ nog niet}. } \communicationConclusion +## Compiling and linking code for the Zumo + +This section tries to answer the question "What are possible debugging options +for code running on the Zumo robot?". + +Debugging running code can usually be done using an on-device debugger, and a +program that interfaces with the debugger and gcc on a computer. Because gcc +only gives valuable information when it has access to the executable file +running on the microcontroller, an attempt at making a makefile-based toolchain +was made. + +Pololu provides C++ libraries for controlling various parts of the Zumo's +hardware. These libraries make use of functions and classes that are part of +the Arduino core library. The Arduino libraries are all open source, and can in +theory be compiled and linked using make, but this would take more effort than +it's worth, since the Zumo has very little responsibility in the end product. + +\def\buildSystemConclusion{ +Because making a custom build system would take too much time, and because the +Zumo robot's code is very simple, unit tests are used to debug the Zumo's code. +For compiling and uploading the full Zumo firmware, the Arduino IDE is used in +combination with the standard Pololu boards and Libraries. +} +\buildSystemConclusion + # Conclusion \communicationConclusion +\buildSystemConclusion diff --git a/doc/makefile b/doc/makefile index 9f4dfa0..a960c63 100644 --- a/doc/makefile +++ b/doc/makefile @@ -1,10 +1,8 @@ .PHONY: all clean -TARGET := $(patsubst %.md,%.pdf, $(wildcard *.md)) +all: dui.pdf -all: $(TARGET) - -garbage = $1.aux $1.bbl $1.bcf $1.blg $1.fdb_latexmk $1.fls $1.log $1.out $1.run.xml $1.synctex.gz $1.toc $1.md.tex +dui.pdf: ../assets/architecture-level-0.pdf %.pdf: %.svg rsvg-convert -f pdf -o $@ $< @@ -16,5 +14,5 @@ garbage = $1.aux $1.bbl $1.bcf $1.blg $1.fdb_latexmk $1.fls $1.log $1.out $1.run pandoc -t latex -o $@ $< clean: - $(RM) $(call garbage,research) research.pdf + $(RM) dui.aux dui.bbl dui.bcf dui.blg dui.fdb_latexmk dui.fls dui.log dui.out dui.run.xml dui.synctex.gz dui.toc dui.md.tex dui.pdf diff --git a/doc/refs.bib b/doc/refs.bib new file mode 100644 index 0000000..e69de29 -- cgit v1.2.3 From ba4cc491d546767fbb344d279d216cfb5ea0cc1f Mon Sep 17 00:00:00 2001 From: lonkaars Date: Sun, 21 May 2023 14:07:37 +0200 Subject: remove custom build system from zumo folder (not worth) --- .gitmodules | 27 -------------- zumo/.gitignore | 4 --- zumo/lib/ArduinoCore-avr | 1 - zumo/lib/fastgpio-arduino | 1 - zumo/lib/pololu-buzzer-arduino | 1 - zumo/lib/pololu-hd44780-arduino | 1 - zumo/lib/pololu-menu-arduino | 1 - zumo/lib/pololu-oled-arduino | 1 - zumo/lib/pushbutton-arduino | 1 - zumo/lib/usb-pause-arduino | 1 - zumo/lib/zumo-32u4-arduino-library | 1 - zumo/makefile | 74 -------------------------------------- zumo/zumo.mk | 73 ------------------------------------- 13 files changed, 187 deletions(-) delete mode 100644 .gitmodules delete mode 160000 zumo/lib/ArduinoCore-avr delete mode 160000 zumo/lib/fastgpio-arduino delete mode 160000 zumo/lib/pololu-buzzer-arduino delete mode 160000 zumo/lib/pololu-hd44780-arduino delete mode 160000 zumo/lib/pololu-menu-arduino delete mode 160000 zumo/lib/pololu-oled-arduino delete mode 160000 zumo/lib/pushbutton-arduino delete mode 160000 zumo/lib/usb-pause-arduino delete mode 160000 zumo/lib/zumo-32u4-arduino-library delete mode 100644 zumo/makefile delete mode 100644 zumo/zumo.mk diff --git a/.gitmodules b/.gitmodules deleted file mode 100644 index a60d698..0000000 --- a/.gitmodules +++ /dev/null @@ -1,27 +0,0 @@ -[submodule "zumo/lib/zumo-32u4-arduino-library"] - path = zumo/lib/zumo-32u4-arduino-library - url = https://github.com/pololu/zumo-32u4-arduino-library -[submodule "zumo/lib/fastgpio-arduino"] - path = zumo/lib/fastgpio-arduino - url = https://github.com/pololu/fastgpio-arduino -[submodule "zumo/lib/pushbutton-arduino"] - path = zumo/lib/pushbutton-arduino - url = https://github.com/pololu/pushbutton-arduino -[submodule "zumo/lib/ArduinoCore-avr"] - path = zumo/lib/ArduinoCore-avr - url = https://github.com/arduino/ArduinoCore-avr -[submodule "zumo/lib/usb-pause-arduino"] - path = zumo/lib/usb-pause-arduino - url = https://github.com/pololu/usb-pause-arduino -[submodule "zumo/lib/pololu-buzzer-arduino"] - path = zumo/lib/pololu-buzzer-arduino - url = https://github.com/pololu/pololu-buzzer-arduino -[submodule "zumo/lib/pololu-hd44780-arduino"] - path = zumo/lib/pololu-hd44780-arduino - url = https://github.com/pololu/pololu-hd44780-arduino -[submodule "zumo/lib/pololu-menu-arduino"] - path = zumo/lib/pololu-menu-arduino - url = https://github.com/pololu/pololu-menu-arduino -[submodule "zumo/lib/pololu-oled-arduino"] - path = zumo/lib/pololu-oled-arduino - url = https://github.com/pololu/pololu-oled-arduino diff --git a/zumo/.gitignore b/zumo/.gitignore index 888e905..e45f7a2 100644 --- a/zumo/.gitignore +++ b/zumo/.gitignore @@ -1,6 +1,2 @@ -main *.o -*.hex -compile_commands.json -.cache pidtest diff --git a/zumo/lib/ArduinoCore-avr b/zumo/lib/ArduinoCore-avr deleted file mode 160000 index 42fa4a1..0000000 --- a/zumo/lib/ArduinoCore-avr +++ /dev/null @@ -1 +0,0 @@ -Subproject commit 42fa4a1ea1b1b11d1cc0a60298e529d37f9d14bd diff --git a/zumo/lib/fastgpio-arduino b/zumo/lib/fastgpio-arduino deleted file mode 160000 index 5853c59..0000000 --- a/zumo/lib/fastgpio-arduino +++ /dev/null @@ -1 +0,0 @@ -Subproject commit 5853c593b07730e632127570279e7dea06de1af3 diff --git a/zumo/lib/pololu-buzzer-arduino b/zumo/lib/pololu-buzzer-arduino deleted file mode 160000 index 20ef7b7..0000000 --- a/zumo/lib/pololu-buzzer-arduino +++ /dev/null @@ -1 +0,0 @@ -Subproject commit 20ef7b734814a7c5e9f02f54a2cdd41729759d51 diff --git a/zumo/lib/pololu-hd44780-arduino b/zumo/lib/pololu-hd44780-arduino deleted file mode 160000 index 0a35789..0000000 --- a/zumo/lib/pololu-hd44780-arduino +++ /dev/null @@ -1 +0,0 @@ -Subproject commit 0a35789a58ca92ca6f69b63fbc269959b2d18584 diff --git a/zumo/lib/pololu-menu-arduino b/zumo/lib/pololu-menu-arduino deleted file mode 160000 index 8970b8d..0000000 --- a/zumo/lib/pololu-menu-arduino +++ /dev/null @@ -1 +0,0 @@ -Subproject commit 8970b8db6e4e80b1c0e95172a87a35410bf593bf diff --git a/zumo/lib/pololu-oled-arduino b/zumo/lib/pololu-oled-arduino deleted file mode 160000 index e6b83b6..0000000 --- a/zumo/lib/pololu-oled-arduino +++ /dev/null @@ -1 +0,0 @@ -Subproject commit e6b83b6c181962ffb98f99a4a4c3fd7cbf7e6707 diff --git a/zumo/lib/pushbutton-arduino b/zumo/lib/pushbutton-arduino deleted file mode 160000 index 442884e..0000000 --- a/zumo/lib/pushbutton-arduino +++ /dev/null @@ -1 +0,0 @@ -Subproject commit 442884e004859ff550d5c0cae70033d7d568fc21 diff --git a/zumo/lib/usb-pause-arduino b/zumo/lib/usb-pause-arduino deleted file mode 160000 index 3f76e48..0000000 --- a/zumo/lib/usb-pause-arduino +++ /dev/null @@ -1 +0,0 @@ -Subproject commit 3f76e486460bb351f9738c86595f22db2da34c51 diff --git a/zumo/lib/zumo-32u4-arduino-library b/zumo/lib/zumo-32u4-arduino-library deleted file mode 160000 index f4dfe05..0000000 --- a/zumo/lib/zumo-32u4-arduino-library +++ /dev/null @@ -1 +0,0 @@ -Subproject commit f4dfe054e23176ba445748b4b91f463701e7eb76 diff --git a/zumo/makefile b/zumo/makefile deleted file mode 100644 index 08c01d7..0000000 --- a/zumo/makefile +++ /dev/null @@ -1,74 +0,0 @@ -PORT = /dev/ttyUSB0 - -C++ = avr-g++ -CC = avr-gcc -LD = avr-gcc -RM = rm -f - -MCU = atmega32u4 -TARGET = main -SRCS += main.cpp - -C_CPP_FLAGS += -mmcu=$(MCU) -C_CPP_FLAGS += -Wl,-gc-sections -SHARED_FLAGS += -Os - -C_CPP_FLAGS += -mcall-prologues -C_CPP_FLAGS += -g -C_CPP_FLAGS += -Wl,-relax -C_CPP_FLAGS += -MMD -C_CPP_FLAGS += -ffunction-sections -C_CPP_FLAGS += -fdata-sections - -LFLAGS += -flto -LFLAGS += -fuse-linker-plugin -LFLAGS += -lc -lm -# LFLAGS += -L/usr/avr/lib/avr5/ -L/usr/lib/gcc/avr/12.2.0/avr5 -lgcc -lm -lc -latmega32u4 -# LFLAGS += -flto -fuse-linker-plugin -mmcu=atmega32u4 -Wl,--gc-sections -Os -lc -lm - - -CFLAGS += -fno-fat-lto-objects -# CFLAGS += -std=gnu11 - -CPPFLAGS += -fpermissive -CPPFLAGS += -fno-exceptions -CPPFLAGS += -fno-threadsafe-statics -CPPFLAGS += -fno-devirtualize -# CPPFLAGS += -std=gnu++11 - - -LFLAGS += $(SHARED_FLAGS) -CFLAGS += $(C_CPP_FLAGS) $(SHARED_FLAGS) -CPPFLAGS += $(C_CPP_FLAGS) $(SHARED_FLAGS) - -include zumo.mk - -OBJS := $(patsubst %.c,%.o, $(SRCS)) -OBJS := $(patsubst %.cpp,%.o, $(OBJS)) - -MAKEFLAGS += -j - -.PHONY: all clean flash - -all: $(TARGET).hex - -%.o: %.cpp - $(C++) $(CPPFLAGS) -o $@ -c $< - -%.o: %.c - $(CC) $(CFLAGS) -o $@ -c $< - -$(TARGET): $(OBJS) - $(LD) $(LFLAGS) -o $@ $^ - -$(TARGET).hex: $(TARGET) - avr-objcopy -R .eeprom -O ihex $< $@ - -flash: $(TARGET).hex - avrdude -p $(MCU) -c avr109 -P $(PORT) -U flash:w:$(TARGET).hex - -clean: - $(RM) $(TARGET) $(TARGET).hex $(OBJS) - -compile_commands.json: makefile - compiledb make -Bn diff --git a/zumo/zumo.mk b/zumo/zumo.mk deleted file mode 100644 index f5ab84b..0000000 --- a/zumo/zumo.mk +++ /dev/null @@ -1,73 +0,0 @@ -C_CPP_FLAGS += -DF_CPU=16000000L -C_CPP_FLAGS += -D__PROG_TYPES_COMPAT__ -C_CPP_FLAGS += -DARDUINO=1819 -C_CPP_FLAGS += -DARDUINO_AVR_LEONARDO -C_CPP_FLAGS += -DARDUINO_ARCH_AVR -C_CPP_FLAGS += -DARDUINO_BOARD='"AVR_LEONARDO"' -C_CPP_FLAGS += -DARDUINO_VARIANT='"leonardo"' -C_CPP_FLAGS += -DUSB_VID=0x2341 -C_CPP_FLAGS += -DUSB_PID=0x8036 -C_CPP_FLAGS += -DUSB_PRODUCT='"Arduino Leonardo"' -C_CPP_FLAGS += -DUSB_MANUFACTURER='"Unknown"' - -C_CPP_FLAGS += -I./lib/zumo-32u4-arduino-library/src -C_CPP_FLAGS += -I./lib/fastgpio-arduino -C_CPP_FLAGS += -I./lib/pushbutton-arduino -C_CPP_FLAGS += -I./lib/usb-pause-arduino -C_CPP_FLAGS += -I./lib/pololu-buzzer-arduino/src -C_CPP_FLAGS += -I./lib/pololu-hd44780-arduino -C_CPP_FLAGS += -I./lib/pololu-menu-arduino/src -C_CPP_FLAGS += -I./lib/pololu-oled-arduino/src -C_CPP_FLAGS += -I./lib/ArduinoCore-avr/cores/arduino -C_CPP_FLAGS += -I./lib/ArduinoCore-avr/libraries/HID/src -C_CPP_FLAGS += -I./lib/ArduinoCore-avr/libraries/SoftwareSerial/src -C_CPP_FLAGS += -I./lib/ArduinoCore-avr/libraries/SPI/src -C_CPP_FLAGS += -I./lib/ArduinoCore-avr/libraries/EEPROM/src -C_CPP_FLAGS += -I./lib/ArduinoCore-avr/libraries/Wire/src -C_CPP_FLAGS += -I./lib/ArduinoCore-avr/variants/leonardo - -# LIBS += lib/ArduinoCore-avr/cores/arduino/PluggableUSB.cpp -LIBS += lib/ArduinoCore-avr/cores/arduino/CDC.cpp -LIBS += lib/ArduinoCore-avr/cores/arduino/HardwareSerial.cpp -LIBS += lib/ArduinoCore-avr/cores/arduino/USBCore.cpp -LIBS += lib/ArduinoCore-avr/cores/arduino/HardwareSerial0.cpp -LIBS += lib/ArduinoCore-avr/cores/arduino/HardwareSerial1.cpp -LIBS += lib/ArduinoCore-avr/cores/arduino/HardwareSerial2.cpp -LIBS += lib/ArduinoCore-avr/cores/arduino/HardwareSerial3.cpp -LIBS += lib/ArduinoCore-avr/cores/arduino/IPAddress.cpp -LIBS += lib/ArduinoCore-avr/cores/arduino/Print.cpp -LIBS += lib/ArduinoCore-avr/cores/arduino/Stream.cpp -LIBS += lib/ArduinoCore-avr/cores/arduino/WMath.cpp -LIBS += lib/ArduinoCore-avr/cores/arduino/WString.cpp -LIBS += lib/ArduinoCore-avr/cores/arduino/abi.cpp -LIBS += lib/ArduinoCore-avr/cores/arduino/main.cpp -LIBS += lib/ArduinoCore-avr/cores/arduino/new.cpp -# LIBS += lib/ArduinoCore-avr/libraries/HID/src/HID.cpp -# LIBS += lib/ArduinoCore-avr/libraries/SPI/src/SPI.cpp -# LIBS += lib/ArduinoCore-avr/libraries/SoftwareSerial/src/SoftwareSerial.cpp -LIBS += lib/ArduinoCore-avr/libraries/Wire/src/Wire.cpp -LIBS += lib/ArduinoCore-avr/cores/arduino/WInterrupts.c -LIBS += lib/ArduinoCore-avr/cores/arduino/hooks.c -LIBS += lib/ArduinoCore-avr/cores/arduino/wiring_shift.c -LIBS += lib/ArduinoCore-avr/cores/arduino/wiring_digital.c -LIBS += lib/ArduinoCore-avr/cores/arduino/wiring_analog.c -LIBS += lib/ArduinoCore-avr/cores/arduino/wiring_pulse.c -LIBS += lib/ArduinoCore-avr/cores/arduino/wiring.c -LIBS += lib/ArduinoCore-avr/cores/arduino/Tone.cpp -# LIBS += lib/ArduinoCore-avr/libraries/Wire/src/utility/twi.c - -LIBS += lib/pololu-buzzer-arduino/src/PololuBuzzer.cpp -LIBS += lib/pushbutton-arduino/Pushbutton.cpp -LIBS += lib/zumo-32u4-arduino-library/src/QTRSensors.cpp -LIBS += lib/zumo-32u4-arduino-library/src/Zumo32U4IRPulses.cpp -LIBS += lib/zumo-32u4-arduino-library/src/Zumo32U4Encoders.cpp -LIBS += lib/zumo-32u4-arduino-library/src/Zumo32U4IMU.cpp -LIBS += lib/zumo-32u4-arduino-library/src/Zumo32U4Motors.cpp -LIBS += lib/zumo-32u4-arduino-library/src/Zumo32U4ProximitySensors.cpp -LIBS += lib/usb-pause-arduino/USBPause.cpp -LIBS += lib/pololu-hd44780-arduino/PololuHD44780.cpp -LIBS += lib/fastgpio-arduino/FastGPIO.cpp -LIBS += lib/pololu-oled-arduino/src/font.cpp - -SRCS += $(LIBS) - -- cgit v1.2.3