At 07:48 PM 15/02/99 -0500, you wrote: VOILA!! I see what you mean. Thanks to all for the suggestions. Peter >> >> At 08:05 AM 15/02/99 -0500, you wrote: >> >> To translate, 0.5MHz means 0.5 microseconds. If I clocked a PIC at 10MHz >> then I would have time to do about 1.25 instructions during this time. I do >> not want to go above 10 MHz for my crystal. I am also doing a lot of other >> things inthe micro and wish to be informed when the counts have finished >> (another signal) > >Peter, > >By setting the counter to overflow, you'll only see an interrupt every 128 uS >by using the TMR0 counter. As I said below it's a bit much to do in software >but by using the timer hardware, it because doable if not easy. > >If the timer isn't available, you definitely need another external part. > >BAJ >> >> Thanks, >> >> Peter >> >> >> >> >> I need to be able to count to 4,000,000 (24 bits) and when complete I wish >> >> to address serially for the result. The counter is clocked at about 0.5MHz >> >> which is a little fast for the PIC to keep up with. Can anyone suggest a >> >> chip that would do this for me. I do not want a parallel output as it uses >> >> too many pins. If this is not possible then perhaps a counter and shift >> >> register?? >> > >> >I'm a bit confused. While this may be a bit much for a PIC to count solely >> >in software, using its hardware counter is an ideal application. The keep >> >the software interaction down you can simply interrupt on rollover and have >> >a short interrupt routine that bumps up the top two bytes. >> > >> >In short you're going to create a whole lot of extra hardware doing this >> >with discretes. >> > >> >If you really feel you must have an extra piece of hardware, then I suggest >> >using a second PIC whose sole purpose is to count and report the count >> >serially to the master PIC. A 12C508 could give you the requested functionality >> >in an 8 pin package. a three line serial interface should be sufficient for >> >both interrupting the master PIC, and commanding and reading the counter PIC. >> > >> >This is the type of application where microcontrollers excell. >> > >> >BAJ >> >> >> >> TIA, >> >> >> >> >> >> Peter Grey >> >> >> > >> > >> > >