Thanks A LOT! This worked perfectly, I had something like this, but couldn't get it working. BTW, in the 'list' directive, what do the 'b' and 'n' parts stand for? I've never seen them in use before. -Peter ----- Original Message ----- From: "Jan-erik Svderholm (QAC)" To: Sent: Saturday, February 01, 2003 12:26 AM Subject: Re: [PIC]: Can't get this code working: PIC18F252 And here is a working 18F252 example : processor 18f252 LIST P=PIC18F252, b=4, n=45 #include __CONFIG _CONFIG1L, 0x00 __CONFIG _CONFIG1H, 0x27 & _OSCS_OFF_1H & _HS_OSC_1H __CONFIG _CONFIG2L, 0x0F & _BOR_OFF_2L & _BORV_20_2L & _PWRT_OFF_2L __CONFIG _CONFIG2H, 0x0F & _WDT_OFF_2H & _WDTPS_128_2H __CONFIG _CONFIG3L, 0x00 __CONFIG _CONFIG3H, 0x01 & _CCP2MX_ON_3H __CONFIG _CONFIG4L, 0x85 & _STVR_ON_4L & _LVP_OFF_4L & _DEBUG_OFF_4L __CONFIG _CONFIG4H, 0x00 __CONFIG _CONFIG5L, 0x0F & _CP0_OFF_5L & _CP1_OFF_5L & _CP2_OFF_5L & _CP3_OFF_5L __CONFIG _CONFIG5H, 0xC0 & _CPB_OFF_5H & _CPD_OFF_5H __CONFIG _CONFIG6L, 0x0F & _WRT0_OFF_6L & _WRT1_OFF_6L & _WRT2_OFF_6L & _WRT3_OFF_6L __CONFIG _CONFIG6H, 0xE0 & _WRTC_OFF_6H & _WRTB_OFF_6H & _WRTD_OFF_6H __CONFIG _CONFIG7L, 0x0F & _EBTR0_OFF_7L & _EBTR1_OFF_7L & _EBTR2_OFF_7L & _EBTR3_OFF_7L __CONFIG _CONFIG7H, 0x40 & _EBTRB_OFF_7H Jan-Erik Svderholm. -- http://www.piclist.com hint: To leave the PICList mailto:piclist-unsubscribe-request@mitvma.mit.edu -- http://www.piclist.com hint: PICList Posts must start with ONE topic: [PIC]:,[SX]:,[AVR]: ->uP ONLY! [EE]:,[OT]: ->Other [BUY]:,[AD]: ->Ads