define out the safe mode message if none
This commit is contained in:
parent
0aa41fa92e
commit
8f82db5b22
@ -2011,6 +2011,10 @@ msgid ""
|
|||||||
"exit safe mode."
|
"exit safe mode."
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
|
#: ports/espressif/boards/m5stack_atom_lite/mpconfigboard.h
|
||||||
|
msgid "The central button was pressed at start up.\n"
|
||||||
|
msgstr ""
|
||||||
|
|
||||||
#: ports/nrf/boards/aramcon2_badge/mpconfigboard.h
|
#: ports/nrf/boards/aramcon2_badge/mpconfigboard.h
|
||||||
msgid "The left button was pressed at start up.\n"
|
msgid "The left button was pressed at start up.\n"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
@ -3839,10 +3843,6 @@ msgstr ""
|
|||||||
msgid "pow() with 3 arguments requires integers"
|
msgid "pow() with 3 arguments requires integers"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#: ports/espressif/boards/m5stack_atom_lite/mpconfigboard.h
|
|
||||||
msgid "The central button was pressed at start up.\n"
|
|
||||||
msgstr ""
|
|
||||||
|
|
||||||
#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c
|
#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c
|
||||||
msgid "pull masks conflict with direction masks"
|
msgid "pull masks conflict with direction masks"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
@ -146,17 +146,17 @@ void print_safe_mode_message(safe_mode_t reason) {
|
|||||||
|
|
||||||
switch (reason) {
|
switch (reason) {
|
||||||
case USER_SAFE_MODE:
|
case USER_SAFE_MODE:
|
||||||
#ifdef BOARD_USER_SAFE_MODE_ACTION
|
#if defined(BOARD_USER_SAFE_MODE_ACTION)
|
||||||
message = BOARD_USER_SAFE_MODE_ACTION;
|
message = BOARD_USER_SAFE_MODE_ACTION;
|
||||||
#elif defined(CIRCUITPY_BOOT_BUTTON)
|
#elif defined(CIRCUITPY_BOOT_BUTTON)
|
||||||
message = translate("The BOOT button was pressed at start up.\n");
|
message = translate("The BOOT button was pressed at start up.\n");
|
||||||
#endif
|
#endif
|
||||||
if (message != NULL) {
|
#if defined(BOARD_USER_SAFE_MODE_ACTION) || defined(CIRCUITPY_BOOT_BUTTON)
|
||||||
// Output a user safe mode string if it's set.
|
// Output a user safe mode string if it's set.
|
||||||
serial_write_compressed(message);
|
serial_write_compressed(message);
|
||||||
message = translate("To exit, please reset the board without requesting safe mode.");
|
message = translate("To exit, please reset the board without requesting safe mode.");
|
||||||
// The final piece is printed below.
|
// The final piece is printed below.
|
||||||
}
|
#endif
|
||||||
break;
|
break;
|
||||||
case MANUAL_SAFE_MODE:
|
case MANUAL_SAFE_MODE:
|
||||||
message = translate("You pressed the reset button during boot. Press again to exit safe mode.");
|
message = translate("You pressed the reset button during boot. Press again to exit safe mode.");
|
||||||
|
Loading…
Reference in New Issue
Block a user