1
0
Fork 0
mirror of https://github.com/betaflight/betaflight.git synced 2025-07-20 06:45:16 +03:00

Fix resource command outputs

This commit is contained in:
jflyper 2017-04-23 03:04:31 +09:00
parent bb5314b825
commit 07b1918acd

View file

@ -2780,7 +2780,7 @@ static void printResource(uint8_t dumpMask)
const ioTag_t ioTagDefault = *((const ioTag_t *)defaultConfig + resourceTable[i].offset + index); const ioTag_t ioTagDefault = *((const ioTag_t *)defaultConfig + resourceTable[i].offset + index);
bool equalsDefault = ioTag == ioTagDefault; bool equalsDefault = ioTag == ioTagDefault;
const char *format = "resource %s %d %c%02dn"; const char *format = "resource %s %d %c%02d\n";
const char *formatUnassigned = "resource %s %d NONE"; const char *formatUnassigned = "resource %s %d NONE";
if (!ioTagDefault) { if (!ioTagDefault) {
cliDefaultPrintLinef(dumpMask, equalsDefault, formatUnassigned, owner, RESOURCE_INDEX(index)); cliDefaultPrintLinef(dumpMask, equalsDefault, formatUnassigned, owner, RESOURCE_INDEX(index));
@ -2862,15 +2862,15 @@ static void cliResource(char *cmdline)
const char* owner; const char* owner;
owner = ownerNames[ioRecs[i].owner]; owner = ownerNames[ioRecs[i].owner];
cliPrintf("%c%02d: %s ", IO_GPIOPortIdx(ioRecs + i) + 'A', IO_GPIOPinIdx(ioRecs + i), owner); cliPrintf("%c%02d: %s", IO_GPIOPortIdx(ioRecs + i) + 'A', IO_GPIOPinIdx(ioRecs + i), owner);
if (ioRecs[i].index > 0) { if (ioRecs[i].index > 0) {
cliPrintf("%d", ioRecs[i].index); cliPrintf(" %d", ioRecs[i].index);
} }
cliPrintLine("\r\n"); cliPrintLine("");
} }
cliPrintLine("\r\n"); cliPrintLine("");
cliPrintLine("\r\n"); cliPrintLine("");
#ifdef MINIMAL_CLI #ifdef MINIMAL_CLI
cliPrintLine("DMA:"); cliPrintLine("DMA:");
#else #else