External Line IRQ

Tip / Sign in to post questions, reply, level up, and achieve exciting badges. Know more

cross mob
User15194
Level 1
Level 1
I use
.edge_detection = XMC_ERU_ETL_EDGE_DETECTION_BOTH.
for exertnal IRQ


This trigger my IRQ function

void ERU0_0_IRQHandler(void) {

if "falling edge" {

}
else {

}

}

Now i have to find out the direction in the IRQ Function, is this possible ?


Thanks,
Embedded
0 Likes
2 Replies
jferreira
Employee
Employee
10 sign-ins 5 sign-ins First like received
Hi,

You will need to check the status of the pin XMC_GPIO_GetInput(). Of course this is assuming the pin remains stable after the edge until the ISR is processed.

Regards,
Jesus
0 Likes
User15194
Level 1
Level 1
Hi Jesus,

thank you for this tip, working fine


Regards,
Embedded
0 Likes