Additional RS232 ports

Discussion to talk about hardware related topics only.
Post Reply
nemiro
Posts: 21
Joined: Mon Sep 06, 2010 10:51 am

Additional RS232 ports

Post by nemiro »

Hello All-
I am working on a project that needs several (at least four) serial ports. I have searched the forums, and found that others have added devices to make this happen. I have read up on various SPI devices that can add up to four ports, and am happy to use them. However, before I make the plunge, does anyone have a working example of this, and would they be willing to share schematics and code? If possible, I'd like to avoid reinventing the wheel. Thanks in advance!
Ridgeglider
Posts: 513
Joined: Sat Apr 26, 2008 7:14 am

Re: Additional RS232 ports

Post by Ridgeglider »

If you are using the Mod5234, it has an eTPU unit that can be congfigured as a UART. The main caveat is that the hardware does not support hardware CTS/RTS although the following post shows how to make the ports support half duplex (for RS422/485). There is a demo showing how to (easily) set the ports up to be UARTS: http://www.netburner.com/downloads/mod5 ... ppNote.zip You may need to add your own RS232/422/485 driver IC as the eTPU ony provides LVTTL levels.
User avatar
pbreed
Posts: 1088
Joined: Thu Apr 24, 2008 3:58 pm

Re: Additional RS232 ports

Post by pbreed »

Attached is a bitbang driver for the original PK70 where we failed to bring out the Serial pins.
It uses GPIO and will run at 38400 with minimal impact.

It could be easily ported to any 5270 or 5234(Use the TPU for 5234) platform.

The comments in this code show where one would change things to change pins or to change from half duplex to full duplex.
It also has the baud rate hard coded so read that comment and change as needed as well.

Paul
Attachments
bitbangserial.cpp
(13.67 KiB) Downloaded 346 times
nemiro
Posts: 21
Joined: Mon Sep 06, 2010 10:51 am

Re: Additional RS232 ports

Post by nemiro »

Thank you both! I should have mentioned I am running a MOD5270 :oops: I will try the bit banging method, but it would probably be best to come up with a hardware solution. In the meantime, the bit banging will at least get me moving again. Thank you so much for sharing!
Post Reply