![](/media/cache/img/default_profile.jpg.50x50_q85.jpg)
AT terminal for the mDot using the USB debug port instead of the serial port.
Dependencies: MTS-Serial libmDot-mbed5
Fork of Dot-AT-Firmware by
Diff: CommandTerminal/CmdResetCpu.cpp
- Revision:
- 14:f9a77400b622
- Parent:
- 1:e52ae6584f1c
--- a/CommandTerminal/CmdResetCpu.cpp Fri Nov 04 19:10:24 2016 +0000 +++ b/CommandTerminal/CmdResetCpu.cpp Fri Nov 04 14:25:43 2016 -0500 @@ -1,15 +1,14 @@ #include "CmdResetCpu.h" -CmdResetCpu::CmdResetCpu(mDot* dot, mts::MTSSerial& serial) : Command(dot, "Reset CPU", "ATZ", "Reset the CPU"), _serial(serial) +CmdResetCpu::CmdResetCpu() : Command("Reset CPU", "ATZ", "Reset the CPU", "NONE") { - _help = std::string(text()) + ": " + std::string(desc()); } uint32_t CmdResetCpu::action(std::vector<std::string> args) { - _serial.writef("\r\nOK\r\n"); + CommandTerminal::Serial()->writef("\r\nOK\r\n"); wait(0.5); - HAL_NVIC_SystemReset(); + CommandTerminal::Dot()->resetCpu(); return 0; }