View Full Version : Problem with clock
Petenausen
- 26th May 2013, 17:24
Which is the instruction to set on a PIC16F628 or PIC16F628A to use the internal 4MHz oscillator?
Demon
- 26th May 2013, 18:21
This was in the similar threads listed below:
http://www.picbasic.co.uk/forum/showthread.php?t=8901
Robert
Petenausen
- 27th May 2013, 06:50
No, I'n Sorry but I can't understand what to do.
I just want to set internal clock to 4Mhz
Ioannis
- 27th May 2013, 08:31
Use the configuration word _INTRC_OSC_NOCLKOUT (or _INTRC_OSC_CLKOUT if you want the clock signal on the PIC pins).
Ioannis
Petenausen
- 27th May 2013, 15:21
But how I set it at 4 Mhz?
Petenausen
- 27th May 2013, 15:58
For example in Pic16f819 I have to set
@ DEVICE INTRC_OSC
DEFINE OSC 4
OSCCON = $60
to use the internal 4Mhz clock
How can I do this on Pic16f628 or Pic16F628A?
Ioannis
- 27th May 2013, 16:53
If you check the data sheet regarding the internal oscillator, you will confirm that there is no option for other frequencies than 4MHz.
So set what I posted above and also DEFINE OSC 4 if you want (PBP considers this as default) and you are OK.
Ioannis
Petenausen
- 28th May 2013, 06:44
Ok thank you and Sorry for my misunderstanding
Ioannis
- 28th May 2013, 07:48
No problem. Thats what this forum is about.
Ioannis
Powered by vBulletin® Version 4.1.7 Copyright © 2025 vBulletin Solutions, Inc. All rights reserved.