Synchronous RS232 interface

I am looking at trying to create an RS232 synchronous adapter using an Arduino Mega. I want to be able to implement a protocol similar to BISYNC. My plan is to communicate with a PC using the Arduino USB serial interface and to communicate with the outside would via RS232 and BISYNC.

I haven't been able to find a great deal of information about using synchronous communications wit the Arduino other than the I2C protocol. I'm not sure how I would use I2C for BISYNC since I am not clear on how to turn the line around from transmit to receive.

On the hardware side I'm thinking that the MAX232 chip would be the tool of choice for converting the TTL levels to RS232 levels. I can see how to implement RTS/CTS and DTR/DSR using the MAX322 but I'm a bit lost on the CLK, TX and RX signals.

Any guidance is appreciated.

Before you and I waste a lot of time, please explain in detail why you want to do such a thing.
Paul

Maybe he has an old RJE terminal around and wants to interface to it with his UNO.

Srsly, BISYNC?

a7

alto777:
Maybe he has an old RJE terminal around and wants to interface to it with his UNO.

Srsly, BISYNC?

a7

Could be. The test will be when the Arduino needs to insert SYNC characters in the outgoing stream because the next character is not available to send. Then, if he is sending/receiving EBCDIC characters, the bit order is reversed from sending ASCII characters. FUN!
Paul

I'm not sure what happened but I wrote a reply and it seems to have disappeared. If this appears twice, my apologies.

There is a possibility that I will come into the possession of a Univac Uniscope 100 terminal. These were current in the mid 1970s. These are synchronous devices that use a modified BISYNC protocol. The character set is ASCII. I want to be able to use the U100 as a console for a Univac 90/30 emulator that I am working on.

I can write a program to implement the Uniscope protocol but I need a way to hook it up to the PC. I've looked at current synchronous communication adapters but they are ridiculously expensive ($600-$700). At lot to spend on something that I'm not sure would do what I want anyway.

sboydlns:
I'm not sure what happened but I wrote a reply and it seems to have disappeared. If this appears twice, my apologies.

There is a possibility that I will come into the possession of a Univac Uniscope 100 terminal. These were current in the mid 1970s. These are synchronous devices that use a modified BISYNC protocol. The character set is ASCII. I want to be able to use the U100 as a console for a Univac 90/30 emulator that I am working on.

I can write a program to implement the Uniscope protocol but I need a way to hook it up to the PC. I've looked at current synchronous communication adapters but they are ridiculously expensive ($600-$700). At lot to spend on something that I'm not sure would do what I want anyway.

That is such a great explanation!
Thanks, Paul

THX, that’s fantastic.

16 lines of 64 characters
80 pounds
$4000 could have bought 2 Volkswagens at that time instead.

A fine reminder of how far it’s all come and what a great time to have lived until.

Good luck! Thumbs up emoji.

a7

sboydlns:
I'm not sure what happened but I wrote a reply and it seems to have disappeared. If this appears twice, my apologies.

There is a possibility that I will come into the possession of a Univac Uniscope 100 terminal. These were current in the mid 1970s. These are synchronous devices that use a modified BISYNC protocol. The character set is ASCII. I want to be able to use the U100 as a console for a Univac 90/30 emulator that I am working on.

I can write a program to implement the Uniscope protocol but I need a way to hook it up to the PC. I've looked at current synchronous communication adapters but they are ridiculously expensive ($600-$700). At lot to spend on something that I'm not sure would do what I want anyway.

To use an Arduino, you need to interface it to an actual USART chip. You need the power of a co-processor to handle ANY synchronous communications. Primarily because you need to adjust the timing of the USART bit rate clock when you read the first of two SYNC characters at the start of any message. I don't see how you can do that with an Arduino with a single processor.

Some of the old Sperry/UNIVAC PCs already have a USART in them. Also look at other manufacturers. I know Burroughs PCs also had USART chips in them. Not always the same chip! Of course, all of them run MSDOS.
Good luck,
Paul

alto777:
THX, that’s fantastic.

16 lines of 64 characters
80 pounds
$4000 could have bought 2 Volkswagens at that time instead.

