So using your example I should put the option_reg declaration where I have it in your example below if I want the interupt to occur on the falling edge? I will try this tonight thanks alot!
Code:LED1 VAR PORTB.1 INCLUDE "DT_INTS-14.bas" ' Base Interrupt System INCLUDE "ReEnterPBP.bas" ' Include if using PBP interrupts OPTION_REG.6 = 0 ' INT on Falling Edge ASM INT_LIST macro ; IntSource, Label, Type, ResetFlag? INT_Handler INT_INT, _ToggleLED1, PBP, yes endm INT_CREATE ; Creates the interrupt processor INT_ENABLE INT_INT ; enable external (INT) interrupts ENDASM Main: PAUSE 1 GOTO Main '---[INT - interrupt handler]--------------------------------------------------- ToggleLED1: TOGGLE LED1 @ INT_RETURN




Bookmarks