1
0
Fork 0
mirror of https://github.com/betaflight/betaflight.git synced 2025-07-25 01:05:27 +03:00

Configurable transponder

This commit is contained in:
jflyper 2017-06-15 15:14:50 +09:00
parent 042ffad61d
commit fda5e0f962
6 changed files with 32 additions and 11 deletions

View file

@ -152,16 +152,8 @@ void transponderIrHardwareInit(ioTag_t ioTag, transponder_t *transponder)
DMA_ITConfig(dmaRef, DMA_IT_TC, ENABLE);
}
bool transponderIrInit(const transponderProvider_e provider)
bool transponderIrInit(const ioTag_t ioTag, const transponderProvider_e provider)
{
ioTag_t ioTag = IO_TAG_NONE;
for (int i = 0; i < USABLE_TIMER_CHANNEL_COUNT; i++) {
if (timerHardware[i].usageFlags & TIM_USE_TRANSPONDER) {
ioTag = timerHardware[i].tag;
break;
}
}
if (!ioTag) {
return false;
}