Rokas
Newbie level 4
- Joined
- May 28, 2011
- Messages
- 6
- Helped
- 0
- Reputation
- 0
- Reaction score
- 0
- Trophy points
- 1,281
- Location
- Coventry, UK
- Activity points
- 1,341
Hello,
Refering to PIC18F47J53 datasheet it can be clocked up to 48MHz, but I can't make it to work with such frequency crystal. I'll explain everything from the begining:
I set oscillator to be in HS mode and CPU clock division to be 1:1. So, the CPU clock should be 48MHz (with 48MHz crystal) and the instruction clock -12MHz. But somehow it overrides my fuse settings and switches to the default internal clock (4MHz).
I've tried to make it work with 48MHz crystal and different capacitors (ranging from 2.2pF to 22pF) - in every way it switches to the internal clock. And on both crystal legs I can't see any oscillation, only DC.
With 40Mhz crystal: crystal oscillates, MCU takes external crystal as a clock, but crystal's frequency isn't 40MHz it somehow becomes ~13.3MHz.
With 20MHz crystal: everything works. CPU clock - 20MHz, instruction - 5MHz (I'm able to get PWM of 5MHz).
P.S. All the crystals are tested with external circuit.
Does anybody have any ideas?
Refering to PIC18F47J53 datasheet it can be clocked up to 48MHz, but I can't make it to work with such frequency crystal. I'll explain everything from the begining:
I set oscillator to be in HS mode and CPU clock division to be 1:1. So, the CPU clock should be 48MHz (with 48MHz crystal) and the instruction clock -12MHz. But somehow it overrides my fuse settings and switches to the default internal clock (4MHz).
I've tried to make it work with 48MHz crystal and different capacitors (ranging from 2.2pF to 22pF) - in every way it switches to the internal clock. And on both crystal legs I can't see any oscillation, only DC.
With 40Mhz crystal: crystal oscillates, MCU takes external crystal as a clock, but crystal's frequency isn't 40MHz it somehow becomes ~13.3MHz.
With 20MHz crystal: everything works. CPU clock - 20MHz, instruction - 5MHz (I'm able to get PWM of 5MHz).
P.S. All the crystals are tested with external circuit.
Does anybody have any ideas?