1
0
Fork 0
mirror of https://github.com/betaflight/betaflight.git synced 2025-07-23 08:15:30 +03:00

Merge pull request #2027 from mikeller/ordered_cli_help_entries

Put CLI help entries into alphabetical order.
This commit is contained in:
J Blackman 2017-01-07 17:28:07 +11:00 committed by GitHub
commit 770b0fe531

View file

@ -3703,9 +3703,12 @@ static void cliHelp(char *cmdline);
const clicmd_t cmdTable[] = { const clicmd_t cmdTable[] = {
CLI_COMMAND_DEF("adjrange", "configure adjustment ranges", NULL, cliAdjustmentRange), CLI_COMMAND_DEF("adjrange", "configure adjustment ranges", NULL, cliAdjustmentRange),
CLI_COMMAND_DEF("aux", "configure modes", NULL, cliAux), CLI_COMMAND_DEF("aux", "configure modes", NULL, cliAux),
#ifdef BEEPER
CLI_COMMAND_DEF("beeper", "turn on/off beeper", "list\r\n"
"\t<+|->[name]", cliBeeper),
#endif
#ifdef LED_STRIP #ifdef LED_STRIP
CLI_COMMAND_DEF("color", "configure colors", NULL, cliColor), CLI_COMMAND_DEF("color", "configure colors", NULL, cliColor),
CLI_COMMAND_DEF("mode_color", "configure mode and special colors", NULL, cliModeColor),
#endif #endif
CLI_COMMAND_DEF("defaults", "reset to defaults and reboot", NULL, cliDefaults), CLI_COMMAND_DEF("defaults", "reset to defaults and reboot", NULL, cliDefaults),
CLI_COMMAND_DEF("dfu", "DFU mode on reboot", NULL, cliDfu), CLI_COMMAND_DEF("dfu", "DFU mode on reboot", NULL, cliDfu),
@ -3713,6 +3716,9 @@ const clicmd_t cmdTable[] = {
"[master|profile|rates|all] {showdefaults}", cliDiff), "[master|profile|rates|all] {showdefaults}", cliDiff),
CLI_COMMAND_DEF("dump", "dump configuration", CLI_COMMAND_DEF("dump", "dump configuration",
"[master|profile|rates|all] {showdefaults}", cliDump), "[master|profile|rates|all] {showdefaults}", cliDump),
#ifdef USE_ESCSERIAL
CLI_COMMAND_DEF("escprog", "passthrough esc to serial", "<mode [sk/bl/ki/cc]> <index>", cliEscPassthrough),
#endif
CLI_COMMAND_DEF("exit", NULL, NULL, cliExit), CLI_COMMAND_DEF("exit", NULL, NULL, cliExit),
CLI_COMMAND_DEF("feature", "configure features", CLI_COMMAND_DEF("feature", "configure features",
"list\r\n" "list\r\n"
@ -3725,13 +3731,9 @@ const clicmd_t cmdTable[] = {
CLI_COMMAND_DEF("flash_write", NULL, "<address> <message>", cliFlashWrite), CLI_COMMAND_DEF("flash_write", NULL, "<address> <message>", cliFlashWrite),
#endif #endif
#endif #endif
CLI_COMMAND_DEF("get", "get variable value", CLI_COMMAND_DEF("get", "get variable value", "[name]", cliGet),
"[name]", cliGet),
#ifdef GPS #ifdef GPS
CLI_COMMAND_DEF("gpspassthrough", "passthrough gps to serial", NULL, cliGpsPassthrough), CLI_COMMAND_DEF("gpspassthrough", "passthrough gps to serial", NULL, cliGpsPassthrough),
#endif
#ifdef USE_ESCSERIAL
CLI_COMMAND_DEF("escprog", "passthrough esc to serial", "<mode [sk/bl/ki/cc]> <index>", cliEscPassthrough),
#endif #endif
CLI_COMMAND_DEF("help", NULL, NULL, cliHelp), CLI_COMMAND_DEF("help", NULL, NULL, cliHelp),
#ifdef LED_STRIP #ifdef LED_STRIP
@ -3740,16 +3742,19 @@ const clicmd_t cmdTable[] = {
CLI_COMMAND_DEF("map", "configure rc channel order", CLI_COMMAND_DEF("map", "configure rc channel order",
"[<map>]", cliMap), "[<map>]", cliMap),
#ifndef USE_QUAD_MIXER_ONLY #ifndef USE_QUAD_MIXER_ONLY
CLI_COMMAND_DEF("mixer", "configure mixer", CLI_COMMAND_DEF("mixer", "configure mixer", "list\r\n"
"list\r\n"
"\t<name>", cliMixer), "\t<name>", cliMixer),
#endif #endif
CLI_COMMAND_DEF("mmix", "custom motor mixer", NULL, cliMotorMix), CLI_COMMAND_DEF("mmix", "custom motor mixer", NULL, cliMotorMix),
#ifdef LED_STRIP
CLI_COMMAND_DEF("mode_color", "configure mode and special colors", NULL, cliModeColor),
#endif
CLI_COMMAND_DEF("motor", "get/set motor", CLI_COMMAND_DEF("motor", "get/set motor",
"<index> [<value>]", cliMotor), "<index> [<value>]", cliMotor),
CLI_COMMAND_DEF("name", "name of craft", NULL, cliName),
#if (FLASH_SIZE > 128) #if (FLASH_SIZE > 128)
CLI_COMMAND_DEF("play_sound", NULL, CLI_COMMAND_DEF("play_sound", NULL,
"[<index>]\r\n", cliPlaySound), "[<index>]", cliPlaySound),
#endif #endif
CLI_COMMAND_DEF("profile", "change profile", CLI_COMMAND_DEF("profile", "change profile",
"[<index>]", cliProfile), "[<index>]", cliProfile),
@ -3757,43 +3762,34 @@ const clicmd_t cmdTable[] = {
#if (FLASH_SIZE > 64) #if (FLASH_SIZE > 64)
CLI_COMMAND_DEF("resource", "view currently used resources", NULL, cliResource), CLI_COMMAND_DEF("resource", "view currently used resources", NULL, cliResource),
#endif #endif
CLI_COMMAND_DEF("rxrange", "configure rx channel ranges", NULL, cliRxRange),
CLI_COMMAND_DEF("rxfail", "show/set rx failsafe settings", NULL, cliRxFail), CLI_COMMAND_DEF("rxfail", "show/set rx failsafe settings", NULL, cliRxFail),
CLI_COMMAND_DEF("rxrange", "configure rx channel ranges", NULL, cliRxRange),
CLI_COMMAND_DEF("save", "save and reboot", NULL, cliSave), CLI_COMMAND_DEF("save", "save and reboot", NULL, cliSave),
#ifdef USE_SDCARD
CLI_COMMAND_DEF("sd_info", "sdcard info", NULL, cliSdInfo),
#endif
CLI_COMMAND_DEF("serial", "configure serial ports", NULL, cliSerial), CLI_COMMAND_DEF("serial", "configure serial ports", NULL, cliSerial),
#ifndef SKIP_SERIAL_PASSTHROUGH #ifndef SKIP_SERIAL_PASSTHROUGH
CLI_COMMAND_DEF("serialpassthrough", "passthrough serial data to port", CLI_COMMAND_DEF("serialpassthrough", "passthrough serial data to port", "<id> [baud] [mode] : passthrough to serial", cliSerialPassthrough),
"<id> [baud] [mode] : passthrough to serial",
cliSerialPassthrough),
#endif #endif
#ifdef USE_SERVOS #ifdef USE_SERVOS
CLI_COMMAND_DEF("servo", "configure servos", NULL, cliServo), CLI_COMMAND_DEF("servo", "configure servos", NULL, cliServo),
#endif #endif
CLI_COMMAND_DEF("set", "change setting", CLI_COMMAND_DEF("set", "change setting", "[<name>=<value>]", cliSet),
"[<name>=<value>]", cliSet),
#ifdef USE_SERVOS #ifdef USE_SERVOS
CLI_COMMAND_DEF("smix", "servo mixer", CLI_COMMAND_DEF("smix", "servo mixer", "<rule> <servo> <source> <rate> <speed> <min> <max> <box>\r\n"
"<rule> <servo> <source> <rate> <speed> <min> <max> <box>\r\n"
"\treset\r\n" "\treset\r\n"
"\tload <mixer>\r\n" "\tload <mixer>\r\n"
"\treverse <servo> <source> r|n", cliServoMix), "\treverse <servo> <source> r|n", cliServoMix),
#endif
#ifdef USE_SDCARD
CLI_COMMAND_DEF("sd_info", "sdcard info", NULL, cliSdInfo),
#endif #endif
CLI_COMMAND_DEF("status", "show status", NULL, cliStatus), CLI_COMMAND_DEF("status", "show status", NULL, cliStatus),
#ifndef SKIP_TASK_STATISTICS #ifndef SKIP_TASK_STATISTICS
CLI_COMMAND_DEF("tasks", "show task stats", NULL, cliTasks), CLI_COMMAND_DEF("tasks", "show task stats", NULL, cliTasks),
#endif #endif
CLI_COMMAND_DEF("version", "show version", NULL, cliVersion), CLI_COMMAND_DEF("version", "show version", NULL, cliVersion),
#ifdef BEEPER
CLI_COMMAND_DEF("beeper", "turn on/off beeper", "list\r\n"
"\t<+|->[name]", cliBeeper),
#endif
#ifdef VTX #ifdef VTX
CLI_COMMAND_DEF("vtx", "vtx channels on switch", NULL, cliVtx), CLI_COMMAND_DEF("vtx", "vtx channels on switch", NULL, cliVtx),
#endif #endif
CLI_COMMAND_DEF("name", "Name of craft", NULL, cliName),
}; };
#define CMD_COUNT (sizeof(cmdTable) / sizeof(clicmd_t)) #define CMD_COUNT (sizeof(cmdTable) / sizeof(clicmd_t))