Hello tumbleweed.

Thanks for posting the additional lines of code. Unfortunately, it didn't help. I also searched for version 3.4c but was not able to find it. I managed to find version 3.4b but it also didn't work. Maybe I'm just setting my registers wrong.

Here is what I use:

' INCLUDE "modedefs.bas"
INCLUDE "DT_INTS-18F67K40.bas" 'Base Interrupt System Generated by Darrel Thomas.
INCLUDE "ReEnterPBP-18.bas" 'Include if using PBP interrupts
@ ERRORLEVEL -306

#CONFIG
CONFIG FEXTOSC = OFF ;Oscillator not enabled
CONFIG RSTOSC = HFINTOSC_64MHZ ;HFINTOSC with HFFRQ = 64 MHz and CDIV = 1:1
CONFIG CLKOUTEN = OFF ;CLKOUT function is disabled
CONFIG CSWEN = OFF ;Writing to NOSC and NDIV is allowed
CONFIG FCMEN = OFF ;Fail-Safe Clock Monitor enabled
CONFIG MCLRE = EXTMCLR ;If LVP = 0, MCLR pin is MCLR; If LVP = 1, RE3 pin function is MCLR
CONFIG PWRTE = ON ;Power up timer enabled
CONFIG LPBOREN = OFF ;ULPBOR disabled
CONFIG BOREN = ON ;Brown-out Reset enabled according to SBOREN
CONFIG BORV = VBOR_285 ;Brown-out Reset Voltage (VBOR) set to 2.85V
CONFIG ZCD = OFF ;ZCD disabled. ZCD can be enabled by setting the ZCDSEN bit of ZCDCON
CONFIG PPS1WAY = OFF ;PPSLOCK bit can be set and cleared repeatedly (subject to the unlock sequence)
CONFIG STVREN = OFF ;Stack full/underflow will cause Reset
CONFIG DEBUG = OFF ;Background debugger disabled
CONFIG XINST = OFF ;Extended Instruction Set and Indexed Addressing Mode disabled
CONFIG WDTCPS = WDTCPS_31 ;Divider ratio 1:65536; software control of WDTPS
CONFIG WDTE = OFF ;WDT enabled regardless of sleep
CONFIG WDTCWS = WDTCWS_7 ;window always open (100%); software control; keyed access not required
CONFIG WDTCCS = LFINTOSC ;WDT reference clock is the 31.0 kHz LFINTOSC
CONFIG WRT0 = OFF ;Block 0 (000800-003FFFh) not write-protected
CONFIG WRT1 = OFF ;Block 1 (004000-007FFFh) not write-protected
CONFIG WRT2 = OFF ;Block 2 (008000-00BFFFh) not write-protected
CONFIG WRT3 = OFF ;Block 3 (00C000-00FFFFh) not write-protected
CONFIG WRT4 = OFF ;Block 4 (010000-013FFFh) not write-protected
CONFIG WRT5 = OFF ;Block 5 (014000-017FFFh) not write-protected
CONFIG WRT6 = OFF ;Block 6 (018000-01BFFFh) not write-protected
CONFIG WRT7 = OFF ;Block 7 (01C000-01FFFFh) not write-protected
CONFIG WRTC = OFF ;Configuration registers (300000-30000Bh) not write-protected
CONFIG WRTB = OFF ;Boot Block (000000-0007FFh) not write-protected
CONFIG WRTD = OFF ;Data EEPROM not write-protected
CONFIG SCANE = OFF ;Scanner module is available for use, SCANMD bit can control the module
CONFIG LVP = OFF ;HV on MCLR/VPP must be used for programming
CONFIG CP = OFF ;UserNVM code protection disabled
CONFIG CPD = OFF ;DataNVM code protection disabled
CONFIG EBTR0 = OFF ;Block 0 (000800-003FFFh) not protected from table reads executed in other blocks
CONFIG EBTR1 = OFF ;Block 1 (004000-007FFFh) not protected from table reads executed in other blocks
CONFIG EBTR2 = OFF ;Block 2 (008000-00BFFFh) not protected from table reads executed in other blocks
CONFIG EBTR3 = OFF ;Block 3 (00C000-00FFFFh) not protected from table reads executed in other blocks
CONFIG EBTR4 = OFF ;Block 4 (010000-013FFFh) not protected from table reads executed in other blocks
CONFIG EBTR5 = OFF ;Block 5 (014000-017FFFh) not protected from table reads executed in other blocks
CONFIG EBTR6 = OFF ;Block 6 (018000-01BFFFh) not protected from table reads executed in other blocks
CONFIG EBTR7 = OFF ;Block 7 (01C000-01FFFFh) not protected from table reads executed in other blocks
CONFIG EBTRB = OFF ;Boot Block (000000-0007FFh) not protected from table reads executed in other blocks
#ENDCONFIG



;************************************************* ******************************
DEFINE OSC 64 ; DEFINE THE FREQUENCY USED TO CALCULATE TIME VALUES FOR PAUSES.

;************************************************* ******************************

