mirror of
https://github.com/silenty4ng/k5web
synced 2025-04-19 00:29:49 +00:00
clean eeprom 0xff
This commit is contained in:
parent
2a41f59656
commit
73a6f8ea30
1 changed files with 1 additions and 1 deletions
|
@ -105,7 +105,7 @@ const checkEeprom = async () => {
|
|||
const clearEEPROM = async () => {
|
||||
if(appStore.connectState != true){alert(sessionStorage.getItem('noticeConnectK5')); return;};
|
||||
const eepromSize = await check_eeprom(appStore.connectPort, appStore.configuration?.uart);
|
||||
let rawEEPROM = new Uint8Array(0x80);
|
||||
let rawEEPROM = new Uint8Array(0x80).fill(0xff);
|
||||
for (let i = 0; i < eepromSize; i += 0x80) {
|
||||
await eeprom_write(appStore.connectPort, i, rawEEPROM, 0x80, appStore.configuration?.uart);
|
||||
state.status = state.status + "清空进度:" + (((i - 0) / eepromSize) * 100).toFixed(1) + "%<br/>";
|
||||
|
|
Loading…
Add table
Reference in a new issue