You need to write to the OSCCON register to select 4MHz. The default value of OSCCON at
power-up is all 0's. That sets the internal osc at 31.5kHz by default.
OSCCON = %xxxxxxxx (replace x's with value shown in data sheet for selecting 4MHz)
Edit: Nice work. It's not that hard is it...;o}
Not bad for your first PIC project.
Bookmarks