Subject: RX boot code (shorter?)

From: [email-masked] (Charles Lasner)
Date: 25 Mar 1994 06:20:13 GMT

cjl> Here's some not-so moldy stuff from pdp8-lovers:

Date: Fri 5 Jan 90 13:55:07
From: Johnny Billquist <[email-masked]>
Subject: Software...
To: [email-masked]

cjl> [Other stuff deleted...]

I would like to get the bootstrap for RX01 and RL01.
I can boot RX through the BOOT program, and has an ugly
hack which boots an RL, but would like to get my hands
on the official way to do this from the front panel.

	Johnny

cjl> And then a response:

Date:    Sat, 06 Jan 90 14:48 CST
From:    [email-masked]
To:      [email-masked]
Subject: Minimal Bootstrap for RX8E

I got this bootstrap code from a manual for an 8/e disk subsystem
built by DSD.  I have been using this bootstrap with my RX8E
controller and find that it is shorter and easier to toggle into
the 8/e than the DEC bootstrap.

------------------------------------------------------------------------

                MINIMAL PDP-8 BOOTSTRAP PROGRAM (RX)

   The following is a minimal length boot program for both the RX01 and
RX02 mode systems.  This boot tries only the specified drive with the
specified density.  Start at location 32 to BOOT drive 0.  Start at
location 22 to boot drive 1.

cjl> I've got a problem with this part of the boot code!  First of all,
cjl> unlike starting at 0032, this code *must* be entered only when the
cjl> drive is no longer performing a self-test.  Moreover, it's wasting
cjl> the read performed by the self-test, which is the whole point of
cjl> starting at 0032.  Otherwise, this boot isn't much (if any!) shorter
cjl> than DEC's, and does a whole lot less.

/ * THIS FIRST SECTION IS NECESSARY ONLY WHEN BOOTING ONTO DRIVE 1.
         / READS IN SECTOR 1 TRACK 1 ON SPECIFIED DRIVE
22*6755  BOTDV1,  SDNF            /START HERE TO BOOT DRIVE 1.
23*7000           NOP             /SKIP THIS WHEN CLEARING FLAG

cjl> Here's where it assumes the flag is stable.  But if the self-test is
cjl> in progress, this flunks!

24*7327           AC6             /SET AC=6

cjl> This makes it unnecessarily dependent on the post-8 instruction set.
cjl> A better technique is to make the NOP above instead the constant 0006
cjl> then reference that constant with TAD .-1.  The AC has to be clear
cjl> because this is a boot situation, etc.

25*1061           TAD  UNIT       /MAKE INTO READ SECTOR COMMAND
26*6751           LCD             /COMMAND = CONTROLLER
27*7301           CLA  IAC        /SET AC TO 1 FOR SECTOR, TRACK
30*4053           JMS  LOAD       /SEND SECTOR TO CONTROLLER
31*4053           JMS  LOAD       /SEND TRACK TO CONTROLLER
         / DOES NOT USE LOCATIONS 22-31 WHEN STARTED AT 32
         /
         / START AT LOCATION 32 TO BOOT DRIVE 0.
         / USES INIT TO READ DRIVE 0 TRACK 1 SECTOR 1
         /
32 7305  BOTDV0,  CLA CLL IAC RAL /GENERATE THE EMPTY BUFFER COMMAN

cjl> Again, an unnecessary dependancy on newer instructions.  Just change
cjl> it to CLA CLL CML RTL and it works on all models.

cjl> Entering here you get the benefit of the figure-8 loop, so the flag
cjl> need not yet be up, just pending, etc.

33 6755  CHKFLG,  SDNF            /WAIT FOR DONE FLAG UP
34 5054           JMP  LOAD+1     /NO - CHECK FOR READY TRANSFER
35 1061           TAD  UNIT       /YES-PUT IN READ UNIT, DENSITY
36 6751           LCD             /SEND EMPTY BUFFER COMMAND
37 5047           JMP  BOTLP      /START TO LOAD SECTOR BUFFER

cjl> This is a *manual* boot!  The 5047 isn't necessary; just put in
cjl> 0000 until you get to 0046.

         ////////
         ////////
47 4053  BOTLP,   JMS  LOAD       /READ NEXT WORD FROM SILO
50 3002           DCA  2          /START LOADING AT LOC. 2
51 2050           ISZ  .-1        /BUMP LOAD ADDRESS
52 5047           JMP  BOTLP      /CONTINUE EMPTYING BUFFER
         /
53 ****  LOAD,    0               /DATA TRANSFER SUBROUTINE

cjl> This is a subroutine header; value unimportant.  It could be used to
cjl> load the 0006 above, etc.  In any case, it's faster and less switch
cjl> manipulation to put in 5047 here since that's the same as the previous.

54 6753           STRF            / SKIP IF CONTROLLER WILL SPEAK
55 5033           JMP  CHKFLG     / NO - CHECK IF FINISHED
56 6752           XDR             / TRANSFER DATA IN OR OUT
57 5453           JMP  I LOAD     / RETURN TO CALLER
         /
60 7004  (DY0)    OR   7024  (DY1)/ USED BY SECONDARY BOOT
                                  / TO SELECT DRIVE 0 OR DRIVE 1

cjl> 0060 is only used by the RX01 boot.

61 0000  OR  0400 OR  0020 OR 0420/ DX0-SD, DX0-DD, DX1-SD, DX1-DD

cjl> The 0061 info is partially redundant to that in 0060 and is only used
cjl> by the RX02 boot.

    This bootstrap requires different values in locations 60 and 61
for single or double density,  and drive 0 or drive 1 bootstrapping.
These values are listed below.

    Drive 0, Single Density - Start at location 32
             60/ 7004
             61/ 0000

    Drive 0, Double Density - Start at location 32
             60/ 7004
             61/ 0400

cjl> Forgot Drive 1, single density - Start at location 22
cjl>
cjl>	     60/ 7024
cjl>	     61/ 0020

    Drive 1, Double Density - Start at location 22
             60/ 7024
             61/ 0420

------------
Richard

cjl> cjl