Forums

pic18f452 interrupts

Started by vijayguru October 5, 2007
how to handle 4 interrupts in pic18f452 out four interrupts 2 are low
interrupts and other two are high but we are having only two vector
address plz suggest me anybody


vijayguru wrote:
> how to handle 4 interrupts in pic18f452 out four interrupts 2 are low > interrupts and other two are high but we are having only two vector > address plz suggest me anybody > >
Welcome to the wonderful world of PIC. In the interrupt routine, you need to check which interrupt bit is set, and service that one first (then clear it), then check the another interrupt flag and service that one. You could also check each bit and set a RAM flag, exit the interrupt and service those in your main loop. Timing on your routines is critical, you routine can not be too long. good luck don