1
0
Fork 0
mirror of https://github.com/betaflight/betaflight.git synced 2025-07-13 11:29:58 +03:00

Removed legacy timer index notation from CLI.

This commit is contained in:
mikeller 2020-02-15 14:56:28 +13:00
parent 563022cc40
commit e785d6eaae

View file

@ -5724,15 +5724,9 @@ static void cliTimer(char *cmdline)
return;
}
} else if (strcasecmp(pch, "none") != 0) {
timerIndex = atoi(pch);
cliPrintErrorLinef("INVALID TIMER OPTION FOR %c%02d: '%s'", IO_GPIOPortIdxByTag(ioTag) + 'A', IO_GPIOPinIdxByTag(ioTag), pch);
const timerHardware_t *timer = timerGetByTagAndIndex(ioTag, timerIndex + 1);
if (!timer) {
cliPrintErrorLinef("INVALID TIMER OPTION FOR %c%02d: '%s'", IO_GPIOPortIdxByTag(ioTag) + 'A', IO_GPIOPinIdxByTag(ioTag), pch);
return;
}
return;
}
int oldTimerIndex = isExistingTimerOpt ? timerIOConfig(timerIOIndex)->index - 1 : -1;