diff --git a/sw/controller/src/cfg.c b/sw/controller/src/cfg.c index d7db3f8..29cec9e 100644 --- a/sw/controller/src/cfg.c +++ b/sw/controller/src/cfg.c @@ -655,6 +655,9 @@ void cfg_process (void) { led_activity_on(); error = sd_card_init(); led_activity_off(); + if (error != SD_OK) { + sd_release_lock(SD_LOCK_N64); + } } break; diff --git a/sw/controller/src/usb.c b/sw/controller/src/usb.c index 70a1a1a..99f9a0b 100644 --- a/sw/controller/src/usb.c +++ b/sw/controller/src/usb.c @@ -404,6 +404,9 @@ static void usb_rx_process (void) { led_activity_on(); error = sd_card_init(); led_activity_off(); + if (error != SD_OK) { + sd_release_lock(SD_LOCK_USB); + } } break;