Interrupts with PIC18F4550

Jtomas

New Member
Hello everyone,
I'm trying to configure the PIC 18F4550 with PIC SIMULATOR IDE and I can't get it to work. I need to use external interrupts via INT0, INT1, and INT2. I'm sure I'm not configuring the interrupt registers correctly. Can you send me a simple example that might help?
Best regards and thanks.
 
 
Vladimir has an interrupt example

All you need to do is modify for each interrupt.
If you have multiple triggers then determine each in turn like this.

Code:
On Interrupt
    If INT0IF then  'int0 flag
            ' do int 0 stuff
   endif
   If INT1IF then  ' int 1
            ' do int 1 stuff
   endif
   If INT2IF then   ' int 2
            ' do int 2 stuff
   endif
Resume
 
Cookies are required to use this site. You must accept them to continue using the site. Learn more…