esp32tool 1.6.6 → 1.7.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/apple-touch-icon.png +0 -0
- package/css/style.css +325 -25
- package/dist/const.d.ts +6 -1
- package/dist/const.js +9 -3
- package/dist/esp_loader.js +35 -22
- package/dist/flash_jedec.js +5 -0
- package/dist/stubs/esp32.json +5 -5
- package/dist/stubs/esp32c2.json +4 -4
- package/dist/stubs/esp32c3.json +4 -4
- package/dist/stubs/esp32c5.json +4 -4
- package/dist/stubs/esp32c6.json +4 -4
- package/dist/stubs/esp32c61.json +4 -4
- package/dist/stubs/esp32h2.json +4 -4
- package/dist/stubs/esp32p4.json +4 -4
- package/dist/stubs/esp32p4r3.json +4 -4
- package/dist/stubs/esp32s2.json +4 -4
- package/dist/stubs/esp32s3.json +27 -5
- package/dist/stubs/esp32s31.json +8 -0
- package/dist/stubs/esp8266.json +5 -5
- package/dist/stubs/index.js +4 -2
- package/dist/util/console-color.js +3 -3
- package/dist/util/timestamp-transformer.js +24 -1
- package/dist/web/esp32-n1hWo9nn.js +1 -0
- package/dist/web/esp32c2-CPnHdueO.js +1 -0
- package/dist/web/esp32c3-ea1mvbdS.js +1 -0
- package/dist/web/esp32c5-Dzn4lVbd.js +1 -0
- package/dist/web/esp32c6-DL8Ekn6h.js +1 -0
- package/dist/web/esp32c61-DDIvCrFA.js +1 -0
- package/dist/web/esp32h2-Dnu87P5q.js +1 -0
- package/dist/web/esp32p4-HGPqzQsU.js +1 -0
- package/dist/web/esp32p4r3-DounZFQB.js +1 -0
- package/dist/web/esp32s2-gzKRBlZl.js +1 -0
- package/dist/web/esp32s3-BzPgJvNE.js +1 -0
- package/dist/web/esp32s31-Ck4fXdho.js +1 -0
- package/dist/web/esp8266-KToZdvHe.js +1 -0
- package/dist/web/index.js +1 -1
- package/electron/cli-main.cjs +19 -19
- package/electron/main.cjs +167 -148
- package/electron/preload.js +16 -18
- package/icons/icon-128.png +0 -0
- package/icons/icon-144.png +0 -0
- package/icons/icon-152.png +0 -0
- package/icons/icon-192.png +0 -0
- package/icons/icon-384.png +0 -0
- package/icons/icon-512.png +0 -0
- package/icons/icon-72.png +0 -0
- package/icons/icon-96.png +0 -0
- package/js/console.js +21 -12
- package/js/hex-editor.js +216 -163
- package/js/improv.js +59 -21
- package/js/modules/esp32-n1hWo9nn.js +1 -0
- package/js/modules/esp32c2-CPnHdueO.js +1 -0
- package/js/modules/esp32c3-ea1mvbdS.js +1 -0
- package/js/modules/esp32c5-Dzn4lVbd.js +1 -0
- package/js/modules/esp32c6-DL8Ekn6h.js +1 -0
- package/js/modules/esp32c61-DDIvCrFA.js +1 -0
- package/js/modules/esp32h2-Dnu87P5q.js +1 -0
- package/js/modules/esp32p4-HGPqzQsU.js +1 -0
- package/js/modules/esp32p4r3-DounZFQB.js +1 -0
- package/js/modules/esp32s2-gzKRBlZl.js +1 -0
- package/js/modules/esp32s3-BzPgJvNE.js +1 -0
- package/js/modules/esp32s31-Ck4fXdho.js +1 -0
- package/js/modules/esp8266-KToZdvHe.js +1 -0
- package/js/modules/esptool.js +1 -1
- package/js/nvs-editor.js +1366 -182
- package/js/script.js +1048 -845
- package/js/util/console-color.js +3 -3
- package/js/util/timestamp-transformer.js +24 -1
- package/js/webusb-serial.js +1075 -950
- package/package.cli.json +2 -2
- package/package.json +22 -13
- package/screenshots/desktop.png +0 -0
- package/screenshots/mobile.png +0 -0
- package/src/const.ts +12 -3
- package/src/esp_loader.ts +41 -24
- package/src/flash_jedec.ts +5 -0
- package/src/stubs/README.md +3 -1
- package/src/stubs/esp32.json +5 -5
- package/src/stubs/esp32c2.json +4 -4
- package/src/stubs/esp32c3.json +4 -4
- package/src/stubs/esp32c5.json +4 -4
- package/src/stubs/esp32c6.json +4 -4
- package/src/stubs/esp32c61.json +4 -4
- package/src/stubs/esp32h2.json +4 -4
- package/src/stubs/esp32h4.json +8 -0
- package/src/stubs/esp32p4.json +4 -4
- package/src/stubs/esp32p4r3.json +4 -4
- package/src/stubs/esp32s2.json +4 -4
- package/src/stubs/esp32s3.json +27 -5
- package/src/stubs/esp32s31.json +8 -0
- package/src/stubs/esp8266.json +5 -5
- package/src/stubs/index.ts +3 -2
- package/src/util/console-color.ts +3 -3
- package/src/util/timestamp-transformer.ts +27 -1
- package/sw.js +1 -1
- package/dist/web/esp32-BRKoi17y.js +0 -1
- package/dist/web/esp32c2-Btgr_lwh.js +0 -1
- package/dist/web/esp32c3-CHKfoI8W.js +0 -1
- package/dist/web/esp32c5-BDW4KtLo.js +0 -1
- package/dist/web/esp32c6-il8tTxAG.js +0 -1
- package/dist/web/esp32c61-thKzxBGf.js +0 -1
- package/dist/web/esp32h2-CxoUHv_P.js +0 -1
- package/dist/web/esp32p4-D3jLP-jY.js +0 -1
- package/dist/web/esp32p4r3-CqI71ojR.js +0 -1
- package/dist/web/esp32s2-iX3WoDbg.js +0 -1
- package/dist/web/esp32s3-DGwDVIgz.js +0 -1
- package/dist/web/esp8266-CUwxJpGa.js +0 -1
- package/js/modules/esp32-BRKoi17y.js +0 -1
- package/js/modules/esp32c2-Btgr_lwh.js +0 -1
- package/js/modules/esp32c3-CHKfoI8W.js +0 -1
- package/js/modules/esp32c5-BDW4KtLo.js +0 -1
- package/js/modules/esp32c6-il8tTxAG.js +0 -1
- package/js/modules/esp32c61-thKzxBGf.js +0 -1
- package/js/modules/esp32h2-CxoUHv_P.js +0 -1
- package/js/modules/esp32p4-D3jLP-jY.js +0 -1
- package/js/modules/esp32p4r3-CqI71ojR.js +0 -1
- package/js/modules/esp32s2-iX3WoDbg.js +0 -1
- package/js/modules/esp32s3-DGwDVIgz.js +0 -1
- package/js/modules/esp8266-CUwxJpGa.js +0 -1
package/js/console.js
CHANGED
|
@@ -133,7 +133,7 @@ export class ESP32ToolConsole {
|
|
|
133
133
|
`;
|
|
134
134
|
|
|
135
135
|
this.console = new ColoredConsole(
|
|
136
|
-
this.containerElement.querySelector(".log")
|
|
136
|
+
this.containerElement.querySelector(".log"),
|
|
137
137
|
);
|
|
138
138
|
|
|
139
139
|
// Setup event listeners
|
|
@@ -152,18 +152,22 @@ export class ESP32ToolConsole {
|
|
|
152
152
|
closeBtn.addEventListener("click", () => {
|
|
153
153
|
// Dispatch close event to parent
|
|
154
154
|
this.containerElement.dispatchEvent(
|
|
155
|
-
new CustomEvent("console-close", { bubbles: true })
|
|
155
|
+
new CustomEvent("console-close", { bubbles: true }),
|
|
156
156
|
);
|
|
157
157
|
});
|
|
158
158
|
}
|
|
159
159
|
|
|
160
|
-
const improvBtn = this.containerElement.querySelector(
|
|
160
|
+
const improvBtn = this.containerElement.querySelector(
|
|
161
|
+
"#console-improv-btn",
|
|
162
|
+
);
|
|
161
163
|
if (improvBtn) {
|
|
162
164
|
improvBtn.addEventListener("click", () => this._openImprov());
|
|
163
165
|
}
|
|
164
166
|
|
|
165
167
|
if (this.allowInput) {
|
|
166
|
-
const input = this.containerElement.querySelector(
|
|
168
|
+
const input = this.containerElement.querySelector(
|
|
169
|
+
".esp32tool-console-input",
|
|
170
|
+
);
|
|
167
171
|
|
|
168
172
|
this.containerElement.addEventListener("click", () => {
|
|
169
173
|
// Only focus input if user didn't select some text
|
|
@@ -217,10 +221,10 @@ export class ESP32ToolConsole {
|
|
|
217
221
|
this.console.addLine("");
|
|
218
222
|
this.console.addLine("");
|
|
219
223
|
this.console.addLine(
|
|
220
|
-
`Terminal disconnected: Port readable stream not available
|
|
224
|
+
`Terminal disconnected: Port readable stream not available`,
|
|
221
225
|
);
|
|
222
226
|
console.error(
|
|
223
|
-
"Port readable stream not available - port may need to be reopened at correct baudrate"
|
|
227
|
+
"Port readable stream not available - port may need to be reopened at correct baudrate",
|
|
224
228
|
);
|
|
225
229
|
return;
|
|
226
230
|
}
|
|
@@ -248,14 +252,14 @@ export class ESP32ToolConsole {
|
|
|
248
252
|
if (pat.test(chunk)) {
|
|
249
253
|
bootloaderDetected = true;
|
|
250
254
|
this.containerElement.dispatchEvent(
|
|
251
|
-
new CustomEvent("console-bootloader", { bubbles: true })
|
|
255
|
+
new CustomEvent("console-bootloader", { bubbles: true }),
|
|
252
256
|
);
|
|
253
257
|
break;
|
|
254
258
|
}
|
|
255
259
|
}
|
|
256
260
|
}
|
|
257
261
|
},
|
|
258
|
-
})
|
|
262
|
+
}),
|
|
259
263
|
);
|
|
260
264
|
if (!abortSignal.aborted) {
|
|
261
265
|
this.console.addLine("");
|
|
@@ -264,7 +268,10 @@ export class ESP32ToolConsole {
|
|
|
264
268
|
}
|
|
265
269
|
} catch (e) {
|
|
266
270
|
// Only log disconnect errors if the abort was NOT intentional
|
|
267
|
-
if (
|
|
271
|
+
if (
|
|
272
|
+
!abortSignal.aborted &&
|
|
273
|
+
!(e instanceof DOMException && e.name === "AbortError")
|
|
274
|
+
) {
|
|
268
275
|
this.console.addLine("");
|
|
269
276
|
this.console.addLine("");
|
|
270
277
|
this.console.addLine(`Terminal disconnected: ${e}`);
|
|
@@ -297,7 +304,9 @@ export class ESP32ToolConsole {
|
|
|
297
304
|
}
|
|
298
305
|
|
|
299
306
|
async _sendCommand() {
|
|
300
|
-
const input = this.containerElement.querySelector(
|
|
307
|
+
const input = this.containerElement.querySelector(
|
|
308
|
+
".esp32tool-console-input",
|
|
309
|
+
);
|
|
301
310
|
const command = input.value;
|
|
302
311
|
|
|
303
312
|
if (command.trim() !== "") {
|
|
@@ -347,8 +356,8 @@ export class ESP32ToolConsole {
|
|
|
347
356
|
|
|
348
357
|
// Only check the first 30 lines (same as _connect) to avoid false positives
|
|
349
358
|
// from bootloader patterns appearing later in normal firmware output
|
|
350
|
-
const lines = text.split(
|
|
351
|
-
const firstLines = lines.slice(0, 30).join(
|
|
359
|
+
const lines = text.split("\n");
|
|
360
|
+
const firstLines = lines.slice(0, 30).join("\n");
|
|
352
361
|
|
|
353
362
|
for (const pat of BOOTLOADER_PATTERNS) {
|
|
354
363
|
if (pat.test(firstLines)) {
|