Connecting multiple interrupt sources on the same port of PSoC 3/5 | Cypress Semiconductor
Support & Community
Connecting multiple interrupt sources on the same port of PSoC 3/5
Why can't I connect multiple interrupts on the same port? i.e., If I connect an ISR to pin P0, I'm not able to connect another ISR to pin P0.
The interrupt option provided in the pin component uses the PICU (Port Interrupt Control Unit) block in PSoC 3/5 to generate the interrupts. Each PICU interrupt is meant to deal with a whole port. If the two interrupt sources are on the same port then they get ORed as an interrupt in the PICU and hence will be treated as a single interrupt.
The user has two ways to solve this
1) Use a single interrupt for the Port and when the interrupt occurs inside the interrupt routine poll the port status using a
2) Here the user will have to use one interrupt as a PICU interrupt and the other as a normal digitally routed interrupt thus treating both sources as distinct interrupts. To achieve this the user has to enable the interrupt in the pin component and then connect the first interrupt to the interrupt pin provided. This interrupt would be treated as a PICU interrupt. The other interrupt can then be connected to the hardware connection of the pin itself as shown in the figure
The pin component configuration should be done in such a way that only the required pin is used as the PICU interrupt source. So the interrupt would be enabled only for the pin selceted and other would have the interrupt disabled as shown
Here Pin_1_0 will be connected to a digitally routed interrupt isr2 and Pin_1_1 would be connected to isr1 which is a PICU interrupt.