esp32,esp8266: Allow Ctrl-C to interrupt the corrupt-fs while loop.
Commit c046b23ea2
prevented frozen boot code
from being interrupted by Ctrl-C, but that means a corrupt filesystem will
forever lock up an esp32/esp8266 board. This commit fixes that by
explicitly enabling Ctrl-C before running the forever loop.
Signed-off-by: Damien George <damien@micropython.org>
This commit is contained in:
parent
0908d00453
commit
47dc7d0130
|
@ -17,6 +17,10 @@ def check_bootsec():
|
||||||
|
|
||||||
def fs_corrupted():
|
def fs_corrupted():
|
||||||
import time
|
import time
|
||||||
|
import micropython
|
||||||
|
|
||||||
|
# Allow this loop to be stopped via Ctrl-C.
|
||||||
|
micropython.kbd_intr(3)
|
||||||
|
|
||||||
while 1:
|
while 1:
|
||||||
print(
|
print(
|
||||||
|
|
|
@ -26,6 +26,10 @@ def check_bootsec():
|
||||||
|
|
||||||
def fs_corrupted():
|
def fs_corrupted():
|
||||||
import time
|
import time
|
||||||
|
import micropython
|
||||||
|
|
||||||
|
# Allow this loop to be stopped via Ctrl-C.
|
||||||
|
micropython.kbd_intr(3)
|
||||||
|
|
||||||
while 1:
|
while 1:
|
||||||
print(
|
print(
|
||||||
|
|
Loading…
Reference in New Issue