The is the codebase for the VESC Express, which is a WiFi and Bluetooth-enabled logger and IO-board. At the moment it is tested and runs on the ESP32C3 and ESP32S3 but other ESP32 devices can be added.
Instructions for how to set up the toolchain can be found here: https://docs.espressif.com/projects/esp-idf/en/latest/esp32c3/get-started/linux-macos-setup.html
Note
ESP-IDF version 5.2 or later is required for building this project.
The instructions linked above will install the master branch of ESP-IDF. To install the stable release you can navigate to the installation directory and use the following commands:
git clone -b v5.2.2 --recursive https://github.com/espressif/esp-idf.git esp-idf-v5.2.2
cd esp-idf-v5.2.2/
./install.sh esp32c3 esp32s3At the moment development is done using the stable 5.2.2-release.
Set the target chip/architecture with
idf.py set-target <target> where target is esp32c3 or esp32s3. You will need to run a fullclean or remove the build directory when changing targets.
Once the toolchain is set up in the current path, the project can be built with
idf.py buildThat will create vesc_express.bin in the build directory, which can be used with the bootloader in VESC Tool. If the ESP32c3 does not come with firmware preinstalled, the USB-port can be used for flashing firmware using the built-in bootloader. That also requires bootloader.bin and partition-table.bin which also can be found in the build directory. This can be done from VESC Tool or using idf.py.
All targets can be built with
python build_all.pyThat will create all required firmware files under the build_output directory, with hardware names as child directories. All target switching is handled automatically with the build_all command.
If you wish to build the project with custom hardware config files you should add the hardware config files to the "main/hwconf" directory and use the HW_NAME build flag
idf.py build -DHW_NAME="VESC Express T"Note: If you ever change the environment variables, or if when you first start using them, you need to first run idf.py reconfigure before building (with the environment variables still set of course!), as the build system unfortunately can't automatically detect this change. Running idf.py fullclean has the same effect as this forces cmake to rebuild the build configurations.