;************************************************* ******************************
; Oscillator control registers.
;************************************************* ******************************
' OSCCON1 = %01100110 ' FOSC = 64 MHz
' OSCCON2 = %01100000
' OSCCON3 = %01000000
' OSCEN = %01000000
' OSCFRQ = %00000110
' CLKRCON = %10010000
' CLKRCLK = %00000001
;************************************************* ******************************
; Interrupt control registers.
;************************************************* ******************************
' INTCON = %11000000 ; Interrupt Control Register, 1 = Interrupt on rising edge of INT pin
' PIE0 = %00010000 ; IOCIE Bit 4 = 1, Enables the IOC change interrupt
' PIE1 = %00000000
' PIE2 = %00000000
' PIE3 = %00000000
' PIE4 = %00000001
' PIE5 = %00000000
' PIE6 = %00000000
' PIE7 = %00000000
' PIE8 = %00000000

;************************************************* ******************************
; Timer 1 control registers.
;************************************************* ******************************
' T1CON = %00110001 ; Prescaler=8, TMR1ON.
' T1GCON = %00000000 ; Timer 1 Gate disabled.
' T1CLK = %00000011 ; MFINTOSC Selected for Timer 1 clock source.
' TMR1H = $FF
' TMR1L = $FF
;************************************************* ******************************
; Port data direction control registers.
;************************************************* ******************************


ANSELA = %00000000 ; Set all analog pins to digital.
TRISA = %11111111 ; Port A set to inputs.
WPUA = %00000000 ; Weak pull-ups disabled.
ODCONA = %00000000 ; 1 = Open Drain, 0 = Push/Pull drive.
PORTA = %00000000 ; Clear register.
LATA = %00000001 ; Clear register, set bit 0 high.
SLRCONA = %00000000 ; Slew rate at maximum
INLVLA = %11111111 ; 1 = ST input used for PORT reads and interrupt-on-change
; 0 = TTL input used for PORT reads and interrupt-on-change

ANSELB = %00000000 ; Set all analog pins to digital.
TRISB = %11111111 ; Port B set to inputs.
WPUB = %00000000 ; Weak pull-ups disabled.
ODCONB = %00000000 ; 1 = Open Drain, 0 = Push/Pull drive.
PORTB = %00000000 ; Clear register.
LATB = %00000000 ; Clear register.
SLRCONB = %00000000 ; Slew rate at maximum
INLVLB = %11111111 ; 1 = ST input used for PORT reads and interrupt-on-change
; 0 = TTL input used for PORT reads and interrupt-on-change

' ANSELC = %00000000 ; Set all analog pins to digital.
TRISC = %11111111 ; Port C set to outputs except for UART.
WPUC = %00000000 ; Weak pull-ups disabled.
ODCONC = %00000000 ; 1 = Open Drain, 0 = Push/Pull drive.
PORTC = %00000000 ; Clear register.
LATC = %00000000 ; Clear register, set bit 0 high.
SLRCONC = %00000000 ; Slew rate at maximum
INLVLC = %11111111 ; 1 = ST input used for PORT reads and interrupt-on-change
; 0 = TTL input used for PORT reads and interrupt-on-change

ANSELD = %00000000 ; Set all analog pins to digital.
TRISD = %11111111 ; Port D set to outputs.
WPUD = %00000000 ; Weak pull-ups disabled.
ODCOND = %00000000 ; 1 = Open Drain, 0 = Push/Pull drive.
PORTD = %00000000 ; Clear register.
LATD = %00000000 ; Clear register.
SLRCOND = %00000000 ; Slew rate at maximum
INLVLD = %11111111 ; 1 = ST input used for PORT reads and interrupt-on-change
; 0 = TTL input used for PORT reads and interrupt-on-change

ANSELE = %00000000 ; Set all analog pins to digital.
TRISE = %11111111 ; Clear register, only 3 pins available.
WPUE = %00000000 ; Weak pull-ups disabled.
ODCONE = %00000000 ; 1 = Open Drain, 0 = Push/Pull drive.
PORTE = %00000000 ; Clear register.
LATE = %00000000 ; Set outputs high.
SLRCONE = %00000000 ; Slew rate at maximum
INLVLE = %11111111 ; 1 = ST input used for PORT reads and interrupt-on-change
; 0 = TTL input used for PORT reads and interrupt-on-change

ANSELF = %00000000 ; Set all analog pins to digital.
TRISF = %11111111 ; Clear register, only 3 pins available.
WPUF = %00000000 ; Weak pull-ups disabled.
ODCONF = %00000000 ; 1 = Open Drain, 0 = Push/Pull drive.
PORTF = %00000000 ; Clear register.
LATF = %00000000 ; Set outputs high.
SLRCONF = %00000000 ; Slew rate at maximum
INLVLF = %11111111 ; 1 = ST input used for PORT reads and interrupt-on-change
; 0 = TTL input used for PORT reads and interrupt-on-change

