Skip to content
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
18 changes: 9 additions & 9 deletions main.c
Original file line number Diff line number Diff line change
Expand Up @@ -538,15 +538,6 @@ int __attribute__((used)) main(void) {
// initialise the cpu and peripherals
safe_mode_t safe_mode = port_init();

// Turn on LEDs
init_status_leds();
rgb_led_status_init();

// Wait briefly to give a reset window where we'll enter safe mode after the reset.
if (safe_mode == NO_SAFE_MODE) {
safe_mode = wait_for_safe_mode_reset();
}

stack_init();

// Create a new filesystem only if we're not in a safe mode.
Expand All @@ -557,6 +548,15 @@ int __attribute__((used)) main(void) {
// displays init after filesystem, since they could share the flash SPI
board_init();

// Turn on LEDs
init_status_leds();
rgb_led_status_init();

// Wait briefly to give a reset window where we'll enter safe mode after the reset.
if (safe_mode == NO_SAFE_MODE) {
safe_mode = wait_for_safe_mode_reset();
}

// Start the debug serial
serial_early_init();

Expand Down