ESP32 Ultra Flasher is a terminal-based tool to easily flash ESP32 devices. It supports project validation, COM port detection, configuration auto-generation, and flashing of firmware using esptool
. This project is designed to streamline flashing ESP32 devices, ensuring that configuration files and memory addresses are correctly set up before flashing.
- Menu-based interface for selecting and flashing ESP32 projects.
- Semi-Automatic generation of
config.ini
based on.bin
files in the project folder. - Memory address validation to prevent conflicts when flashing multiple
.bin
files. - COM port detection to list available serial devices and auto-select the correct port for flashing.
- Error handling with detailed messages, highlighting issues such as missing files or incorrect settings.
- Interactive flashing process, allowing the user to choose whether to erase the flash before writing.
- Tested on Python 3.11.
- The following Python packages:
esptool
: for flashing the ESP32.serial
: for serial communication with the ESP32.tprint
: for colorful terminal outputs and logging.
- Clone the repository or download the script.
- Install required dependencies:
pip install -r requirements.txt
-
Folder Setup:
- Place your ESP32 project in the
esp32/
folder, make sure the project is in a folder as well, exampleesp32/marauder/
. - Each project folder should contain:
.bin
files (firmware binaries).config.ini
(it will be auto-generated if missing with your help).
- Place your ESP32 project in the
-
Run the Tool:
- Navigate to the folder containing the script.
- Execute the script:
python esp32_flasher.py
-
Select a Project:
- The tool will display a list of projects found in the
esp32/
folder. You can select a project to flash or choose options to fix issues with the project. - If a project is missing a
config.ini
, you can choose to autogenerate it.
- The tool will display a list of projects found in the
-
Flashing the ESP32:
- After selecting a project, the tool will prompt you to select a COM port and whether you want to erase the flash before flashing the new firmware.
- Once the correct settings are chosen, the flashing process will begin.
-
Handle Issues:
- If any project has missing or misconfigured files, the tool will display a warning and allow you to fix issues before proceeding.
- 1. Open folder to fix manually: Opens the project folder to allow the user to manually edit the files.
- 2. Autogenerate config.ini: Automatically generates a new
config.ini
based on the.bin
files found in the project. - 3. Recheck this project: Re-checks the project for errors after making manual changes or generating a new config file.
- 4. Return to menu: Returns to the main project menu.
If you need to generate or edit the config.ini
manually, it should be placed in the project folder with the following format:
[Settings]
Baud_Rate = 115200
firmware.bin = 0x1000
...
Baud_Rate
: The baud rate used for flashing (e.g.,115200
).- Each
.bin
file listed in theconfig.ini
must have an associated memory address (in hexadecimal, e.g.,0x1000
).
-
Missing
config.ini
: If a project doesn't have aconfig.ini
, the tool will offer to generate it semi-automatically. -
Memory Address Conflicts: The tool will check for conflicting memory addresses and warn you if two
.bin
files are configured to use the same address. -
COM Port Detection Issues: If the tool cannot detect any available COM ports, ensure your ESP32 device is properly connected and try again.
-
Flashing Fails: If flashing fails, ensure the ESP32 is in bootloader mode and retry.
- Add communication to the tool for already flashed files
This project is licensed under the MIT License. See the LICENSE file for more details.
If you have any suggestions or issues, feel free to contribute or open an issue on the GitHub repository.