|
|
View previous topic :: View next topic |
Author |
Message |
newbieeee Guest
|
PIC OSC settings |
Posted: Thu Jun 12, 2008 3:46 am |
|
|
Hello I have a question about the PIC18F45K20 but this can apply to oscillators source and speed for any chip really.
Regarding the Clock source I need to clarify that is it possible to run the chip at its full speed of 64 mhz without a external cyrstal? ie using the internal clock set at 16 mhz and use the PLL to mulitiply by 4, therefore acheiving a clock speed of 64mhz.
this is acheived by setting the OSCTUNE register to HFINTOSC and then enabling the PLL. I will be doing this by setting the fuses in CCS. I have version 4.062
inaddition, if I did have a external clock of say 16Mhz how do i work out the speed of the processor according to the settings of LP,, XP HS etc...
I have looked at the datasheet and google but me really dont understand probably being a bit stupid.
I am trying to save money by getting ride of a external cyrstal of 16Mhz and therefore would rather opt for the internall osc if possible. What are the advantages and dis of using each type. is there noise issues.
thanks
newbieee |
|
|
Guest
|
|
Posted: Thu Jun 12, 2008 5:46 am |
|
|
Yes.
If you look at the 'spec' page for this chip, internal oscillator 32K to 16MHz. Then the line underneath, 'provides full range of frequencies from 32K to 64MHz, when used with the PLL'.
Primary difference, is _accuracy_. The internal oscillator, is good enough for normal serial I/O, over the limited temperature range (0C to 85C), but outside this range, is not guaranteed to be good enough. For anything with more accuiracy required than this, it is simply not good enough. With the external oscillator, a crystal, or resonator source gives you several decades 'better' accuracy (at the upper end, with a crystal oven needed). There is a slight noise penalty, but provided the oscillator is well designed, it is small.
LP, XP etc., have nothing really to do with the speed. They determine how the internal gates are arranged and driven, to allow the chip to drive an external oscillator. It is the components in this that will determine the speed. XP, versus HS, increases the gain in the oscillator module to help it oscillate at higher frequencies. The frequency is totally determined by the external components attached. Once you have the oscillator components determined, the chip can run at the frequency this generates, or 4* this. The latter is needed for the higher speeds, since the oscillator itself is only designed to operate up to 25Mhz.
Best Wishes |
|
|
newbieee Guest
|
|
Posted: Thu Jun 12, 2008 6:10 am |
|
|
Thanks Guest
Has cleared things up. Don't think we can tolerate the error as our system requires sample at a specific time.
u defo explained a few things
regards
newbieee |
|
|
|
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
Powered by phpBB © 2001, 2005 phpBB Group
|