Due and Pin change Interrupts again :-)

Hello all. It s my first post so be clement. :-) The problem with firing Interrupts after detachInterrupt(Pin) and attachIntterupt(Pin,ISR,status) is known as fare as i read in the forum. What i found out: If you reading the Intterupt Register before attaching the Interrupt it will solve the problem:

  • PIOC->PIO_ISR & PIO_PC12; //Pin 51 is C12*
  • attachInterrupt(51, Puls_LOW, FALLING);*

Now two questions:

  1. Why does the following code not work:
  • NVIC_ClearPendingIRQ(PIOC_IRQn);*
  • attachInterrupt(51, Puls_LOW, FALLING);*
  1. Because the Arduino implementation of the Interrupt handling is slow I wanted to implemet it in my Programm with:

void PIOC_Handler(void) * {* * // searching for the Pin that made the interrupt here* * }*

But I am getting a error message from the compiler because multible definition in WInterrupts.c and my programm. Is there a easy way or do I have to Change the "WInterrupts.c" file ?

Thx alot in advance for your help. Julian

The problem with firing Interrupts after detachInterrupt(Pin) and attachIntterupt(Pin,ISR,status) is known as fare as i read in the forum.

No such problem as for as I have ever heard.

The rest of your post makes no sense!

Mark