diff --git a/main.c b/main.c index 18f145c334..a44e502821 100644 --- a/main.c +++ b/main.c @@ -1078,15 +1078,17 @@ int __attribute__((used)) main(void) { int exit_code = PYEXEC_FORCED_EXIT; bool skip_repl = true; bool simulate_reset = true; + bool first_run = true; for (;;) { if (!skip_repl) { exit_code = run_repl(get_safe_mode()); supervisor_set_run_reason(RUN_REASON_REPL_RELOAD); } if (exit_code == PYEXEC_FORCED_EXIT) { - if (!simulate_reset) { + if (!first_run) { serial_write_compressed(translate("soft reboot\n")); } + first_run = false; if (pyexec_mode_kind == PYEXEC_MODE_FRIENDLY_REPL) { // If code.py did a fake deep sleep, pretend that we // are running code.py for the first time after a hard