Actually it is 20MHz maximum for PIC16's and 40MHz for PIC18's using an oscillator in EC mode.
For crystals/resonators the maximum is 20MHz for PIC16's and 25MHz (10MHz if PLL is enabled) for PIC18's in HS mode.
Actually it is 20MHz maximum for PIC16's and 40MHz for PIC18's using an oscillator in EC mode.
For crystals/resonators the maximum is 20MHz for PIC16's and 25MHz (10MHz if PLL is enabled) for PIC18's in HS mode.
Yes i was planning to use them with PICs. Im using 24MHz at the moment with PIC18Fs (i know 16Fs can only do 20). Im pretty sure 18Fs can handle upto 60MHz or atleast the ones im using can (according to the datasheet). Even 40MHz would be a help tho. Im struggling at the moment cramming all my PWM code and extras into the 6M instructions you can get with a 24MHz resonator. I will also be looking at writing the code in slightly different ways but a better resonator would help a lot.
Ill have a look at digikey. Ive already tried my local places but it seems that nobody really uses over 16MHz. Thanks for your help
Hmm, i think you might have to explain that one too me. Also, how come my 24MHz resonators work fine with a 18F?
I thought PICs ran instructions at a quarter of the speed of the resonator
The resonators i use dont need external capacitors (they are the 3 pin ones). Do i need to use a 2 pin one with caps?
Edit: My circuits are already working. I just want to speed them up a bit
Which part?
Because 18F's oscillate just fine up to 25mhz.Also, how come my 24MHz resonators work fine with a 18F?
They Do.I thought PICs ran instructions at a quarter of the speed of the resonator
But you seem to be missing the 4xPLL part.
Are you familiar with the 4xPLL?
That is simply my suggestion.
Do your development with a crystal.
When it's all working perfectly with the crystal, test it with a resonator while varying the ambient temperature to the furthest extremes you can or really need.
If everything still works, you should be OK to uses resonators for a production run.
add: If not, you can make allowances for the deviations from "nominal".
But having timing related problems that you can't find in the program, while you're trying to program it, really sucks.
Use a crystal.
Last edited by Darrel Taylor; - 20th December 2009 at 01:57. Reason: add
DT
No i dont know what 4xPLL is (thats the bit i need explaining).
I definately read in a datasheet somewhere that the PICs supported 60MHz. Now that you mention it im not completely sure that was for the actual resonator value but it had something to do with it.
So far ive been working it out that a 24MHz resonator divided by 4 gives me 6,000,000 instruction cycles per second. Ive also counted how many my program uses. Apart from variable declarations the whole program is in ASM now so i know exactly how many instruction cycles everything should take. I adjusted the timing so it should have taken under 6M cycles and it worked. Then i adjusted it to go slightly over and i started seeing the kind of behaviour that you get when its using too many commands so it seemed like i had worked everything out correctly.
I take it crystals are more accurate than resonators. I like resonators because they are nice and small and simple. I currently have 2 circuits running outside where its -2C. They worked exactly the same inside at room temperature. The timing in just about ever circuit i do isnt critical. As long as it is timed well enough to use serial then its good enough. I do usually add allowances anyway by varying the timing a little.
I do know exactly where my timing problems are and how to fix them (one way being a fastor resonator). I would rather do that first as my other ideas invovle removing functionality.
Edit: I just opened a datasheet randomly for a PIC18F2420. It says "Two External Clock modes, up to 40 MHz". I thought that was the max resonator speed. Is it something else?
Buy a 10mhz crystal with 2-22pF capacitors.
Use the 4xPLL to get 40mhz.
You can not run a 40mhz crystal or resonator from a PIC's oscillator.
P.S.
Use a crystal. Resonators have their uses, and you can figure out if it'll work in your application, after you have your application working.
DT
Bookmarks