diff --git a/bootloader/main.c b/bootloader/main.c
index 4dd5737755462a53d5760ffab243c5bf730cbc12..5b99e5362943add028c925b1b22c26f2e2d47799 100644
--- a/bootloader/main.c
+++ b/bootloader/main.c
@@ -288,6 +288,13 @@ int main(void)
 		}
 	}
 
+	/* Get the intital SP of the firmware. If it is 0xFFFFFFFF, no image has been
+	 * flashed yet. Drop into MSC for initial flashing. */
+	if (*((uint32_t *)PARTITION_START) == 0xFFFFFFFF) {
+		printf("No valid image in flash\n");
+		msc();
+	}
+
 	printf("Trying to boot\n");
 
 	boot((uintptr_t *)PARTITION_START);