ESP32: reboot whole ESP32 at when invoking reset
This commit is contained in:
parent
e5dd0105af
commit
439c34abab
1 changed files with 8 additions and 7 deletions
15
debugger.cpp
15
debugger.cpp
|
@ -135,22 +135,23 @@ void debugger(console *const cnsl, bus *const b, std::atomic_bool *const interru
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
else if (cmd == "reset" || cmd == "r") {
|
else if (cmd == "reset" || cmd == "r") {
|
||||||
|
#if defined(ESP32)
|
||||||
|
ESP.restart();
|
||||||
|
#else
|
||||||
terminate = false;
|
terminate = false;
|
||||||
|
|
||||||
event = 0;
|
event = 0;
|
||||||
|
|
||||||
c->reset();
|
c->reset();
|
||||||
|
|
||||||
#if defined(ESP32)
|
|
||||||
setBootLoader(b);
|
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
#if !defined(ESP32)
|
else if (cmd == "quit" || cmd == "q") {
|
||||||
else if (cmd == "quit" || cmd == "q")
|
#if defined(ESP32)
|
||||||
break;
|
ESP.restart();
|
||||||
#endif
|
#endif
|
||||||
|
break;
|
||||||
|
}
|
||||||
else if (cmd == "help" || cmd == "h" || cmd == "?") {
|
else if (cmd == "help" || cmd == "h" || cmd == "?") {
|
||||||
cnsl->put_string_lf("disassemble/d - show current instruction (pc=/n=)");
|
cnsl->put_string_lf("disassemble/d - show current instruction (pc=/n=)");
|
||||||
cnsl->put_string_lf("go - run until trap or ^e");
|
cnsl->put_string_lf("go - run until trap or ^e");
|
||||||
|
|
Loading…
Add table
Reference in a new issue