EmbeddedRelated.com
Forums
The 2024 Embedded Online Conference

Microcontroller with 4x16 Bit Timers

Started by Stephen Jones June 24, 2004
I am looking for small low cost processor ideally with 4 16 bit
capture on interrupt timers. Its to measure the minimum bit width of 4
RS232 sources, which can have a minimum bit width of 8.2uS. This has
to be done continuously with the results filtered etc with resulting
bit width converted to its corresponding baud rate and then an
equivalent 4 bit number which is output to a IO port. Therefore the
processor requires 20 I/O lines.

Any ideas etc would be appreciated

Thanks


Steve Jones
sjones@scannex.co.uk (Stephen Jones) wrote in
news:40227952.0406240347.b233e43@posting.google.com: 

> I am looking for small low cost processor ideally with 4 16 bit > capture on interrupt timers. Its to measure the minimum bit width of 4 > RS232 sources, which can have a minimum bit width of 8.2uS. This has > to be done continuously with the results filtered etc with resulting > bit width converted to its corresponding baud rate and then an > equivalent 4 bit number which is output to a IO port. Therefore the > processor requires 20 I/O lines. > > Any ideas etc would be appreciated
I seem to remember that the TI MSP430 had many capture registers and there were parts with a good amount of I/O. Not sure if it's what you need. HTH, -- - Mark -> --
Mark A. Odell wrote:
> sjones@scannex.co.uk (Stephen Jones) wrote in > news:40227952.0406240347.b233e43@posting.google.com: > > >>I am looking for small low cost processor ideally with 4 16 bit >>capture on interrupt timers. Its to measure the minimum bit width of 4 >>RS232 sources, which can have a minimum bit width of 8.2uS. This has >>to be done continuously with the results filtered etc with resulting >>bit width converted to its corresponding baud rate and then an >>equivalent 4 bit number which is output to a IO port. Therefore the >>processor requires 20 I/O lines. >> >>Any ideas etc would be appreciated > > > I seem to remember that the TI MSP430 had many capture registers and there > were parts with a good amount of I/O. Not sure if it's what you need. >
Capturing all that should be no problem, but processing it might be... 8 us isn't a lot of time to do a subtraction to get the period, addition to filter it (I'm assuming you just use /8 so you don't have to do any shifts),lookup the result and output the bits, and all that b4 times over. I think you'll either need more of a processor that the MSP430, or perhaps you'll get away with using one MSP430 for each channel. Paul Burke
Paul Burke wrote:
> > Mark A. Odell wrote: > > sjones@scannex.co.uk (Stephen Jones) wrote in > > news:40227952.0406240347.b233e43@posting.google.com: > > > > > >>I am looking for small low cost processor ideally with 4 16 bit > >>capture on interrupt timers. Its to measure the minimum bit width of 4 > >>RS232 sources, which can have a minimum bit width of 8.2uS. This has > >>to be done continuously with the results filtered etc with resulting > >>bit width converted to its corresponding baud rate and then an > >>equivalent 4 bit number which is output to a IO port. > > > > I seem to remember that the TI MSP430 had many capture registers and there > > were parts with a good amount of I/O. Not sure if it's what you need. > > Capturing all that should be no problem, but processing it might be... 8 > us isn't a lot of time to do a subtraction to get the period, addition > to filter it (I'm assuming you just use /8 so you don't have to do any > shifts),lookup the result and output the bits, and all that b4 times > over. I think you'll either need more of a processor that the MSP430, or > perhaps you'll get away with using one MSP430 for each channel.
It depends on how fast the output must be updated and whether every pulse must be measured. The application sounds like data rate detection on incoming lines. Filtering implies that the output isn't changed with every incoming bit. Normally applications wouldn't change bit rates often, if at all. Periodic sampling and updating every 10 milliseconds might be adequate for the application. Thad
Paul Burke <paul@scazon.com> wrote:

