in , , , ,

Add internet access to a vintage computer using Raspberry Pi

- Werbung -
Reading Time: 7 minutes

The bulletin boards of the 1980s haven’t died out quite yet, but they have gone online. There’s only a handful of BBSes (bulletin board systems) that you can dial up with your old-time modem.

If you like the idea of accessing an internet-based BBS from your Atari ST, Amiga, or BBC Micro, then we can use a Raspberry Pi computer to act as a translator. You can even use modern services like Twitter! All we need to do is get Raspberry Pi talking in one of the most popular communications protocols of all time: RS232.

- Werbung -
- Werbung -

By interfacing the Raspberry Pi computer UART interface to RS232 and then using WiFi, we bridge the gap between old and new technology

A little history

Every Raspberry Pi computer has a form of serial access, which is one of the oldest and simplest ways of communicating with computers. These days you’re more likely to use TCP/IP, the protocol of the internet, to chat to a remote device, but back in the day it was RS232 that ruled the communications world.

Raspberry Pi circuitry features a further simplified version often referred to UART (universal asynchronous receiver/transmitter) running at 3.3 V, but we can adapt it to ‘full’ RS232 at 12 V so that older computers can handle the signal.

Cheat #1: If you don’t fancy soldering, you can buy these pre-assembled units (for a few pounds) that can connect to the GPIO

You’ll need

Top tip 1: Not just vintage

This project works well with older PCs. Although they refer to them as COM ports, their 9-pin connectors are really RS232.

Top tip 2: Be careful of weird wiring

Do your research on your choice of classic machine. Some, such as the Cambridge Z88, use non-standard wiring to their connectors.

Study and shop

To ‘downgrade’ a Raspberry Pi to RS232, we’ll need to build a small circuit to act as a transceiver so the vintage computer can ‘hear’ our virtual modem and the RS232 signals do not fry our delicate Raspberry Pi board. Luckily, all the heavy lifting for such a job can be done by the MAX3232CPC integrated circuit. All you need to do is wire it up, add a few capacitors, and you’ll be BBSing in no time.

Have a look at the circuit diagram in Figure 1. We’ve deliberately made it larger than it needs to be for simplicity. More experienced makers will be able to reduce it in size if they wish.

Figure 1: the connector from the solder (rear) side. Use DuPont-style jumper cables to connect the circuit to your GPIO. Make sure you wire up correctly to pins 2 and 3 and ground it

Soldering the main circuit

Time to get building. Thankfully, the circuit itself is not very complicated, but it’s also unforgiving, so make sure all the wiring is in the correct place or nothing will work! We recommend starting with the IC socket, then the wiring, followed by the capacitors, finishing with the headers (optional if you’d like to use jumper cables). The result takes the two transmit (TX) and receive (RX) lines from the GPIO and feeds them into the IC. The MAX3232CPC converts the data into RS232 standard and outputs them to the 9-pin D connector and vice versa. Check and double-check everything.

Add connectors

Unless you’re going for a permanent setup or looking to make it as low-profile as possible, we recommend using DuPont-style jumper cables to connect the circuit to your GPIO. Which model of Raspberry Pi you use is up to you, but unless you have a specific use case in mind, a Raspberry Pi Zero W is the perfect choice as it’s small and there’s little horsepower required. You will also need to solder up the 9-pin D connector. The diagram (Figure 1) shows the connector from the solder (rear) side. Make sure you wire up correctly to pins 2 and 3 and ground it too.

Raspberry Pi time

Your Raspberry Pi Zero W will need a bit of configuration before you can get going. Start with a fresh microSD card with Raspbian Lite (we don’t need a desktop, but feel free to install ‘full’ Raspbian if you wish). This is also a great project for reusing any old low-capacity microSD cards you have, as there’s not much software to install. Once booted up, make sure everything is up to date by running sudo apt -y update && sudo apt -y upgrade. Time to grab a refreshing beverage as Raspbian applies all the latest updates.

Prepare your virtual modem

