Hi All,

I am making good inroads programming the PIC16F1503.
I am able to set Timer1 and IOC interrupts with Darrel's DT_INT routine and can flash LED's at appropriate rates but I have hit a snag setting up weak pull-ups on PORTC.
I can set up weak pull-ups on PORTA but I get a syntax error message when compiling with a weak pull-up on PORTC setting.
My code is as follows:

Code:
#CONFIG
        __config _CONFIG1, _FOSC_INTOSC & _MCLRE_OFF & _CP_OFF & _CLKOUTEN_OFF
        __config _CONFIG2, _LVP_OFF & _LPBOR_OFF
#ENDCONFIG

OSCCON = %01101000              ; Fosc = 4MHz
                                ; Clock determined by Fosc<1:0> Config Word
DEFINE OSC 4                    ; Define socillator as 4MHz

' Included the interrupt system
INCLUDE "DT_INTS-14.bas"
INCLUDE "ReEnterPBP.bas"

ASM
INT_LIST  macro    ; IntSource,        Label,  Type, ResetFlag?
        INT_Handler   TMR1_INT,  _ISR,   PBP,  yes
    endm
    INT_CREATE            ; Creates the interrupt processor
ENDASM


@   INT_ENABLE  TMR1_INT  ; Enable Timer 1 Interrupts

                                
ANSELA = 0                      ; Disable PORTA ADC
ANSELC = 0                      ; Disable PORTC ADC
DACCON0.7 = 0                   ; Disable DAC
CM1CON0.7 = 0                   ; Disable comparator 1
CM2CON0.7 = 0                   ; Disable comparator 2
T1CON = %00110000               ; Fosc/4
                                ; 1:8 Prescaler
                                ; Timer1 OFF
T1GCON.7 = 0                    ; Timer1 counts regardless of gate function
TRISA = %00011000               ; PORTA.3 and PORTA.4 as inputs
TRISC = %00001101               ; PORTC.0, PORTC.2 and PORTC.3 as inputs
OPTION_REG.7 = 0                ; Enable Weak Pull-ups
WPUA = %00011000                ; Pull-ups on PORTA.3 and PORTA.4WPUC = 1 
WPUC = %00001101                ; Pull-ups on PORTC.0, PORTC.2 and PORTC.3
IOCAP = %00011000               ; IOC positive edge register PORTA.3 + PORTA.4
IOCAN = %00011000               ; IOC negative edge register PORTA.3 + PORTA.4
The compiler reports a syntax error at the WPUC = %00001101 statement.
No problems with the WPUA = %00011000 statement so I am bewildered.
The datasheet clearly states how to use the WPUC register and I believe I have followed the instructions correctly.
Am I missing something?

I am using Microcode Studio Version 5.0.0.0, PBP3.0.5.4 and MeLabs U2 programmer.

Any assistance would be greatly appreciated.

Cheers
Barry
VK2XBP