EmbeddedRelated.com
Forums

Overclocking a PIC 18F252

Started by Wim March 27, 2004
I was wondering how fast I can run a 18F252 processor.

Some time ago I wrote a small very-low cost "Software Logic Analyser"
utility (on a PC) which uses a pic processor as the "capture device".
The PIC sampled the channels in an interrupt service routine and if a
change was detected on one of its inputs an event was places in a
ringbuffer.

Using on-board UART the events were transmitted to a PC which took
care of buffering,display,triggers etc.

This software approach limited the capture rate (few microseconds
capture time) and could only process bursts of fast pulses because
the offloading to the PC was a lot slower than this. You can however
capture minutes of data. The average puls length should not exceed the
transfer time. (Limited by UART although the use of a FT232BM improved
this a lot)

The original application (using a 16F628) had to do with analysing
the output of RFID tags which operate on 125KHz and the output of the
RFID decoder are pulses with lengths ranging from ten- to hundreds
microseconds)

Now I am rebuilding this app with an 18F252 processor (larger internal
memory, faster core) and was wondering how fast I could push this
device. 4 Mhz parts could easily be pushed to operate on 6 and
sometimes on 8 Mhz but I have no experience with the 18F range.

Please note that I am not talking about production series, but just a
small number of devices. Does somebody have any experience or hints
regarding the operation of these devices on e.g. 48 or 64 MHz.

Thanks in advance
On Sat, 27 Mar 2004 15:02:50 +0100, Wim wrote:

>I was wondering how fast I can run a 18F252 processor.
Depends on how reliable you want it to be. The specs guarantee operation to 40MHz (10MIPS), but you'll have to experiment to see how far you can push any given part.
>Some time ago I wrote a small very-low cost "Software Logic Analyser" >utility (on a PC) which uses a pic processor as the "capture device". >The PIC sampled the channels in an interrupt service routine and if a >change was detected on one of its inputs an event was places in a >ringbuffer. > >Using on-board UART the events were transmitted to a PC which took >care of buffering,display,triggers etc. > >This software approach limited the capture rate (few microseconds >capture time) and could only process bursts of fast pulses because >the offloading to the PC was a lot slower than this. You can however >capture minutes of data. The average puls length should not exceed the >transfer time. (Limited by UART although the use of a FT232BM improved >this a lot)
How many signals are you monitoring in parallel? Using an MPU seems the wrong way to go if you want high-speed capture of more than a couple of pins. I'd consider using a cheap CPLD or FPGA for the capture, and an FT245BM for the USB interface (or maybe 100Mbps Ethernet).
>The original application (using a 16F628) had to do with analysing >the output of RFID tags which operate on 125KHz and the output of the >RFID decoder are pulses with lengths ranging from ten- to hundreds >microseconds) > >Now I am rebuilding this app with an 18F252 processor (larger internal >memory, faster core) and was wondering how fast I could push this >device. 4 Mhz parts could easily be pushed to operate on 6 and >sometimes on 8 Mhz but I have no experience with the 18F range.
The 18FXX2 parts can already run at 40MHz, and have capture inputs capable of 6.25nS resolution. Why do you need to go faster?
>Please note that I am not talking about production series, but just a >small number of devices. Does somebody have any experience or hints >regarding the operation of these devices on e.g. 48 or 64 MHz.
You'll have to try it and see. I'd think 48MHz is quite likely to be OK, but 64MHz could be dodgy. -- Max