EmbeddedRelated.com
Forums

How to add uarts to an lpc2xxx

Started by Christophe September 30, 2006
Hello,

for my project, I need more than two uarts that my lpc2148 provides.
Futhermore I want tokeep uart_0 for code download and communictaion
with the board. So, as I am a newbie, I am wondering how it is
possible to add more uarts : SPI to uart converter like the MAX3100,
I2C to uart or perhaps, if it is possible software uart with GPIO. Any
advices will be helpful...

Thanks for your help,
Best regards,
Christophe.

An Engineer's Guide to the LPC2100 Series

Christophe wrote:
> for my project, I need more than two uarts that my lpc2148 provides.
> Futhermore I want tokeep uart_0 for code download and communictaion
> with the board. So, as I am a newbie, I am wondering how it is
> possible to add more uarts : SPI to uart converter like the MAX3100,
> I2C to uart or perhaps, if it is possible software uart with GPIO. Any
> advices will be helpful...

When micros were discrete CPU, RAM, ROM, I/O etc it was never a problem
to just add those extra chips as long as you had the address/data bus
available and a spare chip select. Of course when everything that you
would normally need is packed into one tiny cheap smd chip it is a
different story and expansion is not so straightforward even if you do
happen to have an external bus.

You mentioned the MAX3100 which provides a single basic uart interfaced
via SPI. The MAX3100CPD+ is priced at $7 from Digikey whereas an LPC2101
with two uarts, via SPI or I2C, and the smarts only costs $3.15 in one
off from the same supplier. The LPC2101 can even share your LPC2148 clock.

I know which one I would choose.

The newer LPCs that are sampling are equipped with 4 uarts already.

When it comes to soft uarts well that really depends upon the baud-rates
required etc and whether the cpu has processing capacity available as a
reliable soft uart can eat into those mips.

just my2cents
*Peter*
NPX (was Philips) has a nice looking chip. The SC16IS752/SC16IS762
Dual UART with I2C-bus/SPI interface, 64 bytes of transmit
and receive FIFOs, IrDA SIR built-in support looks like a better bet.
(use SPI port not I2C.)

Maxim has some interesting chips, but if you have low or medium
production, the fact that they have long lead times and most places do
not stock Maxim makes me not want to use them after being burned too
often.

You can do software UART with a GPIO (better if it is an interrupt) but
it takes a lot of processing to keep from missing bits. I would not
recommend it.

Kip

On Sat, 2006-09-30 at 19:59 +0000, Christophe wrote:
> Hello,
>
> for my project, I need more than two uarts that my lpc2148 provides.
> Futhermore I want tokeep uart_0 for code download and communictaion
> with the board. So, as I am a newbie, I am wondering how it is
> possible to add more uarts : SPI to uart converter like the MAX3100,
> I2C to uart or perhaps, if it is possible software uart with GPIO. Any
> advices will be helpful...
>
> Thanks for your help,
> Best regards,
> Christophe.

>
--
Kipton Moravec
----- Original Message -----
From: "Christophe"
To:
Sent: Saturday, September 30, 2006 8:59 PM
Subject: [lpc2000] How to add uarts to an lpc2xxx
>
> Hello,
>
> for my project, I need more than two uarts that my lpc2148 provides.
> Futhermore I want tokeep uart_0 for code download and communictaion
> with the board. So, as I am a newbie, I am wondering how it is
> possible to add more uarts : SPI to uart converter like the MAX3100,
> I2C to uart or perhaps, if it is possible software uart with GPIO. Any
> advices will be helpful...

It depends on how many you need. If you just need one, a software UART might
be best. The MAX3100 is a good solution, but rather expensive. I once used
used several Atmel '2313 AVRs as UARTS, interfaced to a PIC via SPI.

Leon
In case it's any help, I have developed an spi_uart module based around
the Phillips SPI-Uart chips, but it could be easily adapted for MAX
versions I'd think.
It is a newlib_lpc driver, currently untested.
I have an application that requires 6 serial ports, so the module can
handle multiple dual spi-uart chips.

________________________________

From: l... [mailto:l...]
On Behalf Of Christophe
Sent: Sunday, 1 October 2006 6:00 AM
To: l...
Subject: [lpc2000] How to add uarts to an lpc2xxx

Hello,

for my project, I need more than two uarts that my lpc2148
provides.
Futhermore I want tokeep uart_0 for code download and
communictaion
with the board. So, as I am a newbie, I am wondering how it is
possible to add more uarts : SPI to uart converter like the
MAX3100,
I2C to uart or perhaps, if it is possible software uart with
GPIO. Any
advices will be helpful...

Thanks for your help,
Best regards,
Christophe.