ESP 32

ESP32

In this experiment we will develop on ESP32 using Rust.

In my setup I have an ESP32 devkit v1 type-C

Step 1 : Setup the eco system

The ESP32 DevKit has an Xtensa architecture, so we will have to make some adjustments, but it will work.

# Rust toolchain for Xtensa (espressif fork)
cargo install espup
espup install

At the end of the espup install, ready carefully the output. You must launch a script to set up env var. You should run it every time you start a new terminal, or you can add it to your .zshrc.

. $HOME/export-esp.sh

And finally install the flash tool and the project generator tool

cargo install espflash
cargo install cargo-generate
cargo install esp-generate
cargo install esp-config

Step 2 : Create a project

Now that everything is setup, we will create the project.

esp-generate --chip esp32 mon-capteur

Now you will be facing an interactive prompt to select your chip and a few other options