At 17.11 2005.05.02 +0200, you wrote: >Dave Turner wrote : > >> I have set the osc to INTRC-CLKOUT, which should be about 8MHz, but >> with the MPLAB SIM, I have to set the processor speed to about 20Khz >> to get near to the speed I'm using. Am I setting up the clock >> incorrectly? All I changed was the __CONFIG. Is there another place >> to change the clock speed? > >And you don't think that the fact that "about 20Khz" happens to be quite >close to 31.25 Khz would ring a bell ?? > >As I wrote in another post : > >-- Have you setup OSCCON correctly ? >-- I think that 31.25 Khz is the POR (power on) default. > >Try to set SIM to (something closer to) 31.25 and see if you >don't get the same time as you see in your hardware. > >Then setup OSCCON correctly to get 8Mhz. > >And yes, this actualy means that the PIC will be running >slowly *until* you set OSCCON in the code. By changing >OSCON you can "gear" the PIC up and down in 8 steps >between 8 Mhz and 31.25 Khz as you like. Cool, now if they only added a Reverse Idler bit in OSCCON.. :D (Reverse Idler =3D Backaxel p=E5 Svenska) > >Jan-Erik. > >=20 --=20 http://www.piclist.com PIC/SX FAQ & list archive View/change your membership options at http://mailman.mit.edu/mailman/listinfo/piclist