summaryrefslogtreecommitdiff
path: root/main.c
diff options
context:
space:
mode:
authorDan Halbert <halbert@halwitz.org>2020-08-13 17:47:35 -0400
committerDan Halbert <halbert@halwitz.org>2020-08-13 17:47:35 -0400
commitd0ffdda5bb8f81fcf5002e2a75b4fef5b652fd7a (patch)
treed5a3fb733b92f821937fac6cba28ae1b26317c70 /main.c
parent44c9c43cd15ea7be3192313b1a1bb204743492a1 (diff)
fix reset logic to not do pin ops or heap ops at bad times
Diffstat (limited to 'main.c')
-rwxr-xr-xmain.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/main.c b/main.c
index 4dd93374e..e1078edc1 100755
--- a/main.c
+++ b/main.c
@@ -212,6 +212,8 @@ bool maybe_run_list(const char ** filenames, pyexec_result_t* exec_result) {
}
void cleanup_after_vm(supervisor_allocation* heap) {
+ // Reset port-independent devices, like CIRCUITPY_BLEIO_HCI.
+ reset_devices();
// Turn off the display and flush the fileystem before the heap disappears.
#if CIRCUITPY_DISPLAYIO
reset_displays();