TU58FS - PDP-11 boot loader operation
After you have started a TU58 emulation on a serial port, you probably wish to boot from that "tape". If you don't have TU58 "DD" ROMs in your PDP-11, tu58fs can isntall and run a TU58 boot loader over console monitor.
Boot PROMs and the boot process
Some theory first:
Almost all PDP-11s have boot software installed in internal ROMs. There is
- an interactive "console monitor", which lets you manipulate memory and start/stop program execution.
- one ore more special "boot loader", which can transfer the boot sector of a mass storage device to memory and start it. There is one bootloader per device class needed (RK disk, RL disk, TM1 tape, TU58, Network, MSCP, ...).
On QBUS machines, the console monitor is part of CPU micro code and is always there. On UNIBUS machines, the console monitor may be executed by a separate front end processor (as on the 11/44). Or is executed by PDP-11 CPU itself. Widely used is the "boot strap terminator" ROM card M9312, which contains console monitor code and boot loaders in changable ROM sockets.
Due to space limitations and because over the years DEC built so much different peripherals, no PDP-11 contains boot code for all possible devices.
What does a PDP-11 do after Power-ON or Reset?
There are too many options to boot a PDP-11 to describe. After Power-ON, a PDP-11 may perform different functions, depending on machine generation, jumper settings and ROM content:
- the PDP-11 executes some advanced multi-function Boot-ROM. Then after self testcheck a whole list of disk/tape devices is checked periodically for response and a boot attempts made.
- the PDP-11 is pre-wired to boot a fixed device type.
- it may boot into the interactive console monitor and await some Boot commands
- if the PDP-11 was used as machine controller, it may boot into some special user-code. You typically will never find out what the machine tries to do!
How about TU58?
Well, after Power-ON, several scenarios are possible:
- Your PDP-11 boots automatically from connected TU58. (If you have a device-probing multifunction ROM, this may take some time however.)
- You have TU58 ROM code installed, but just the console monitor prompt appears. Then you have to enter the boot command by hand, for example on UNIBUS M9312:
- You see the console monitor prompt, but apparently don't have boot code for the TU58 "DD" device.
- Nothing happens after Power-ON. Try to force a console monitor prompt by resetting the machine with a console switch sequence like
"Set HALT, Toggle START, Release HALT".
Most likely cases are 3 and 4: you don't have TU58 "DD" boot ROMs, but see a console monitor prompt.
If you see a console monitor prompt, tu58fs can install and start a boot loader over console serial line.
Since you can manipulate memory and start programs over the console monitor, tu58fs can automatically write the TU58 bootloader into the PDP-11 and start it.
The Commandline is
tu58fs -p <serial port> -b <baudrate> -f <serial format> --boot <monitor_type> <keep>
<serial port>, <baudrate> and the <serial format> of the console are set by "-p", "-b" and "-f" options left of "--boot".
<monitor type> specifies the implemented console: "ODT", "M9312", or "M9301".
"code" displays the bootloader code as value/address pairs on stdout.
With <keep>=1 the transfer dialog terminal window remains active, so you can immediately operate the booted TU58 OS. With <keep>=0 connection is terminated and you have to start a more comfortable terminal emulator.
- The serial CONSOLE port is always DIFFERENT from the TU58 port!
- The PDP-11 must be HALTed and show its monitor prompt, with the HALT/RUN switch in RUN position.
- the bootloader doesn't catch any TRAPs, so best turn off the BEVENT/LTC signal.
- the code is loaded at end of first 4k page at address 7000.
- "tu58fs --boot" has nothing todo with TU58 emulation. It is in fact a completely different program, accessible over the tu58fs command line.
$ sudo ./tu58fs -V -p /dev/ttyO2 -b 2400 -f 7e2 -- boot odt 1 [06:46:15 info] tu58fs - DEC TU58 tape emulator with File Sharing v1.2.0 (compile Apr 14 2017 20:40:34) [06:46:15 info] Using serial port /dev/ttyO2 at 2400 baud with 7E2 format. [06:46:15 info] No simulated drives were specified, emulator not started. ?
TU58FS: teletype session to PDP-11 console opened.
TU58FS: Terminate teletype session with ^A ^A double key sequence.
BOOTING UP XXDP-XM EXTENDED MONITOR
XXDP-XM EXTENDED MONITOR - XXDP V2.5
BOOTED FROM DD0
064KW OF MEMORY
RESTART ADDRESS: 152000
TYPE "H" FOR HELP !
tu58fs operates the ODT console to DEPOSIT code at 7000, and issues a 7000 GO to start the boot loader.
Then it remains in "teletype" mode, so the output of the booted operationg system is visible.
Operating emulator and boot loader in parallel
Normally yout want to run tu58fs both as device emulator and simultaneously as TU58 boot loader. Then two separate instances are run in parallel. These are wired to the PDP-11 Serial Line Units (SLU) over two different RS232 connections in the follwoing way:
This example is for a QBUS PDP-11 connected to a MSWindows machine over 2 FTDI USB-to-serial adapters.
Figuring out the virtual COMx device for each USB port can be an extra job!
Note that the console connection may not have "8N1" transmission format (the TU58 connection always has 8N1).
The boot loader code used by tu58fs can be accessed in two ways:
- call "tu58fs --boot code", the binary code is dumped as octal address/value pairs.
- or download MACRO source and listing files from the attachement.