DOS in Y2016 – How to Run It Smoothly in Your Clinic Lab

  1. Tools/Reference used for the project:

dosbox debug:  http://www.vogons.org/viewtopic.php?t=394

http://www.vcfed.org/forum/showthread.php?11320-NE2000-card-emulation-with-DOSBox-

http://www.columbia.edu/~em36/pcltopdf.html

https://sourceforge.net/projects/vjoystick/

https://en.wikipedia.org/wiki/Cyrix_6x86

OK. Let’s talk the grandpa’s OS, the Dos.

You may wonder, is DOS still survived at some corners in Silicon Valley in USA, the Most Developed digital and AI-pioneer area?  The answer is “IT DID”.

Here are some photos to rock you!

   From left to right, bottom to top, you can see Dos, 3 ISA cards, Clinic Lab PC and 80486 CPU.

Those machines are used for work endurance test for workers, who are employed widely in the logistics fields.  Workers may need to pass the test before they can get employed. The software was developed in the Dos era, ~1991, and the company was bankrupt once, and seems was bought by another foreign company, and then no more support/dev.  Yes, here you are, you need to maintain it and upgrade hardware.

Another updated windows version does not support the some features in this Dos version, and most importantly, the price of windows version is expensive.  The clinic owner is a tiny company with ~50 patients in one month, so the clinic is still running the Dos software with 486/Pentium CPU, and there is no plan to upgrade to windows version.

So, that leads to this story. How can we run the Dos smoothly?

Let’s start with the software requirement in lab pc and master pc.

  1. The software requirement in each lab PC.
  1. )One A/D (Analog-to-digital) Converter Card in ISA slot

It is used to gather the external analog signal, such as lift weight, push/pull weight and grip, optical pass-through signal, etc, and convert it into digital to PC Dos.

Here is the scare statement of the A/D manual:

Copyright @ 1992 by xx xx xxx, Inc.

  1. )One Ethernet Card running with BNC connector in ISA slot
  2. )One sound blaster card in ISA slot

To instruct patients how to lift/pull/push, etc.

  1. )Proprietary Network Software (not tcp/ip or other sound name. It is called LBL network.)

 To connect several test lab PCs with a master PC. So, we can centralize all lab units test data into one master PC to manage patient information, together with all labs result.

Here is the scare statement of Readme.doc in LBL network software:

                           Version 2.0h

                        Copyright 1990-1996

                         

  1. )One more, the lab software has passcode, bundled with Ethernet MAC address.
  1. The software requirement in master PC only requires the above #2, #4 and #5, and one Printer LPT.

The Challenge

Those ISA cards (A/D, Ethernet, Sound) works still well after more than 2 decades.

The current most emergency issue are the unstable of motherboard and hard drive. Sometimes, motherboard can’t post; hard drives are dead, then live again. The bad news are we do not have spare motherboards, even from EBAY, as the motherboard requires 3 ISA cards.

The clinic owner wants to build second labs, but, we can’t find those motherboards to support that.

The patient report in master will be printed with 50~100 pages for each patient. It wastes lots of paper. However, this is the only way that the doctor can get the lab test result from printed report.

The Proposed sky-high-level Replacement Requirement from BOSS

Only one ISA slot in motherboard to support A/D card.

Those A/D card are using 50pin interface with external circuits which connected with weight-lift, weight-push/pull/grip devices.  

We can’t find any replacement for the ISA A/D card. So, we have to keep this card.  That means the replacement motherboard must have one ISA slot.

My Final Proposals for Replacement

  1. Upgrade the Proprietary Network Software to Microsoft Network Client version 3.0 for MS-DOS

This proposal is based on the detail analysis of lab software.  The lab software only accesses the network drive (which is shared by Master) when check the lab test setting and save the lab data.  The original network sharing Proprietary software has many other features, such as shared via COM/LPT, besides of shared via Ethernet. But, we do not need to have such powerful features.

        The major contribution of the proposal is to expand the choice of Network Card. The original network software only support ISA NE2000 card and Packet Drive card. With Microsoft Network Client version, we can use PCI network card in the Dos system.

  1. Upgrade the Master PC from Dos to Half-Dos and Half Window 7 version.

What does it mean for “Half-Dos and Half Window 7”? Yep, it is Dosbox in Win 7. As Master PC is only used for information management. It shares a folder to lab PC to save data and access lab setting configuration.  Now, the information management software in Master is running in Dos via Dosbox in win 7 (you may upgrade to win 10, wow!).  

The major contribution of the proposal is to

  1. )Nurses are able to use modern UI-Friendly win 7 machine, instead of iced-black-white Dos machine.
  2. )It is much more handful to copy data from master. Before we use 1.44M floppy to copy data. It helps to our next step on how to use the data in a web .Net project.
  3. ) The Dosbox can simulate print function to print as a prn file, which is a printer protocol format file.  We use another software to convert it to PDF file (using pcltopdf). So, no more waste paper to print.  Nurses can direct send the PDF to doctor to review patient’s result.

—dosbox.conf setting as below for print as prn file:

printer=true

dpi=360

width=85

height=110

printoutput=png

#printoutput=printer

multipage=false

  1. )It will be easy to setup the windows sharing to allow lab PC to connect with the master with Microsoft Network Client version 3.0.
  1. Upgrade the lab PC to use PCI sound blaster card.

This step seems very easy, however, it takes much more time than above proposals. The lab PC software are only perfect fit for the first generation of SB. Several types of motherboards which embedded simulate SB features are not able to use by the software to play sound.  We bought many demo old motherboard from China for test. Finally, we find an ASUS motherboard and use external 1.5 generation of PCI SB card to solve the issue.  We almost give up when search the replacement of PCI SB card.

The major contribution of the proposal is to drop one ISA slot requirement.

By using the 3 proposals, we can use one ISA slot only for the software. That is much easier to buy motherboards with one ISA slot.

The Last Extreme Challenge in the Experiment

If you read the article carefully, you will know that we still miss one important part to make the replacement project success. That is the MAC address and the (a word hidden, you knew that if you have the similar issue and want to fix it).  The master in dosbox is easy to handle it as dosbox can fill any MAC address for the underlined dos software.  But lab PC is still Dos.

Most of developers in the Dos era will use sofxxx to do that.  I try it together with visual box. But maybe I am too new to this field. So, I can’t find the way to route it.  Finally, I have to use DOSBox to compare the data in Registers one line by one line to find out the hidden.   I open two Dosbox to run the same lab software in a window machine: one dosbox run with known good MAC address, another run with wrong one.  When debug both codes one line by one line, you can see the different of data in Register. As the two Dosbox run same software and same data, except MAC. So, when you find the different data in some Register, that will be the data you want to use for the wrong one.  By the way, you should use screen video catch software to record every step when you debug two dosbox. That will help you a lot to trace back. Here is the screen shot of the video:

It takes 2 days to finish this single task. The size of the lab PC exe file is about 400k.

Summary

It is not an easy job to maintain and upgrade old Dos software. You need to be patient and trials. With Google, you can get lot’s of information about Dos era information, such as Int 21, DosBox, SB, Network in Dos, etc. That will help you to finish your task to upgrade Dos software with newer hardware support which you can still buy it in the market.






Leave a Reply