Skip to content

Commit

Permalink
Loco deck has an option for alternative pins for IRQ and RESET. This …
Browse files Browse the repository at this point in the history
…is the implementation that changes to the alternative pins set in the config.mk
  • Loading branch information
WoNd3RBoY committed Aug 11, 2017
1 parent 5090fae commit 7c0d0e3
Showing 1 changed file with 1 addition and 15 deletions.
16 changes: 1 addition & 15 deletions src/deck/drivers/src/locodeck.c
Original file line number Diff line number Diff line change
Expand Up @@ -262,20 +262,9 @@ static void spiRead(dwDevice_t* dev, const void *header, size_t headerLength,

#if LOCODECK_USE_ALT_PINS
void __attribute__((used)) EXTI5_Callback(void)
{
portBASE_TYPE xHigherPriorityTaskWoken = pdFALSE;

NVIC_ClearPendingIRQ(EXTI_IRQChannel);
EXTI_ClearITPendingBit(EXTI_LineN);

//To unlock RadioTask
xSemaphoreGiveFromISR(irqSemaphore, &xHigherPriorityTaskWoken);

if(xHigherPriorityTaskWoken)
portYIELD();
}
#else
void __attribute__((used)) EXTI11_Callback(void)
#endif
{
portBASE_TYPE xHigherPriorityTaskWoken = pdFALSE;

Expand All @@ -288,9 +277,6 @@ static void spiRead(dwDevice_t* dev, const void *header, size_t headerLength,
if(xHigherPriorityTaskWoken)
portYIELD();
}
#endif



static void spiSetSpeed(dwDevice_t* dev, dwSpiSpeed_t speed)
{
Expand Down

0 comments on commit 7c0d0e3

Please sign in to comment.