diff --git a/libraries/AP_IOMCU/AP_IOMCU.cpp b/libraries/AP_IOMCU/AP_IOMCU.cpp index ac68c7524d..58065a8095 100644 --- a/libraries/AP_IOMCU/AP_IOMCU.cpp +++ b/libraries/AP_IOMCU/AP_IOMCU.cpp @@ -1193,6 +1193,10 @@ bool AP_IOMCU::healthy(void) */ void AP_IOMCU::shutdown(void) { + if (!initialised) { + // we're not initialised yet, so cannot shutdown + return; + } do_shutdown = true; while (!done_shutdown) { hal.scheduler->delay(1);