>Mark A. Odell wrote: >> sjones@scannex.co.uk (Stephen Jones) wrote in >> news:40227952.0406240347.b233e43@posting.google.com: >> >> >>>I am looking for small low cost processor ideally with 4 16 bit >>>capture on interrupt timers. Its to measure the minimum bit width of 4 >>>RS232 sources, which can have a minimum bit width of 8.2uS. This has >>>to be done continuously with the results filtered etc with resulting >>>bit width converted to its corresponding baud rate and then an >>>equivalent 4 bit number which is output to a IO port. Therefore the >>>processor requires 20 I/O lines. >>> >>>Any ideas etc would be appreciated >> >> >> I seem to remember that the TI MSP430 had many capture registers and there >> were parts with a good amount of I/O. Not sure if it's what you need. >> > >Capturing all that should be no problem, but processing it might be... 8 >us isn't a lot of time to do a subtraction to get the period, addition >to filter it (I'm assuming you just use /8 so you don't have to do any >shifts),lookup the result and output the bits, and all that b4 times >over. I think you'll either need more of a processor that the MSP430, or >perhaps you'll get away with using one MSP430 for each channel.
The sampling has to be statistical to some extent. You may not see a minimum bit width for many symbols. Also how long do you remember seeing the faster baud rate when it drops? I would presume the RS232 signals are not changing baud rate that often so I would guess a detection time of a second or so would be reasonable - only the OP can say what he is really trying to do. I would consider monitoring the inputs in a software loop counting cycles. Limit the loop to the longest bit time you expect and look at each channel sequentially. It would require a few MIPS to get enough resolution but no timers at all.
On 24 Jun 2004 04:47:33 -0700, sjones@scannex.co.uk (Stephen Jones) wrote:
>I am looking for small low cost processor ideally with 4 16 bit >capture on interrupt timers. Its to measure the minimum bit width of 4 >RS232 sources, which can have a minimum bit width of 8.2uS. This has >to be done continuously with the results filtered etc with resulting >bit width converted to its corresponding baud rate and then an >equivalent 4 bit number which is output to a IO port. Therefore the >processor requires 20 I/O lines.
Any Cypress PSoC with 8 digital modules can be configured with 4 16 bit timers. The bad news is that you won't have any modules left over for other digital peripherals. The good news is that you can reconfigure those 4 timers into 4 uarts (or whatever) at will. There is a new family of chips coming out with more digital modules if 8 is too limiting for your application. Disclaimer: we are CyPros certified consultants -- Chuck Cox, President SynchroSystems chuckPORK@synchro.com, cccoxPORK@fas.harvard.edu, www.synchro.com (my address is politician proof, just remove the PORK)
On 24 Jun, in article
     <40227952.0406240347.b233e43@posting.google.com>
     sjones@scannex.co.uk "Stephen Jones" wrote:

>I am looking for small low cost processor ideally with 4 16 bit
That depends on what you mean by small and low cost :)
>capture on interrupt timers. Its to measure the minimum bit width of 4 >RS232 sources, which can have a minimum bit width of 8.2uS. This has >to be done continuously with the results filtered etc with resulting >bit width converted to its corresponding baud rate and then an >equivalent 4 bit number which is output to a IO port. Therefore the >processor requires 20 I/O lines.
When doing this sort of thing I use the H8/H8S from Renesas, I used one with 5 X 16 bits timers to use four to control a linescan CCD and the fifth to detect rising and falling edges on a signal coming back. I then used two further 8 bit timers for task scheduling and interupt ready for LCD delays. See circuit cellar Renesas comeptition on their website. Most of the timers have rising edge and falling edge as SEPARATE registers and separate interupts on each timer to enable fast capture of events. They are plenty of evaluation boards available for this sort of thing.
>Any ideas etc would be appreciated
HTH -- Paul Carpenter | paul@pcserv.demon.co.uk <http://www.pcserv.demon.co.uk/> Main Site <http://www.gnuh8.org.uk/> GNU H8 & mailing list info. <http://www.badweb.org.uk/> For those web sites you hate.
Stephen Jones wrote:
> I am looking for small low cost processor ideally with 4 16 bit > capture on interrupt timers. Its to measure the minimum bit width of 4 > RS232 sources, which can have a minimum bit width of 8.2uS. This has > to be done continuously with the results filtered etc with resulting > bit width converted to its corresponding baud rate and then an > equivalent 4 bit number which is output to a IO port. Therefore the > processor requires 20 I/O lines. > > Any ideas etc would be appreciated
You do not need 4 timers, you need 4 capture channels. That puts the problem into the realm of any FX cored 89C51, (RD2 etc) and there are a LOT of those around. Since this sounds like homework, or a one-off, your best chip is one of the Cygnal C8051F lineup. These have various channel counts on the PCA (3..6+), low pin counts, and inbuilt debug. You will need to determine the precision of bit-measurement, and sampling/reponse times for your baud-readouts. -jg

The 2024 Embedded Online Conference