An ‘out of the box’ Raspbian installation isn’t quite ready to go back to the 1980s just yet, so we need to do a little further configuration. From the command line, run sudo raspi-config to start the Raspberry Pi configuration utility. From the top of the menu, start by changing your password (optional, but recommended); then, under Network Options, set your host name (again, optional) and configure WiFi. Finally, under Interfacing Options, enable SSH and Serial. When asked ‘Would you like a login shell’, select ‘Yes’. Now exit the utility and shut down the computer (sudo shutdown).

Cheat #2: The simplest solution of all is the widely available USB-to-RS232 cables based on the Prolific PL2303 chipset

Testing time

Check your circuit board for any short circuits or dry solder joints. Once happy, connect it to the GPIO. There are four connection points: one for 3.3 V (physical pin 1), ground (pin 9), and TX/RX (pins 8 and 10 respectively). We recommend getting an RS232/USB cable and testing with a modern computer first. Connect the 9-pin connectors together and boot your Raspberry Pi. Now, using your favourite Terminal emulator program (we like Serial for macOS), try to connect over RS232. Raspbian’s default settings are 115,200bps (connection speed), eight data bits, no parity, one stop bit (aka 8N1).

Troubleshooting

Having problems? RS232 can be a tricky beast as, unless everything is perfect, nothing will work at all. The most common issue will be polarity of the TX and RX lines. For things to work, the RX of the GPIO must be connected via the MAX3232CPC to the TX line of the computer and vice versa.

Start by checking that your speed is correct and the protocol is set for 8N1. Also try ‘reset’ or ‘send break’ in your terminal emulator, which is sometimes needed to wake up the connection. Finally, try using a null modem cable (which crosses over the lines) or swapping the connectors to pins 8 and 10.

- Werbung -

Get online

If everything is working, you should now be greeted with the Raspbian terminal login (you might need to press ENTER a couple of times to wake it up). You can now log in as normal. If the connection is behaving, feel free to try it out on a real vintage machine. Some may require adapters to connect (1990s home computers favoured 25-pin D connectors).

You will probably need to reduce the speed of the connection, as many older computers cannot handle the default 115,200bps. Unless your computer is very old, 9,600bps will probably work. To set the port to this, enter the following from an SSH session:

sudo stty -F /dev/serial0 9600

Connect to a BBS

Almost every BBS is now online and ‚talks‘ using a protocol called Telnet. It is very insecure, sending plain text over the internet and has since been replaced with SSH (Secure Shell). However, many of these services are being run on original equipment that has no support for SSH, so Telnet it is.

Many classic BBSes are still online, some even supporting PSTN modems. These days, most can be found at the end of an IP address

The Telnet client software is not installed by default, so run sudo apt install telnet. Once finished, try connecting to the popular Particles BBS (running on an Apple II/e!), by entering:

telnet particlesbbs.dyndns.org 6400

Within a few seconds you’ll see a welcome message. After you’ve had a look around, use CTRL+] followed by ‘exit’ to leave Telnet.

Emulate a classic modem

If you want a genuine experience, and full compatibility with vintage BBS software, it’s easy to emulate the classic Hayes AT command-set. To install the emulator:

sudo apt install tcpser

Before running tcpser, go back into raspi-config, select ‘Interfacing Options’, then ‘Serial’, and answer ‘No’ when asked if you want a login shell to be accessible and then ‘Yes’ if you want the serial port to be enabled. Now start tcpser using SSH:

tcpser /dev/serial0 -s 9600 -l 7

(You can change 9600 to be your desired speed).

Try connecting over serial again and this time you’ll be able to enter AT commands, replacing phone numbers with domain names.

Polarity is the most common problem encountered when working with RS232. Remember that TX (transmit) goes to RX (receive) and vice versa

Do more!

Your original ‘comms’ software should be blissfully unaware that it is talking over the internet. There’s now another web of vintage BBSes to explore on your original machine, but why stop there? The Raspbian repositories are full of command-line software that can be accessed by your classic machine. Tweeting from an old 8-bit is always fun, so why not install ‘t’, a command-line Twitter client (github.com/sferik/t)?

Of course, you can now do anything in the Raspbian shell that you can in an SSH session, so get your BBC Model B to operate LEDs and switches, or have your Commodore Amiga send Telegram messages!

- Werbung -

Report

- Werbung -

What do you think?

Schreibe einen Kommentar