ANSELG = %00000000 ; Set all analog pins to digital.
TRISG = %11100011 ; Clear register, only 3 pins available.
WPUG = %00000000 ; Weak pull-ups disabled.
ODCONG = %00000000 ; 1 = Open Drain, 0 = Push/Pull drive.
PORTG = %00000000 ; Clear register.
LATG = %00000000 ; Set outputs high.
SLRCONG = %00000000 ; Slew rate at maximum
INLVLG = %11111111 ; 1 = ST input used for PORT reads and interrupt-on-change
; 0 = TTL input used for PORT reads and interrupt-on-change

' ANSELH = %00000000 ; Set all analog pins to digital.
TRISH = %11110111 ; Clear register, only 3 pins available.
WPUH = %00000000 ; Weak pull-ups disabled.
ODCONH = %00000000 ; 1 = Open Drain, 0 = Push/Pull drive.
PORTH = %00000000 ; Clear register.
LATH = %00000000 ; Set outputs high.
SLRCONH = %00000000 ; Slew rate at maximum
INLVLH = %11111111 ; 1 = ST input used for PORT reads and interrupt-on-change
; 0 = TTL input used for PORT reads and interrupt-on-change
;************************************************* ******************************
; Peripheral Pin Select Modules.
;************************************************* ******************************

;************************************************* ******************************
; Peripheral Module Disable. Page 243 of the datasheet.
; 0 = enabled, 1 = disabled.
;************************************************* ******************************
' PMD0 = %01110000 ; Bit 0 = 0, All IOC modules enabled, CLC.
' PMD1 = %00000000 ; Timer 0-7 modules module enabled.
' PMD2 = %11111111 ; Comaparators 1/2, ZCD modules disabled.
' PMD3 = %00000000 ; DAC,ADC, modules disabled.
' PMD4 = %11111111 ; PWM and CCP CWG moduLes disabled.
' PMD5 = %00000000 ; ESUART/MSSP moduLes Enabled.

;************************************************* ******************************
; Interrupt On Change for ports with IOC.
; 1 = enabled, 0 = diabled.
;************************************************* ******************************
' IOCAF = %00000000 ; Interrupt-on-Change PORTA flags.
' IOCAP = %11111111 ; Interrupt-on-Change PORTA Positive Edge Enable bits.
' IOCAN = %00000000 ; Interrupt-on-Change PORTA Negative Edge Enable bits.

IOCBF = %00000000 ; Interrupt-on-Change PORTB flags.
IOCBP = %00000000 ; Interrupt-on-Change PORTB Positive Edge Enable bits.
IOCBN = %00000000 ; Interrupt-on-Change PORTB Negative Edge Enable bits.

IOCCF = %00000000 ; Interrupt-on-Change PORTC flags.
IOCCP = %00000000 ; Interrupt-on-Change PORTC Positive Edge Enable bits.
IOCCN = %00000000 ; Interrupt-on-Change PORTC Negative Edge Enable bits.

IOCEF = %00000000 ; Interrupt-on-Change PORTE flags.
IOCEP = %00000000 ; Interrupt-on-Change PORTE Positive Edge Enable bits.
IOCEN = %00000000 ; Interrupt-on-Change PORTE Negative Edge Enable bits.

IOCGF = %00000000 ; Interrupt-on-Change PORTG flags.
IOCGP = %00000000 ; Interrupt-on-Change PORTG Positive Edge Enable bits.
IOCGN = %00000000 ; Interrupt-on-Change PORTG Negative Edge Enable bits.

;************************************************* ******************************
; Constants.
;************************************************* ******************************
TimerCounts con 24500

DEFINE SHIFT_PAUSEUS 100
DEFINE WRITE_INT 1
;************************************************* ******************************
; Variables listing.
;************************************************* ******************************
GPCounter var byte ; General Puspose Counter.
Packet var byte[12] ;
StatusFlgs var byte ;
DatIn var StatusFlgs.0

;************************************************* ******************************
; Port Pin names.
;************************************************* ******************************
HeartBeat var LATH.3
STROBE VAR PORTG.2
CLOCK VAR PORTG.3
DATAOUT VAR PORTG.4
;************************************************* ******************************

;************************************************* ******************************
;ASM INTERRUPTS COURTESY OF DARREL TAYLOR.
ASM
INT_LIST macro ; IntSource, Label, Type, ResetFlag?
; INT_Handler RX_INT, _USB_RX_DATA, PBP, yes
INT_Handler TMR2_INT, _Heart_Beat, PBP, yes
endm
INT_CREATE ; Creates the interrupt processor
INT_ENABLE TMR2_INT ; enable Timer 2 interrupts

; INT_ENABLE RX_INT ; enable RECEIVER interrupts.
ENDASM
T2PR = $0F
T2CON = %10010001 ; Prescaler=128, TMR2ON,POSTSCALER=1:16.
T2HLT = %00100000
T2CLKCON = %00000010
' T2RST = %00000000

;************************************************* ******************************
goto Start

;************************************************* ******************************
'USB_RX_DATA:
' HSERIN 100, DONE, [STR FRAME\8]
'DONE:
'@ INT_RETURN
;************************************************* ******************************
Heart_Beat:
toggle HeartBeat

@ INT_RETURN

;************************************************* ******************************
Start:
Any other advise would be appreciated.