mirror of
https://github.com/betaflight/betaflight.git
synced 2025-07-20 06:45:16 +03:00
Transponder - update PG initialisation code to use `timerioTagG… (#8483)
Transponder - update PG initialisation code to use `timerioTagGetByUsage`
This commit is contained in:
commit
16ee340649
1 changed files with 1 additions and 6 deletions
|
@ -52,12 +52,7 @@ void pgResetFn_transponderConfig(transponderConfig_t *transponderConfig)
|
||||||
.data = { 0x12, 0x34, 0x56, 0x78, 0x9A, 0xBC, 0x0, 0x0, 0x0 }, // Note, this is NOT a valid transponder code, it's just for testing production hardware
|
.data = { 0x12, 0x34, 0x56, 0x78, 0x9A, 0xBC, 0x0, 0x0, 0x0 }, // Note, this is NOT a valid transponder code, it's just for testing production hardware
|
||||||
.ioTag = IO_TAG_NONE
|
.ioTag = IO_TAG_NONE
|
||||||
);
|
);
|
||||||
for (unsigned i = 0; i < TIMER_CHANNEL_COUNT; i++) {
|
transponderConfig->ioTag = timerioTagGetByUsage(TIM_USE_TRANSPONDER, 0);
|
||||||
if (TIMER_HARDWARE[i].usageFlags & TIM_USE_TRANSPONDER) {
|
|
||||||
transponderConfig->ioTag = TIMER_HARDWARE[i].tag;
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
static bool transponderInitialised = false;
|
static bool transponderInitialised = false;
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue