#include <menu.h>
Public Attributes | |
const char | command [MENU_COMMAND_MAX] |
int8_t(* | func )(uint8_t argc, const struct arg *argv) |
callback function |
menu command description
Definition at line 68 of file menu.h.
const char Menu::command::command[MENU_COMMAND_MAX] |
int8_t(* Menu::command::func)(uint8_t argc, const struct arg *argv) |
callback function
The function to call when the command is received.
The argc argument will be at least 1, and no more than MENU_ARGS_MAX. The argv array will be populated with arguments typed/received up to MENU_ARGS_MAX. The command name will always be in argv[0].
Commands may return -2 to cause the menu itself to exit. The "?", "help" and "exit" commands are always defined, but can be overridden by explicit entries in the command array.