3 UART support in Arduino Uno

Hi,

We are planning to use Arduino Uno for a new development.
We understand that there is only 1 HW UART supported in Uno. But using software serial, converting some pins to act as UART is possible right?

Pins 2 & 3 are already connected to USB chip. And hoping that pins 8 & 9 should be possible to make as serial port.

But the question is, is there any other pair of pins that can be converted to serial using some libraries?

Mainly we want to see if achieving 3 UART communication is possible with Arduino Uno or not.

Your inputs will be of great help.

Thank you,
~Jinoj

Have you seen:

"Return a character that was received on the RX pin of the software serial port. Note that only one SoftwareSerial instance can receive incoming data at a time (select which one with the listen() function)."

Thank you Larry for the response.

Even if only one instance can receive from serial port at a given time, is it possible to have one more port simulated using software libraries and another pair of pins to have a total of 3 ports?

Thank you,
~Jinoj

I have never done more than one.
I see no reason why not.

SoftwareSerial mySerial(10, 11); // RX, TX

SoftwareSerial myOtherSerial(8, 9); // RX, TX

Ok Larry.

Thank you for the inputs. I will give it a try.

Thanks,
~Jinoj

Hi,

From the pin mapping of Atmega328 (http://arduino.cc/en/Hacking/PinMapping168), it says pin 11 is used by ICSP header.

Will it affect my requirement? If so is there any other pin that can be used for this purpose?

Thanks
~Jinoj

it says pin 11 is used by ICSP header. Will it affect my requirement?

Not if you are not using the ICSP header.

You need to be aware the SoftwareSerial can only listen OR talk on one instance at any one time. It cannot listen to 2 or more Rx pins at the same time. And it cannot send and receive at the same time.

If those limitations cause a problem you probably need a Mega which has 4 hardware USARTs

...R

Can also look at adding Dual UART with SPI interface, off load the buffering, then can have 3 active interfaces.
Are there libraries for this device? Probably.

The SC16IS752/SC16IS762 is an I2C-bus/SPI bus interface to a dual-channel high
performance UART offering data rates up to 5 Mbit/s, low operating and sleeping current;
it also provides the application with 8 additional programmable I/O pins. The device
comes in very small HVQFN32 and TSSOP28 packages, which makes it ideally suitable
for hand-held, battery-operated applications. This chip enables seamless protocol
conversion from I2C-bus/SPI to RS-232/RS-485 and is fully bidirectional.

The SC16IS762 differs from the SC16IS752 in that it supports SPI clock speeds up to
15 Mbit/s instead of the 4 Mbit/s supported by the SC16IS752, and in that it supports IrDA
SIR up to 1.152 Mbit/s. In all other aspects, the SC16IS762 is functionally and electrically
the same as the SC16IS752.

The SC16IS752/SC16IS762’s internal register set is backward compatible with the widely
used and widely popular 16C450. This allows the software to be easily written or ported
from another platform.

The SC16IS752/SC16IS762 also provides additional advanced features such as auto
hardware and software flow control, automatic RS-485 support and software reset. This
allows the software to reset the UART at any moment, independent of the hardware reset
signal.

Maybe a couple of these

Thank you for the responses.

I also need to access SD card from Uno.
My plan was to use pins 8 & 9 and 10 & 11 for serial port using some libraries to achieve 3 UARTs.

I was about to place the order for Uno and microSD shield. But I see the below information from microSD shield:

Communication with microSD cards is achieved over an SPI interface. The SCK, DI, and DO pins of the microSD socket are broken out to the ATmega168/328's standard SPI pins (digital 11-13), while the CS pin is broken out to Arduino's D8 pin.

Could you please guide me if I can still use this method to achieve 3 UARTs if I need to also use microSD card through SPI?

Thanks
~Jinoj

Hi,

Please guide me to choose the correct version of Arduino.

Our current understanding is as below, please correct if this is not achievable using Arduino Uno.

pin 2&3 -> debugger use and will not be reused
pin 9,10 -> serial 1 -> used with modem
pin 8,11 -> serial 2-> used with serial based sensor device (reuse)
pin 8,11,12,13 -> sd card -> used with sd card (reuse)
logic we are planning is something like below:
init
{
setup 9,10 for software serial for modem
init modem
setup 2,3 for serial to uart for debugger
}
loop
{
setup 8,11 for software serial
read data from serial based sensor device
keep the data in ram
setup 8,11,12,13 for sd card
write the data from ram to sd card
push the data from sd card to modem
}

Please correct me if the above logic is not possible using Uno.
Your quick response will be highly appreciated.

Thank you,
~Jinoj