; optional path information - default output folder is ; user documents -> umcbuild... [PATH] Output=C:\MYBOOTLOADER ; source code files... [TEMPLATE] PIC16=..\src\16F\umc_loader.asm PIC18=..\src\18F\umc_loader.asm [USART] BAUDRATE=19200 BRGH=1 BRG16=1 ; device name and OSC... [MCU] Device=18F25K22 OSC=64000000 ; device configuration settings... [CONFIG] config FOSC = INTIO67 config PLLCFG = OFF config PRICLKEN = ON ; Primary clock Enabled config FCMEN = OFF ; Fail-Safe Clock Disabled config IESO = OFF ; Oscillator Switchover Disabled config PWRTEN = ON ; Powerup Timer Enabled config HFOFST = OFF ; HFINTOSC delayed until oscillator stable config BOREN = ON ; Brown Out Detector Enabled config BORV = 250 ; VBOR set to 2.50 V nominal config WDTEN = OFF ; WDT Enabled; SWDTEN bit has no effect config WDTPS = 512 ; WDT = 1:512 = 2048 ms config CCP2MX = PORTB3 ; CCP2 i/o is multiplexed with RB3 (not RC1) config CCP3MX = PORTB5 ; P3A/CCP3 i/o is multiplexed with RB5 (not RC6) config T3CMX = PORTB5 ; T3CKI is on RB5 (not RC0) config P2BMX = PORTC0 ; ECCP2 P2B is on RC0 (not RB5) config PBADEN = OFF ; PORTB<5:0> pins configured as digital i/o (not analog) config MCLRE = EXTMCLR config STVREN = ON ; Stack Overflow Reset Enabled config XINST = OFF ; Extended Instructions Disabled config LVP = OFF ; Low-Voltage-Programming Disabled config CP0 = OFF ;Code Protect 00800-03FFF config CP1 = OFF ;Code Protect 04000-07FFF config CP2 = OFF ;Code Protect 08000-0BFFF config CP3 = OFF ;Code Protect 0C000-0FFFF config CPB = OFF ;Code Protect Boot config CPD = OFF ;Data EE Read Protect config WRT0 = OFF ;Table Write Protect 00800-03FFF config WRT1 = OFF ;Table Write Protect 04000-07FFF config WRT2 = OFF ;Table Write Protect 08000-0BFFF config WRT3 = OFF ;Table Write Protect 0C000-0FFFF config WRTC = OFF ;Config. Write Protect config WRTB = OFF ;Table Write Protect Boot config WRTD = OFF ;Data EE Write Protect config EBTR0 = OFF ;Table Read Protect 00800-03FFF config EBTR1 = OFF ;Table Read Protect 04000-07FFF config EBTR2 = OFF ;Table Read Protect 08000-0BFFF config EBTR3 = OFF ;Table Read Protect 0C000-0FFFF config EBTRB = OFF ;Table Read Protect Boot ; place startup code in here... [USERCODE] movlb 0x0F ; MANDATORY: BSR set to SFR bank movlw b'00000000' movwf ANSELC ; MANDATORY: analog off on port C movlw 0x70 movwf OSCCON bsf OSCTUNE,6 BTFSS OSCCON2,7 BRA $-2