Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,14 +8,17 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
## [Unreleased]

### Added
- `read_efuse_le` should be preferred over `read_efuse` (#969)

- A new CLI argument `rom-elf` was added which will be used for backtraces (#963)

### Changed
- `read_efuse` is deprecated (#969)

### Fixed

- Corrected eFuse BLOCK0 definitions for ESP32-C2, ESP32-C3, and ESP32-S3 (#961)
- Several fixes in `read_efuse` (#969)

### Removed

Expand Down
10 changes: 8 additions & 2 deletions espflash/src/error.rs
Original file line number Diff line number Diff line change
Expand Up @@ -319,7 +319,7 @@ pub enum Error {
#[error("Invalid `address`({address}) and/or `size`({size}) argument(s)")]
#[diagnostic(
code(espflash::erase_region::invalid_argument),
help("`address` and `size` must be multiples of 0x1000 (4096)")
help("`address` ({address}) and `size` ({size}) must be multiples of 0x1000 (4096)")
)]
InvalidEraseRegionArgument {
/// Address argument
Expand All @@ -332,7 +332,9 @@ pub enum Error {
#[error("The firmware was built for {elf}, but the detected chip is {detected}")]
#[diagnostic(
code(espflash::chip_mismatch),
help("Ensure that the device is connected and your host recognizes the serial adapter")
help(
"Ensure that the device is connected and your host recognizes the serial adapter. (File {elf}, detected chip is {detected})"
)
)]
FirmwareChipMismatch {
/// Chip which the ELF file was built for
Expand All @@ -357,6 +359,10 @@ pub enum Error {
/// Key is not in the expected section
#[error("Misplaced key, check your configuration file. Key: {0}")]
MisplacedKey(String),

/// The efuse field is larger than 32 bit.
#[error("Requested efuse field is larger than 32 bit. Use `read_efuse_le`.")]
EfuseFieldTooLarge,
}

#[cfg(feature = "serialport")]
Expand Down
2 changes: 1 addition & 1 deletion espflash/src/target/efuse/esp32.rs
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
//!
//! This file was automatically generated, please do not edit it manually!
//!
//! Generated: 2025-06-25 11:06
//! Generated: 2025-11-19 12:31
//! Version: 369d2d860d34e777c0f7d545a7dfc3c4

#![allow(unused)]
Expand Down
4 changes: 2 additions & 2 deletions espflash/src/target/efuse/esp32c2.rs
Original file line number Diff line number Diff line change
Expand Up @@ -2,15 +2,15 @@
//!
//! This file was automatically generated, please do not edit it manually!
//!
//! Generated: 2025-06-26 09:47
//! Generated: 2025-11-19 12:31
//! Version: 897499b0349a608b895d467abbcf006b

#![allow(unused)]

use super::EfuseField;

/// Total size in bytes of each block
pub(crate) const BLOCK_SIZES: &[u32] = &[8, 11, 32, 32];
pub(crate) const BLOCK_SIZES: &[u32] = &[8, 12, 32, 32];

/// Disable programming of individual eFuses
pub const WR_DIS: EfuseField = EfuseField::new(0, 0, 0, 8);
Expand Down
4 changes: 2 additions & 2 deletions espflash/src/target/efuse/esp32c3.rs
Original file line number Diff line number Diff line change
Expand Up @@ -2,15 +2,15 @@
//!
//! This file was automatically generated, please do not edit it manually!
//!
//! Generated: 2025-06-26 09:47
//! Generated: 2025-11-19 12:31
//! Version: 4622cf9245401eca0eb1df8122449a6d

#![allow(unused)]

use super::EfuseField;

/// Total size in bytes of each block
pub(crate) const BLOCK_SIZES: &[u32] = &[23, 24, 32, 32, 32, 32, 32, 32, 32, 32, 32];
pub(crate) const BLOCK_SIZES: &[u32] = &[24, 24, 32, 32, 32, 32, 32, 32, 32, 32, 32];

/// Disable programming of individual eFuses
pub const WR_DIS: EfuseField = EfuseField::new(0, 0, 0, 32);
Expand Down
2 changes: 1 addition & 1 deletion espflash/src/target/efuse/esp32c5.rs
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
//!
//! This file was automatically generated, please do not edit it manually!
//!
//! Generated: 2025-06-26 09:47
//! Generated: 2025-11-19 12:31
//! Version: 31c7fe3f5f4e0a55b178a57126c0aca7

#![allow(unused)]
Expand Down
2 changes: 1 addition & 1 deletion espflash/src/target/efuse/esp32c6.rs
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
//!
//! This file was automatically generated, please do not edit it manually!
//!
//! Generated: 2025-06-25 11:06
//! Generated: 2025-11-19 12:31
//! Version: df46b69f0ed3913114ba53d3a0b2b843

#![allow(unused)]
Expand Down
2 changes: 1 addition & 1 deletion espflash/src/target/efuse/esp32h2.rs
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
//!
//! This file was automatically generated, please do not edit it manually!
//!
//! Generated: 2025-06-25 11:06
//! Generated: 2025-11-19 12:31
//! Version: 44563d2af4ebdba4db6c0a34a50c94f9

#![allow(unused)]
Expand Down
2 changes: 1 addition & 1 deletion espflash/src/target/efuse/esp32p4.rs
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
//!
//! This file was automatically generated, please do not edit it manually!
//!
//! Generated: 2025-06-25 11:06
//! Generated: 2025-11-19 12:31
//! Version: f7765f0ac3faf4b54f8c1f064307522c

#![allow(unused)]
Expand Down
2 changes: 1 addition & 1 deletion espflash/src/target/efuse/esp32s2.rs
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
//!
//! This file was automatically generated, please do not edit it manually!
//!
//! Generated: 2025-06-26 09:47
//! Generated: 2025-11-19 12:31
//! Version: 888a61f6f500d9c7ee0aa32016b0bee7

#![allow(unused)]
Expand Down
4 changes: 2 additions & 2 deletions espflash/src/target/efuse/esp32s3.rs
Original file line number Diff line number Diff line change
Expand Up @@ -2,15 +2,15 @@
//!
//! This file was automatically generated, please do not edit it manually!
//!
//! Generated: 2025-06-26 09:47
//! Generated: 2025-11-19 12:31
//! Version: 7127dd097e72bb90d0b790d460993126

#![allow(unused)]

use super::EfuseField;

/// Total size in bytes of each block
pub(crate) const BLOCK_SIZES: &[u32] = &[23, 24, 32, 32, 32, 32, 32, 32, 32, 32, 32];
pub(crate) const BLOCK_SIZES: &[u32] = &[24, 24, 32, 32, 32, 32, 32, 32, 32, 32, 32];

/// Disable programming of individual eFuses
pub const WR_DIS: EfuseField = EfuseField::new(0, 0, 0, 32);
Expand Down
Loading