reset stats
This commit is contained in:
parent
d90c29536f
commit
3d54b9ee09
@ -26,6 +26,11 @@ static bool globalStatsCmd(uint8_t argc, char **args) {
|
|||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
static bool resetStatsCmd(uint8_t argc, char **args) {
|
||||||
|
t_deviceStats *deviceStats = getGlobalDeviceStats();
|
||||||
|
deviceStats->totalWatchdogResets = 0;
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
const cmd_t COMMANDS[] = {
|
const cmd_t COMMANDS[] = {
|
||||||
@ -33,6 +38,10 @@ const cmd_t COMMANDS[] = {
|
|||||||
.help = \
|
.help = \
|
||||||
"stats .......................... Show the device statistics\n\r"
|
"stats .......................... Show the device statistics\n\r"
|
||||||
},
|
},
|
||||||
|
{ .name = "resetStats", .cmdFunc = resetStatsCmd,
|
||||||
|
.help = \
|
||||||
|
"resetStats ..................... Reset the device statistics\n\r"
|
||||||
|
},
|
||||||
{ .name = "END_OF_CMDS", .help = "",.cmdFunc = NULL }
|
{ .name = "END_OF_CMDS", .help = "",.cmdFunc = NULL }
|
||||||
};
|
};
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user