Dave,
Seems that there were a few mistakes when the low priority interrupts were defined. Try this new version (3.4c) and see if it works out.
It compiled ok using the test code below, but I didn't try actually running it
Code:'18F27K40 DEFINE OSC 64 DEFINE USE_LOWPRIORITY 1 INCLUDE "DT_INTS-18_3_4c.bas" ' Interrupt Control routines INCLUDE "ReEnterPBP-18.bas" ' Interrupt Control routines INCLUDE "ReEnterPBP-18LP.bas" ' Include if using Low Pr. PBP INTS GIEH VAR INTCON.7 ' high priority interrupts GIEL VAR INTCON.6 ' low priority interrupts asm ;----[High Priority Interrupts]----------------------------------------------- INT_LIST macro ; IntSource, Label, Type, ResetFlag? ;LINEAR or ROTARY ENCODER INPUT - A (INCREMENT POSITION) INT_Handler INT0_INT, _INC_C, PBP, yes ;LINEAR or ROTARY ENCODER INPUT - B (DECREMENT POSITION) INT_Handler INT1_INT, _DEC_C, PBP, yes endm INT_CREATE ; Creates the High Priority interrupt processor ;----[Low Priority Interrupts]------------------------------------------------ INT_LIST_L macro ; IntSource, Label, Type, ResetFlag? INT_Handler TX1_INT, _UARTTX1, PBP, no INT_Handler RX1_INT, _UARTRX1, PBP, no INT_Handler TX2_INT, _UARTTX2, PBP, no INT_Handler RX2_INT, _UARTRX2, PBP, no INT_Handler TMR1_INT, _TIMER1, PBP, yes endm INT_CREATE_L ; Creates the LOW Priority interrupt processor ENDASM goto OverIntHandlers INC_C: @ INT_RETURN DEC_C: @ INT_RETURN UARTTX1: @ INT_RETURN UARTRX1: @ INT_RETURN UARTTX2: @ INT_RETURN UARTRX2: @ INT_RETURN TIMER1: @ INT_RETURN OverIntHandlers: '----[ Interrupt control ]------------------------------------------------------- main: NOP GIEL = 1 ' Enable low priority interrupts GIEH = 1 ' Enable global interrupts




Bookmarks