Can't Flash ESP32-C5 - Chip Revision In Range [v0.0 - V0.99] (this Chip Is Revision V1.0)
Introduction
The ESP32-C5 is a popular microcontroller developed by Espressif, known for its high-performance capabilities and low power consumption. However, some users have reported issues flashing the chip, particularly when the chip revision is outside the range of [v0.0 - v0.99]. In this article, we will explore the issue and provide a solution to help users overcome this problem.
Problem Description
The issue arises when trying to flash the ESP32-C5 using the ESP-IDF (Espressif IoT Development Framework) and the esptool.py utility. The error message indicates that the bootloader requires a chip revision in the range of [v0.0 - v0.99], but the actual chip revision is v1.0. This prevents the user from flashing the chip, even when using the latest version of the ESP-IDF.
Possible Causes
There are several possible causes for this issue:
- Incompatible chip revision: The ESP32-C5 chip revision may not be compatible with the current version of the ESP-IDF.
- Outdated ESP-IDF version: The user may be using an outdated version of the ESP-IDF, which may not support the latest chip revisions.
- Incorrect esptool.py configuration: The esptool.py configuration may not be set up correctly, leading to the error.
Steps to Reproduce the Issue
To reproduce the issue, follow these steps:
- Connect the ESP32-C5 board to the computer using a USB cable.
- Open the terminal or command prompt and navigate to the ESP-IDF directory.
- Run the following command to flash the bootloader and firmware:
/home/grigio/.espressif/python_env/idf5.4_py3.9_env/bin/python /home/grigio/esp/v5.4.1/esp-idf/components/esptool_py/esptool/esptool.py -p /dev/ttyUSB0 -b 460800 --before default_reset --after hard_reset --chip esp32c5 write_flash --flash_mode dio --flash_freq 80m --flash_size 2MB 0x2000 bootloader/bootloader.bin 0x10000 blink.bin 0x8000 partition_table/partition-table.bin
- Observe the error message indicating that the bootloader requires a chip revision in the range of [v0.0 - v0.99].
Diagnostic Report
The diagnostic report is as follows:
Answers Checklist
- [x] I have read the documentation ESP-IDF Programming Guide and the issue is not addressed there.
- [x] I have updated my IDF branch (master or release) to the latest version and checked that the issue is present there.
- [x] I have searched the issue tracker for a similar issue and not found a similar issue.
IDF Version
5.4.1
Operating System Used
Linux
How Did You Build Your Project?
VS Code IDE
If You Are Using Windows, Please Specify Command Line Type
None
What is the Expected Behavior?
I'd like to flash the blink example
What is the Actual Behavior?
A fatal error occurred: bootloader/bootloader.bin requires chip revision in range [v0.0 - v0.99] (this chip is revision v1.0). Use --force to flash anyway.
Steps to Reproduce
Executing task: /home/grigio/.espressif/python_env/idf5.4_py3.9_env/bin/python /home/grigio/esp/v5.4.1/esp-idf/components/esptool_py/esptool/esptool.py -p /dev/ttyUSB0 -b 460800 --before default_reset --after hard_reset --chip esp32c5 write_flash --flash_mode dio --flash_freq 80m --flash_size 2MB 0x2000 bootloader/bootloader.bin 0x10000 blink.bin 0x8000 partition_table/partition-table.bin
esptool.py v4.8.1
Serial port /dev/ttyUSB0
Connecting....
WARNING: This chip doesn't appear to be a ESP32-C5 (chip magic value 0x5fd1406f). Probably it is unsupported by this version of esptool.
Chip is ESP32-C5 (revision v1.0)
Features: WiFi 6, BT 5, IEEE802.15.4
Crystal is 48MHz
MAC: ---
BASE MAC: ---
MAC_EXT: ff:fe
Uploading stub...
Running stub...
Stub running...
Changing baud rate to 460800
Changed.
Configuring flash size...
A fatal error occurred: bootloader/bootloader.bin requires chip revision in range [v0.0 - v0.99] (this chip is revision v1.0). Use --force to flash anyway.
Solution
To solve this issue, follow these steps:
- Update the ESP-IDF version: Update the ESP-IDF version to the latest release, which may include support for the latest chip revisions.
- Use the --force option: Use the --force option when flashing the bootloader and firmware to override the chip revision check.
- Check the esptool.py configuration: Check the esptool.py configuration to ensure that it is set up correctly for the ESP32-C5 chip.
Conclusion
The issue of flashing the ESP32-C5 chip revision in range [v0.0 - v0.99] can be resolved by updating the ESP-IDF version, using the --force option, and checking the esptool.py configuration. By following these steps, users can overcome this problem and successfully flash their ESP32-C5 boards.
Related Issues
The issue may be related to the following:
Additional Information
For additional information, please refer to the following resources:
- ESP-IDF Programming Guide: https://docs.espressif.com/projects/esp-idf/en/latest/
- ESP32-C5 Documentation: https://docs.espressif.com/projects/esp32c5/en/latest/
Introduction
In our previous article, we explored the issue of flashing the ESP32-C5 chip revision in range [v0.0 - v0.99] and provided a solution to help users overcome this problem. In this Q&A article, we will answer some of the most frequently asked questions related to this issue.
Q: What is the cause of the issue?
A: The cause of the issue is that the bootloader requires a chip revision in the range of [v0.0 - v0.99], but the actual chip revision is v1.0.
Q: How can I update the ESP-IDF version?
A: To update the ESP-IDF version, follow these steps:
- Open the terminal or command prompt and navigate to the ESP-IDF directory.
- Run the following command to update the ESP-IDF version:
git pull origin master
- Run the following command to build the ESP-IDF:
make menuconfig
- Select the latest version of the ESP-IDF and build the project.
Q: What is the --force option and how can I use it?
A: The --force option is used to override the chip revision check when flashing the bootloader and firmware. To use the --force option, follow these steps:
- Open the terminal or command prompt and navigate to the ESP-IDF directory.
- Run the following command to flash the bootloader and firmware with the --force option:
/home/grigio/.espressif/python_env/idf5.4_py3.9_env/bin/python /home/grigio/esp/v5.4.1/esp-idf/components/esptool_py/esptool/esptool.py -p /dev/ttyUSB0 -b 460800 --before default_reset --after hard_reset --chip esp32c5 write_flash --flash_mode dio --flash_freq 80m --flash_size 2MB --force 0x2000 bootloader/bootloader.bin 0x10000 blink.bin 0x8000 partition_table/partition-table.bin
- Observe the output to ensure that the flash operation is successful.
Q: How can I check the esptool.py configuration?
A: To check the esptool.py configuration, follow these steps:
- Open the terminal or command prompt and navigate to the ESP-IDF directory.
- Run the following command to check the esptool.py configuration:
python /home/grigio/esp/v5.4.1/esp-idf/components/esptool_py/esptool/esptool.py --help
- Observe the output to ensure that the esptool.py configuration is set up correctly for the ESP32-C5 chip.
Q: What are the possible causes of the issue?
A: The possible causes of the issue are:
- Incompatible chip revision: The ESP32-C5 chip revision may not be compatible with the current version of the ESP-IDF.
- Outdated ESP-IDF version: The user may be using an outdated version of the ESP-IDF, which may not support the latest chip revisions.
- Incorrect esptool.py configuration: The esptool.py configuration may not be set up correctly, leading to the error.
Q: How can I troubleshoot the issue?
A: To troubleshoot the issue, follow these steps:
- Check the ESP-IDF version and ensure that it is up-to-date.
- Check the esptool.py configuration and ensure that it is set up correctly for the ESP32-C5 chip.
- Use the --force option when flashing the bootloader and firmware to override the chip revision check.
- Observe the output to ensure that the flash operation is successful.
Q: What are the related issues?
A: The related issues are:
Q: Where can I find additional information?
A: For additional information, please refer to the following resources:
- ESP-IDF Programming Guide: https://docs.espressif.com/projects/esp-idf/en/latest/
- ESP32-C5 Documentation: https://docs.espressif.com/projects/esp32c5/en/latest/
Conclusion
In this Q&A article, we answered some of the most frequently asked questions related to the issue of flashing the ESP32-C5 chip revision in range [v0.0 - v0.99]. We provided solutions to help users overcome this problem and troubleshoot the issue. We also provided related issues and additional information resources for further reference.