assemply with pic18f4520

Status
Not open for further replies.

tinhnho

New Member
Hi guys,

I have this assemply code which poll 2 low priority interrupts INT1 and INT2
Code:
org 0x0018               ; low priority interrupt vector
btfsc INTCON3,INT1F
goto  ISR_for_INT1    ; service device 1
btfsc INTCON3,INT2F
goto  ISR_for_INT2    ; service device 2
goto  $                    ; trap $

I know that INT1 has higher priority than INT2 (correct me if i'm wrong). What should i do to implement equal priority for the two interrupts in this code above. thanks.
 

org 0x0018
btfsc INTCON3,INT1F
goto ISR_for_both
btfsc INTCON3,INT2F
goto ISR_for_both
return
 
Status
Not open for further replies.
Cookies are required to use this site. You must accept them to continue using the site. Learn more…