UART handshaking + control over 2 wire link

Hi, i am looking at running serial comms over a bidirectional fibre link. What i would like is to run full handshaking and control lines over this link. Are there any chips which will do this for me?

If not, i am considering using a microcontroller to sample all the line states, then send the bit states over the link to be reconstructed the other end.

Any ideas or suggestions much appreciated.

Cheers,

Chris

Reply to
g18c
Loading thread data ...

Can you use software flow control like Xon/Xoff?

You might look up how PPP sends TCP/IP over modems to get some idea's.

You might also consider having a packet transfer system where each packet must be acknowledged before the next packet is sent.

Reply to
Gerald Bonnstetter

I think you misunderstood. He doesn't want to do serial flow control.

He wants to multiplex multiple signals over a single "wire". In this case the wire is optical, but that's mostly irrelevent.

I do know of people who do this. They run 16 high-speed serial ports over a single wire. The modem control/status/handshake lines are multiplexed at a much lower rate than the data lines (KHz for the handshake lines vs. MHz for the data lines). The people I know that do this designed a full-custom ASIC to do it, but I think you could probably do the same thing in an FPGA.

--
Grant Edwards                   grante             Yow!  Are the STEWED PRUNES
                                  at               still in the HAIR DRYER?
                               visi.com
Reply to
Grant Edwards

Thanks for the replies. I will be controling a modem on the other end of the fibre. I need all the serial lines so that the software sees what it expects to see and can control the modem with DTR etc lines as needed. Whilst i could use XON/XOFF i do also need the other lines... hoping there was a off the shelf chip i could by to do this for me!

Cheers,

Chris

Reply to
g18c

as

I guess you need chips not modules such as

formatting link

Reply to
Lanarcam

A cheap 8:1 multiplex/demultiplex that I built 30 years ago did the transmission over several miles of twisted pair, carrying a current loop. The multiplexor was a UART, set to transmit with 2 stop bits, and receive with 1. (This allowed for rate mismatches at the ends). Each input went to one input bit of 8, and was received on the corresponding 1 of 8 at the other end. What it really needed for long term reliability was 8 stop bits on send, which unfortunately needed added hardware. Today I would suggest building it all out of a single bit-banging PIC, and to turn the bit rates up by about a factor of 4 or more.

The result was used to move 8 110 to 300 baud lines over a 9600 baud link. Note that things are transparent, so you can use a multiplexed line as a transparent handshaking signal if you wish. Effectively you have:

+-------+ +------+ 8 lines --->---| MX | | deMX |-->-- 8 lines | |--| | 8 lines ---
Reply to
CBFalconer

I guess I did misunderstand. He did add that he's controlling a modem on the other end so that's clear now even to me.

I just didn't want him doing all the extra work if he really didn't need to.

Another similar way to do it might be to have your two PICs (or other micro) sending the data between themselves 4 bits at a time and using the other bits for control signals. That might work for him and only run at two times the bit rate.

It seems like some micros can do a 9 bit transfer. Would that be a way to pass an occasional control byte now and then?

If bit 9 is 0, then its data. Otherwise it's a flow control byte thats only sent when the hardware lines have changed state.

Reply to
Gerald Bonnstetter

This may be a little over the top for your particular app, but there is an internet protocol defined in

formatting link
to address this kind of thing.

-- Cecil Hill

Reply to
Cecil Hill

ElectronDepot website is not affiliated with any of the manufacturers or service providers discussed here. All logos and trade names are the property of their respective owners.