Oct 19, 2023
Building A 3270 Terminal Controller
We like to talk about how most of our computers today would have been mainframes
We like to talk about how most of our computers today would have been mainframes a scant 40 or 50 years ago. Because of that, many people who want to run IBM mainframes such as the IBM 360 or 370 use the Hercules emulator to run the big iron on their PCs. However, mainframe IBM computers used an odd style of terminal and emulating it on a PC isn't always as satisfying. At least, that's what [lowobservable] thought, so he decided to get a 3270 terminal working with Hercules.
Back in the bad old days of computing, there were two main styles of terminals. Some companies, for example DEC, essentially used terminals as a "glass teletype." That is, the screen was an analog of a roll of paper — more or less — and the keyboard immediately sent things to the remote system. However, companies like IBM and HP favored a different approach. Their terminals dealt with screens full of data. The terminal was smart enough to let you fill in forms, edit text on the screen, and then you’d send the entire screen in one gulp. Both systems had pros and cons, but — as you might expect — the screen-oriented terminals were more complex.
The project turned out to be a lot of detective work. A lot of these old protocols were poorly documented or even secret. However, some datasheets for old interface chips had some details and eBay even had the chips in question. We had forgotten that the 3270 used 93 ohm coax, but we never knew why they picked that particular value.
It turns out there were two different styles of terminals. One required a very sophisticated controller that did most of the work. The other did most of the work locally. Either way, the mainframe only dealt with the processed data. Luckily, [lowobservable] is documenting what he's learned on GitHub.
At the start of the project, [lowobservable] picked up a surplus terminal unit. However, it had a corrupt disk image so it wouldn't work. It did, however, have a usable diagnostic disk that could talk to the terminal. This allowed some analysis of the traffic which helped answer some questions.
The end result is a controller that isn't complete (yet) but it is workable. There are plans for an FPGA version that doesn't rely on obsolete chips, too.
Of course, we wish we had a real IBM 360. You could settle for an AS400, though.