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

Cleanup unused features

This commit is contained in:
Bas Delfos 2017-07-08 22:24:10 +02:00
parent 491ecba4ed
commit b0b339fe31
2 changed files with 11 additions and 10 deletions

View file

@ -161,12 +161,12 @@ static const char * const mixerNames[] = {
// sync this with features_e
static const char * const featureNames[] = {
"RX_PPM", "VBAT", "INFLIGHT_ACC_CAL", "RX_SERIAL", "MOTOR_STOP",
"RX_PPM", "UNUSED", "INFLIGHT_ACC_CAL", "RX_SERIAL", "MOTOR_STOP",
"SERVO_TILT", "SOFTSERIAL", "GPS", "FAILSAFE",
"SONAR", "TELEMETRY", "CURRENT_METER", "3D", "RX_PARALLEL_PWM",
"SONAR", "TELEMETRY", "UNUSED", "3D", "RX_PARALLEL_PWM",
"RX_MSP", "RSSI_ADC", "LED_STRIP", "DISPLAY", "OSD",
"UNUSED", "CHANNEL_FORWARDING", "TRANSPONDER", "AIRMODE",
"SDCARD", "VTX", "RX_SPI", "SOFTSPI", "ESC_SENSOR", "ANTI_GRAVITY", "DYNAMIC_FILTER", NULL
"UNUSED", "UNUSED", "RX_SPI", "SOFTSPI", "ESC_SENSOR", "ANTI_GRAVITY", "DYNAMIC_FILTER", NULL
};
// sync this with rxFailsafeChannelMode_e
@ -1945,7 +1945,8 @@ static void cliFeature(char *cmdline)
for (uint32_t i = 0; ; i++) {
if (featureNames[i] == NULL)
break;
cliPrintf(" %s", featureNames[i]);
if (strcmp(featureNames[i], "UNUSED") != 0)
cliPrintf(" %s", featureNames[i]);
}
cliPrintLinefeed();
return;
@ -2638,7 +2639,7 @@ static void cliSet(char *cmdline)
break;
}
} else if ((valEnd == NULL) && (i == arrayLength - 1)) {
array[i] = atoi(valPtr);
array[i] = atoi(valPtr);
uint8_t *ptr = getValuePointer(val);
memcpy(ptr, array, arrayLength);