- Using DOSBox to run PC2HGM software on windows 7 1. Download and run the win32 installer from the DOSBox web sight (works on win64 as well). PC software will be launched and setup data collected from the monitor. Control Pan El Control Panel Home Device Manager. LISB Serial Port (COMI) Properties Port Settings Bits per second 9200 Data.
- Setting up real serial port to dosbox macos. I'm trying to read data from an arduino to tasm running on dos box I've read that I need to set up the serial port in the dosbox preferences like this: serial1=directserial realport:COM1. If I understand correctly as I'm on mac it isn't called com and I need to replace it with my port which is.
Next, install dosbox, vnc4server, and socat. Now, when you use socat, ideally you'll want DOSBox to connect to a 'virtual' serial port device, like /dev/virtualcom0 in my example, but for some reason that device always has root permissions no matter what I do, so instead I had to cheat a little bit in my DOSBox serial configuration. Of course it's possible to write programs that display on the screen and send/receive bytes on serial ports. Asking how to get started writing such a program is not an on-topic SO question (too broad), so I retitled to ask about the part about configuring DOSBox. – Peter Cordes Jun 19 '18 at 21:35.
What is dosbox? DOSbox home page
It is a free/open-source DOS emulator that runs on many operating systems.
It runs DOS inside a virtual machine in a much more true native mode than running a DOS command window inside Windows XP.
What does this do? It allows for old original DOS software including radio programming interfaces to run on current computer operating systems or hardware.
The issue it fixes is that many old DOS applications relied on the speed of the machine running it for handling timing and interrupts. On current hardware, this means the old software runs too fast and is unreliable.
Also, old DOS software wasn’t aware of things like USB to serial adapters and other new hardware.
This software allows you to create virtual bridges between a new serial port USB device and old ‘com1’ only DOS software.
What have I tested it with so far?
I’ve used the CE14 software for Vertex LMR radios inside DOSbox and it make it work perfectly. Whereas with Windows XP on a 1+GHz laptop, it would run, but not function properly.
You can tell you have a problem this may fix, when the software runs, but you don’t get actual read/write performance to the device you are programming. This can cause a lot of errors with the hardware and possibly even brick the firmware if you aren’t careful.
So, go get it...
Go to http://www.dosbox.com/ and download whatever version you need for the platform you are running it on. Follow the basic download and install instructions.
After install…now what?
So you have it up and running now. These are the steps using a USB serial adapter and programming software.
First, you need to map your com port, using Windows XP as an example. The USB adapter is com4 , you can find this in Windows device mgr, right click on My Computer and select ‘manage’ and then ‘device manager’ and inside there, LPT and com ports. You will see your USB device in there if the driver is properly installed and the com port number it has.
So to set/map the com4 in Windows XP to com1 inside of dosbox while it is running do the following
Z:>serial1=directserial realport:com4
This will make com1 inside dosbox map to com4 in Windows XP directly.
Dosbox Configure Serial Port Settings
Next you have to ‘mount’ your path to your programming software. To make this very easy, I just copied my folders for CE14 into the root of C: as in C:CE14 that is where CE14.EXE lives.
The command to mount inside dosbox is
Z:>mount c c:ce14
This is specific for me as c:ce14 is where my software is, replace this with whatever you have, wherever you put it.
Now to get to that location you just do
Z:>c:
Now you see C:> as the prompt
C:>dir
Dosbox Config Serial Port
Will show you what is in there. In my case I see all the CE14.* files so I do
C:>CE14.exe
Now the software runs.
The only thing left to know, is you need to go into whatever app you are using and tell it that the serial port to use is ‘com1’ as that is what we mapped earlier.
DOSbox allows you to map serial1 serial2 serial3 serial4 to four external serial devices, they are treated as com1 com2 com3 and com4 respectively.
You can also map multiple paths to multiple ‘local’ DOSbox ‘drives’
mount c c:path1
mount d c:path2
Dosbox Configure Serial Portable
At the prompt to switch around you would just enter c: or d: and you’ll toggle between the paths. Just typing ‘mount’ will list what you have configured.
There are a bunch of neat features to control slow down and speed up within DOSbox so definitely check out the documentation links on their site and also try the Z:>info
command as it has a bunch of on line help within the application itself.
The immediate applications for this are with old DOS based radio programming software for LMR radios, but I can imagine that many crusty DOS based packet radio apps and other things will run a lot better in it too. I’m not much of a gamer, but it’s evidently quite effective for that as well.
I think this should cover it.
73 de KC2RGW
Please enable JavaScript to view the comments powered by Disqus.blog comments powered by DisqusPublished
Tags
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.
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
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:
Dosbox Configure Serial Port Free
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):
Dosbox Configure Serial Port
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.
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…
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.
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!