![](/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
CommandTerminal/CmdDisplayStats.cpp
- Committer:
- Mike Fiore
- Date:
- 2016-11-04
- Revision:
- 14:f9a77400b622
- Parent:
- 1:e52ae6584f1c
File content as of revision 14:f9a77400b622:
#include "CmdDisplayStats.h" CmdDisplayStats::CmdDisplayStats() : Command("Display Stats", "AT&S", "Display statistics", "TABLE") { } uint32_t CmdDisplayStats::action(std::vector<std::string> args) { mDot::mdot_stats stats = CommandTerminal::Dot()->getStats(); CommandTerminal::Serial()->writef("Join Attempts: %5lu\r\n", stats.Joins); CommandTerminal::Serial()->writef("Join Fails: %5lu\r\n", stats.JoinFails); CommandTerminal::Serial()->writef("Up Packets: %5lu\r\n", stats.Up); CommandTerminal::Serial()->writef("Down Packets: %5lu\r\n", stats.Down); CommandTerminal::Serial()->writef("Missed Acks: %5lu\r\n", stats.MissedAcks); CommandTerminal::Serial()->writef("CRC Errors: %5lu\r\n", stats.CRCErrors); return 0; }