File tree Expand file tree Collapse file tree 1 file changed +5
-4
lines changed Expand file tree Collapse file tree 1 file changed +5
-4
lines changed Original file line number Diff line number Diff line change @@ -317,7 +317,7 @@ STATIC bool run_code_py(safe_mode_t safe_mode) {
317
317
318
318
// Program has finished running.
319
319
320
- bool serial_connected_before_animation = serial_connected () ;
320
+ bool printed_press_any_key = false ;
321
321
#if CIRCUITPY_DISPLAYIO
322
322
bool refreshed_epaper_display = false;
323
323
#endif
@@ -364,19 +364,20 @@ STATIC bool run_code_py(safe_mode_t safe_mode) {
364
364
}
365
365
#endif
366
366
367
- if (!serial_connected_before_animation && serial_connected ()) {
367
+ if (!printed_press_any_key && serial_connected ()) {
368
368
if (!serial_connected_at_start ) {
369
369
print_code_py_status_message (safe_mode );
370
370
}
371
371
372
372
print_safe_mode_message (safe_mode );
373
373
serial_write ("\n" );
374
374
serial_write_compressed (translate ("Press any key to enter the REPL. Use CTRL-D to reload.\n" ));
375
+ printed_press_any_key = true;
375
376
}
376
- if (serial_connected_before_animation && !serial_connected ()) {
377
+ if (!serial_connected ()) {
377
378
serial_connected_at_start = false;
379
+ printed_press_any_key = false;
378
380
}
379
- serial_connected_before_animation = serial_connected ();
380
381
381
382
// Refresh the ePaper display if we have one. That way it'll show an error message.
382
383
#if CIRCUITPY_DISPLAYIO
You can’t perform that action at this time.
0 commit comments