From 9f2d870fca8085d9dcc2a2714d254da412f82293 Mon Sep 17 00:00:00 2001 From: Paulus Schoutsen Date: Sun, 6 Jun 2021 21:39:02 -0700 Subject: [PATCH] Implement erase-first --- index.html | 1 + src/start-flash.ts | 7 ++++++- 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/index.html b/index.html index 04f8b2c..a5aad83 100644 --- a/index.html +++ b/index.html @@ -56,6 +56,7 @@ your computer and hit the button:

diff --git a/src/start-flash.ts b/src/start-flash.ts index 788b38f..c4dfb44 100644 --- a/src/start-flash.ts +++ b/src/start-flash.ts @@ -129,7 +129,12 @@ export const startFlash = async ( if (eraseFirst) { logEl.addRow({ id: "erase", - content: html`Erasing device`, + content: html`Erasing device...`, + }); + await espStub.eraseFlash(); + logEl.addRow({ + id: "erase", + content: html`Device erased`, }); }