esptool-js icon indicating copy to clipboard operation
esptool-js copied to clipboard

Timeout connecting, but works on adafruit version of esptool-js

Open tyeth opened this issue 1 year ago • 3 comments

Board = PyPortal Titano (SAMD51 with onboard ESP32) Uploaded the SerialNINAPassthru sketch to allow esp32 to be connected to serial port in download mode. Connecting to serial shows esp boot message and download mode. image

Connecting using esptool-js site just keeps attempting to connect and fails https://espressif.github.io/esptool-js/ image

Connecting using adafruit site works. https://adafruit.github.io/Adafruit_WebSerial_ESPTool/ image

tyeth avatar May 09 '24 14:05 tyeth

Getting a slip read error programming, going to try another pc.

tyeth avatar May 09 '24 14:05 tyeth

Kept getting slip errors on adafruit esptool (espressif esptool wouldnt even connect) writing a 1.4mb firmware until I erased another time. (Had previously erased in theory, but not sure I let it complete). Then wrote fine

Still would expect espressif esptool-js to report the connected device like the adafruit one does.

tyeth avatar May 09 '24 15:05 tyeth

Could you Copy the trace and share here ?

brianignacio5 avatar May 28 '24 09:05 brianignacio5

Could you try my fork in https://brianignacio5.github.io/esptool-js/ which implement #160 changes ?

brianignacio5 avatar Nov 15 '24 01:11 brianignacio5

@brianignacio5 I thought generally this worked better, but had little proof. I even directed a user who had erasing issues to use it (successfully). Now tonight trying to erase an Adafruit Metro ESP32-S2 it seems to only fail / timeout. Same with main esptool-js, but the adafruit one has erased it successfully.

I'd put tinyuf2 bootloader 0.20.1 on it, along with Adafruit WipperSnapper a few days ago, and tonight I was testing the factory reset demo image via uf2 and now was about to test the .bin version when erase repeatedly failed in web version of esptool. Log from page with debug on:

esptool.js
Serial port WebSerial VendorID 0x303a ProductID 0x2
Connecting...Debug: _connect_attempt default_reset false
Debug: Timeout
Debug: Sync
Debug: Sync err Error: Timeout
.Debug: Sync
Debug: Sync err Error: Timeout
.Debug: Sync
Debug: 538052359

Debug: Chip Magic 7c6
Detecting chip type... ESP32-S2
Chip is ESP32-S2
Features: Wi-Fi,No Embedded Flash,No Embedded Flash,ADC and temperature sensor calibration in BLK2 of efuse V2
Crystal is 40MHz
MAC: 60:55:f9:d9:b1:46
Uploading stub...
Debug: mem_begin 4336 1 6144 40028000
Debug: check_command enter RAM download mode
Debug: check_command write to target RAM
Error: Timeout
Console Details

23:18:11.433 index.ts:121 Uncaught (in promise) NotFoundError: Failed to execute 'requestPort' on 'Serial': No port selected by the user.Understand this errorAI
23:18:17.114 esptool-js/:115 Canvas2D: Multiple readback operations using getImageData are faster with the willReadFrequently attribute set to true. See: https://html.spec.whatwg.org/multipage/canvas.html#concept-canvas-will-read-frequently
apply @ esptool-js/:115Understand this warningAI
23:18:18.297 webserial.js:47 TRACE 1188.000 command op:0x08 data len=36 wait_response=1 timeout=0.100 data=
    0707122055555555 5555555555555555 | ... UUUUUUUUUUUU
    5555555555555555 5555555555555555 | UUUUUUUUUUUUUUUU
    55555555                          | UUUU
23:18:18.297 webserial.js:115 Write bytes
23:18:18.297 webserial.js:47 TRACE 1188.000 Write 46 bytes: 
    c000082400000000 0007071220555555 | ...$........ UUU
    5555555555555555 5555555555555555 | UUUUUUUUUUUUUUUU
    5555555555555555 5555555555c0     | UUUUUUUUUUUUU.
23:18:18.358 webserial.js:47 TRACE 1249.000 command op:0x08 data len=36 wait_response=1 timeout=0.100 data=
    0707122055555555 5555555555555555 | ... UUUUUUUUUUUU
    5555555555555555 5555555555555555 | UUUUUUUUUUUUUUUU
    55555555                          | UUUU
23:18:18.358 webserial.js:115 Write bytes
23:18:18.358 webserial.js:47 TRACE 1249.000 Write 46 bytes: 
    c000082400000000 0007071220555555 | ...$........ UUU
    5555555555555555 5555555555555555 | UUUUUUUUUUUUUUUU
    5555555555555555 5555555555c0     | UUUUUUUUUUUUU.
23:18:18.525 webserial.js:47 TRACE 1416.000 command op:0x08 data len=36 wait_response=1 timeout=0.100 data=
    0707122055555555 5555555555555555 | ... UUUUUUUUUUUU
    5555555555555555 5555555555555555 | UUUUUUUUUUUUUUUU
    55555555                          | UUUU
23:18:18.525 webserial.js:115 Write bytes
23:18:18.525 webserial.js:47 TRACE 1416.000 Write 46 bytes: 
    c000082400000000 0007071220555555 | ...$........ UUU
    5555555555555555 5555555555555555 | UUUUUUUUUUUUUUUU
    5555555555555555 5555555555c0     | UUUUUUUUUUUUU.
23:18:18.534 webserial.js:228 Read bytes
23:18:18.534 webserial.js:47 TRACE 1425.000 Read 13 bytes: c0010804000707122000000000
23:18:18.534 webserial.js:234 Slip reader results
23:18:18.534 webserial.js:47 TRACE 1425.000 Read 0 bytes:                 
23:18:18.535 webserial.js:228 Read bytes
23:18:18.535 webserial.js:47 TRACE 1426.000 Read 14 bytes: c0010804000707122000000000c0
23:18:18.535 webserial.js:234 Slip reader results
23:18:18.535 webserial.js:47 TRACE 1426.000 Read 12 bytes: 010804000707122000000000
23:18:18.535 webserial.js:47 TRACE 1426.000 command op:0x0a data len=4 wait_response=1 timeout=3.000 data=00100040        
23:18:18.535 webserial.js:115 Write bytes
23:18:18.535 webserial.js:47 TRACE 1426.000 Write 14 bytes: c0000a04000000000000100040c0
23:18:18.541 webserial.js:228 Read bytes
23:18:18.541 webserial.js:47 TRACE 1432.000 Read 13 bytes: c0010804000707122000000000
23:18:18.541 webserial.js:234 Slip reader results
23:18:18.541 webserial.js:47 TRACE 1432.000 Read 0 bytes:                 
23:18:18.542 webserial.js:228 Read bytes
23:18:18.542 webserial.js:47 TRACE 1433.000 Read 15 bytes: c0010804000707122000000000c0c0
23:18:18.542 webserial.js:234 Slip reader results
23:18:18.542 webserial.js:47 TRACE 1433.000 Read 12 bytes: 010804000707122000000000
23:18:18.548 webserial.js:228 Read bytes
23:18:18.548 webserial.js:47 TRACE 1439.000 Read 12 bytes: c00108040007071220000000
23:18:18.548 webserial.js:234 Slip reader results
23:18:18.548 webserial.js:47 TRACE 1439.000 Read 0 bytes:                 
23:18:18.548 webserial.js:228 Read bytes
23:18:18.548 webserial.js:47 TRACE 1439.000 Read 13 bytes: c0010804000707122000000000
23:18:18.548 webserial.js:234 Slip reader results
23:18:18.548 webserial.js:47 TRACE 1439.000 Read 0 bytes:                 
23:18:18.549 webserial.js:228 Read bytes
23:18:18.549 webserial.js:47 TRACE 1440.000 Read 14 bytes: c0010804000707122000000000c0
23:18:18.549 webserial.js:234 Slip reader results
23:18:18.549 webserial.js:47 TRACE 1440.000 Read 12 bytes: 010804000707122000000000
23:18:18.556 webserial.js:228 Read bytes
23:18:18.556 webserial.js:47 TRACE 1447.000 Read 12 bytes: c00108040007071220000000
23:18:18.556 webserial.js:234 Slip reader results
23:18:18.556 webserial.js:47 TRACE 1447.000 Read 0 bytes:                 
23:18:18.556 webserial.js:228 Read bytes
23:18:18.556 webserial.js:47 TRACE 1447.000 Read 13 bytes: c0010804000707122000000000
23:18:18.556 webserial.js:234 Slip reader results
23:18:18.556 webserial.js:47 TRACE 1447.000 Read 0 bytes:                 
23:18:18.557 webserial.js:228 Read bytes
23:18:18.557 webserial.js:47 TRACE 1448.000 Read 14 bytes: c0010804000707122000000000c0
23:18:18.557 webserial.js:234 Slip reader results
23:18:18.557 webserial.js:47 TRACE 1448.000 Read 12 bytes: 010804000707122000000000
23:18:18.564 webserial.js:228 Read bytes
23:18:18.564 webserial.js:47 TRACE 1455.000 Read 12 bytes: c00108040007071220000000
23:18:18.564 webserial.js:234 Slip reader results
23:18:18.564 webserial.js:47 TRACE 1455.000 Read 0 bytes:                 
23:18:18.565 webserial.js:228 Read bytes
23:18:18.565 webserial.js:47 TRACE 1456.000 Read 14 bytes: c0010804000707122000000000c0
23:18:18.565 webserial.js:234 Slip reader results
23:18:18.565 webserial.js:47 TRACE 1456.000 Read 12 bytes: 010804000707122000000000
23:18:18.571 webserial.js:228 Read bytes
23:18:18.571 webserial.js:47 TRACE 1462.000 Read 12 bytes: c00108040007071220000000
23:18:18.571 webserial.js:234 Slip reader results
23:18:18.571 webserial.js:47 TRACE 1462.000 Read 0 bytes:                 
23:18:18.572 webserial.js:228 Read bytes
23:18:18.572 webserial.js:47 TRACE 1463.000 Read 14 bytes: c0010804000707122000000000c0
23:18:18.572 webserial.js:234 Slip reader results
23:18:18.572 webserial.js:47 TRACE 1463.000 Read 12 bytes: 010804000707122000000000
23:18:18.580 webserial.js:228 Read bytes
23:18:18.580 webserial.js:47 TRACE 1471.000 Read 12 bytes: c00108040007071220000000
23:18:18.580 webserial.js:234 Slip reader results
23:18:18.580 webserial.js:47 TRACE 1471.000 Read 0 bytes:                 
23:18:18.581 webserial.js:228 Read bytes
23:18:18.581 webserial.js:47 TRACE 1472.000 Read 13 bytes: c0010804000707122000000000
23:18:18.581 webserial.js:234 Slip reader results
23:18:18.581 webserial.js:47 TRACE 1472.000 Read 0 bytes:                 
23:18:18.582 webserial.js:228 Read bytes
23:18:18.582 webserial.js:47 TRACE 1473.000 Read 15 bytes: c0010804000707122000000000c0c0
23:18:18.582 webserial.js:234 Slip reader results
23:18:18.582 webserial.js:47 TRACE 1473.000 Read 12 bytes: 010804000707122000000000
23:18:18.588 webserial.js:228 Read bytes
23:18:18.588 webserial.js:47 TRACE 1479.000 Read 13 bytes: c0010804000707122000000000
23:18:18.588 webserial.js:234 Slip reader results
23:18:18.588 webserial.js:47 TRACE 1479.000 Read 0 bytes:                 
23:18:18.589 webserial.js:228 Read bytes
23:18:18.589 webserial.js:47 TRACE 1480.000 Read 14 bytes: c0010804000707122000000000c0
23:18:18.589 webserial.js:234 Slip reader results
23:18:18.589 webserial.js:47 TRACE 1480.000 Read 12 bytes: 010804000707122000000000
23:18:18.596 webserial.js:228 Read bytes
23:18:18.596 webserial.js:47 TRACE 1487.000 Read 12 bytes: c0010a0400c6070000000000
23:18:18.596 webserial.js:234 Slip reader results
23:18:18.596 webserial.js:47 TRACE 1487.000 Read 0 bytes:                 
23:18:18.596 webserial.js:228 Read bytes
23:18:18.597 webserial.js:47 TRACE 1488.000 Read 13 bytes: c0010a0400c607000000000000
23:18:18.597 webserial.js:234 Slip reader results
23:18:18.597 webserial.js:47 TRACE 1488.000 Read 0 bytes:                 
23:18:18.597 webserial.js:228 Read bytes
23:18:18.597 webserial.js:47 TRACE 1488.000 Read 14 bytes: c0010a0400c607000000000000c0
23:18:18.597 webserial.js:234 Slip reader results
23:18:18.597 webserial.js:47 TRACE 1488.000 Read 12 bytes: 010a0400c607000000000000
23:18:18.597 webserial.js:47 TRACE 1488.000 command op:0x0a data len=4 wait_response=1 timeout=3.000 data=50a0413f        
23:18:18.597 webserial.js:115 Write bytes
23:18:18.597 webserial.js:47 TRACE 1488.000 Write 14 bytes: c0000a04000000000050a0413fc0
23:18:18.604 webserial.js:228 Read bytes
23:18:18.604 webserial.js:47 TRACE 1495.000 Read 13 bytes: c0010a04000000000000000000
23:18:18.604 webserial.js:234 Slip reader results
23:18:18.604 webserial.js:47 TRACE 1495.000 Read 0 bytes:                 
23:18:18.605 webserial.js:228 Read bytes
23:18:18.605 webserial.js:47 TRACE 1496.000 Read 14 bytes: c0010a04000000000000000000c0
23:18:18.605 webserial.js:234 Slip reader results
23:18:18.605 webserial.js:47 TRACE 1496.000 Read 12 bytes: 010a04000000000000000000
23:18:18.605 webserial.js:47 TRACE 1496.000 command op:0x0a data len=4 wait_response=1 timeout=3.000 data=50a0413f        
23:18:18.605 webserial.js:115 Write bytes
23:18:18.605 webserial.js:47 TRACE 1496.000 Write 14 bytes: c0000a04000000000050a0413fc0
23:18:18.612 webserial.js:228 Read bytes
23:18:18.612 webserial.js:47 TRACE 1503.000 Read 12 bytes: c0010a040000000000000000
23:18:18.612 webserial.js:234 Slip reader results
23:18:18.612 webserial.js:47 TRACE 1503.000 Read 0 bytes:                 
23:18:18.612 webserial.js:228 Read bytes
23:18:18.612 webserial.js:47 TRACE 1503.000 Read 13 bytes: c0010a04000000000000000000
23:18:18.612 webserial.js:234 Slip reader results
23:18:18.612 webserial.js:47 TRACE 1503.000 Read 0 bytes:                 
23:18:18.613 webserial.js:228 Read bytes
23:18:18.613 webserial.js:47 TRACE 1504.000 Read 14 bytes: c0010a04000000000000000000c0
23:18:18.613 webserial.js:234 Slip reader results
23:18:18.613 webserial.js:47 TRACE 1504.000 Read 12 bytes: 010a04000000000000000000
23:18:18.614 webserial.js:47 TRACE 1505.000 command op:0x0a data len=4 wait_response=1 timeout=3.000 data=50a0413f        
23:18:18.614 webserial.js:115 Write bytes
23:18:18.614 webserial.js:47 TRACE 1505.000 Write 14 bytes: c0000a04000000000050a0413fc0
23:18:18.620 webserial.js:228 Read bytes
23:18:18.620 webserial.js:47 TRACE 1511.000 Read 12 bytes: c0010a040000000000000000
23:18:18.620 webserial.js:234 Slip reader results
23:18:18.620 webserial.js:47 TRACE 1511.000 Read 0 bytes:                 
23:18:18.621 webserial.js:228 Read bytes
23:18:18.621 webserial.js:47 TRACE 1512.000 Read 14 bytes: c0010a04000000000000000000c0
23:18:18.621 webserial.js:234 Slip reader results
23:18:18.621 webserial.js:47 TRACE 1512.000 Read 12 bytes: 010a04000000000000000000
23:18:18.622 webserial.js:47 TRACE 1513.000 command op:0x0a data len=4 wait_response=1 timeout=3.000 data=6ca0413f        
23:18:18.622 webserial.js:115 Write bytes
23:18:18.622 webserial.js:47 TRACE 1513.000 Write 14 bytes: c0000a0400000000006ca0413fc0
23:18:18.628 webserial.js:228 Read bytes
23:18:18.628 webserial.js:47 TRACE 1519.000 Read 13 bytes: c0010a0400ae972c0800000000
23:18:18.628 webserial.js:234 Slip reader results
23:18:18.628 webserial.js:47 TRACE 1519.000 Read 0 bytes:                 
23:18:18.629 webserial.js:228 Read bytes
23:18:18.629 webserial.js:47 TRACE 1520.000 Read 14 bytes: c0010a0400ae972c0800000000c0
23:18:18.629 webserial.js:234 Slip reader results
23:18:18.630 webserial.js:47 TRACE 1521.000 Read 12 bytes: 010a0400ae972c0800000000
23:18:18.630 webserial.js:47 TRACE 1521.000 command op:0x0a data len=4 wait_response=1 timeout=3.000 data=44a0413f        
23:18:18.630 webserial.js:115 Write bytes
23:18:18.630 webserial.js:47 TRACE 1521.000 Write 14 bytes: c0000a04000000000044a0413fc0
23:18:18.636 webserial.js:228 Read bytes
23:18:18.636 webserial.js:47 TRACE 1527.000 Read 13 bytes: c0010a040046b1d9f900000000
23:18:18.636 webserial.js:234 Slip reader results
23:18:18.636 webserial.js:47 TRACE 1528.000 Read 0 bytes:                 
23:18:18.637 webserial.js:228 Read bytes
23:18:18.637 webserial.js:47 TRACE 1528.000 Read 14 bytes: c0010a040046b1d9f900000000c0
23:18:18.638 webserial.js:234 Slip reader results
23:18:18.638 webserial.js:47 TRACE 1529.000 Read 12 bytes: 010a040046b1d9f900000000
23:18:18.638 webserial.js:47 TRACE 1529.000 command op:0x0a data len=4 wait_response=1 timeout=3.000 data=48a0413f        
23:18:18.638 webserial.js:115 Write bytes
23:18:18.638 webserial.js:47 TRACE 1529.000 Write 14 bytes: c0000a04000000000048a0413fc0
23:18:18.646 webserial.js:228 Read bytes
23:18:18.646 webserial.js:47 TRACE 1537.000 Read 14 bytes: c0010a04005560000000000000c0
23:18:18.646 webserial.js:234 Slip reader results
23:18:18.646 webserial.js:47 TRACE 1537.000 Read 12 bytes: 010a04005560000000000000
23:18:18.646 webserial.js:47 TRACE 1537.000 command op:0x0a data len=4 wait_response=1 timeout=3.000 data=44a0413f        
23:18:18.646 webserial.js:115 Write bytes
23:18:18.646 webserial.js:47 TRACE 1537.000 Write 14 bytes: c0000a04000000000044a0413fc0
23:18:18.654 webserial.js:228 Read bytes
23:18:18.654 webserial.js:47 TRACE 1545.000 Read 13 bytes: c0010a040046b1d9f900000000
23:18:18.654 webserial.js:234 Slip reader results
23:18:18.654 webserial.js:47 TRACE 1545.000 Read 0 bytes:                 
23:18:18.655 webserial.js:228 Read bytes
23:18:18.655 webserial.js:47 TRACE 1546.000 Read 14 bytes: c0010a040046b1d9f900000000c0
23:18:18.655 webserial.js:234 Slip reader results
23:18:18.655 webserial.js:47 TRACE 1546.000 Read 12 bytes: 010a040046b1d9f900000000
23:18:18.655 webserial.js:47 TRACE 1546.000 command op:0x0a data len=4 wait_response=1 timeout=3.000 data=48a0413f        
23:18:18.655 webserial.js:115 Write bytes
23:18:18.655 webserial.js:47 TRACE 1546.000 Write 14 bytes: c0000a04000000000048a0413fc0
23:18:18.665 webserial.js:228 Read bytes
23:18:18.665 webserial.js:47 TRACE 1556.000 Read 12 bytes: c0010a040055600000000000
23:18:18.665 webserial.js:234 Slip reader results
23:18:18.665 webserial.js:47 TRACE 1556.000 Read 0 bytes:                 
23:18:18.666 webserial.js:228 Read bytes
23:18:18.666 webserial.js:47 TRACE 1557.000 Read 13 bytes: c0010a04005560000000000000
23:18:18.666 webserial.js:234 Slip reader results
23:18:18.666 webserial.js:47 TRACE 1557.000 Read 0 bytes:                 
23:18:18.667 webserial.js:228 Read bytes
23:18:18.667 webserial.js:47 TRACE 1558.000 Read 14 bytes: c0010a04005560000000000000c0
23:18:18.667 webserial.js:234 Slip reader results
23:18:18.667 webserial.js:47 TRACE 1558.000 Read 12 bytes: 010a04005560000000000000
23:18:18.667 webserial.js:47 TRACE 1558.000 command op:0x05 data len=16 wait_response=1 timeout=3.000 data=f0100000010000000018000000800240
23:18:18.667 webserial.js:115 Write bytes
23:18:18.667 webserial.js:47 TRACE 1558.000 Write 26 bytes: 
    c000051000000000 00f0100000010000 | ................
    0000180000008002 40c0             | ........@.
