CP/M-86 for IBM PC/XT
I’ve been curious about running CP/M on an old PC. As it turns out Digital Research did create a CP/M version for the 8086 and it will run on an original PC with an 8088. However, by the time the AT came around, and the 286, the CP/M-86 was abandoned on the PC, in favor of MS-DOS.
I did some reading and there is a version of CP/M-86 available for download that is reported to run on PC compatibles. It originally would not boot on AT machines. But there is a hack that can change the boot disk to work on an AT. So, I downloaded the file and am now trying to figure out how to create a boot disk that may work on this XT-286 (which is an AT class machine). (Note: my original idea was to try to run CP/M-86 on the IBM XT-286. But I can’t get the floppy drive to boot so I ended up using the KLH-195 instead).
The file I downloaded included a copy of CopyQM, a shareware diskette copying program. It can be used to copy an image file to a diskette. I installed it on my KLH-195 AT machine and gave it a try.
The first try I made was to use a 360K diskette (on the KLH-195). The program sees the drive as a 1.2 drive and asks me to put in a 1.2 5.25 floppy. But I put in the 360K disk. The program continued and it seems to complete but I don’t know if it will work. Maybe I need to use a 1.2 disk? Let’s try to boot with it and see what happens.
I put the 360k disk in the IBM XT-286 and turned it on. After the memory check I got the typical two beeps, after which I hit F1 to continue to boot. The floppy drive spins up the disk but it does not boot. Instead, it continues to boot to the hard drive, and I end up at C:\>. It doesn’t work. Let’s try a 1.2 disk.
I found a 1.2 disk and used NC to format it to 1.2MB. I noticed that the choices of format in NC included 320K and 360K. I don’t know if that will be significant. I think the original CP/M-86 disk size was 320K. Anyway, I’m going to continue with the 1.2MB format and do another session with CopyQM.
I ran CopyQM again. This time I chose to select “Format conversion” and selected 1.2M. I did not set the format conversion to 360K when I tried this the first time on the 360K disk. That may have made a difference. Ok, let’s continue, with the format as 1.2M. The program finished and I took the disk over to the XT-286 and tried to boot it. It didn’t work. Same as before with the 360K disk. It spins the A; drive but does not boot, it continues to boot from the hard drive and leaves me at the C:\> prompt.
Lets try the 360K disk again, but this time let’s format it to 320K. It didn’t boot.
I tried to boot some other 5.25 floppy disks on the XT-286. I can’t get it to boot with a floppy. I may have a problem with the XT-286. Let’s try booting on the KLH-195. But it will have to be a 3.5”.
I ran the CopyQM program and tried to create a 1.44M 3.5 boot floppy. The 1.2M disk was bad so I switched to making a 720K disk instead. I tried booting it on the KLH-195. I got a message saying *** Cannot find CPM.SYS or CCPM.SYS ***. At least I got something this time. Let’s try it on the PB VX88. Same error message.
Maybe it’s a problem with the types of drives I have. Maybe I need a special drive on the XT-286 to boot CP/M? Let’s try another image file.
I downloaded a version of the CPM86 disk that was imaged as a 1.44M disk. I started up OpenQM again and tried again to make the disk on a 1.44M disk. I did not select to do a format conversion. It took awhile to find a 1.44M disk that would format and finish. But eventually I got a “completed” disk. I rebooted on the KLH-195 with the disk in the A drive - it just hangs. Drive light stays on and a blinking cursor. Try a hard boot (I did a Ctrl-Alt-Del when I tried the reboot the first time). Shut down and then turned the power back on. Nothing. No boot.
I tried again with the same image file (CPM86B.144) but this time I used a 720K disk. Just to see what would happen. The image appears to be a 640K image. It doesn’t work. Try using format conversion. It seems to “convert” to 720K. I should go back and try format convert to 1.44. When I did the 1.44 I did not convert. I went back and redid the 1.44 disk by choosing “Format Conversion to 1.44M”. Then I’ll try booting both the 720K and the 1.44M disks.
I rebooted with the 1.44 disk in the KLH-195. I got the error message again, but at least it didn’t just hang like last time. Now try the 720K on the VX88. Same error as above.
So, what is the difference between a disk that hangs and one that gives an error report? Does this mean I am getting closer to a boot when I get an error message?
I found another couple of files that said they would work for 1.44M and 720K disks to boot on an IBM PC/AT. (from here: http://www.cpm.z80.de/binary.html) I downloaded and am trying them now. They come with a batch file to make the operation easier to use with CopyQM and they supposedly use a special piece of software on the disks to allow them to boot CP/M. Let’s give it a try.
I completed both the 1.44M and 720K disks. Now let’s try booting the 1.44M on the KLH-195.
That worked! I got the KLH-195 AT booted with the CP/M 86 disk. Next try the VX88.
Yes! That works also. The VX88 is now running CP/M-86 with two floppies.
On the boot of this version it says there is a version for 1.2M. I wonder if I can use the 1.44 image file for a 1.2M diskette? Or do I need to find a 1.2M image?
Also, I have to figure out how to get CP/M software to load from floppy, or maybe a hard disk directory.
So far I have been unable to get CP/M-86 on the XT-286. But I have been able to get it booted on both the KLH-195 and the VX88 using floppy boot drives. What I can’t figure out is how to use additional floppies and copy files between them. CP/M-86 does not use anything beyond a 360K disk, which I don’t have. (There seems to be a problem with booting from the floppy on the XT-286. I can’t test CP/M-86 on this computer until I can solve the floppy boot issue.)
I did find this on a web page:
-----
It would also be very helpful if you could install a 360k 5.25-inch
disk drive in your computer. Don't use your 1.2 meg drive; CP/M-86
doesn't know about such things.
In the meantime, you can use your 3.5-inch floppy drive as a "360k"
drive by doing this:
- Put a write-protect tab (or some black electrical tape) over
the "high density" hole in a 1.44 meg floppy disk.
- Boot CP/M-86 from the hard disk. Then use DSKMAINT.CMD to
format that floppy disk (as "double-sided").
- You'll now have a floppy disk with a standard CP/M-86 314k
format on it.
You can then use this floppy as if it were a true CP/M-86 5.25-inch
disk. 22DISK and other DOS-to-CP/M file transfer utilities should
recognize it as an IBM CP/M-86 disk.
its better to take a 720 kb Disk because of better magnetic
characteristics
(the thickness of the magnetic layer is different and this can cause
problems!!)
-----
I have downloaded 22DISK and will give this a try.
I installed 22Disk on the KLH-195 and ran it. I set the format to IBM PC DSDD 48 tpi 5.25” format. Then I set the drive to A:, which is a 3.5” 1.44. Then I put in a 720K disk and chose “Format a CP/M disk” and then typed “G” to start the process. It finished with “Format Complete -No Errors”. So, I should now have a 320K CP/M-86 disk on a 3.5” disk. Let’s try to copy a file to it and then move that file onto the boot disk. I want the 144FEAT files.
I unzipped the 144feat2.zip file to the hard drive in C:\HOLDTANK\144FEAT. I want the following files on my CP/M-86 boot disk:
144PAT2.CMD - the driver
144PREP2.CMD - prepares diskettes as higher capacity disks (720, 1.2, 1.44)
I copied the two files to this disk using 22Disk. When I tried to get a directory list in CP/M-86 it came up NO FILE. I put the boot disk back in and hit Ctrl-C. Then I asked for a DIR and it works. I tried copying a file to the M: drive using pip. I couldn’t get it to copy.
How do I copy a file from drive A: to drive A:?
I tried to use DSKMAINT in CP/M to verify the disk created by 22Disk. It came back with error “Sector not found”. Try formatting it in CP/M-86 and then try copying to it from 22Disk. It didn’t work. DSKMAINT formatted with 80 tracks and 22Disk does not recognize it. Try a 360K disk in the 5.25 drive. I re-set 22Disk to use drive B: and then used 22Disk to format a 360K floppy to CP/M format. It finished with no errors.
I copied the two files (144PAT2.CMD, 144PREP2.CMD) to the disk using 22Disk. Now reboot to CP/M-86 and try to copy the files off this 5.25 disk and onto the boot disk. I am able to get a directory of the B: disk but I tried to use PIP to copy the files and it won’t work. Maybe I have the wrong syntax? Yep - bad syntax. I forgot the “=” (equal) sign. In PIP it is:
PIP a:=b:*.cmd
DOS does not use the equal sign and the source and destination are reversed. I had remembered the reversal of source and destination but I forgot the equal sign.
OK, I got the files moved over to the boot drive. Now, can I figure out how to create 144FEAT disks?
I need to start with a DOS formatted 1.2M disk, so I rebooted to DR-DOS and formatted a 1.2M floppy to the standard 1.2M DOS format. Then rebooted to CP/M-86 using the 3.5” boot disk, that now has the 144FEAT programs on it, and the 1.2M disk in the B: drive. The instructions say to create a 9Kb area of FIDD memory using the SETUP program. So, I ran SETUP, set the FIDD to 9K and saved back to the same boot disk. Then rebooted. The FIDDS was reported as 9K on screen.
I ran the 144FEAT2.CMD from the A> prompt of the boot disk, using the “V” option. It ended by reporting that the “1.44 MB Feature” software is already active. Apparently the boot disk already has this built-in, running from the file 144BLDR2.CMD on bootup. In other words, this “Driver” file does not need to be run from the command line in this version of CP/M-86, it’s already installed by default. (Although the FIDD still needed to be set to 9K). OK, so now to “prepare” a high capacity 1.2M disk for use with CP/M-86.
(Note: I was able to copy the 144FEAT files to the 720K boot disk I am using on the VX88. I removed both disks (on the KLH-195) and inserted the 320K disk in Drive B: and the 720K boot disk from the VX88 into Drive A:, then ^C, then PIP a:=b:*.cmd to copy the files over (only had these two files on this 320K disk for now). Then I put the 720K boot disk back in the VX88 and did ^C, then DIR, and the files are there. Great! Now I have the 144FEAT files on both systems)
To prepare a 1.2M disk for CP/M-86 I need to run the program named 144PREP2.CMD. The options need to be set to use 1.2M media. Like this:
144PREP2 B: 1V
This tells 144PREP2 to use the B: drive, use 1.2M format, and display the diagnostic messages.
I ran the program and it completed the prep on the 1.2M disk. Then I used PIP to copy CPM.SYS and the other files from the boot disk to the newly prepared 1.2M disk. It works! Now I have a fully working dual-floppy CP/M-86 system on the KLH-195, with 1.44 3.5” A: drive and 1.2 5.25” B: drive. Next to do the same for the VX88, dual 720K floppies.
Before moving over to the VX88 I re-did the 3.5” floppy using 22Disk. It wouldn’t read on the KLH-195 but maybe it will on the VX88. Nope. Doesn’t read the files. STAT seems to read the disk info but I can’t get DIR or PIP to work. It seems that 22Disk only works with 5.25” drives. Is there a similar program that supports 3.5” drives? Probably not. CP/M was not aware of 3.5” drives. Ok, now to try the 144PREP2 program on the VX88 with 720K disks.
144PREP2 B: 7V
The first time I ran this I got an error. I realized it was because I was trying to use the disk that was created by 22DISK. In order for 144PREP2 to work the disk has to be formatted by DOS as a 720K. I tried again with a DOS formatted 720K disk. It got further, but ended in an error again. I tried again with another disk. Error again, seek failure. Let’s try formatting the disks in the VX88. I had used NC on the KLH-195 to format the disks. Maybe using the actual drive from the computer I am trying to use will make a difference. I rebooted into DOS 3.3 and ran the format from there. Didn’t work. The VX88 is only formatting to 360K on the B: drive. I am now trying to format to 720K using the A: drive. Not working. Not sure why I can’t format 720K on this machine. It’s been a while since I setup this machine. I do remember something about adding drivers for the floppy and there was something to do with there now being a drive C: and D: as reassigned from A: and B:. But I don’t remember what the deal is.
I tracked it down. Turns out I needed to use the format program on the D: drive to format a floppy in the B: drive. I have a driver loaded in Config.sys that allows using the B: drive as a 720K drive on drive D: and the A: drive is drive C: when using the driver. This is only needed when formatting to 720K on this machine. It will read 720K disks made on other machines and write to them. But the special driver is needed when formatting to 720K. So, instead of using the /f:720 switch like in DOS 5.0 we use the standard “format d:” command and the special driver takes over and acts on the B: drive in 720K instead of the 360K that is supported in the BIOS. So, I did get a formatted 720K disk formatted in this computer’s B: drive. Now back to CP/M-86 to try 144PREP2 on this disk.
I tried “144PREP2 B: 7V” again. As before it got to the end and reported an error. So, I tried the “Quick” option instead - “144PREP2 B: Q7V”. That worked! And I was able to PIP the CPM.SYS file over to the newly prepared 720K disk and get it to show up with DIR and STAT. It seems to be working. The key was to use the “Quick” option.
Now, to get some programs on these disks. A word processor and a spreadsheet? A game?
veplus86.zip - VEDIT Plus 2.03/2.33 for CP/M-86
Editor, comes with a PC version already pre-configured.
Copied to DOS in C:\Holdtank. Unzip files to \Temp. Select files to fit 320K disk.
Used 22DISK to copy files to 5.25” 320K floppy.
Rebooted to CP/M-86
Use PIP to move files from 320K disk to 1.44M disk for temporary storage.
Use PIP to move files to a 1.2M floppy for daily use. Copies to 720K for VX88.
-----
I can only use 314K 5.25” disks formatted with 22DISK to copy files from DOS to CP/M. Once I get the files onto a CP/M disk I can use the higher capacity disks. There is a way to modify the 22DISK definition files to add the 144FEAT disks but it is too complicated. For now, I will stay with the 314K disks. I think I can also figure out how to transfer through a serial port with a LapLink cable. The file sizes are pretty small in CP/M so I have been able to move files with the 314K size disks.
I have copied and tried the following programs:
Word Processors/Editors:
VPlus - Vedit Plus, Word Processor
Ted - Editor
Write - quick note taker, not a full editor
Spreadhseet:
MicroCalc - very small spreadsheet, it works but it is small and simple
Database:
Dbase II - full database program
Utilities:
XDIR - gives alphabetically sorted directory and file sizes, and space available on disk
SD - same as XDIR
VFILER - allows viewing and marking files in a directory, copy & delete, etc.
Several ARC/SQUEEZE/LBR archive utilities
Games:
Gulper - Pac-Man type game
Pong2 - Pong type game
Tetris3 - Tetris type game
Tic - 1-player Tic-Tac-Toe
TicTac - 2-player Tic-Tac-Toe
Worm - Tron type game
Snake - avoid the snake, gobble up coins, escape the room
Hangman - text based, Hangman game
Gunner - text based, enter angle for gun to hit target
Blackjack - text based, 21/Blackjack
-----
Haven’t tried printer yet.
Haven’t tried terminal/serial port communication yet