Making an ESP32-based quadcopter from scratch
Python arduinoautopilotcontrol-theorydroneesp32flight-controlflight-controllermavlinkquadcopterquadcopter-firmwareuav
#1 - use MAVLink Arduino library
Oleg Kalachev82f3ab563a5d
diff --git a/Makefile b/Makefileindex bdceaad..b627cd4 100644--- a/Makefile+++ b/Makefile@@ -15,6 +15,7 @@ dependencies .dependencies:arduino-cli core update-index --config-file arduino-cli.yamlarduino-cli core install esp32:[email protected] --config-file arduino-cli.yamlarduino-cli lib install "Bolder Flight Systems SBUS"@1.0.1+ arduino-cli lib install "MAVLink"@2.0.1arduino-cli lib install --git-url https://github.com/okalachev/MPU9250.git --config-file arduino-cli.yamltouch .dependenciesdiff --git a/docs/build.md b/docs/build.mdindex 759d1e5..d6f5d04 100644--- a/docs/build.md+++ b/docs/build.md@@ -66,9 +66,10 @@ Dependencies are [Gazebo Classic simulator](https://classic.gazebosim.org) and [1. Install [Arduino IDE](https://www.arduino.cc/en/software) (version 2 is recommended).2. Install ESP32 core using [Boards Manager](https://docs.arduino.cc/learn/starting-guide/cores).-3. Install the following libraries using [Library Manager](https://docs.arduino.cc/software/ide-v2/tutorials/ide-v2-installing-a-library) (versions are significant):+3. Install the following libraries using [Library Manager](https://docs.arduino.cc/software/ide-v2/tutorials/ide-v2-installing-a-library) (**versions are significant**):* `Bolder Flight Systems SBUS`, version 1.0.1.* `Bolder Flight Systems MPU9250`, version 1.0.1. <!-- TODO: actually the fork is needed -->+ * `MAVLink`, version 2.0.1.4. Clone the project using git or [download the source code as a ZIP archive](https://codeload.github.com/okalachev/flix/zip/refs/heads/master).5. Open the downloaded Arduino sketch `flix/flix.ino` in Arduino IDE.6. [Build and upload](https://docs.arduino.cc/software/ide-v2/tutorials/getting-started/ide-v2-uploading-a-sketch) the firmware using Arduino IDE.diff --git a/flix/mavlink.ino b/flix/mavlink.inoindex 8dfff14..a869784 100644--- a/flix/mavlink.ino+++ b/flix/mavlink.ino@@ -5,7 +5,7 @@#if WIFI_ENABLED == 1-#include "mavlink/common/mavlink.h"+#include <MAVLink.h>#define SYSTEM_ID 1#define PERIOD_SLOW 1.0