>>Reginald Neale wrote: >>[snip] >>> Why can't I tweak the internal oscillator on a 12C671/JW part? I'm using >>> the standard header file with MPLAB and a PicStart Plus. My code is: >>> >>> org 0x00 >>> movlw 0xXX >>> movwf OSCCAL >>> >>> But no matter what I put in for XX, the osc freq doesn't change. I must be >>> overlooking something pretty basic. >>> Reg Neale OSCCAL is in BANK1. have you selected BANK1? >> >>Reg - - >>I don't program the 12C671, but the chips that I do program require >>that the OSCCAL value be placed at the top location in memory. >> >> ORG 0x1FF >> MOVLW 0xXX >> ORG 0x000 >> MOVWF OSCCAL >> >>Hope that this helps you, >> - Nick - Unlike the 12c508/509, the instruction at the top of the address space is retlw 0xXX, not movlw 0xXX code_start equ 0x05 org top_of_memory retlw 0xXX org 0x00 ;reset vector goto code_start code_start bsf STATUS, RP0 ; select BANK1 call top_of_memory movwf OSCCAL > >Thanks, Nick. The top location for this part is 0x3FF. I did try that. >Didn't seem to cause any change. Maybe I'm screwing something else up. > >Reg >