Quote Originally Posted by Acetronics2 View Post
Oooops, my fault ... wrong chip selected

this one looks to work fine...

Code:
'   set parameters
'
ADCON0=0 'all digital I/O
TRISIO=0 'all outputs (GPIO.3 is input only so it's ignored)
DEFINE OSC 8
DEFINE OSCCAL_1K 1


'*************************************
'     variables and constants
'
tempvar var byte
'***********************************
'    Other housekeeping
'peekcode $1FF, tempvar 'OSCCAL calibration value
'POKE $05, tempvar      'OSCCAL register location


'**************************************************************
'     begin program


GPIO.0=0


loophere:
GPIO.0=1
pause 500
GPIO.0=0
pause 500


goto loophere


end
But you should use PEEKCODE along with POKECODE ...
I'm not writing to CODE area though, it's writing to the OSCCAL register, location $05. Am I wrong in thinking this should do it? It didn't recognize OSCCAL and threw an error when I tried writing it to the register directly using that naming convention.