Skip to content

Commit 710c2dc

Browse files
committed
safe_mode: Exclude NORDIC_SOFT_DEVICE_ASSERT str if possible
1 parent d92a77f commit 710c2dc

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

supervisor/shared/safe_mode.c

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -151,9 +151,13 @@ void print_safe_mode_message(safe_mode_t reason) {
151151
case GC_ALLOC_OUTSIDE_VM:
152152
serial_write_compressed(translate("Attempted heap allocation when MicroPython VM not running."));
153153
break;
154+
#ifdef SOFTDEVICE_PRESENT
155+
// defined in ports/nrf/bluetooth/bluetooth_common.mk
156+
// will print "Unknown reason" if somehow encountered on other ports
154157
case NORDIC_SOFT_DEVICE_ASSERT:
155158
serial_write_compressed(translate("Nordic Soft Device failure assertion."));
156159
break;
160+
#endif
157161
case FLASH_WRITE_FAIL:
158162
serial_write_compressed(translate("Failed to write internal flash."));
159163
break;

0 commit comments

Comments
 (0)