bkamen
Joined: 07 Jan 2004 Posts: 1615 Location: Central Illinois, USA
|
PIC18FxxJ60 w/PLLx5 and #use delay |
Posted: Mon Jul 06, 2009 6:31 pm |
|
|
Hey all,
I'm using a PIC18F97J60 and would like to run at max speed which for this chip means turning on the PLL (x5) and then the pre/post scaler.
The datasheet allows for a 25MHz Xtal which x5 = 125MHz which is out of range... so instead you can set it for 25MHz / 3 * 5 = 41.6667MHz.
But what should one put in #use delay (clock=41.6667M, crystal=25M)??
I have this and now my #use RS232 statements produce gobbledy gook for obvious reasons.
I'll fiddle, but I thought I might ask some of you if there's a more official answer.
Thanks!
-Ben
UPDATE: I fixed this. Make sure to use clock=41666700 with #fuses H4_SW and setup_oscillator(OSC_PLL_5_DIV_3) and all is fine. _________________ Dazed and confused? I don't think so. Just "plain lost" will do. :D |
|