Dosbox Configure Serial Port

This instructs DOSBox to configure a virtual port (COM1) and map it to the real/physical interface COM3. Transfer Ghostlink to the ST. (COM & LPT)” - “Serial Port” - “Port Settings”. Increase the bits per second to 19200 and press “OK”: Whilst running PCSLAVE.EXE in DOSBox, press F4 to set the Baud rate to 19200. DOSBox networking works in a client-server architecture, where one machine acts as a server and all the others connect to it as its clients. DOSBox emulates outdated protocols and actually routes them to Internet's own IP protocol (TCP/IP for serial/modem emulation and the even better UDP/IP for IPX emulation).

Ever since discovering that DOSBox has stable IPX and serial tunneling, I’ve been digging through my old files and rediscovering some classic multiplayer games of yesteryear with my brother (who still has the edge in C&C).

The issue with a lot of multiplayer games from 10 or 15 (or more) years ago is that they either rely on the IPX protocol for networked games or that they only support serial (modem or null-modem) connections. Pushing these over the Internet requires some trickery, in this case in the form of a tunnel to provide what appears to be a direct connection between the participant’s instances of DOSBox.

DOSBox achieves this by having one user’s setup running as a server (host), with any other participants connecting as clients – all that is required is for the host to forward a port through their firewall.

First, configure DOSBox with a serial port emulating a modem: serial serial1 = modem listenport:2323 Next, launch your favorite DOS terminal or BBS hosting software and configure its corresponding serial port with default settings, as follows: COM1: - COM port 1 - 8N1 data-bits, stop-bits, and parity - 57600 baud - 03F8 address - IRQ4.

Serial or Null Modem

First we’ll look at a null modem setup, a common way of allowing two player gaming via cross-over serial cable. To configure a virtual COM port as a null modem link, the below needs to be added to dosbox.conf. The examples below assume COM1 (referred to by DOSBox as serial1. One PC will act as the host/server and the other, the client.

On the server, specify the type of serial connection and the port in the dosbox.conf file, located in ~/.dosbox/ under GNU/Linux or under the user’s profile folder under Windows (for example, C:Users{username}AppDataLocalDOSBox. The TCP port you specify will also need to be forwarded through your firewall to the host PC.. The port can be anything you like, provided it is valid and available – if using GNU/Linux, stay above the first 1024 ports.


[serial]
serial1=nullmodem port:12345

Dosbox Configure Serial Port Settings

Dosbox configure serial port settings

On the client, specify the type of serial connection, the IP address of the server to which you’ll be connecting, and the port used. Example below using a fake IP address and an arbitrary port number.


[serial]
serial1=nullmodem server:423.456.789.123 port=12345

Note: The host’s instance of DOSBox needs to be running before the client’s in order for the tunnel to be created successfully.

Once both host and client have started up, open up a game that supports null modem connections (for example, Command & Conquer) and head for the multiplayer section. When configuring the serial connection in your chose game, be sure to set the COM port to the number you specified earlier in dosbox.conf.

IPX

The second method is to create an IPX tunnel. Many games used the IPX protocol to support multiplayer – for example, DOOM allows up to 4 player network games via IPX.

To establish an the tunnel, the process is similar to configuring the null modem link but with a couple extra steps. First, ensure IPX is enabled in dosbox.conf with the following:


[ipx]
ipx=true

Note: If you’re compiling DOSBox under GNU/Linux, make sure that SDL net is available before doing so. The package on Debian (and Ubuntu) is called libsdl-net1.2-dev and probably something similar on other distros.

Start DOSBox and, at the prompt, start the server by running the following command on the host machine:


ipxnet startserver 12346

The number after the ipxnet startserver command is the port number that the service will use. This is a UDP port and will need to be forwarded to the host through your firewall.

Then connect clients by running the following command, specifying both the host IP address and the port being used (substitute your host’s IP and port into the below example):


ipxnet connect 423.456.789.123 12346

Once started, check the status of the IPX tunnel with the following:


ipxnet status

The connection from localhost (127.0.0.1) is the local instance of DOSBox, remote connections will appear below with their IP addresses. If there are problems creating the connection, first ensure that the host’s copy of DOSBox is running before any clients attempt to connect. Another common problem is a firewall blocking the port or the port not being correctly forwarded.

Dosbox Configure Serial Port

After confirming that the tunnel is established and that the client/s has/have connected, it’s time to fire up a game and test it. Under the game’s multiplayer section, select IPX and start a game.

And then…

Dosbox Config Serial Port

In addition to the above two methods, there is also a way to create a link with virtual modems for software that lacks support for IPX or null modem play. I haven’t checked this out yet, but there’s a good run-down at VOGONS.

Dosbox Configure Serial Port Command

The creators of DOSBox have provided a really nice service with these tunneling options which provide a good way to re-live and share some gaming memories. I’m really pleased to be able to again play the multiplayer games that I started out with – my first experience was (IIRC) Command & Conquer linked via a null modem cable, then moving on to 4 player DOOM over a DOS-based home 10BASE2 network. Ah, the memories *sighs*. Happy gaming!

Comments are closed.