Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Cannot read flash partition #697

Open
DaneSlattery opened this issue Oct 25, 2024 · 3 comments
Open

Cannot read flash partition #697

DaneSlattery opened this issue Oct 25, 2024 · 3 comments
Labels
bug Something isn't working

Comments

@DaneSlattery
Copy link
Contributor

DaneSlattery commented Oct 25, 2024

I cannot read flash partitions with espflash on an esp32-s3 devkit over UART.

[2024-10-25T10:47:14Z INFO ] 🚀 A new version of espflash is available: v3.2.0
[2024-10-25T10:47:14Z INFO ] Serial port: '/dev/ttyUSB0'
[2024-10-25T10:47:14Z INFO ] Connecting...
[2024-10-25T10:47:14Z INFO ] Using flash stub
Chip type:         esp32s3 (revision v0.2)
Crystal frequency: 40 MHz
Flash size:        8MB
Features:          WiFi, BLE
MAC address:       30:30:f9:55:19:54
Error: espflash::read_flash::corrupt_data

  × Corrupt data, expected 1000 bytes but receved fd1 bytes

I am able to do the same with esptool.py:

esptool.py read_flash 0x9000 0x6000 ./nvs_dump.bin
esptool.py v4.8.1
Found 33 serial ports
Serial port /dev/ttyUSB0
Connecting....
Detecting chip type... ESP32-S3
Chip is ESP32-S3 (QFN56) (revision v0.2)
Features: WiFi, BLE, Embedded PSRAM 8MB (AP_3v3)
Crystal is 40MHz
MAC: 30:30:f9:55:19:54
Uploading stub...
Running stub...
Stub running...
Configuring flash size...
24576 (100 %)
24576 (100 %)
Read 24576 bytes at 0x00009000 in 2.2 seconds (90.0 kbit/s)...
Hard resetting via RTS pin...

I don't know what is missing?

@MabezDev
Copy link
Member

Can you try again with --no-stub?

@DaneSlattery
Copy link
Contributor Author

Here's the result:

espflash read-flash --no-stub 0x9000 0x6000 ./nvs_dump_devkit   
[2024-10-25T10:45:55Z INFO ] 🚀 A new version of espflash is available: v3.2.0
Error: espflash::stub_required

  × This command requires using the RAM stub
  help: Don't use the `--no-stub` option with the command

@zakimoo
Copy link

zakimoo commented Nov 21, 2024

same hier

espflash read-flash 0x0 0x0400000 test_3.bin

[2024-11-21T14:48:38Z INFO ] Serial port: '/dev/ttyUSB0'
[2024-11-21T14:48:38Z INFO ] Connecting...
[2024-11-21T14:48:38Z INFO ] Using flash stub
Chip type:         esp32c3 (revision v0.3)
Crystal frequency: 40 MHz
Flash size:        4MB
Features:          WiFi, BLE
MAC address:       a0:76:4e:5a:41:70
Error: espflash::read_flash::corrupt_data

  × Corrupt data, expected 1000 bytes but receved fcf bytes

but with esptool.py it works

esptool.py -b 460800 read_flash 0 0x0400000 flash_contents.bin
esptool.py v4.8.1
Found 1 serial ports
Serial port /dev/ttyUSB0
Connecting....
Detecting chip type... ESP32-C3
Chip is ESP32-C3 (QFN32) (revision v0.3)
Features: WiFi, BLE, Embedded Flash 4MB (XMC)
Crystal is 40MHz
MAC: a0:76:4e:5a:41:70
Uploading stub...
Running stub...
Stub running...
Changing baud rate to 460800
Changed.
Configuring flash size...
4194304 (100 %)
4194304 (100 %)
Read 4194304 bytes at 0x00000000 in 106.9 seconds (314.0 kbit/s)...
Hard resetting via RTS pin...

@jessebraham jessebraham added the bug Something isn't working label Jan 9, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
Status: Todo
Development

No branches or pull requests

4 participants