Forum Discussion
Altera_Forum
Honored Contributor
15 years agoHi skw
In order to reset the edge capture register you must write one to the bits you want to reset, not write zero into the register. Then, this line IOWR_ALTERA_AVALON_PIO_EDGE_CAP (PIO_BASE,0); must be changed in IOWR_ALTERA_AVALON_PIO_EDGE_CAP (PIO_BASE, IRQ_BIT_MASK); For example, if your irq signal is connected to pio bit 5, you'll define IRQ_BIT_MASK = 0x40 Regards