23:18:18.674 webserial.js:228 Read bytes
23:18:18.674 webserial.js:47 TRACE 1565.000 Read 12 bytes: c00105040055600000000000
23:18:18.674 webserial.js:234 Slip reader results
23:18:18.674 webserial.js:47 TRACE 1565.000 Read 0 bytes:                 
23:18:18.675 webserial.js:228 Read bytes
23:18:18.675 webserial.js:47 TRACE 1566.000 Read 13 bytes: c0010504005560000000000000
23:18:18.675 webserial.js:234 Slip reader results
23:18:18.675 webserial.js:47 TRACE 1566.000 Read 0 bytes:                 
23:18:18.675 webserial.js:228 Read bytes
23:18:18.675 webserial.js:47 TRACE 1566.000 Read 14 bytes: c0010504005560000000000000c0
23:18:18.675 webserial.js:234 Slip reader results
23:18:18.675 webserial.js:47 TRACE 1566.000 Read 12 bytes: 010504005560000000000000
23:18:18.677 webserial.js:47 TRACE 1568.000 command op:0x07 data len=4352 wait_response=1 timeout=3.000 data=
    f010000000000000 0000000000000000 | ................
    080000601c000060 4800fd3f10000060 | ...`...`H..?...`
    36410021fbffc020 00380241faffc020 | 6A.!... .8.A... 
    0028042020949ce2 41f8ff4604000c38 | .(.  ...A..F...8
    308801c02000a808 8804a0a074e00800 | 0... .......t...
    0b226602e886f4ff 21f1ffc020003902 | ."f.....!... .9.
    1df00000ec2bfe3f 64abfd3f84800000 | .....+.?d..?....
    40400000a4ebfd3f f02bfe3f364100b1 | @@.....?.+.?6A..
    f9ff20a074101120 650101961a0681f6 | .. .t.. e.......
    ff92a1019099119a 98c02000b80991f3 | .......... .....
    ffa0a0749a88c020 009218009090f41b | ...t... ........
    c9c0c0f4c02000c2 58009a9bc02000a2 | ..... ..X.... ..
    4900c02000921800 81eaff9090f48080 | I.. ............
    f487994781e5ff92 a1019099119a98c0 | ...G............
    2000c809a1e5ffb1 e3ff879c17c60100 |  ...............
    7ce8871adec60800 c02000890ac02000 | |........ .... .
    b909460200c02000 b90ac02000890991 | ..F... .... ....
    d7ff9a880c09c020 009258001df00000 | ....... ..X.....
    5420403f5430403f 36410091fdffc020 | T @?T0@?6A..... 
    0088098080245648 ff91faffc0200088 | .....$VH..... ..
    098080245648ff1d f00000002c20403f | ...$VH......, @?
    0020403f00000008 364100101120a5fc | . @?....6A... ..
    ff21faff0c08c020 0082620091faff81 | .!..... ..b.....
    f8ffc02000926800 c0200098085679ff | ... ..h.. ...Vy.
    c0200088027cf280 22302020041df000 | . ...|.."0  ....
    0000004036410010 1120e5fbff166aff | ...@6A... ....j.
    81ecff91fbffc020 00926800c0200098 | ....... ..h.. ..
    085679ff1df00000 5800fd3fffffff00 | .Vy.....X..?....
    0420403f36410021 fcff384216830610 | . @?6A.!..8B....
    112065f8ff16fa05 0cf80c0437a80d98 | . e.........7...
    2280991082a00190 4883404074101120 | ".......H.@@t.. 
    25faff10112025f3 ff88220c1b409811 | %.... %..."..@..
    90ab01cc1480ab01 b1edffb09910b1ec | ................
    ffc02000926b0091 ceffc02000a26900 | .. ..k..... ..i.
    c02000a809567aff 1c090c1a409a8390 | . ...Vz.....@...
    33c09a8839428922 1df0000070e2fa3f | 3...9B."....p..?
    0820403f84620140 a462014036610010 | . @[email protected].@6a..
    112065edff31f9ff bd01ad0381faffe0 | . e..1..........
    08004d0a0c12ecea 880192a200908810 | ..M.............
    8901101120e5f1ff 91f2ffa0a201c020 | .... .......... 
    008809a08820c020 008909b801ad0381 | ..... . ........
    eeffe00800a02483 1df00000ff0f0000 | ......$.........
    36410081c5ff0c19 924800309c419928 | 6A.......H.0.A.(
    91fbff3918293830 30b49a222a33303c | ...9.)800.."*30

tyeth avatar Nov 19 '24 23:11 tyeth

It seems the esp32 s2 has some issues yet. I have here a esp32 s2 devkitC 1 which seems to connect properly on my setup but I need more testing.

Could you try with esptool.py but using the --trace argument so I can compare the output ?

brianignacio5 avatar Nov 20 '24 00:11 brianignacio5

Just to confirm, which version of esptool.py?

On Wed, 20 Nov 2024 at 00:27, Brian A. Ignacio @.***> wrote:

It seems the esp32 s2 has some issues yet. I have here a esp32 s2 devkitC 1 which seems to connect properly on my setup but I need more testing.

Could you try with esptool.py but using the --trace argument so I can compare the output ?

— Reply to this email directly, view it on GitHub https://github.com/espressif/esptool-js/issues/141#issuecomment-2487040423, or unsubscribe https://github.com/notifications/unsubscribe-auth/ABTBZ4Y6DDWPCPNPNWSBWFD2BPJQJAVCNFSM6AAAAABR2EJDEGVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDIOBXGA2DANBSGM . You are receiving this because you authored the thread.Message ID: @.***>

tyeth avatar Nov 20 '24 00:11 tyeth

This was 5.3.1 idf using esptool 4.8.1

Details

C:\dev\esp-idf [(v5.3.1) +0 ~19 -0 !]> ./export.ps1
Setting IDF_PATH: C:\dev\esp-idf
Checking Python compatibility
Adding ESP-IDF tools to PATH...
Not using an unsupported version of tool xtensa-esp-elf found in PATH: esp-13.2.0_20230928. To use it, run 'C:\Python312\python.exe C:\dev\esp-idf\tools\idf_tools.py export --prefer-system'

Name                           Value
----                           -----
OPENOCD_SCRIPTS                C:\dev\Espressif\tools\openocd-esp32\v0.12.0-esp32-20240318\openocd-esp32\sh… 
IDF_CCACHE_ENABLE              1
ESP_ROM_ELF_DIR                C:\dev\Espressif\tools\esp-rom-elfs\20240305\
IDF_PYTHON_ENV_PATH            C:\dev\Espressif\python_env\idf5.3_py3.12_env
ESP_IDF_VERSION                5.3
IDF_DEACTIVATE_FILE_PATH       C:\Users\tyeth\AppData\Local\Temp\tmp8n_1h77qidf_4584

Added to PATH
-------------
C:\dev\Espressif\tools\xtensa-esp-elf-gdb\14.2_20240403\xtensa-esp-elf-gdb\bin
C:\dev\Espressif\tools\riscv32-esp-elf-gdb\14.2_20240403\riscv32-esp-elf-gdb\bin
C:\dev\Espressif\tools\xtensa-esp-elf\esp-13.2.0_20240530\xtensa-esp-elf\bin
C:\dev\Espressif\tools\riscv32-esp-elf\esp-13.2.0_20240530\riscv32-esp-elf\bin
C:\dev\Espressif\tools\esp32ulp-elf\2.38_20240113\esp32ulp-elf\bin
C:\dev\Espressif\tools\cmake\3.24.0\bin
C:\dev\Espressif\tools\openocd-esp32\v0.12.0-esp32-20240318\openocd-esp32\bin
C:\dev\Espressif\tools\ninja\1.11.1\
C:\dev\Espressif\tools\idf-exe\1.0.3\
C:\dev\Espressif\tools\ccache\4.8\ccache-4.8-windows-x86_64
C:\dev\Espressif\tools\dfu-util\0.11\dfu-util-0.11-win64
C:\dev\Espressif\python_env\idf5.3_py3.12_env\Scripts
C:\dev\esp-idf\tools
Checking if Python packages are up to date...
Constraint file: C:\dev\Espressif\espidf.constraints.v5.3.txt
Requirement files:
 - C:\dev\esp-idf\tools\requirements\requirements.core.txt
Python being checked: C:\dev\Espressif\python_env\idf5.3_py3.12_env\Scripts\python.exe
Python requirements are satisfied.

Detected installed tools that are not currently used by active ESP-IDF version.
For removing old versions of espup, msys2, rustup, vc_redist, xtensa-esp32s2-elf use command 'python.exe C:\dev\esp-idf\tools\idf_tools.py uninstall'
For free up even more space, remove installation packages of those tools. Use option 'python.exe C:\dev\esp-idf\tools\idf_tools.py uninstall --remove-archives'.


Done! You can now compile ESP-IDF projects.
Go to the project directory and run:
    idf.py build



C:\dev\esp-idf [(v5.3.1) +0 ~19 -0 !]> esptool.py.exe
esptool.py.exe: The term 'esptool.py.exe' is not recognized as a name of a cmdlet, function, script file, or executable program.
Check the spelling of the name, or if a path was included, verify that the path is correct and try again.
C:\dev\esp-idf [(v5.3.1) +0 ~19 -0 !]> python -m esptool --trace erase_flash                                 
esptool.py v4.8.1
Found 1 serial ports
Serial port COM29
Connecting...
COM29 failed to connect: Cannot configure port, something went wrong. Original message: OSError(22, 'A device which does not exist was specified.', None, 433)

A fatal error occurred: Could not connect to an Espressif device on any of the 1 available serial ports.     
C:\dev\esp-idf [(v5.3.1) +0 ~19 -0 !]> python -m esptool --trace erase_flash
esptool.py v4.8.1
Found 1 serial ports
Serial port COM7
Connecting...TRACE +0.000 command op=0x08 data len=36 wait_response=1 timeout=0.100 data=
    0707122055555555 5555555555555555 | ... UUUUUUUUUUUU
    5555555555555555 5555555555555555 | UUUUUUUUUUUUUUUU
    55555555                          | UUUU
TRACE +0.001 Write 46 bytes:
    c000082400000000 0007071220555555 | ...$........ UUU
    5555555555555555 5555555555555555 | UUUUUUUUUUUUUUUU
    5555555555555555 5555555555c0     | UUUUUUUUUUUUU.
TRACE +0.001 Read 1 bytes: c0
TRACE +0.001 Read 1 bytes: 01
TRACE +0.001 Read 1 bytes: 08
TRACE +0.000 Read 1 bytes: 04
TRACE +0.001 Read 1 bytes: 00
TRACE +0.000 Read 1 bytes: 07
TRACE +0.001 Read 1 bytes: 07
TRACE +0.000 Read 1 bytes: 12
TRACE +0.001 Read 1 bytes: 20
TRACE +0.000 Read 1 bytes: 00
TRACE +0.001 Read 1 bytes: 00
TRACE +0.000 Read 1 bytes: 00
TRACE +0.001 Read 1 bytes: 00
TRACE +0.000 Read 1 bytes: c0
TRACE +0.000 Received full packet: 010804000707122000000000
TRACE +0.022 Read 47 bytes: 
    c001080400070712 2000000000c0c001 | ........ .......
    0804000707122000 000000c0c0010804 | ...... .........
    0007071220000000 00c0c001080400   | .... ..........
TRACE +0.002 Received full packet: 010804000707122000000000
TRACE +0.023 Received full packet: 010804000707122000000000
TRACE +0.002 Received full packet: 010804000707122000000000
TRACE +0.003 Read 51 bytes:
    0707122000000000 c0c0010804000707 | ... ............
    122000000000c0c0 0108040007071220 | . .............
    00000000c0c00108 0400070712200000 | ............. ..
    0000c0                            | ...
TRACE +0.000 Received full packet: 010804000707122000000000
TRACE +0.003 Received full packet: 010804000707122000000000
TRACE +0.003 Received full packet: 010804000707122000000000
TRACE +0.003 Received full packet: 010804000707122000000000

Detecting chip type...TRACE +0.003 command op=0x14 data len=0 wait_response=1 timeout=3.000 data=
TRACE +0.000 Write 10 bytes: c00014000000000000c0
TRACE +0.001 Read 1 bytes: c0
TRACE +0.001 Read 1 bytes: 01
TRACE +0.001 Read 1 bytes: 14
TRACE +0.001 Read 1 bytes: 10
TRACE +0.001 Read 1 bytes: 00
TRACE +0.000 Read 1 bytes: 00
TRACE +0.001 Read 1 bytes: 00
TRACE +0.000 Read 1 bytes: 00
TRACE +0.001 Read 1 bytes: 00
TRACE +0.000 Read 1 bytes: 00
TRACE +0.001 Read 1 bytes: 00
TRACE +0.000 Read 1 bytes: 00
TRACE +0.001 Read 1 bytes: 00
TRACE +0.000 Read 1 bytes: 00
TRACE +0.002 Read 1 bytes: 00
TRACE +0.000 Read 1 bytes: 00
TRACE +0.001 Read 1 bytes: 00
TRACE +0.000 Read 1 bytes: 00
TRACE +0.001 Read 1 bytes: 00
TRACE +0.000 Read 1 bytes: 00
TRACE +0.001 Read 1 bytes: 00
TRACE +0.000 Read 1 bytes: 00
TRACE +0.001 Read 1 bytes: 00
TRACE +0.000 Read 1 bytes: 00
TRACE +0.001 Read 1 bytes: 00
TRACE +0.000 Read 1 bytes: c0
TRACE +0.000 Received full packet:
    0114100000000000 0000000000000000 | ................
    0000000000000000                  | ........
 Unsupported detection protocol, switching and trying again...
Detecting chip type...TRACE +0.003 command op=0x0a data len=4 wait_response=1 timeout=3.000 data=00100040    
TRACE +0.000 Write 14 bytes: c0000a04000000000000100040c0
TRACE +0.000 Read 1 bytes: c0
TRACE +0.002 Read 1 bytes: 01
TRACE +0.001 Read 1 bytes: 0a
TRACE +0.000 Read 1 bytes: 04
TRACE +0.001 Read 1 bytes: 00
TRACE +0.000 Read 1 bytes: c6
TRACE +0.001 Read 1 bytes: 07
TRACE +0.000 Read 1 bytes: 00
TRACE +0.001 Read 1 bytes: 00
TRACE +0.000 Read 1 bytes: 00
TRACE +0.001 Read 1 bytes: 00
TRACE +0.000 Read 1 bytes: 00
TRACE +0.001 Read 1 bytes: 00
TRACE +0.000 Read 1 bytes: c0
TRACE +0.000 Received full packet: 010a0400c607000000000000
TRACE +0.000 command op=0x0a data len=4 wait_response=1 timeout=3.000 data=14fdff3f
TRACE +0.000 Write 14 bytes: c0000a04000000000014fdff3fc0
TRACE +0.001 Read 1 bytes: c0
TRACE +0.001 Read 1 bytes: 01
TRACE +0.000 Read 1 bytes: 0a
TRACE +0.001 Read 1 bytes: 04
TRACE +0.000 Read 1 bytes: 00
TRACE +0.001 Read 1 bytes: 02
TRACE +0.001 Read 1 bytes: 00
TRACE +0.000 Read 1 bytes: 00
TRACE +0.001 Read 1 bytes: 00
TRACE +0.000 Read 1 bytes: 00
TRACE +0.001 Read 1 bytes: 00
TRACE +0.000 Read 1 bytes: 00
TRACE +0.001 Read 1 bytes: 00
TRACE +0.001 Read 1 bytes: c0
TRACE +0.000 Received full packet: 010a04000200000000000000
 ESP32-S2
TRACE +0.004 command op=0x0a data len=4 wait_response=1 timeout=3.000 data=50a0413f
TRACE +0.000 Write 14 bytes: c0000a04000000000050a0413fc0
TRACE +0.000 Read 1 bytes: c0
TRACE +0.001 Read 1 bytes: 01
TRACE +0.000 Read 1 bytes: 0a
TRACE +0.001 Read 1 bytes: 04
TRACE +0.001 Read 1 bytes: 00
TRACE +0.001 Read 1 bytes: 00
TRACE +0.000 Read 1 bytes: 00
TRACE +0.001 Read 1 bytes: 00
TRACE +0.000 Read 1 bytes: 00
TRACE +0.001 Read 1 bytes: 00
TRACE +0.000 Read 1 bytes: 00
TRACE +0.001 Read 1 bytes: 00
TRACE +0.000 Read 1 bytes: 00
TRACE +0.001 Read 1 bytes: c0
TRACE +0.000 Received full packet: 010a04000000000000000000
TRACE +0.002 command op=0x0a data len=4 wait_response=1 timeout=3.000 data=50a0413f
TRACE +0.001 Write 14 bytes: c0000a04000000000050a0413fc0
TRACE +0.000 Read 1 bytes: c0
TRACE +0.001 Read 1 bytes: 01
TRACE +0.001 Read 1 bytes: 0a
TRACE +0.000 Read 1 bytes: 04
TRACE +0.002 Read 1 bytes: 00
TRACE +0.001 Read 1 bytes: 00
TRACE +0.000 Read 1 bytes: 00
TRACE +0.001 Read 1 bytes: 00
TRACE +0.001 Read 1 bytes: 00
TRACE +0.000 Read 1 bytes: 00
TRACE +0.001 Read 1 bytes: 00
TRACE +0.000 Read 1 bytes: 00
TRACE +0.001 Read 1 bytes: 00
TRACE +0.000 Read 1 bytes: c0
TRACE +0.000 Received full packet: 010a04000000000000000000
TRACE +0.003 command op=0x0a data len=4 wait_response=1 timeout=3.000 data=50a0413f
TRACE +0.000 Write 14 bytes: c0000a04000000000050a0413fc0
TRACE +0.000 Read 1 bytes: c0
TRACE +0.001 Read 1 bytes: 01
TRACE +0.002 Read 1 bytes: 0a
TRACE +0.000 Read 1 bytes: 04
TRACE +0.001 Read 1 bytes: 00
TRACE +0.000 Read 1 bytes: 00
TRACE +0.001 Read 1 bytes: 00
TRACE +0.001 Read 1 bytes: 00
TRACE +0.001 Read 1 bytes: 00
TRACE +0.000 Read 1 bytes: 00
TRACE +0.001 Read 1 bytes: 00
TRACE +0.001 Read 1 bytes: 00
TRACE +0.000 Read 1 bytes: 00
TRACE +0.000 Read 1 bytes: c0
TRACE +0.000 Received full packet: 010a04000000000000000000
TRACE +0.002 command op=0x0a data len=4 wait_response=1 timeout=3.000 data=50a0413f
TRACE +0.002 Write 14 bytes: c0000a04000000000050a0413fc0
TRACE +0.000 Read 1 bytes: c0
TRACE +0.002 Read 1 bytes: 01
TRACE +0.000 Read 1 bytes: 0a
TRACE +0.001 Read 1 bytes: 04
TRACE +0.000 Read 1 bytes: 00
TRACE +0.000 Read 1 bytes: 00
TRACE +0.000 Read 1 bytes: 00
TRACE +0.002 Read 1 bytes: 00
TRACE +0.000 Read 1 bytes: 00
TRACE +0.000 Read 1 bytes: 00
TRACE +0.002 Read 1 bytes: 00
TRACE +0.000 Read 1 bytes: 00
TRACE +0.002 Read 1 bytes: 00
TRACE +0.000 Read 1 bytes: c0
TRACE +0.000 Received full packet: 010a04000000000000000000
TRACE +0.003 command op=0x0a data len=4 wait_response=1 timeout=3.000 data=54a0413f
TRACE +0.000 Write 14 bytes: c0000a04000000000054a0413fc0
TRACE +0.001 Read 1 bytes: c0
TRACE +0.001 Read 1 bytes: 01
TRACE +0.001 Read 1 bytes: 0a
TRACE +0.000 Read 1 bytes: 04
TRACE +0.001 Read 1 bytes: 00
TRACE +0.000 Read 1 bytes: 00
TRACE +0.001 Read 1 bytes: 00
TRACE +0.000 Read 1 bytes: 00
TRACE +0.001 Read 1 bytes: 00
TRACE +0.000 Read 1 bytes: 00
TRACE +0.001 Read 1 bytes: 00
TRACE +0.000 Read 1 bytes: 00
TRACE +0.001 Read 1 bytes: 00
TRACE +0.001 Read 1 bytes: c0
TRACE +0.000 Received full packet: 010a04000000000000000000
Chip is ESP32-S2 (revision v0.0)
TRACE +0.003 command op=0x0a data len=4 wait_response=1 timeout=3.000 data=50a0413f
TRACE +0.000 Write 14 bytes: c0000a04000000000050a0413fc0
TRACE +0.001 Read 1 bytes: c0
TRACE +0.001 Read 1 bytes: 01
TRACE +0.001 Read 1 bytes: 0a
TRACE +0.001 Read 1 bytes: 04
TRACE +0.001 Read 1 bytes: 00
TRACE +0.000 Read 1 bytes: 00
TRACE +0.003 Read 1 bytes: 00
TRACE +0.000 Read 1 bytes: 00
TRACE +0.001 Read 1 bytes: 00
TRACE +0.001 Read 1 bytes: 00
TRACE +0.001 Read 1 bytes: 00
TRACE +0.000 Read 1 bytes: 00
TRACE +0.001 Read 1 bytes: 00
TRACE +0.000 Read 1 bytes: c0
TRACE +0.000 Received full packet: 010a04000000000000000000
TRACE +0.003 command op=0x0a data len=4 wait_response=1 timeout=3.000 data=50a0413f
TRACE +0.001 Write 14 bytes: c0000a04000000000050a0413fc0
TRACE +0.000 Read 1 bytes: c0
TRACE +0.002 Read 1 bytes: 01
TRACE +0.001 Read 1 bytes: 0a
TRACE +0.000 Read 1 bytes: 04
TRACE +0.001 Read 1 bytes: 00
TRACE +0.000 Read 1 bytes: 00
TRACE +0.000 Read 1 bytes: 00
TRACE +0.001 Read 1 bytes: 00
TRACE +0.000 Read 1 bytes: 00
TRACE +0.001 Read 1 bytes: 00
TRACE +0.001 Read 1 bytes: 00
TRACE +0.000 Read 1 bytes: 00
TRACE +0.000 Read 1 bytes: 00
TRACE +0.001 Read 1 bytes: c0
TRACE +0.001 Received full packet: 010a04000000000000000000
TRACE +0.003 command op=0x0a data len=4 wait_response=1 timeout=3.000 data=6ca0413f
TRACE +0.000 Write 14 bytes: c0000a0400000000006ca0413fc0
TRACE +0.001 Read 1 bytes: c0
TRACE +0.001 Read 1 bytes: 01
TRACE +0.000 Read 1 bytes: 0a
TRACE +0.001 Read 1 bytes: 04
TRACE +0.000 Read 1 bytes: 00
TRACE +0.001 Read 1 bytes: ae
TRACE +0.000 Read 1 bytes: 97
TRACE +0.001 Read 1 bytes: 2c
TRACE +0.000 Read 1 bytes: 08
TRACE +0.001 Read 1 bytes: 00
TRACE +0.000 Read 1 bytes: 00
TRACE +0.001 Read 1 bytes: 00
TRACE +0.000 Read 1 bytes: 00
TRACE +0.002 Read 1 bytes: c0
TRACE +0.000 Received full packet: 010a0400ae972c0800000000
Features: WiFi, No Embedded Flash, No Embedded PSRAM, ADC and temperature sensor calibration in BLK2 of efuse V2
Crystal is 40MHz
TRACE +0.004 command op=0x0a data len=4 wait_response=1 timeout=3.000 data=44a0413f
TRACE +0.001 Write 14 bytes: c0000a04000000000044a0413fc0
TRACE +0.000 Read 1 bytes: c0
TRACE +0.001 Read 1 bytes: 01
TRACE +0.001 Read 1 bytes: 0a
TRACE +0.000 Read 1 bytes: 04
TRACE +0.001 Read 1 bytes: 00
TRACE +0.000 Read 1 bytes: 46
TRACE +0.002 Read 1 bytes: b1
TRACE +0.000 Read 1 bytes: d9
TRACE +0.001 Read 1 bytes: f9
TRACE +0.000 Read 1 bytes: 00
TRACE +0.002 Read 1 bytes: 00
TRACE +0.000 Read 1 bytes: 00
TRACE +0.001 Read 1 bytes: 00
TRACE +0.000 Read 1 bytes: c0
TRACE +0.000 Received full packet: 010a040046b1d9f900000000
TRACE +0.002 command op=0x0a data len=4 wait_response=1 timeout=3.000 data=48a0413f
TRACE +0.000 Write 14 bytes: c0000a04000000000048a0413fc0
TRACE +0.001 Read 1 bytes: c0
TRACE +0.001 Read 1 bytes: 01
TRACE +0.000 Read 1 bytes: 0a
TRACE +0.001 Read 1 bytes: 04
TRACE +0.000 Read 1 bytes: 00
TRACE +0.001 Read 1 bytes: 55
TRACE +0.001 Read 1 bytes: 60
TRACE +0.001 Read 1 bytes: 00
TRACE +0.000 Read 1 bytes: 00
TRACE +0.000 Read 1 bytes: 00
TRACE +0.001 Read 1 bytes: 00
TRACE +0.000 Read 1 bytes: 00
TRACE +0.001 Read 1 bytes: 00
TRACE +0.001 Read 1 bytes: c0
TRACE +0.000 Received full packet: 010a04005560000000000000
MAC: 60:55:f9:d9:b1:46
Uploading stub...
TRACE +0.013 command op=0x05 data len=16 wait_response=1 timeout=3.000 data=5c110000030000000008000000800240 
TRACE +0.000 Write 26 bytes:
    c000051000000000 005c110000030000 | .........\......
    0000080000008002 40c0             | ........@.
TRACE +0.001 Read 1 bytes: c0
TRACE +0.000 Read 1 bytes: 01
TRACE +0.000 Read 1 bytes: 05
TRACE +0.002 Read 1 bytes: 04
TRACE +0.001 Read 1 bytes: 00
TRACE +0.001 Read 1 bytes: 55
TRACE +0.001 Read 1 bytes: 60
TRACE +0.000 Read 1 bytes: 00
TRACE +0.001 Read 1 bytes: 00
TRACE +0.000 Read 1 bytes: 00
TRACE +0.001 Read 1 bytes: 00
TRACE +0.000 Read 1 bytes: 00
TRACE +0.001 Read 1 bytes: 00
TRACE +0.000 Read 1 bytes: c0
TRACE +0.001 Received full packet: 010504005560000000000000
TRACE +0.003 command op=0x07 data len=2064 wait_response=1 timeout=3.000 data=
    0008000000000000 0000000000000000 | ................
    080000601c000060 4800fd3f10000060 | ...`...`H..?...`
    36410021fbffc020 00380241faffc020 | 6A.!... .8.A...
    0028042020949ce2 41f8ff4604000c38 | .(.  ...A..F...8
    308801c02000a808 8804a0a074e00800 | 0... .......t...
    0b226602e886f4ff 21f1ffc020003902 | ."f.....!... .9.
    1df00000ec2bfe3f 64abfd3f84800000 | .....+.?d..?....
    40400000a4ebfd3f f02bfe3f364100b1 | @@.....?.+.?6A..
    f9ff20a074101120 250801961a0681f6 | .. .t.. %.......
    ff92a1019099119a 98c02000b80991f3 | .......... .....
    ffa0a0749a88c020 009218009090f41b | ...t... ........
    c9c0c0f4c02000c2 58009a9bc02000a2 | ..... ..X.... ..
    4900c02000921800 81eaff9090f48080 | I.. ............
    f487994781e5ff92 a1019099119a98c0 | ...G............
    2000c809a1e5ffb1 e3ff879c17c60100 |  ...............
    7ce8871adec60800 c02000890ac02000 | |........ .... .
    b909460200c02000 b90ac02000890991 | ..F... .... ....
    d7ff9a880c09c020 009258001df00000 | ....... ..X.....
    5420403f5430403f 36410091fdffc020 | T @?T0@?6A.....
    0088098080245648 ff91faffc0200088 | .....$VH..... ..
    098080245648ff1d f00000002c20403f | ...$VH......, @?
    0020403f00000008 364100101120a5fc | . @?....6A... ..
    ff21faff0c08c020 0082620091faff81 | .!..... ..b.....
    f8ffc02000926800 c0200098085679ff | ... ..h.. ...Vy.
    c0200088027cf280 22302020041df000 | . ...|.."0  ....
    0000004036410010 1120e5fbff166aff | ...@6A... ....j.
    81ecff91fbffc020 00926800c0200098 | ....... ..h.. ..
    085679ff1df00000 5880fd3fffffff00 | .Vy.....X..?....
    0420403f36410021 fcff384216830610 | . @?6A.!..8B....
    112065f8ff16fa05 0cf80c0437a80d98 | . e.........7...
    2280991082a00190 4883404074101120 | ".......H.@@t..
    25faff10112025f3 ff88220c1b409811 | %.... %..."..@..
    90ab01cc1480ab01 b1edffb09910b1ec | ................
    ffc02000926b0091 ceffc02000a26900 | .. ..k..... ..i.
    c02000a809567aff 1c090c1a409a8390 | . ...Vz.....@...
    33c09a8839428922 1df0000070e2fa3f | 3...9B."....p..?
    0820403f84620140 a462014036610010 | . @[email protected].@6a..
    112065edff31f9ff bd01ad0381faffe0 | . e..1..........
    08004d0a0c12ecea 880192a200908810 | ..M.............
    8901101120e5f1ff 91f2ffa0a201c020 | .... ..........
    008809a08820c020 008909b801ad0381 | ..... . ........
    eeffe00800a02483 1df00000ff0f0000 | ......$.........
    36410081c5ff0c19 924800309c419928 | 6A.......H.0.A.(
    91fbff3918293830 30b49a222a33303c | ...9.)800.."*30Sp.."..V..-.
    860200002a939869 4b2299089d0a20fe | ....*..iK".... .
    c02a8d7732ed16c9 d8f90c890b4661ff | .*.w2........Fa.
    000c12668717214d fe88028c1882a0c8 | ...f..!M........
    0c0779022149fe79 020c128027830c08 | ..y.!I.y....'...
    460100000c0822a0 ff20a07482610c10 | F.....".. .t.a..
    11206562ff88c180 a074101120a561ff | . eb.....t.. .a.
    1011206560ff5602 b52203011c272737 | .. e`.V.."...''7
    1ef6320286d0fe22 c2fd2020740cf727 | ..2...."..  t..'
    b70206cdfe7136fe 7022a02802a00200 | .....q6.p".(....
    72a0d277125f72a0 d4779202062100c6 | r..w._r..w...!..
    c5fe000078333823 101120254fff8d0a | ....x38#.. %O...
    566ab0a2a271c0aa 1189c18130fee008 | Vj...q......0...
    002128fe9129fec0 2000280288c120b4 | .!(..).. .(... .
    35c0221190221020 bb2070bb82ad0830 | 5."..". . p....0
    bbc28136fee00800 a2a3e88124fee008 | ...6........$...
    0046b1fe0000d853 c843b833a8231011 | .F.....S.C.3.#..
    20656cff86acfeb2 030322030280bb11 |  el.......".....
    20bb20b2cbf0a2c3 18101120e537ffc6 |  . ........ .7..
    a5fe000022030372 0302802211702220 | ...."..r...".p"
    8124fee008007190 fc22c2f088378022 | .$....q.."...7."
    631652a788178a82 808c4186020089c1 | c.R.......A.....
    1011202523ff8221 0c922704a6190498 | .. %#..!..'.....
    2797a8e910112025 1bff166affa817cd | '..... %...j....
    02b2c3188114fee0 08008c3a32a0c439 | ...........:2..9
    5738172a33391738 372023c02937810e | W8.*39.87 #.)7..
    fee008008688fe00 0022030382030272 | .........".....r
    c318802211383580 222022c2f056c309 | ...".85." "..V..
    f6520286250022a0 c9462a0031ecfd81 | .R..%."..F*.1...
    6efce8032991e088 c089418826ad0987 | n...).....A.&...
TRACE +0.002 Write 2122 bytes:
    c000071008ee0000 0000080000010000 | ................
    0000000000000000 006800014036c100 | .........h..@6..
    21ccff0c0a29a181 e6ffe00800101120 | !....).........
    65bbff16ea0431f3 fe41f2fedbdc2000 | e.....1..A.... .
    280351f2fe2904db dc2000280561ecfe | (.Q..)... .(.a..
    a2a064290661eefe 60221062a4006022 | ..d).a..`".b..`"
    20dbdc2000290581 d8ffe0080048047c |  .. .).......H.|
    c24022100c244022 20dbdc2000290386 | .@"..$@" .. .)..
    010049024b22c601 0021b2ff31b3ff0c | ..I.K"...!..1...
    043732ed101120e5 c1ff0c4ba2c12810 | .72... ....K..(.
    112065c5ff22a101 101120a5dbdcff41 | . e..".... ....A
    f1fd9022112a24db dc2000490231a8ff | ...".*$.. .I.1..
    21d9fd3262001011 2025b2ff163a0621 | !..2b... %...:.!
    9dfec19dfea8020c 2b819ffee008000c | ........+.......
    9c3c0b0c0a81baff e00800b19eff0c0c | .<.............. a2a2008132ffe008 ............2... ......r......... .. .... . cd0a0c5a81a6ffe0 ...........z.... dbdc200028032c0a ..1..r.... p a1ffe008002185ff dbdc20002802ccba ..... ..0 ...... a10040dd1100cc11 ffe008002179ff51 ....... .2..00t. f304a2a200dbdc20 ....q..... .....qh. .8. a2afff80331010aa ....3...... .9.. e00800ad02817dff e008007150fedbdc ...qp... ... .8..... .y. a. fb. c222510f101120e5 a4ffb2a008a2c11c ......... e..r.. w .w....... e..... t.b.f ..2.. fe2020741c2827b8 t. c230808074b658c4 a0dbdc97170286e5 ....r e........ v2.. ad07812effe00800 ........v.4..... ae0000000c1256b7 e.........v. c600000078232833 ....x ...v. fe101120656dff2a em. ac41811cffe00800 .a......v.. dbdccc22069b0000 a080f45618fe8604 ffe0080088c156ca ..............v. fa8022dbdc0c1800 e1860300a0ac4181 ......a......v.. a2fe468a00000c08 ...v..f..... a8000c082d08c6a6 ....f. c277ba02469900b8 .w..f...s. a09283860d000c19 f.1xc f.. w..... y a099307728f27203 ..........0w .....w..w p. r...w..w p... c66c007138fd22a0 r..... c69207008d091659 .......y..7.. ........a..s.c.s c843b833a8230c07 .c.3. a02783065a000c12 fe8197fedbdc2000 .x. .y...... dbdc200078098077 .x..w. y...... .w. .....p.4.. d18184fee0080098 ..9............. e1b8c128298819a8 dbdc2000890a1b77 ....w....7.f. ff664702c67fff0c .fg...... d80b0c1a72c7f09d ....r....-.. f01422a0dbdc56af>Sp.."...V.
    042d09860200002a 9398694b2299089d | .-.....*..iK"...
    0a20fedbdc2a8d77 32ed16c9d8f90c89 | . ...*.w2.......
    0b4661ff000c1266 8717214dfe88028c | .Fa....f..!M....
    1882a0c80c077902 2149fe79020c1280 | ......y.!I.y....
    27830c0846010000 0c0822a0ff20a074 | '...F.....".. .t
    82610c1011206562 ff88c180a0741011 | .a... eb.....t..
    20a561ff10112065 60ff5602b5220301 |  .a... e`.V.."..
    1c2727371ef63202 86d0fe22c2fd2020 | .''7..2...."..
    740cf727b70206cd fe7136fe7022a028 | t..'.....q6.p".(
    02a0020072a0d277 125f72a0d4779202 | ....r..w._r..w..
    062100c6c5fe0000 7833382310112025 | .!......x38#.. %
    4fff8d0a566ab0a2 a271dbdcaa1189c1 | O...Vj...q......
    8130fee008002128 fe9129fedbdc2000 | .0....!(..)... .
    280288c120b435db dc221190221020bb | (... .5.."..". .
    2070bb82ad0830bb c28136fee00800a2 |  p....0...6.....
    a3e88124fee00800 46b1fe0000d853c8 | ...$....F.....S.
    43b833a823101120 656cff86acfeb203 | C.3.#.. el......
    0322030280bb1120 bb20b2cbf0a2c318 | ."..... . ......
    101120e537ffc6a5 fe00002203037203 | .. .7......"..r.
    0280221170222081 24fee008007190fc | ..".p" .$....q..
    22c2f08837802263 1652a788178a8280 | "...7."c.R......
    8c4186020089c110 11202523ff82210c | .A....... %#..!.
    922704a619049827 97a8e9101120251b | .'.....'..... %.
    ff166affa817cd02 b2c3188114fee008 | ..j.............
    008c3a32a0c43957 38172a3339173837 | ..:2..9W8.*39.87
    2023dbdc2937810e fee008008688fe00 |  #..)7..........
    0022030382030272 c318802211383580 | .".....r...".85.
    222022c2f056c309 f6520286250022a0 | " "..V...R..%.".
    c9462a0031ecfd81 6efce8032991e088 | .F*.1...n...)...
    dbdc89418826ad09 87c0             | ...A.&....
TRACE +0.021 Read 1 bytes: c0
TRACE +0.001 Read 1 bytes: 01
TRACE +0.001 Read 1 bytes: 07
TRACE +0.000 Read 1 bytes: 04
TRACE +0.000 Read 1 bytes: 00
TRACE +0.001 Read 1 bytes: 55
TRACE +0.000 Read 1 bytes: 60
TRACE +0.002 Read 1 bytes: 00
TRACE +0.000 Read 1 bytes: 00
TRACE +0.001 Read 1 bytes: 00
TRACE +0.000 Read 2 bytes: 0000
TRACE +0.001 Read 1 bytes: 00
TRACE +0.000 Read 1 bytes: c0
TRACE +0.000 Received full packet: 010704005560000000000000
TRACE +0.003 command op=0x07 data len=364 wait_response=1 timeout=3.000 data=
    5c01000002000000 0000000000000000 | \...............
    b2010c3a99e1a9d1 e9c1101120651aff | ...:........ e..
    a8d181e3fde8c1a9 01a1e2fddd08bd07 | ................
    c2c124f2c11089c1 81f5fde00800b826 | ..$............&
    cd0aa89198e1a0bb c0b926a022c0b803 | ..........&."...
    aa77a84188c1aabb 0c0ab903c0a98380 | .w.A............
    bbc0a0d074cc9ae2 db80ad0de0a98316 | ....t...........
    ea01ad0889c199e1 c9d1101120e525ff | ............ .%.
    88c198e1c8d18903 46010000000c1c9d | ........F.......
    0c8cb238358c73c0 3f31c033c096b3f5 | ...85.s.?1.3....
    d68c0022a0c72955 8653fe0056ac9428 | ..."..)U.S..V..(
    3516529422a0c8c6 faff282356a29310 | 5.R.".....(#V...
    1120254cffa2a271 c0aa1181bcfde008 | . %L...q........
    001011202533ff81 cefde008004646fe | ... %3.......FF.
    0028331632911011 20a549ffa2a3e881 | .(3.2... .I.....
    b3fde00800101120 e530ffe00200063e | ....... .0.....>
    fe001011202530ff 1df000003641009d | .... %0.....6A..
    0282a0c028038799 0fcc320c12860700 | ....(.....2.....
    0c0229037ce2860f 0026120726221886 | ..).|....&..&"..
    0300000082a0db80 292387992a0c2229 | ........)#..*.")
    037cf24608000000 22a0dc27990a0c12 | .|.F...."..'....
    29032d0806040000 0082a0dd7cf28799 | ).-.........|...
    060c12290322a0db 1df00000         | ...)."......
TRACE +0.000 Write 386 bytes:
    c000076c01810000 005c010000020000 | ...l.....\......
    0000000000000000 00b2010c3a99e1a9 | ............:...
    d1e9c1101120651a ffa8d181e3fde8c1 | ..... e.........
    a901a1e2fddd08bd 07c2c124f2c11089 | ...........$....
    c181f5fde00800b8 26cd0aa89198e1a0 | ........&.......
    bbdbdcb926a022db dcb803aa77a84188 | ....&.".....w.A.
    c1aabb0c0ab903db dca98380bbdbdca0 | ................
    d074cc9ae2dbdd80 ad0de0a98316ea01 | .t..............
    ad0889c199e1c9d1 101120e525ff88c1 | .......... .%...
    98e1c8d189034601 0000000c1c9d0c8c | ......F.........
    b238358c73dbdc3f 31dbdc33dbdc96b3 | .85.s..?1..3....
    f5d68c0022a0c729 558653fe0056ac94 | ...."..)U.S..V..
    283516529422a0c8 c6faff282356a293 | (5.R.".....(#V..
    101120254cffa2a2 71dbdcaa1181bcfd | .. %L...q.......
    e008001011202533 ff81cefde0080046 | ..... %3.......F
    46fe002833163291 101120a549ffa2a3 | F..(3.2... .I...
    e881b3fde0080010 1120e530ffe00200 | ......... .0....
    063efe0010112025 30ff1df000003641 | .>.... %0.....6A
    009d0282a0dbdc28 0387990fcc320c12 | .......(.....2..
    8607000c0229037c e2860f0026120726 | .....).|....&..&
    2218860300000082 a0dbdd8029238799 | "...........)#..
    2a0c2229037cf246 0800000022a0dc27 | *.").|.F...."..'
    990a0c1229032d08 060400000082a0dd | ....).-.........
    7cf28799060c1229 0322a0dbdd1df000 | |......)."......
    00c0                              | ..
TRACE +0.004 Read 1 bytes: c0
TRACE +0.002 Read 1 bytes: 01
TRACE +0.001 Read 1 bytes: 07
TRACE +0.000 Read 1 bytes: 04
TRACE +0.001 Read 1 bytes: 00
TRACE +0.000 Read 1 bytes: 55
TRACE +0.001 Read 1 bytes: 60
TRACE +0.001 Read 1 bytes: 00
TRACE +0.001 Read 1 bytes: 00
TRACE +0.000 Read 1 bytes: 00
TRACE +0.001 Read 1 bytes: 00
TRACE +0.001 Read 1 bytes: 00
TRACE +0.000 Read 1 bytes: 00
TRACE +0.001 Read 1 bytes: c0
TRACE +0.000 Received full packet: 010704005560000000000000
TRACE +0.003 command op=0x05 data len=16 wait_response=1 timeout=3.000 data=a00000000100000000080000fc2bfe3f 
TRACE +0.000 Write 26 bytes:
    c000051000000000 00a0000000010000 | ................
    0000080000fc2bfe 3fc0             | ......+.?.
TRACE +0.000 Read 1 bytes: c0
TRACE +0.002 Read 1 bytes: 01
TRACE +0.001 Read 1 bytes: 05
TRACE +0.001 Read 1 bytes: 04
TRACE +0.001 Read 1 bytes: 00
TRACE +0.001 Read 1 bytes: 55
TRACE +0.000 Read 1 bytes: 60
TRACE +0.001 Read 1 bytes: 00
TRACE +0.000 Read 1 bytes: 00
TRACE +0.001 Read 1 bytes: 00
TRACE +0.000 Read 1 bytes: 00
TRACE +0.001 Read 1 bytes: 00
TRACE +0.000 Read 1 bytes: 00
TRACE +0.001 Read 1 bytes: c0
TRACE +0.000 Received full packet: 010504005560000000000000
TRACE +0.002 command op=0x07 data len=176 wait_response=1 timeout=3.000 data=
    a000000000000000 0000000000000000 | ................
    5800fd3f4b8b0240 dd8b0240f2900240 | X..?K..@...@...@
    668c0240fe8b0240 668c0240c58c0240 | f..@...@f..@...@
    de8d0240518e0240 f98d0240d58a0240 | ...@Q..@...@...@
    778d0240d08d0240 e88c0240748e0240 | w..@...@...@t..@
    108d0240748e0240 cb8b02402a8c0240 | ...@t..@...@*..@
    668c0240c58c0240 e38b0240178b0240 | f..@...@...@...@
    378f0240aa900240 ea890240d1900240 | 7..@...@...@...@
    ea890240ea890240 ea890240ea890240 | ...@...@...@...@
    ea890240ea890240 ea890240ea890240 | ...@...@...@...@
    d48e0240ea890240 c98f0240aa900240 | ...@...@...@...@
TRACE +0.001 Write 186 bytes:
    c00007b000520000 00a0000000000000 | .....R..........
    0000000000000000 005800fd3f4b8b02 | .........X..?K..
    40dd8b0240f29002 40668c0240fe8b02 | @...@...@f..@...
    40668c0240c58c02 40de8d0240518e02 | @f..@...@...@Q..
    40f98d0240d58a02 40778d0240d08d02 | @...@...@w..@...
    40e88c0240748e02 40108d0240748e02 | @...@t..@...@t..
    40cb8b02402a8c02 40668c0240c58c02 | @...@*..@f..@...
    40e38b0240178b02 40378f0240aa9002 | @...@...@7..@...
    40ea890240d19002 40ea890240ea8902 | @...@...@...@...
    40ea890240ea8902 40ea890240ea8902 | @...@...@...@...
    40ea890240ea8902 40d48e0240ea8902 | @...@...@...@...
    40c98f0240aa9002 40c0             | @...@...@.
TRACE +0.002 Read 1 bytes: c0
TRACE +0.001 Read 1 bytes: 01
TRACE +0.000 Read 1 bytes: 07
TRACE +0.002 Read 1 bytes: 04
TRACE +0.001 Read 1 bytes: 00
TRACE +0.001 Read 1 bytes: 55
TRACE +0.000 Read 1 bytes: 60
TRACE +0.001 Read 1 bytes: 00
TRACE +0.001 Read 1 bytes: 00
TRACE +0.000 Read 1 bytes: 00
TRACE +0.001 Read 1 bytes: 00
TRACE +0.000 Read 1 bytes: 00
TRACE +0.001 Read 1 bytes: 00
TRACE +0.000 Read 1 bytes: c0
TRACE +0.000 Received full packet: 010704005560000000000000
Running stub...
TRACE +0.003 command op=0x06 data len=8 wait_response=1 timeout=0.200 data=0000000004880240
TRACE +0.000 Write 18 bytes:
    c000060800000000 0000000000048802 | ................
    40c0                              | @.
TRACE +0.001 Read 1 bytes: c0
TRACE +0.001 Read 1 bytes: 01
TRACE +0.000 Read 1 bytes: 06
TRACE +0.001 Read 1 bytes: 04
TRACE +0.002 Read 1 bytes: 00
TRACE +0.000 Read 1 bytes: 55
TRACE +0.001 Read 1 bytes: 60
TRACE +0.000 Read 1 bytes: 00
TRACE +0.001 Read 1 bytes: 00
TRACE +0.000 Read 1 bytes: 00
TRACE +0.001 Read 1 bytes: 00
TRACE +0.000 Read 1 bytes: 00
TRACE +0.001 Read 1 bytes: 00
TRACE +0.000 Read 1 bytes: c0
TRACE +0.000 Received full packet: 010604005560000000000000
TRACE +0.003 Read 6 bytes: c04f484149c0
TRACE +0.000 Received full packet: 4f484149
Stub running...
TRACE +0.000 command op=0x0a data len=4 wait_response=1 timeout=3.000 data=1820403f
TRACE +0.000 Write 14 bytes: c0000a0400000000001820403fc0
TRACE +0.001 Read 1 bytes: c0
TRACE +0.000 Read 12 bytes: 010a0200dbdc0000800000c0
TRACE +0.000 Received full packet: 010a0200c00000800000
TRACE +0.002 command op=0x0a data len=4 wait_response=1 timeout=3.000 data=2020403f
TRACE +0.000 Write 14 bytes: c0000a0400000000002020403fc0
TRACE +0.000 Read 1 bytes: c0
TRACE +0.001 Read 1 bytes: 01
TRACE +0.000 Read 10 bytes: 0a0200000000700000c0
TRACE +0.000 Received full packet: 010a0200000000700000
TRACE +0.002 command op=0x09 data len=16 wait_response=1 timeout=3.000 data=2820403f17000000ffffffff00000000 
TRACE +0.000 Write 26 bytes:
    c000091000000000 002820403f170000 | .........( @?...
    00ffffffff000000 00c0             | ..........
TRACE +0.000 Read 1 bytes: c0
TRACE +0.001 Read 1 bytes: 01
TRACE +0.000 Read 10 bytes: 090200000000000000c0
TRACE +0.000 Received full packet: 01090200000000000000
TRACE +0.002 command op=0x09 data len=16 wait_response=1 timeout=3.000 data=1820403f00000090ffffffff00000000 
TRACE +0.000 Write 26 bytes:
    c000091000000000 001820403f000000 | .......... @?...
    90ffffffff000000 00c0             | ..........
TRACE +0.000 Read 1 bytes: c0
TRACE +0.000 Read 1 bytes: 01
TRACE +0.000 Read 10 bytes: 090200000000000000c0
TRACE +0.000 Received full packet: 01090200000000000000
TRACE +0.002 command op=0x09 data len=16 wait_response=1 timeout=3.000 data=2020403f9f000070ffffffff00000000 
TRACE +0.000 Write 26 bytes:
    c000091000000000 002020403f9f0000 | .........  @?...
    70ffffffff000000 00c0             | p.........
TRACE +0.001 Read 1 bytes: c0
TRACE +0.000 Read 1 bytes: 01
TRACE +0.000 Read 10 bytes: 090200000000000000c0
TRACE +0.000 Received full packet: 01090200000000000000
TRACE +0.002 command op=0x09 data len=16 wait_response=1 timeout=3.000 data=5820403f00000000ffffffff00000000 
TRACE +0.001 Write 26 bytes:
    c000091000000000 005820403f000000 | .........X @?...
    00ffffffff000000 00c0             | ..........
TRACE +0.000 Read 1 bytes: c0
TRACE +0.000 Read 1 bytes: 01
TRACE +0.000 Read 10 bytes: 090200000000000000c0
TRACE +0.001 Received full packet: 01090200000000000000
TRACE +0.002 command op=0x09 data len=16 wait_response=1 timeout=3.000 data=0020403f00000400ffffffff00000000 
TRACE +0.000 Write 26 bytes:
    c000091000000000 000020403f000004 | .......... @?...
    00ffffffff000000 00c0             | ..........
TRACE +0.001 Read 1 bytes: c0
TRACE +0.000 Read 1 bytes: 01
TRACE +0.000 Read 10 bytes: 090200000000000000c0
TRACE +0.000 Received full packet: 01090200000000000000
TRACE +0.003 command op=0x0a data len=4 wait_response=1 timeout=3.000 data=0020403f
TRACE +0.000 Write 14 bytes: c0000a0400000000000020403fc0
TRACE +0.000 Read 1 bytes: c0
TRACE +0.000 Read 1 bytes: 01
TRACE +0.000 Read 10 bytes: 0a0200000000000000c0
TRACE +0.000 Received full packet: 010a0200000000000000
TRACE +0.002 command op=0x0a data len=4 wait_response=1 timeout=3.000 data=5820403f
TRACE +0.000 Write 14 bytes: c0000a0400000000005820403fc0
TRACE +0.001 Read 1 bytes: c0
TRACE +0.000 Read 1 bytes: 01
TRACE +0.000 Read 10 bytes: 0a0200204016000000c0
TRACE +0.000 Received full packet: 010a0200204016000000
TRACE +0.002 command op=0x09 data len=16 wait_response=1 timeout=3.000 data=1820403fc0000080ffffffff00000000 
TRACE +0.000 Write 27 bytes:
    c000091000000000 001820403fdbdc00 | .......... @?...
    0080ffffffff0000 0000c0           | ...........
TRACE +0.000 Read 1 bytes: c0
TRACE +0.000 Read 1 bytes: 01
TRACE +0.001 Read 10 bytes: 090200000000000000c0
TRACE +0.000 Received full packet: 01090200000000000000
TRACE +0.002 command op=0x09 data len=16 wait_response=1 timeout=3.000 data=2020403f00000070ffffffff00000000 
TRACE +0.000 Write 26 bytes:
    c000091000000000 002020403f000000 | .........  @?...
    70ffffffff000000 00c0             | p.........
TRACE +0.000 Read 1 bytes: c0
TRACE +0.001 Read 1 bytes: 01
TRACE +0.000 Read 10 bytes: 090200000000000000c0
TRACE +0.000 Received full packet: 01090200000000000000
TRACE +0.002 command op=0x0a data len=4 wait_response=1 timeout=3.000 data=34a0413f
TRACE +0.000 Write 14 bytes: c0000a04000000000034a0413fc0
TRACE +0.001 Read 1 bytes: c0
TRACE +0.000 Read 1 bytes: 01
TRACE +0.000 Read 10 bytes: 0a0200000000000000c0
TRACE +0.000 Received full packet: 010a0200000000000000
TRACE +0.002 command op=0x0a data len=4 wait_response=1 timeout=3.000 data=38a0413f
TRACE +0.000 Write 14 bytes: c0000a04000000000038a0413fc0
TRACE +0.000 Read 1 bytes: c0
TRACE +0.000 Read 1 bytes: 01
TRACE +0.000 Read 10 bytes: 0a0200000000000000c0
TRACE +0.000 Received full packet: 010a0200000000000000
Erasing flash (this may take a while)...
TRACE +0.003 command op=0xd0 data len=0 wait_response=1 timeout=120.000 data=
TRACE +0.000 Write 10 bytes: c000d0000000000000c0
TRACE +0.001 Read 1 bytes: c0
TRACE +16.291 Read 1 bytes: 01
TRACE +0.000 Read 10 bytes: d00200000000000000c0
TRACE +0.001 Received full packet: 01d00200000000000000
Chip erase completed successfully in 16.3s
TRACE +0.004 command op=0x0a data len=4 wait_response=1 timeout=3.000 data=3840403f
TRACE +0.000 Write 14 bytes: c0000a0400000000003840403fc0
TRACE +0.000 Read 1 bytes: c0
TRACE +0.000 Read 1 bytes: 01
TRACE +0.000 Read 10 bytes: 0a0200000000000000c0
TRACE +0.000 Received full packet: 010a0200000000000000
TRACE +0.003 command op=0x0a data len=4 wait_response=1 timeout=3.000 data=2881403f
TRACE +0.000 Write 14 bytes: c0000a0400000000002881403fc0
TRACE +0.000 Read 1 bytes: c0
TRACE +0.000 Read 1 bytes: 01
TRACE +0.000 Read 10 bytes: 0a0200010000000000c0
TRACE +0.000 Received full packet: 010a0200010000000000
Hard resetting via RTS pin...
C:\dev\esp-idf [(v5.3.1) +0 ~19 -0 !]> 

tyeth avatar Nov 20 '24 01:11 tyeth

Hi @tyeth thank you for the very detailed feedback. I've continued to do more changes and released them in my fork. There was some code in the run stub that was not aligned to esptool.py and new changes should make it more similar. Please take a look again. I hope to resolve these issues you are facing as soon as possible.

Could you please retry my fork in https://brianignacio5.github.io/esptool-js/ with Show Debug log enabled ?

brianignacio5 avatar Nov 20 '24 11:11 brianignacio5

Debug log version:

esptool.js
Serial port WebSerial VendorID 0x303a ProductID 0x2
Connecting...Debug: using Classic Serial Reset
Debug: _connect_attempt default_reset
Debug: Sync connect attempt 0
Debug: Sync
Debug: Sync err Error: No serial data received.
Debug: Error at sync Error: No serial data received.
Debug: Sync connect attempt 1
Debug: Sync
Debug: Sync err Error: No serial data received.
Debug: Error at sync Error: No serial data received.
Debug: Sync connect attempt 2
Debug: Sync
Debug: Sync err Error: No serial data received.
Debug: Error at sync Error: No serial data received.
Debug: Sync connect attempt 3
Debug: Sync
Debug: 538052359
Debug: Connect attempt successful.

Debug: Chip Magic 7c6
Detecting chip type... ESP32-S2
Chip is ESP32-S2 (revision v0.0)
Features: Wi-Fi,No Embedded Flash,No Embedded Flash,ADC and temperature sensor calibration in BLK2 of efuse V2
Crystal is 40MHz
MAC: 60:55:f9:d9:b1:46
Uploading stub...
Debug: mem_begin 4444 1 6144 40028000
Debug: check_command enter RAM download mode
Debug: check_command write to target RAM
Error: No serial data received.

Browser console log: esptool-js-log-20241120_1429.txt

tyeth avatar Nov 20 '24 14:11 tyeth

@brianignacio5 I should probably mention that I'm now in a state where there is no normal serial port when running, so I'm using the bootloader stage1 reset mode (boot0 held while device reset) to see the device in the serial port list (so the device reset before stub upload is technically unneccessary as it's already in download mode). Not sure if that makes a difference for your code/test

tyeth avatar Nov 20 '24 14:11 tyeth

I think I may have found the culprit. Esp32s2 was missing the post connect function that update the ESP_RAM_BLOCK for S2 chips.

Changes are up in https://brianignacio5.github.io/esptool-js/ Could you please try again ? Apologies for the trouble.

brianignacio5 avatar Nov 21 '24 04:11 brianignacio5

@brianignacio5 Seems to connect nicely now, and erase was successful (repeatedly in theory), but writing a small file at 0x0 had a weird pause at 60% and then finished, but failed checksum verification of the write. Writing a different file at 0x10000 the checksum also fails after writing but there was no noticeable pause in write of packets.

Debug log Details (both file write attempts)

esptool.js
Serial port WebSerial VendorID 0x303a ProductID 0x2
Connecting...Debug: using Classic Serial Reset
Debug: _connect_attempt default_reset
Debug: Sync connect attempt 0
Debug: Sync
Debug: Sync err Error: No serial data received.
Debug: Error at sync Error: No serial data received.
Debug: Sync connect attempt 1
Debug: Sync
Debug: Sync err Error: No serial data received.
Debug: Error at sync Error: No serial data received.
Debug: Sync connect attempt 2
Debug: Sync
Debug: Sync err Error: No serial data received.
Debug: Error at sync Error: No serial data received.
Debug: Sync connect attempt 3
Debug: Sync
Debug: 538052359
Debug: Connect attempt successful.

Debug: Chip Magic 7c6 Detecting chip type... ESP32-S2 Chip is ESP32-S2 (revision v0.0) Features: Wi-Fi,No Embedded Flash,No Embedded Flash,ADC and temperature sensor calibration in BLK2 of efuse V2 Crystal is 40MHz MAC: 60:55:f9:d9:b1:46 Debug: In _post_connect using USB OTG ?true Uploading stub... Debug: mem_begin 4444 3 2048 40028000 Debug: check_command enter RAM download mode Debug: check_command write to target RAM Debug: check_command write to target RAM Debug: check_command write to target RAM Debug: mem_begin 160 1 2048 3ffe2bfc Debug: check_command enter RAM download mode Debug: check_command write to target RAM Running stub... Debug: check_command leave RAM download mode Stub running... Changing baudrate to 921600 Changed Erasing flash (this may take a while)... Debug: check_command erase flash Chip erase completed successfully in 16.273s Debug: EspLoader program Debug: Data Length 3113904 Debug: Image Length 3113904 Debug: _update_image_flash_params keep undefined undefined Debug: Image MD5 b6a27342b3b68de9954807f586561251 Compressed 3113904 bytes to 323130... Debug: check_command enter compressed flash mode Took 0.0s to erase flash block Debug: Write loop 0 0 20 Writing at 0x0... (5%) Debug: flash_defl_block 78 da Debug: check_command write compressed data to flash after seq 0 Debug: Write loop 0 1 20 Writing at 0x11000... (10%) Debug: flash_defl_block e3 ed Debug: check_command write compressed data to flash after seq 1 Debug: Write loop 0 2 20 Writing at 0x1d24d... (15%) Debug: flash_defl_block c1 18 Debug: check_command write compressed data to flash after seq 2 Debug: Write loop 0 3 20 Writing at 0x289d8... (20%) Debug: flash_defl_block 97 9 Debug: check_command write compressed data to flash after seq 3 Debug: Write loop 0 4 20 Writing at 0x2e0ce... (25%) Debug: flash_defl_block e2 66 Debug: check_command write compressed data to flash after seq 4 Debug: Write loop 0 5 20 Writing at 0x33c83... (30%) Debug: flash_defl_block e5 71 Debug: check_command write compressed data to flash after seq 5 Debug: Write loop 0 6 20 Writing at 0x392bb... (35%) Debug: flash_defl_block 10 16 Debug: check_command write compressed data to flash after seq 6 Debug: Write loop 0 7 20 Writing at 0x3e84c... (40%) Debug: flash_defl_block e0 21 Debug: check_command write compressed data to flash after seq 7 Debug: Write loop 0 8 20 Writing at 0x43965... (45%) Debug: flash_defl_block b8 71 Debug: check_command write compressed data to flash after seq 8 Debug: Write loop 0 9 20 Writing at 0x48d9b... (50%) Debug: flash_defl_block 1e 45 Debug: check_command write compressed data to flash after seq 9 Debug: Write loop 0 10 20 Writing at 0x4e07f... (55%) Debug: flash_defl_block e9 22 Debug: check_command write compressed data to flash after seq 10 Debug: Write loop 0 11 20 Writing at 0x565d0... (60%) Debug: flash_defl_block 89 78 Debug: check_command write compressed data to flash after seq 11 Debug: Write loop 0 12 20 Writing at 0x5e961... (65%) Debug: flash_defl_block f1 c3 Debug: check_command write compressed data to flash after seq 12 Debug: Write loop 0 13 20 Writing at 0x2d0d05... (70%) Debug: flash_defl_block 66 8d Debug: check_command write compressed data to flash after seq 13 Debug: Write loop 0 14 20 Writing at 0x2d84e8... (75%) Debug: flash_defl_block c fc Debug: check_command write compressed data to flash after seq 14 Debug: Write loop 0 15 20 Writing at 0x2def43... (80%) Debug: flash_defl_block fc 6 Debug: check_command write compressed data to flash after seq 15 Debug: Write loop 0 16 20 Writing at 0x2e45be... (85%) Debug: flash_defl_block 98 24 Debug: check_command write compressed data to flash after seq 16 Debug: Write loop 0 17 20 Writing at 0x2e9958... (90%) Debug: flash_defl_block 9d 17 Debug: check_command write compressed data to flash after seq 17 Debug: Write loop 0 18 20 Writing at 0x2eeb5a... (95%) Debug: flash_defl_block 1c d5 Debug: check_command write compressed data to flash after seq 18 Debug: Write loop 0 19 20 Writing at 0x2f3e51... (100%) Debug: flash_defl_block a6 36 Debug: check_command write compressed data to flash after seq 19 Wrote 3113904 bytes (323130 compressed) at 0x0 in 3.447 seconds. Debug: check_command calculate md5sum File md5: b6a27342b3b68de9954807f586561251 Flash md5: 0fa1d49fe2452360d9cc730dba2715e2 Error: MD5 of file does not match data in flash! Debug: EspLoader program Debug: Data Length 3113904 Debug: Image Length 3113904 Debug: _update_image_flash_params keep undefined undefined Debug: Image MD5 b6a27342b3b68de9954807f586561251 Compressed 3113904 bytes to 323130... Debug: check_command enter compressed flash mode Took 0.0s to erase flash block Debug: Write loop 0 0 20 Writing at 0x0... (5%) Debug: flash_defl_block 78 da Debug: check_command write compressed data to flash after seq 0 Debug: Write loop 0 1 20 Writing at 0x11000... (10%) Debug: flash_defl_block e3 ed Debug: check_command write compressed data to flash after seq 1 Debug: Write loop 0 2 20 Writing at 0x1d24d... (15%) Debug: flash_defl_block c1 18 Debug: check_command write compressed data to flash after seq 2 Debug: Write loop 0 3 20 Writing at 0x289d8... (20%) Debug: flash_defl_block 97 9 Debug: check_command write compressed data to flash after seq 3 Debug: Write loop 0 4 20 Writing at 0x2e0ce... (25%) Debug: flash_defl_block e2 66 Debug: check_command write compressed data to flash after seq 4 Debug: Write loop 0 5 20 Writing at 0x33c83... (30%) Debug: flash_defl_block e5 71 Debug: check_command write compressed data to flash after seq 5 Debug: Write loop 0 6 20 Writing at 0x392bb... (35%) Debug: flash_defl_block 10 16 Debug: check_command write compressed data to flash after seq 6 Debug: Write loop 0 7 20 Writing at 0x3e84c... (40%) Debug: flash_defl_block e0 21 Debug: check_command write compressed data to flash after seq 7 Debug: Write loop 0 8 20 Writing at 0x43965... (45%) Debug: flash_defl_block b8 71 Debug: check_command write compressed data to flash after seq 8 Debug: Write loop 0 9 20 Writing at 0x48d9b... (50%) Debug: flash_defl_block 1e 45 Debug: check_command write compressed data to flash after seq 9 Debug: Write loop 0 10 20 Writing at 0x4e07f... (55%) Debug: flash_defl_block e9 22 Debug: check_command write compressed data to flash after seq 10 Debug: Write loop 0 11 20 Writing at 0x565d0... (60%) Debug: flash_defl_block 89 78 Debug: check_command write compressed data to flash after seq 11 Debug: Write loop 0 12 20 Writing at 0x5e961... (65%) Debug: flash_defl_block f1 c3 Debug: check_command write compressed data to flash after seq 12 Debug: Write loop 0 13 20 Writing at 0x2d0d05... (70%) Debug: flash_defl_block 66 8d Debug: check_command write compressed data to flash after seq 13 Debug: Write loop 0 14 20 Writing at 0x2d84e8... (75%) Debug: flash_defl_block c fc Debug: check_command write compressed data to flash after seq 14 Debug: Write loop 0 15 20 Writing at 0x2def43... (80%) Debug: flash_defl_block fc 6 Debug: check_command write compressed data to flash after seq 15 Debug: Write loop 0 16 20 Writing at 0x2e45be... (85%) Debug: flash_defl_block 98 24 Debug: check_command write compressed data to flash after seq 16 Debug: Write loop 0 17 20 Writing at 0x2e9958... (90%) Debug: flash_defl_block 9d 17 Debug: check_command write compressed data to flash after seq 17 Debug: Write loop 0 18 20 Writing at 0x2eeb5a... (95%) Debug: flash_defl_block 1c d5 Debug: check_command write compressed data to flash after seq 18 Debug: Write loop 0 19 20 Writing at 0x2f3e51... (100%) Debug: flash_defl_block a6 36 Debug: check_command write compressed data to flash after seq 19 Wrote 3113904 bytes (323130 compressed) at 0x0 in 3.532 seconds. Debug: check_command calculate md5sum File md5: b6a27342b3b68de9954807f586561251 Flash md5: 0fa1d49fe2452360d9cc730dba2715e2 Error: MD5 of file does not match data in flash! Debug: EspLoader program Debug: Data Length 1351872 Debug: Image Length 1351872 Debug: _update_image_flash_params keep undefined undefined Debug: Image MD5 0046555ea4b81684c854b17af2191888 Compressed 1351872 bytes to 852414... Debug: check_command enter compressed flash mode Took 0.0s to erase flash block Debug: Write loop 65536 0 53 Writing at 0x10000... (1%) Debug: flash_defl_block 78 da Debug: check_command write compressed data to flash after seq 0 Debug: Write loop 65536 1 53 Writing at 0x1e147... (3%) Debug: flash_defl_block eb ac Debug: check_command write compressed data to flash after seq 1 Debug: Write loop 65536 2 53 Writing at 0x2a327... (5%) Debug: flash_defl_block d8 8c Debug: check_command write compressed data to flash after seq 2 Debug: Write loop 65536 3 53 Writing at 0x352de... (7%) Debug: flash_defl_block f8 41 Debug: check_command write compressed data to flash after seq 3 Debug: Write loop 65536 4 53 Writing at 0x3a240... (9%) Debug: flash_defl_block 1b 1f Debug: check_command write compressed data to flash after seq 4 Debug: Write loop 65536 5 53 Writing at 0x41e91... (11%) Debug: flash_defl_block a3 cd Debug: check_command write compressed data to flash after seq 5 Debug: Write loop 65536 6 53 Writing at 0x51dd7... (13%) Debug: flash_defl_block ce e9 Debug: check_command write compressed data to flash after seq 6 Debug: Write loop 65536 7 53 Writing at 0x6234b... (15%) Debug: flash_defl_block fa 5d Debug: check_command write compressed data to flash after seq 7 Debug: Write loop 65536 8 53 Writing at 0x685a4... (16%) Debug: flash_defl_block 3c 5e Debug: check_command write compressed data to flash after seq 8 Debug: Write loop 65536 9 53 Writing at 0x6e4f0... (18%) Debug: flash_defl_block 8e 1a Debug: check_command write compressed data to flash after seq 9 Debug: Write loop 65536 10 53 Writing at 0x734c3... (20%) Debug: flash_defl_block 48 2f Debug: check_command write compressed data to flash after seq 10 Debug: Write loop 65536 11 53 Writing at 0x7884a... (22%) Debug: flash_defl_block 2e 89 Debug: check_command write compressed data to flash after seq 11 Debug: Write loop 65536 12 53 Writing at 0x7e644... (24%) Debug: flash_defl_block a0 bb Debug: check_command write compressed data to flash after seq 12 Debug: Write loop 65536 13 53 Writing at 0x84bd6... (26%) Debug: flash_defl_block 28 8c Debug: check_command write compressed data to flash after seq 13 Debug: Write loop 65536 14 53 Writing at 0x8a874... (28%) Debug: flash_defl_block ef 1c Debug: check_command write compressed data to flash after seq 14 Debug: Write loop 65536 15 53 Writing at 0x8fb5c... (30%) Debug: flash_defl_block ef 20 Debug: check_command write compressed data to flash after seq 15 Debug: Write loop 65536 16 53 Writing at 0x95142... (32%) Debug: flash_defl_block 8a 12 Debug: check_command write compressed data to flash after seq 16 Debug: Write loop 65536 17 53 Writing at 0x9a4aa... (33%) Debug: flash_defl_block 2c d2 Debug: check_command write compressed data to flash after seq 17 Debug: Write loop 65536 18 53 Writing at 0x9fdf0... (35%) Debug: flash_defl_block 37 f0 Debug: check_command write compressed data to flash after seq 18 Debug: Write loop 65536 19 53 Writing at 0xa5bc8... (37%) Debug: flash_defl_block a3 d5 Debug: check_command write compressed data to flash after seq 19 Debug: Write loop 65536 20 53 Writing at 0xab710... (39%) Debug: flash_defl_block a9 5 Debug: check_command write compressed data to flash after seq 20 Debug: Write loop 65536 21 53 Writing at 0xb0d51... (41%) Debug: flash_defl_block 96 c5 Debug: check_command write compressed data to flash after seq 21 Debug: Write loop 65536 22 53 Writing at 0xb5df0... (43%) Debug: flash_defl_block e8 19 Debug: check_command write compressed data to flash after seq 22 Debug: Write loop 65536 23 53 Writing at 0xbad3d... (45%) Debug: flash_defl_block a8 10 Debug: check_command write compressed data to flash after seq 23 Debug: Write loop 65536 24 53 Writing at 0xbfea4... (47%) Debug: flash_defl_block f1 47 Debug: check_command write compressed data to flash after seq 24 Debug: Write loop 65536 25 53 Writing at 0xc4e04... (49%) Debug: flash_defl_block fd a3 Debug: check_command write compressed data to flash after seq 25 Debug: Write loop 65536 26 53 Writing at 0xca37b... (50%) Debug: flash_defl_block 1e 6 Debug: check_command write compressed data to flash after seq 26 Debug: Write loop 65536 27 53 Writing at 0xcf72f... (52%) Debug: flash_defl_block bd 17 Debug: check_command write compressed data to flash after seq 27 Debug: Write loop 65536 28 53 Writing at 0xd45f1... (54%) Debug: flash_defl_block b3 f5 Debug: check_command write compressed data to flash after seq 28 Debug: Write loop 65536 29 53 Writing at 0xd9578... (56%) Debug: flash_defl_block 27 83 Debug: check_command write compressed data to flash after seq 29 Debug: Write loop 65536 30 53 Writing at 0xdeb59... (58%) Debug: flash_defl_block df a8 Debug: check_command write compressed data to flash after seq 30 Debug: Write loop 65536 31 53 Writing at 0xe3ed0... (60%) Debug: flash_defl_block 6c e4 Debug: check_command write compressed data to flash after seq 31 Debug: Write loop 65536 32 53 Writing at 0xe8db8... (62%) Debug: flash_defl_block 17 50 Debug: check_command write compressed data to flash after seq 32 Debug: Write loop 65536 33 53 Writing at 0xee291... (64%) Debug: flash_defl_block 3f 81 Debug: check_command write compressed data to flash after seq 33 Debug: Write loop 65536 34 53 Writing at 0xf3e28... (66%) Debug: flash_defl_block d1 66 Debug: check_command write compressed data to flash after seq 34 Debug: Write loop 65536 35 53 Writing at 0xf9286... (67%) Debug: flash_defl_block 5e e5 Debug: check_command write compressed data to flash after seq 35 Debug: Write loop 65536 36 53 Writing at 0xfe37d... (69%) Debug: flash_defl_block 31 ec Debug: check_command write compressed data to flash after seq 36 Debug: Write loop 65536 37 53 Writing at 0x10330c... (71%) Debug: flash_defl_block 0 14 Debug: check_command write compressed data to flash after seq 37 Debug: Write loop 65536 38 53 Writing at 0x10828a... (73%) Debug: flash_defl_block 6f 9 Debug: check_command write compressed data to flash after seq 38 Debug: Write loop 65536 39 53 Writing at 0x10d3d9... (75%) Debug: flash_defl_block b5 7 Debug: check_command write compressed data to flash after seq 39 Debug: Write loop 65536 40 53 Writing at 0x112470... (77%) Debug: flash_defl_block ef 76 Debug: check_command write compressed data to flash after seq 40 Debug: Write loop 65536 41 53 Writing at 0x1178b2... (79%) Debug: flash_defl_block c5 cb Debug: check_command write compressed data to flash after seq 41 Debug: Write loop 65536 42 53 Writing at 0x11cbb9... (81%) Debug: flash_defl_block 13 d6 Debug: check_command write compressed data to flash after seq 42 Debug: Write loop 65536 43 53 Writing at 0x1226b5... (83%) Debug: flash_defl_block 3a d0 Debug: check_command write compressed data to flash after seq 43 Debug: Write loop 65536 44 53 Writing at 0x127e54... (84%) Debug: flash_defl_block 22 3d Debug: check_command write compressed data to flash after seq 44 Debug: Write loop 65536 45 53 Writing at 0x12d402... (86%) Debug: flash_defl_block 14 67 Debug: check_command write compressed data to flash after seq 45 Debug: Write loop 65536 46 53 Writing at 0x135eea... (88%) Debug: flash_defl_block 5c 2 Debug: check_command write compressed data to flash after seq 46 Debug: Write loop 65536 47 53 Writing at 0x13e6e7... (90%) Debug: flash_defl_block 11 df Debug: check_command write compressed data to flash after seq 47 Debug: Write loop 65536 48 53 Writing at 0x143a3b... (92%) Debug: flash_defl_block 35 67 Debug: check_command write compressed data to flash after seq 48 Debug: Write loop 65536 49 53 Writing at 0x1488a1... (94%) Debug: flash_defl_block f3 57 Debug: check_command write compressed data to flash after seq 49 Debug: Write loop 65536 50 53 Writing at 0x14e6e9... (96%) Debug: flash_defl_block 29 e0 Debug: check_command write compressed data to flash after seq 50 Debug: Write loop 65536 51 53 Writing at 0x1541b5... (98%) Debug: flash_defl_block e9 65 Debug: check_command write compressed data to flash after seq 51 Debug: Write loop 65536 52 53 Writing at 0x159e36... (100%) Debug: flash_defl_block 8c 8b Debug: check_command write compressed data to flash after seq 52 Wrote 1351872 bytes (852414 compressed) at 0x10000 in 4.918 seconds. Debug: check_command calculate md5sum File md5: 0046555ea4b81684c854b17af2191888 Flash md5: 2ecd7da3e8246446ebd396b1dd751d80 Error: MD5 of file does not match data in flash!

Second attempt Debug Log Details (erase and just writing factory reset image)

esptool.js
Serial port WebSerial VendorID 0x303a ProductID 0x2
Connecting...Debug: using Classic Serial Reset
Debug: _connect_attempt default_reset
Debug: Sync connect attempt 0
Debug: Sync
Debug: Sync err Error: No serial data received.
Debug: Error at sync Error: No serial data received.
Debug: Sync connect attempt 1
Debug: Sync
Debug: Sync err Error: No serial data received.
Debug: Error at sync Error: No serial data received.
Debug: Sync connect attempt 2
Debug: Sync
Debug: Sync err Error: No serial data received.
Debug: Error at sync Error: No serial data received.
Debug: Sync connect attempt 3
Debug: Sync
Debug: 538052359
Debug: Connect attempt successful.

Debug: Chip Magic 7c6 Detecting chip type... ESP32-S2 Chip is ESP32-S2 (revision v0.0) Features: Wi-Fi,No Embedded Flash,No Embedded Flash,ADC and temperature sensor calibration in BLK2 of efuse V2 Crystal is 40MHz MAC: 60:55:f9:d9:b1:46 Debug: In _post_connect using USB OTG ?true Uploading stub... Debug: mem_begin 4444 3 2048 40028000 Debug: check_command enter RAM download mode Debug: check_command write to target RAM Debug: check_command write to target RAM Debug: check_command write to target RAM Debug: mem_begin 160 1 2048 3ffe2bfc Debug: check_command enter RAM download mode Debug: check_command write to target RAM Running stub... Debug: check_command leave RAM download mode Stub running... Erasing flash (this may take a while)... Debug: check_command erase flash Chip erase completed successfully in 16.273s Debug: EspLoader program Debug: Data Length 3113904 Debug: Image Length 3113904 Debug: _update_image_flash_params keep undefined undefined Debug: Image MD5 b6a27342b3b68de9954807f586561251 Compressed 3113904 bytes to 323130... Debug: check_command enter compressed flash mode Took 0.0s to erase flash block Debug: Write loop 0 0 20 Writing at 0x0... (5%) Debug: flash_defl_block 78 da Debug: check_command write compressed data to flash after seq 0 Debug: Write loop 0 1 20 Writing at 0x11000... (10%) Debug: flash_defl_block e3 ed Debug: check_command write compressed data to flash after seq 1 Debug: Write loop 0 2 20 Writing at 0x1d24d... (15%) Debug: flash_defl_block c1 18 Debug: check_command write compressed data to flash after seq 2 Debug: Write loop 0 3 20 Writing at 0x289d8... (20%) Debug: flash_defl_block 97 9 Debug: check_command write compressed data to flash after seq 3 Debug: Write loop 0 4 20 Writing at 0x2e0ce... (25%) Debug: flash_defl_block e2 66 Debug: check_command write compressed data to flash after seq 4 Debug: Write loop 0 5 20 Writing at 0x33c83... (30%) Debug: flash_defl_block e5 71 Debug: check_command write compressed data to flash after seq 5 Debug: Write loop 0 6 20 Writing at 0x392bb... (35%) Debug: flash_defl_block 10 16 Debug: check_command write compressed data to flash after seq 6 Debug: Write loop 0 7 20 Writing at 0x3e84c... (40%) Debug: flash_defl_block e0 21 Debug: check_command write compressed data to flash after seq 7 Debug: Write loop 0 8 20 Writing at 0x43965... (45%) Debug: flash_defl_block b8 71 Debug: check_command write compressed data to flash after seq 8 Debug: Write loop 0 9 20 Writing at 0x48d9b... (50%) Debug: flash_defl_block 1e 45 Debug: check_command write compressed data to flash after seq 9 Debug: Write loop 0 10 20 Writing at 0x4e07f... (55%) Debug: flash_defl_block e9 22 Debug: check_command write compressed data to flash after seq 10 Debug: Write loop 0 11 20 Writing at 0x565d0... (60%) Debug: flash_defl_block 89 78 Debug: check_command write compressed data to flash after seq 11 Debug: Write loop 0 12 20 Writing at 0x5e961... (65%) Debug: flash_defl_block f1 c3 Debug: check_command write compressed data to flash after seq 12 Debug: Write loop 0 13 20 Writing at 0x2d0d05... (70%) Debug: flash_defl_block 66 8d Debug: check_command write compressed data to flash after seq 13 Debug: Write loop 0 14 20 Writing at 0x2d84e8... (75%) Debug: flash_defl_block c fc Debug: check_command write compressed data to flash after seq 14 Debug: Write loop 0 15 20 Writing at 0x2def43... (80%) Debug: flash_defl_block fc 6 Debug: check_command write compressed data to flash after seq 15 Debug: Write loop 0 16 20 Writing at 0x2e45be... (85%) Debug: flash_defl_block 98 24 Debug: check_command write compressed data to flash after seq 16 Debug: Write loop 0 17 20 Writing at 0x2e9958... (90%) Debug: flash_defl_block 9d 17 Debug: check_command write compressed data to flash after seq 17 Debug: Write loop 0 18 20 Writing at 0x2eeb5a... (95%) Debug: flash_defl_block 1c d5 Debug: check_command write compressed data to flash after seq 18 Debug: Write loop 0 19 20 Writing at 0x2f3e51... (100%) Debug: flash_defl_block a6 36 Debug: check_command write compressed data to flash after seq 19 Wrote 3113904 bytes (323130 compressed) at 0x0 in 3.525 seconds. Debug: check_command calculate md5sum File md5: b6a27342b3b68de9954807f586561251 Flash md5: 0fa1d49fe2452360d9cc730dba2715e2 Error: MD5 of file does not match data in flash!

2nd attempt Browser Console Log Details: esptool-js-log-20241121_1344.txt

Firmware being written: Metro_ESP32S2_FactoryReset (1).zip

tyeth avatar Nov 21 '24 13:11 tyeth

Testing a couple more of the Adafruit boards (was on my todo list) it turns out there's a bit of variation (starting each test at baud 921600 unless it errors and I drop to trying 115k then other bauds):

  • S3 F4N2 fails checksum validation after writing, erases and connects fine. (QtPy S3 with psram)
  • C6 (no psram) verified checksum OK, all functions OK (adafruit feather c6)
  • ESP32-D0WD-V3 (revision 3) aka Feather ESP32 v1, or "Huzzah32" v1 fails to erase. Connect failed once but then OK, the write fails too. Switching to 115k baud the write proceeds, but slower than expected, data checksum OK. erase works after too. All other baud rates except 115k fail to erase/write, but do connect the stub successfully in theory. esp32v1featherHuzzah32-esptool-js-20241121_1408.txt
  • ESP32-S3 (QFN56) (revision v0.1) (QtPy ESP32S3 8mb flash No PSRAM) connects fine, but fails to verify checksum, at all speeds, and the erase takes 0.6seconds at all bauds which is clearly not working correctly. ESP32-S3 (QFN56) (revision v0.1)-qtpy-s3noPSRAM-esptool-js-20241121_1408.txt
ESP32-S3 (QFN56) (revision v0.1) debug log

esptool.js
Serial port WebSerial VendorID 0x303a ProductID 0x1001
Connecting...Debug: using USB JTAG Serial Reset
Debug: _connect_attempt default_reset
Debug: Sync connect attempt 0
Debug: Sync
Debug: Sync err Error: Invalid head of packet (0x53): Possible serial noise or corruption.
Debug: Error at sync Error: Invalid head of packet (0x53): Possible serial noise or corruption.
Debug: Sync connect attempt 1
Debug: Sync
Debug: 538052359
Debug: Connect attempt successful.

Debug: Chip Magic 9 Detecting chip type... ESP32-S3 Chip is ESP32-S3 (QFN56) (revision v0.1) Features: Wi-Fi,BLE,Embedded Flash 8MB (GD) Crystal is 40MHz MAC: f4:12:fa:6d:b1:e4 Debug: In _post_connect 4 Uploading stub... Debug: mem_begin 5292 1 6144 40378000 Debug: check_command enter RAM download mode Debug: check_command write to target RAM Debug: mem_begin 252 1 6144 3fcb2bfc Debug: check_command enter RAM download mode Debug: check_command write to target RAM Running stub... Debug: check_command leave RAM download mode Stub running... Debug: EspLoader program Debug: Data Length 1356848 Debug: Image Length 1356848 Debug: _update_image_flash_params keep undefined undefined Warning: Image file at 0x0 doesn't look like an image file, so not changing any flash settings. Debug: Image MD5 a5f7fbfecd46104ad4845f1c74f29a5e Compressed 1356848 bytes to 864435... Debug: check_command enter compressed flash mode Took 0.0s to erase flash block Debug: Write loop 0 0 53 Writing at 0x0... (1%) Debug: flash_defl_block 78 da Debug: check_command write compressed data to flash after seq 0 Debug: Write loop 0 1 53 Writing at 0xdb3a... (3%) Debug: flash_defl_block ef 3d Debug: check_command write compressed data to flash after seq 1 Debug: Write loop 0 2 53 Writing at 0x1429a... (5%) Debug: flash_defl_block 60 59 Debug: check_command write compressed data to flash after seq 2 Debug: Write loop 0 3 53 Writing at 0x19335... (7%) Debug: flash_defl_block c0 2b Debug: check_command write compressed data to flash after seq 3 Debug: Write loop 0 4 53 Writing at 0x1e702... (9%) Debug: flash_defl_block 5b 7e Debug: check_command write compressed data to flash after seq 4 Debug: Write loop 0 5 53 Writing at 0x280da... (11%) Debug: flash_defl_block cb 54 Debug: check_command write compressed data to flash after seq 5 Debug: Write loop 0 6 53 Writing at 0x32f8c... (13%) Debug: flash_defl_block 6f e1 Debug: check_command write compressed data to flash after seq 6 Debug: Write loop 0 7 53 Writing at 0x37ec8... (15%) Debug: flash_defl_block ef b7 Debug: check_command write compressed data to flash after seq 7 Debug: Write loop 0 8 53 Writing at 0x3f6aa... (16%) Debug: flash_defl_block 87 24 Debug: check_command write compressed data to flash after seq 8 Debug: Write loop 0 9 53 Writing at 0x4f81a... (18%) Debug: flash_defl_block 12 19 Debug: check_command write compressed data to flash after seq 9 Debug: Write loop 0 10 53 Writing at 0x5f267... (20%) Debug: flash_defl_block 2c 24 Debug: check_command write compressed data to flash after seq 10 Debug: Write loop 0 11 53 Writing at 0x6524b... (22%) Debug: flash_defl_block ea 12 Debug: check_command write compressed data to flash after seq 11 Debug: Write loop 0 12 53 Writing at 0x6bfb6... (24%) Debug: flash_defl_block 97 24 Debug: check_command write compressed data to flash after seq 12 Debug: Write loop 0 13 53 Writing at 0x711bf... (26%) Debug: flash_defl_block cf 49 Debug: check_command write compressed data to flash after seq 13 Debug: Write loop 0 14 53 Writing at 0x762ef... (28%) Debug: flash_defl_block ed 4c Debug: check_command write compressed data to flash after seq 14 Debug: Write loop 0 15 53 Writing at 0x7bbd7... (30%) Debug: flash_defl_block cb 99 Debug: check_command write compressed data to flash after seq 15 Debug: Write loop 0 16 53 Writing at 0x81fcc... (32%) Debug: flash_defl_block c2 9a Debug: check_command write compressed data to flash after seq 16 Debug: Write loop 0 17 53 Writing at 0x87e20... (33%) Debug: flash_defl_block 15 a0 Debug: check_command write compressed data to flash after seq 17 Debug: Write loop 0 18 53 Writing at 0x8d297... (35%) Debug: flash_defl_block b a0 Debug: check_command write compressed data to flash after seq 18 Debug: Write loop 0 19 53 Writing at 0x9265b... (37%) Debug: flash_defl_block 6d 4d Debug: check_command write compressed data to flash after seq 19 Debug: Write loop 0 20 53 Writing at 0x9831c... (39%) Debug: flash_defl_block 11 a0 Debug: check_command write compressed data to flash after seq 20 Debug: Write loop 0 21 53 Writing at 0x9dac5... (41%) Debug: flash_defl_block 9 62 Debug: check_command write compressed data to flash after seq 21 Debug: Write loop 0 22 53 Writing at 0xa3690... (43%) Debug: flash_defl_block df fe Debug: check_command write compressed data to flash after seq 22 Debug: Write loop 0 23 53 Writing at 0xa8edb... (45%) Debug: flash_defl_block f 5c Debug: check_command write compressed data to flash after seq 23 Debug: Write loop 0 24 53 Writing at 0xadff1... (47%) Debug: flash_defl_block a6 2 Debug: check_command write compressed data to flash after seq 24 Debug: Write loop 0 25 53 Writing at 0xb2f6c... (49%) Debug: flash_defl_block eb 74 Debug: check_command write compressed data to flash after seq 25 Debug: Write loop 0 26 53 Writing at 0xb80bf... (50%) Debug: flash_defl_block 73 70 Debug: check_command write compressed data to flash after seq 26 Debug: Write loop 0 27 53 Writing at 0xbd11d... (52%) Debug: flash_defl_block 6b 85 Debug: check_command write compressed data to flash after seq 27 Debug: Write loop 0 28 53 Writing at 0xc2668... (54%) Debug: flash_defl_block aa ae Debug: check_command write compressed data to flash after seq 28 Debug: Write loop 0 29 53 Writing at 0xc793f... (56%) Debug: flash_defl_block 16 52 Debug: check_command write compressed data to flash after seq 29 Debug: Write loop 0 30 53 Writing at 0xcc7c2... (58%) Debug: flash_defl_block 34 92 Debug: check_command write compressed data to flash after seq 30 Debug: Write loop 0 31 53 Writing at 0xd16a1... (60%) Debug: flash_defl_block 7f 57 Debug: check_command write compressed data to flash after seq 31 Debug: Write loop 0 32 53 Writing at 0xd6d08... (62%) Debug: flash_defl_block 33 75 Debug: check_command write compressed data to flash after seq 32 Debug: Write loop 0 33 53 Writing at 0xdbbf1... (64%) Debug: flash_defl_block ce 9d Debug: check_command write compressed data to flash after seq 33 Debug: Write loop 0 34 53 Writing at 0xe0e0c... (66%) Debug: flash_defl_block 89 3b Debug: check_command write compressed data to flash after seq 34 Debug: Write loop 0 35 53 Writing at 0xe6a41... (67%) Debug: flash_defl_block c 21 Debug: check_command write compressed data to flash after seq 35 Debug: Write loop 0 36 53 Writing at 0xebe7b... (69%) Debug: flash_defl_block aa 89 Debug: check_command write compressed data to flash after seq 36 Debug: Write loop 0 37 53 Writing at 0xf109a... (71%) Debug: flash_defl_block 21 0 Debug: check_command write compressed data to flash after seq 37 Debug: Write loop 0 38 53 Writing at 0xf6443... (73%) Debug: flash_defl_block 58 66 Debug: check_command write compressed data to flash after seq 38 Debug: Write loop 0 39 53 Writing at 0xfb31e... (75%) Debug: flash_defl_block 2c ac Debug: check_command write compressed data to flash after seq 39 Debug: Write loop 0 40 53 Writing at 0x10046b... (77%) Debug: flash_defl_block 3 33 Debug: check_command write compressed data to flash after seq 40 Debug: Write loop 0 41 53 Writing at 0x10539c... (79%) Debug: flash_defl_block ff 7 Debug: check_command write compressed data to flash after seq 41 Debug: Write loop 0 42 53 Writing at 0x10a7f6... (81%) Debug: flash_defl_block cd 94 Debug: check_command write compressed data to flash after seq 42 Debug: Write loop 0 43 53 Writing at 0x10fb2e... (83%) Debug: flash_defl_block 8c e1 Debug: check_command write compressed data to flash after seq 43 Debug: Write loop 0 44 53 Writing at 0x115056... (84%) Debug: flash_defl_block d4 34 Debug: check_command write compressed data to flash after seq 44 Debug: Write loop 0 45 53 Writing at 0x11ad81... (86%) Debug: flash_defl_block 7c 10 Debug: check_command write compressed data to flash after seq 45 Debug: Write loop 0 46 53 Writing at 0x12018b... (88%) Debug: flash_defl_block a 38 Debug: check_command write compressed data to flash after seq 46 Debug: Write loop 0 47 53 Writing at 0x1266f1... (90%) Debug: flash_defl_block f5 70 Debug: check_command write compressed data to flash after seq 47 Debug: Write loop 0 48 53 Writing at 0x130a32... (92%) Debug: flash_defl_block a3 47 Debug: check_command write compressed data to flash after seq 48 Debug: Write loop 0 49 53 Writing at 0x136cba... (94%) Debug: flash_defl_block c3 8a Debug: check_command write compressed data to flash after seq 49 Debug: Write loop 0 50 53 Writing at 0x13bb54... (96%) Debug: flash_defl_block 1b 7f Debug: check_command write compressed data to flash after seq 50 Debug: Write loop 0 51 53 Writing at 0x1414af... (98%) Debug: flash_defl_block 67 f1 Debug: check_command write compressed data to flash after seq 51 Debug: Write loop 0 52 53 Writing at 0x146b90... (100%) Debug: flash_defl_block d6 5c Debug: check_command write compressed data to flash after seq 52 Wrote 1356848 bytes (864435 compressed) at 0x0 in 6.994 seconds. Debug: check_command calculate md5sum File md5: a5f7fbfecd46104ad4845f1c74f29a5e Flash md5: 4d9cca4036fa9f24ff449b216f88a59a Error: MD5 of file does not match data in flash! Erasing flash (this may take a while)... Debug: check_command erase flash Chip erase completed successfully in 0.659s

tyeth avatar Nov 21 '24 14:11 tyeth

@brianignacio5 I haven't got any of the Adafruit ESP32-C3 QtPy's and I'm told we wont be producing more, but I grabbed a random SuperMini C3 that I got from aliexpress, an ESP32-C3 (revision 4), and it erases fine at 921k baud, but the write fails verification. Same at 115k baud

tyeth avatar Nov 21 '24 14:11 tyeth

Hi @tyeth I've found that the IS_STUB was not being set so the flash values were not being picked correctly. Now I fixed it.

Could you please retry my fork in https://brianignacio5.github.io/esptool-js/ with Show Debug log enabled ?

brianignacio5 avatar Nov 25 '24 10:11 brianignacio5

@brianignacio5 looks good on the Metro S2 that I have handy, erase and verify successful, there was a big pause in writing the factory reset image at about 70% - no idea why, I'll retest the others later.

There was a considerable amount of weirdness with not opening the serial port (it was always in bootloader mode and visible), which then breaks the disconnect button, requiring the tab to be refreshed. I found that resetting the device (boot0 + reset) and refreshing the tab resolved the issue. Maybe the connected state could be not enabled if the device is still null (as it shows in the UI label).

The serial errors on connect varied between couldn't fire setDTR/RTS, and the "Failed to execute 'open' on 'SerialPort': Failed to open serial port.". I'll try to keep an eye on it, and restart my poor machine before labelling it buggy 😉

Console just shows:

esptool-js/:22 Canvas2D: Multiple readback operations using getImageData are faster with the willReadFrequently attribute set to true. See: https://html.spec.whatwg.org/multipage/canvas.html#concept-canvas-will-read-frequently
apply @ esptool-js/:22
getImageData @ esptool-js/:242
t._drawToCache @ xterm.min.js:7
t.draw @ xterm.min.js:7
e._drawChars @ xterm.min.js:7
(anonymous) @ xterm.min.js:7
t._forEachCell @ xterm.min.js:7
t._drawForeground @ xterm.min.js:7
t.onGridChanged @ xterm.min.js:7
t.renderRows @ xterm.min.js:7
t._renderRows @ xterm.min.js:7
(anonymous) @ xterm.min.js:7
e._innerRefresh @ xterm.min.js:7
(anonymous) @ xterm.min.js:7
requestAnimationFrame
e.refresh @ xterm.min.js:7
t.refreshRows @ xterm.min.js:7
t.refresh @ xterm.min.js:7
(anonymous) @ xterm.min.js:7
e.fire @ xterm.min.js:7
t.parse @ xterm.min.js:7
(anonymous) @ xterm.min.js:7
e._innerWrite @ xterm.min.js:7
(anonymous) @ xterm.min.js:7
setTimeout
e.write @ xterm.min.js:7
t.write @ xterm.min.js:7
e.writeln @ xterm.min.js:7
writeLine @ index.ts:80
write @ esploader.js:185
info @ esploader.js:210
$b9be20b2c9078c9b$export$b0f7a6c745790308 @ esploader.js:171
$382e02c9bbd5d50b$var$connectButton.onclick @ index.ts:100Understand this warningAI
14:55:47.264 index.ts:107 NetworkError: Failed to execute 'open' on 'SerialPort': Failed to open serial port.
$382e02c9bbd5d50b$var$connectButton.onclick @ index.ts:107Understand this errorAI
14:55:47.265 index.ts:111 Settings done for :null
14:55:53.998 webserial.js:379 Uncaught (in promise) InvalidStateError: Failed to execute 'close' on 'SerialPort': The port is already closed.
    at $4616b1a2f9a5b082$export$86495b081fef8e52.disconnect (webserial.js:379:27)
    at async $382e02c9bbd5d50b$var$disconnectButton.onclick (index.ts:219:18)
disconnect @ webserial.js:379
await in disconnect
$382e02c9bbd5d50b$var$disconnectButton.onclick @ index.ts:219Understand this errorAI
14:55:57.202 Navigated to https://brianignacio5.github.io/esptool-js/

tyeth avatar Nov 25 '24 15:11 tyeth

I'm not able to reproduce this issue @tyeth but if you can describe some steps to reproduce it I'll fix it in a separate PR.

brianignacio5 avatar Nov 27 '24 09:11 brianignacio5

Thanks Brian! I think it's just that connections which fail still then show a connected state (device listed as null in page and the 3 buttons show including disconnect), and then clicking disconnect errors silently or endlessly waits due to the await port something at the top of the disconnect routine. I'll give you a better report in future (on phone now)

tyeth avatar Nov 27 '24 20:11 tyeth