Subject: EMULATOR WANTED

From: [email-masked] (David Turner)
Date: Fri, 1 Oct 93 22:35:00 -0500

I read that there is several PDP-8 emulators around. I am looking for
one that will run on an IBM Clone. I don't need it to do any fancy I/O
work (ie real peripherals), but just want one that will run standard
PDP-8/E software and any I/O would come and go to files on the hard
disk (except for screen I/O). Ideally, there would be certain filenames
or directories on the drive that would be for the different types of I/O
devices... does that make sense? :-) I just want it to practice writing
some PDP-8 code.

In any case, is there an emulator that someone could recommend to me?

Regards,
** David Turner **
---
 þ QMPro 1.0 14-3452 þ ¯ìûÔÔh·¤ ŽCþhanks for hanging up, dear.

---

From: [email-masked] (Charles Lasner)
Date: 4 Oct 1993 03:59:53 GMT

In article <[email-masked]>,
>devices... does that make sense? :-) I just want it to practice writing

Without having a *real* emulator, you don't get the utilities to actually
run the code, or even write it.  There really isn't too much available for a
complete development environment for the -8 on other machines available.

You would have to write a comprehensive assembler (Doug Jones seems to be
the latest to attempt this;  over the years many have started, and to the
best of my knowledge, none have finished!) to assemble real -8 code from, 
and then you need a means to load the binary into a simulated CPU with
memory, and the attendant peripherals you want the program to actually run
from.  Treating the -8 as merely a paper-tape system, whether emulated or not,
severely shortchanges the process of dealing with the machine.

However, a practical emulator is being worked on for PC-class machines.  It
depends on the ability of the 5.25" HD drive to physically read floppies that
are compatible with existent peripherals.  Someone else is working on one for
the Mac as well, etc.

The reason this can be done is that there are three viable disk formats that
can be used to run from an -8, and also on an emulator:

1)	5.25" CESI HD format is essentially the same as standard PC format
	except that it uses 26 sectors/track, and the sectors are 256 bytes.
	The PDP-8 can only access 12 bits every pair of bytes, but that's
	quite a useful size on the -8, since it means that each physical
	record is 1 pdp-8 page long.  This works quite well with P?S/8 and
	OS/8 standards.  Such disks can be booted on my PDP-8/e-a machine
	directly; you can run P?S/8 in 4K on such a machine or OS/8 in 8K
	on the same hardware, etc.  The controller is an OMTI 20 family or
	5000 series SCSI controller which supports HD floppies, MFM hard disks
	and optionally a QIC-02 tape backup unit.  All are in turn custom-
	supported by the MDC8 SCSI host adaptor from CESI.  The -8 offloads the
	data transfer (via DMA) to an on-board micro, so all it has to do is
	start up the transfer operation of DMAing an SCSI command in memory,
	to the micro which then does the command.  If the command is read or
	write, then the micro initiates a DMA operation for the data transfer
	as well.  PDP-8 programming consists of setting up the SCSI command
	and a few augmentations, and pointing the micro to the DMA address of
	this command, then wait for done and/or interrupt.  The controller
	is used the same way with hard disks, except that you have to logically
	map the partitioned disk to appropriate sized chunks for the various
	P?S/8 and/or OS/8 logical devices, etc.

	So reading such a disk is really quite easy on a PC.  In fact, the -8
	can read standard PC disks, but that format isn't quite so attractive
	for the prevailing software.  (And there's that limitation on getting
	at those extra bits.)

2)	The OMTI 5000 series specifically also supports 3.5" drives in HD as
	well.  By configuring the SCSI adaptor accordingly, the MDC8 can easily
	support the same logical drives, but physically be 3.5" with the same
	variation.  While not an efficient use of the media, this format can
	also be used on PC's, and also can be used on a newer MAC.

3)	DECmate RX50 format can also be used on the PC.  There is a slight
	problem in attempting to get OS/278 to run on a real -8, much less
	an emulated one, since OS/278 has problems of "emasculation" relative
	to OS/8.  No one is attempting to emulate the quirky variants of an
	actual DECmate, but the format itself is what matters.  Using various
	methods (such as Kermit-12 on a DECmate and on an -8, etc.) it's quite
	easy to get an OS/8 system written onto an RX50 that can only boot on
	a mythical machine, i.e., a PDP-8 with the DECmate's RX50 hardware, but
	with the PDP-8's otherwise compatible hardware.  On the DECmate, such
	a system is viable when referenced as a non-system device, but would
	boot on an emulator.

	In fact, there exists a CESI board called the FLP8 that solves just 
	about all of these problems of data compatibility:

The FLP8 can support a pair of identical drives that can be compatible with
the TEAC FD55E or F.  When considered as a single-sided device, it can be
configured to be media compatible with RX50.  The card is in turn a quad
Omnibus card suitable for the PDP-8/e,f,m,a, or perhaps a DW8E for earlier
machines, etc.  The overall programming style is RX01-like, although not
really compatible when used with these 5.25" drives.  (It can also be
configured to be used with 8" drives and be in fact a superset of the actual
RX01, in that it can also format!  The commands reserved for RX02 use of the
"set media density" will format on this device.  Formatting also applies to
the use with the RX50 format.)

So, an FLP8 can be used on a PDP-8/e using 5.25" drives (such as FD55GFR with
the jumpers set to emulate an FD55E such as is the case inside of the DECmate
III+; an RX33 *is* a TEAC FD55GFR/V drive!).  For such a device that is
similar to both an RX01 and also the RX portion of the DECmate, it is fairly
easy to write a set of handlers for P?S/8 and/or OS/8 (borrowing liberally
from the existing RX01 and DECmate RX50 handlers).  So, a bootable (on a real
-8/e) system can be created that would be data-compatible with the DECmate and
also can be directly emulated on the PC.  Also, this device supports 8-bit mode
thus allowing it to be configured to completely be able to access PC floppies,
thus opening up yet another avenue of compatibility.  PC HD 1.2 MB floppies
in MS-DOS format could be accessed using something to be named PIPMS.  And
of course such a utility could be run on an emulated version on an actual
PC so as to be an easy data conversion route between PDP-8 software and the
MS-DOS system running the emulator, etc.  Such a system could also access the
bootable floppies from the MDC8 system, including getting at the data bits
lost in the MDC8 transfers, etc.  (Note: while the FLP8 is a good device for
data transfer, it is *not* a good device to emulate!  This is a high overhead
slow device at best, and makes the real and emulated machines slow down quite
a lot!  The MDC8 is probably the best standard device to emulate since the -8
isn't directly involved with the transfer, etc.

Regardless of device chosen, this makes for the best avenue between emulations
and the real -8's.  Emulators can also choose to implement non-dismountable
media such as the RF08.  Before and after the emulation execution, the RF
image can be contained in an auxiliary file, etc.  This would likely be
implemented as a RAM disk, thus increasing the basic speed of the emulator.
Paper-tape devices can be emulated as files such as READER.BIN and PUNCH.BIN
for compatibility with these simple devices.  We already have utilities to
move PDP-8 binary files around that can be represented on systems such as
MS-DOS in the appropriate format, etc.

cjl