1
0
Fork 0
mirror of https://github.com/betaflight/betaflight.git synced 2025-07-19 22:35:23 +03:00

Converted more 'feature' type defines to use the 'USE_<x>' convention: LED_STRIP TARGET_CONFIG BRUSHED_ESC_AUTODETECT SERIAL_RX TELEMETRY TELEMETRY_CRSF TELEMETRY_FRSKY TELEMETRY_HOTT TELEMETRY_IBUS TELEMETRY_JETIEXBUS TELEMETRY_LTM TELEMETRY_MAVLINK TELEMETRY_SMARTPORT TELEMETRY_SRXL TELEMETRY_NRF24_LTM TELEMETRY_LTM SPEKTRUM_BIND NAV BUTTONS

This commit is contained in:
mikeller 2017-11-06 23:28:43 +13:00
parent cd2fc5254d
commit b78d8ad83e
140 changed files with 300 additions and 308 deletions

View file

@ -1226,7 +1226,7 @@ static void cliRxRange(char *cmdline)
}
}
#ifdef LED_STRIP
#ifdef USE_LED_STRIP
static void printLed(uint8_t dumpMask, const ledConfig_t *ledConfigs, const ledConfig_t *defaultLedConfigs)
{
const char *format = "led %u %s";
@ -3135,7 +3135,7 @@ const cliResourceValue_t resourceTable[] = {
{ OWNER_SONAR_TRIGGER, PG_SONAR_CONFIG, offsetof(sonarConfig_t, triggerTag), 0 },
{ OWNER_SONAR_ECHO, PG_SONAR_CONFIG, offsetof(sonarConfig_t, echoTag), 0 },
#endif
#ifdef LED_STRIP
#ifdef USE_LED_STRIP
{ OWNER_LED_STRIP, PG_LED_STRIP_CONFIG, offsetof(ledStripConfig_t, ioTag), 0 },
#endif
{ OWNER_SERIAL_TX, PG_SERIAL_PIN_CONFIG, offsetof(serialPinConfig_t, ioTagTx[0]), SERIAL_PORT_MAX_INDEX },
@ -3440,7 +3440,7 @@ static void printConfig(char *cmdline, bool doDiff)
// reset all configs to defaults to do differencing
resetConfigs();
#if defined(TARGET_CONFIG)
#if defined(USE_TARGET_CONFIG)
targetConfiguration();
#endif
if (checkCommand(options, "defaults")) {
@ -3501,7 +3501,7 @@ static void printConfig(char *cmdline, bool doDiff)
cliPrintHashLine("serial");
printSerial(dumpMask, &serialConfig_Copy, serialConfig());
#ifdef LED_STRIP
#ifdef USE_LED_STRIP
cliPrintHashLine("led");
printLed(dumpMask, ledStripConfig_Copy.ledConfigs, ledStripConfig()->ledConfigs);
@ -3615,7 +3615,7 @@ const clicmd_t cmdTable[] = {
"\t<+|->[name]", cliBeeper),
#endif
CLI_COMMAND_DEF("bl", "reboot into bootloader", NULL, cliBootloader),
#ifdef LED_STRIP
#ifdef USE_LED_STRIP
CLI_COMMAND_DEF("color", "configure colors", NULL, cliColor),
#endif
CLI_COMMAND_DEF("defaults", "reset to defaults and reboot", "[nosave]", cliDefaults),
@ -3649,7 +3649,7 @@ const clicmd_t cmdTable[] = {
CLI_COMMAND_DEF("gpspassthrough", "passthrough gps to serial", NULL, cliGpsPassthrough),
#endif
CLI_COMMAND_DEF("help", NULL, NULL, cliHelp),
#ifdef LED_STRIP
#ifdef USE_LED_STRIP
CLI_COMMAND_DEF("led", "configure leds", NULL, cliLed),
#endif
CLI_COMMAND_DEF("map", "configure rc channel order", "[<map>]", cliMap),
@ -3657,7 +3657,7 @@ const clicmd_t cmdTable[] = {
CLI_COMMAND_DEF("mixer", "configure mixer", "list\r\n\t<name>", cliMixer),
#endif
CLI_COMMAND_DEF("mmix", "custom motor mixer", NULL, cliMotorMix),
#ifdef LED_STRIP
#ifdef USE_LED_STRIP
CLI_COMMAND_DEF("mode_color", "configure mode and special colors", NULL, cliModeColor),
#endif
CLI_COMMAND_DEF("motor", "get/set motor", "<index> [<value>]", cliMotor),