This repository contains the setup and code for using an ESP32 with sensors (IMU and barometer) for the Gaucho Rocket Project.
The ESP32 uses a USB-C connection for uploading code.
- Make sure you're using the Arduino IDE
- Select the following under Tools:
- Board:
ESP32 Dev Module - Port: The correct COM port your ESP32 is connected to
- Baud Rate: Check the correct baud rate for serial monitor and anywhere else relevant (115200 typically)
- Board:
Install the following libraries via the Arduino Library Manager, or manually download them from GitHub and include them:
- Madgwick by Arduino
- Mahony by Arduino
- Adafruit BMP3XX by Adafruit
- Adafruit BusIO by Adafruit
- Adafruit Unified Sensor by Adafruit
- ESP32SPISlave by hideakitai
- ICM20948_WE by Wolfgang Ewald
- SparkFun BMP581 Arduino Library by SparkFun Electronics
- SparkFun 9DoF IMU Breakout - ICM 20948 by SparkFun Electronics
💡 Windows users: Install the CP210x Universal Windows Driver if your board doesn’t appear under Ports.
-
Navigate to:
Documents/Arduino/libraries/SparkFun_ICM-20948_ArduinoLibrary/src/util/ -
Open
ICM_20948_C.hand uncomment the following line:#define ICM_20948_USE_DMP -
Wire the ICM-20948 to the ESP32 using this schematic:
-
Open or paste the provided sketch from this repository into a new Arduino IDE project.
-
Upload the sketch, and hold the boot button on the ESP32 while uploading
-
Open Serial Moniter at
115200 baudand when prompted enter any key
