MC9S12DT256: Assigning external interrupts to port pins

取消
显示结果 
显示  仅  | 搜索替代 
您的意思是: 

MC9S12DT256: Assigning external interrupts to port pins

2,093 次查看
swaroop
Contributor I
Hi,
I am desiging a board with the MC9S12DT256 MCU on it. I have a requirement of assigning two external interrupts from two external communication chips to the interrupt inputs of the MCU.
 
I have decided on using PJ0 and PJ1 (Port J) of MCU as edge triggered interrupt inputs for these external interrupts.
 
I do not want to use XIRQ or IRQ.
 
Please tell me if I can use PJ0 and PJ1 as external interrupt inputs.
 
Regards
Swaroop
标签 (1)
0 项奖励
回复
2 回复数

774 次查看
mke_et
Contributor IV
I've not used 'J' but I've done a system that used P and H for port pin interrupts. Just remember, you get a single interrupt for the port, then you have to divide the input as to what it was. And write you ISR so that it can handle the case of a second pin kick coming in while the first is being processed. The easiest way I found is to write your ISR so the 'kick' is generic, then loop until all the pins are clear, then exit on a clear port.

Mike
0 项奖励
回复

774 次查看
Aditya
Contributor I
Can you post the code that you are working on? I am in a similar dilemma and  even after making a number of manupulations, my code does not enter into my ISR. I just wanted to know how we can handle them.
0 项奖励
回复