diff --git a/features/FEATURE_BLE/targets/TARGET_NORDIC/TARGET_NRF5/source/nRF5xn.cpp b/features/FEATURE_BLE/targets/TARGET_NORDIC/TARGET_NRF5/source/nRF5xn.cpp index 0f25e1634b..e79e962ba0 100644 --- a/features/FEATURE_BLE/targets/TARGET_NORDIC/TARGET_NRF5/source/nRF5xn.cpp +++ b/features/FEATURE_BLE/targets/TARGET_NORDIC/TARGET_NRF5/source/nRF5xn.cpp @@ -233,8 +233,12 @@ nRF5xn::waitForEvent(void) } void nRF5xn::processEvents() { + core_util_critical_section_enter(); if (isEventsSignaled) { isEventsSignaled = false; + core_util_critical_section_exit(); intern_softdevice_events_execute(); + } else { + core_util_critical_section_exit(); } }