Friday, February 9, 2024

USB to serial adapter to transfer files from a modern to a vintage XT IBM PC

In this previous post I've talked about the restoration of an IBM vintage PC: https://davidegironi.blogspot.com/2023/12/vintage-ibm-5160-xt-pc-restoration.html

Once I've booted this PC the first thing I had to do was to transfer files from and to the Hard Drive of that PC.

My IBM 5160 has a 5 1/4 inch floppy driver. But this is not the way I want to use to transfer files.  At the minuszerodegrees website there's a full page dedicated to the transferring methods, https://www.minuszerodegrees.net/transfer/transfer.htm.

Luckily my IBM pc has a serial board, so I decided to use the FastLynx 3.3 software one. FastLynx 3.3 is a program designed to help you transfer files, directories, or entire hard disks quickly and easily from PC to PC, it can transfer files through USB, parallel or serial port.

I've found a trial version of FastLynx software on https://archive.org/. It is limited to 10Mb files only. But if you consider my Hard Drive on the IBM c is 25Mb, that is more than enough.


As a first test I've built a test serial to serial cable on a breadboard. On the modern PC side I've used a USB to serial adapter while on the IBM side the straight DB connector. This kind of serial cable is called null modem cable.


 One I've realized that the cable works I decided to build an all in one USB to serial adapter.

I take a PL2303 USB serial adapter apart, and wire the DB25 connector as specified on the FastLynx manual. You can find the wiring diagram above.

One connected you have to run FastLynx on the modern PC, then you have to run the Upload Dos Slave function to load the DOS slave program. It will be uploaded through serial port. The process is a wizard, you just have to follow the instructions. On the DOS PC you simply have to run the mode command (mode com1:2400,n,8,1,p) and then the ctty command (ctty com1). Then on the modern pc you can upload the SL.exe slave program.


Once done you can move SL.exe to the directory you want, and run it on DOS.

The master modern PC have now access to the hard drive of your slave PC.

That simple I was able to transfer files on the vintage PC to a dump folder of my modern PC, and then upload a few usefull program on the vintage PC, like the Norton Commander

You can find full instructions on the FastLynx page at minuszerodegrees.net here: https://www.minuszerodegrees.net/transfer/fastlynx33/fastlynx33_serial.htm

Notes

  • read risk disclaimer
  • excuse my bad english

Wednesday, January 3, 2024

IBM AT (PS/2) to XT (DIN) keyboard conversion

In my blog post here: https://davidegironi.blogspot.com/2023/12/vintage-ibm-5160-xt-pc-restoration.html I've talked about the restoration of an IBM 5160 vintage PC.

The first time I've tried to boot this PC it ends up with an error. The error was due to the missing keyboard. Investigating further It turns out that I need an XT keyboard in order to make this PC works.


IBM PC of that era uses the XT protocol to communicate with the keyboard. From the 1984 IBM starts building AT compatible keyboard. Starting from 1987 IBM also introduce another kind of connector for the AT keyabords, the PS/2 mini-DIN 6 pin connector.

There are a few differences between the XT and AT protocol, the main difference is that XT can only send data, while AT can receive and send data. Under the hood they are completely different protocol, so it's not just a matter of changing the connector wiring, one have to write some logic in order to make an XT keyboard work.

So, in order to boot my PC I need an XT keyboard, which I don't have. I have searched for an used one but I can not find it. Well I've found it later on after a few months, but at that time I don't have that keyboard, so I decided to build it.

There are a few DIY commercialized adapter, but I've an Arduino micro clone and I want to use this cheap board. I've found a PS/2 to XT code for Arduino on github (https://github.com/kesrut/pcxtkbd).


Just I have to wire it according to the DIN connector pinout, XT keyboards uses a 5 pin DIN connector with the following pinout:

  1. clock
  2. data
  3. /
  4. ground
  5. +5V
Then I've compiled and upload the Arduino firmware and I've tried it using a PS/2 keyboard as the master.
It works!

I don't like to have the adapter flying on the bench, so I've decided to pack it in an IBM 90's keyboard, the IBM KB-7953 model.


I've opened it, and wire the internal PCB to the Arduino and the Arduino to the DIN connector, using the original keyboard PS/2 wire. I've exposed a 5 pin adapter to eventually update a new firmware to the Arduino in the future.

The keyboards is now ready, compact and perfect for my vintage IBM pc.

Notes
  • read risk disclaimer
  • excuse my bad english