A fine reminder of how far it’s all come and what a great time to have lived until.

Good luck! Thumbs up emoji.

a7

You sound like an old Univac'r.

Not yet born:

"I think there is a world market for maybe five computers."

Thomas Watson, president of IBM, 1943

Mostly all growed up and able to recognize a bad prediction:

"There is no reason anyone would want a computer in their home."

Ken Olsen, founder of Digital Equipment Corporation, 1977

TBF he was quoted out of context, but…

Please don't do any math. :wink:

a7

That thought was still very much alive in the 1970's.
IBM convinced severl customers that only 3-4 large computer centers across the country could process all the country;s data processing using the phone lines/modems to connect to the customers print/card reading equipment.
Travelers Insurance bought the bait and purchased United Data Processing in Cincinnati for one such center and began to pour millions into it. Next they bought United Data Processing In Portland, OR. where I was programmer/systems programmer and began to do the same.
At the same time a group in Portland formed their own corporation to build he ultimate data center. Many local people poured their life savings into buying stock in the company.
Eventually someone was brave enough to point out to IBM and others that the telephone lines were not and could never be capable of doing what they had proposed. Travelers and others who had believed IBM finally did the math and came to the same conclusion.
Travelers sold both of their centers at great loss. The Portland center was sold to a local small insurance company.
The Portland company trying to be big went bankrupt. Investors lost all their money. The owner of a local investment management company waited till all his employees were at lunch and then jumped out the 10th story window to his death.
Years later I met the treasurer of the want-to-be company while we were both doing contract programming. He said the IRS still audited his tax returns every year because they sure he had stolen the company money.
So sad the intelligent people do not do their maths!
Paul

Paul_KD7HB:
Some of the old Sperry/UNIVAC PCs already have a USART in them.
Good luck,
Paul

I had one of those way back when. Not any more though. Even with those you had to buy a communications adapter to run Uniscope emulation. I suspect the PCs of the day just didn't have the horsepower needed.

Any recommendations on a USART chip?

Perhaps the Z80-SIO chip will do what you want...
I’m sure there will be parts flying around the backwoods of the internet.

https://www.google.com/search?q=z80-sio&rlz=1C9BKJA_enAU768AU768&oq=z80-sio&aqs=chrome..69i57j0i30l5.4868j0j7&hl=en-GB&sourceid=chrome-mobile&ie=UTF-8

sboydlns:
I had one of those way back when. Not any more though. Even with those you had to buy a communications adapter to run Uniscope emulation. I suspect the PCs of the day just didn't have the horsepower needed.

Any recommendations on a USART chip?

On the contrary, they had plenty of power! I wrote c code for PCs running BiSync point-to-point, transparent to communicate with Unisys high-speed check reader-sorters. Speed was 19,200 BPS. Less than 10ms. turn-around time.
Some customers insisted on Sperry PCs and the Communication chips were not all the same. I had to program to determine which one to use. One or more of them had a couple of memory locations on the chip. If I could write something to the location and read it back correctly, then I know which chip it was.
That was back in the good-old-days!
Paul

Dear All,

I do not see why a MEGA 2560 should be unable to do synchronous communication?

If you look at the Atmel Atmega 640/V-1280/V 1281/V 2560/V datasheet, you will see at page 200 (USART) that it is able to do Asynchronous and Synchronous communication, it is a question of setting the CPU registers right. The hardware is foreseen in the CPU to do synchronous communication!

You might need to modify the serial library a little bit or make a copy of your own but if you set your mind to it, it must be possible.

I have modified the Serial library to run Siemens Profibus DP (a RS485 protocol that has a strict timing so you need to process your telegrams in the interrupt handler themselves).

In order for it to work you need to control the direction of the MAX485 manually by use of the processor facilities that are provided. The Arduino serial libs do not support this function. So i needed to address the CPU directly.

Hence I do believe that it should be possible to do the job with an Arduino (Mega 2560) by setting the registers right.

Profibus - Arduino demo

Best regards,
Johi.

Thanks everyone. Lots to think about.

This topic was automatically closed 120 days after the last reply. New replies are no longer allowed.