DataMuseum.dk

Presents historical artifacts from the history of:

RC4000/8000/9000

This is an automatic "excavation" of a thematic subset of
artifacts from Datamuseum.dk's BitArchive.

See our Wiki for more about RC4000/8000/9000

Excavated with: AutoArchaeologist - Free & Open Source Software.


top - metrics - download

⟦183f99cb8⟧ TextFile

    Length: 17664 (0x4500)
    Types: TextFile
    Names: »tautoboot«

Derivation

└─⟦621cfb9a2⟧ Bits:30002817 RC8000 Dump tape fra HCØ.  Detaljer om "HC8000" projekt.
    └─⟦0364f57e3⟧ 
        └─⟦87223b8a0⟧ »kkrcmonfil« 
└─⟦00964e8f7⟧ Bits:30007478 RC8000 Dump tape fra HCØ.
    └─⟦b2ec5d50f⟧ 
        └─⟦87223b8a0⟧ »kkrcmonfil« 
            └─⟦this⟧ 

TextFile

autoboot=slang
b.

m. autoboot 81.03.26 15.00.00
m. version 2

; bootloader, rc8000.

; autoload program for load from disc or fpa.
; the autoload from disc is performed in the following way:
;  -  the autoload bottom is suppressed and released.
;       the rc8000 cpu executes a general clear, inserts two channelcommands
;       in the core store (an initialize and an input command), initializes
;       the basis address of the controller (word 8) and starts the 
;       channelprogram on the device with io-device number 4 (the disc).
;  -  first command initiates the disc controller, positions to cylinder zero,
;       head zero and sector zero.
;  -  second command inputs one segment (the bootloader) to first free core
;       after the input command.
;  -  the segment now loaded must start with a continuation of the initial
;       channelprogram, which normally consists of a stop command only.
;
;  -  in case the device 4 does not respond the start channelprogram command,
;       the cpu now tries to autoload from device number 2, which is the fpa.
;       this requires only reinitialisation of the basis address of the con-
;       troller table. the channelprogram inserted in core is now started
;       on the fpa.
;

b.a20,p10 

; the channelprogram placed in core after activation of the autoload buttom
; has the format shown below. Part of this channelprogram area does also serve
; as device controller description and as standard status area. the format is:
;
;   address    contents   channelprogram    controller desc   status area
;
;    8         12-iodev<3
;   10         6<8        initialize
;   12         10         dummy             start of chpg
;   14         20         dummy             start of st.area
;   16         1<8(256)   input             interrupt addr
;   18         22         first addr        interrupt number
;   20         768        blocklength                         chpg addr
;   22         word0      ...                                 rem. char. count
;   24         word1      ...                                 curr. status
;   26         word2      ...                                 event status
;   28         word3      ...
;   30         ...        ...

; word0,1,2 are the beginning of the first segment loaded. they do at load time
; contain the channelcommand:
;   word0      15<8       stop
;   word1      ..         dummy
;   word2      ..         dummy
;   word3      ..         ....

a1 =8.60<1             ; display register
a2 =8.17<1             ; coresize register
a3 =8.57<1             ; interrupt register
a4 =4                  ; device number of disc
a5 =2                  ; device number of fpa
a6 =8                  ; basis of controller table
a7 =12                 ; start of controller description
a8 =10                 ; start of channelprogram
a9 =20                 ; start of standard status area
a10=22                 ; first free address after autoload channel program
a11=256                ; interrupt address (contents of word(16))
a12=22                 ; interrupt number (contents of word(18))

; user defined parameters:

p0 =+4             ; first sector of monitor area
p1 =+840           ; first sector of coredump area, if p1<0 then no coredump
p2 =21                 ; number of sectors per track (head)
p3 =168                ; max size, dumping the core (in segments)
                       ;   = max size, loading the monitor + p4 (in segments)
p4 =1024               ; load address of monitor

; when loading from fixed media disc with fixed head part, then use
;  p0=4+1008, p1=840+1008
; else use
;  p0=4     , p1=840

\f



s.b50,m6,n6 w.

k=a10

; channelcommands continuing the init autoload channelprogram:
b0:  15<8              ; stop
     0                 ; dummy
     0                 ; dummy

; the following four words are intended for automatic startup area name
; default is: manual startup!
;
; these four words are known(!) by absolute core-address in moncatinit
; they are also known by the 'install'-program!
     0, r.4            ; startup name

; device address:
b3:  1<23+a4<3         ; device address of disc
b4:  1<23+a5<3         ; device address of fpa

b5:  1<12              ; load flag: discload: 1<12, fpaload: 0<12
b6:  -1                ; core flag: unchanged: -1, changed: 0
\f



; channelprogram for fpaload of monitor.

b10: 3<8               ; output
     b15               ;  addr of status byte
     1                 ;  size:=1 char
b11: 1<8+1<7           ; input and continue
     b16               ;  addr of start byte
     1                 ;  size:=1 char
b12: 1<8               ; input
b13: p4                ;  start addr (init: load addr(monitor))
     768               ;  size:=1 segment
b14: 15<8              ; stop
                       ;  dummy
                       ;  dummy

b15: 0<16              ; status byte<16:=transfer next block
b16: 0                 ; start byte<16
b17: p4                ; top of last loaded segment
b18: 255<16            ; status byte<16:=stop transfer

\f



; channelprogram for discload of monitor:
b20: 2<8               ; seek
     b30               ;  addr of seek information
     6                 ;  number of chars
b21: 1<8+1             ; input address mark
     b35               ;  addr mark area
     12                ;  read one addr mark
b22: 15<8              ; stop
                       ;  dummy
                       ;  dummy

; position area.
b30: 0<8+0             ;   cylinder0, head0
     (:p2-1:)<16+0     ;   last sector, empty flag

; input area for addr marks.
b35=b10                ; b10:   0,0 ; addr mark area(curr)
b36=b35+4              ; b10+4: 0,0 ; addr mark area(next)

; format of disc.
b31: 0                 ;   segments per cylinder 
b32: p2                ;   segments per track
b33: 0                 ;   screw

b38: p3*768            ;   max transfer size 
  
; channelprogram used to initialize the
; first 4 words of core
 
b39: 0<8               ; sense
     0                 ; addr:= core(0);
     12                ; number of chars
b40: 15<8              ; stop
                       ; dummy
                       ; dummy

\f


; discload.
b.i4,j6 w.
m2:  al  w0  b20       ; discload:
     rs  w0  a7+0      ;   start(chpg):=start(discloadpg);
j0:  al  w2  b22+6     ; next head:
     jl  w3  n0        ;   execute chpg(top(discchpg));
     jl      -16       ;    error: sysfault(16);
     al  w0  1         ;    ok:
     ba  w0  b30+1     ;
     hs  w0  b30+1     ;   head:=head+1;
     rl  w3  b36+0     ;
     sh  w3  1<8-1     ;   if cylinder(next)>0 then
     jl      j0        ;     goto next head;
     wm  w0  b32       ;
     rs  w0  b31       ;   segments per cylinder:=head*segments per track;
     bz  w0  b36+2     ;
     ls  w0  -4        ;
     rs  w0  b33       ;   screw:=sector(next);
                       ;
     gg  w1  a2        ; set up chpg parameters:
     al  w0  x1        ;   load length:=
     ls  w0  -1        ;     (coresize-ca. first load addr)/2*3;
     wa  w1  0         ;
     sl  w1 (b38)      ;   if load length>max load length then
     rl  w1  b38       ;      load length:=max load length;
c.p1                   ;
     al  w0  3<8       ; coredump:
     rs  w0  b21+0     ;   command:=write;
     al  w0  0         ;   first:=0 (=first byte of core);
     ds  w1  b21+4     ;   size:=load length;
     rl  w0  b6        ;
     se  w0  -1        ;   if coreflag=unchanged then
     jl      j1        ;
     rl  w2  i0        ;
     jl  w3  n1        ;   set position(first sector coredump area);
     al  w2  b22+6     ;
     jl  w3  n0        ;   execute chpg(top(discpg));
     jl      -32       ;    error: sysfault(32);
     rl  w1  b21+4     ;    ok:
j1:                    ;
z.                     ;
     al  w0  1<8       ; load monitor:
     rs  w0  b21+0     ;   command:=read;
     al  w0  p4        ;   first:=load addr(monitor);
     al  w1  x1-p4*3/2 ;   size:=load length-load addr(monitor);
     ds  w1  b21+4     ;
     rl  w2  i1        ;
     jl  w3  n1        ;   set position(first sector of monitor area);
     al  w2  b22+6     ;
     jl  w3  n0        ;   execute chpg(top(chpg));
     jl      -64       ;    error: sysfault(64);
                       ;    ok:
     jl      m5        ;   goto finis;
i0:  p1                ;
i1:  p0                ;
e.                     ; end of discload;
\f


; fpaload.
b.i10,j10 w.
m4:                    ; fpaload
     al  w0  b10       ;   start(chpg):=start(fpaloadpg);
     rs  w0  a7+0      ;
     al  w0  0         ;
     rs  w0  b5        ;   load flag:=load from fpa;
j0:  al  w2  b14+6     ; next:
     jl  w3  n0        ;   execute chpg(top(chpg));
     jl      -4        ;    error: sysfault(4);
                       ;    ok:
     al  w1  512       ;
     wa  w1  b13       ;
     rs  w1  b13       ;   first addr:=first addr+512;
     rl  w2  b17       ;
j2:  sl  w2  x1        ; check next:
     jl      j0        ;   if block top>=top transferred then
     rl  w3  x2        ;     goto next;
     wa  w2  x2        ;   size:=word(block top);
     rs  w2  b17       ;   block top:=block top+size;
     se  w3  0         ;   if size<>0 then
     jl      j2        ;     goto check next;
     rl  w0  b18       ; end:
     rs  w0  b15       ;   status byte:=stop transfer;
     rl  w0  b14       ;
     rs  w0  b11       ;   insert stopcommand in second command;
     al  w2  b11+6     ;
     jl  w3  n0        ;   execute chpg(top(chpg);
     jl      -8        ;   error: sysfault(8);
                       ;    ok:
     jl      m5        ;   goto finis;
e.
 \f


0, r.(:a11-k:)/2+1     ; fill up
0                      ; a11: interrupt word



; start load.
; this block is entered right after load of bootloader.
b.i4,j10 w.
m0:  rl  w0  a11       ; start load:
     se  w0  a12       ;   wait interrupt;
     jl      m0        ;
     dl  w1  a9+2      ; check status:
     dl  w3  a9+6      ;
     sn  w0  b0+6      ;   if next chpg command<>top(init chpg)
     sl  w1  1  ;sew1 0;   or rem char count<>0
     jl      -2        ;   or curr status(bit0)<>0
     sl  w2  0         ;   or event status<>0 then
     sz  w3 (i0);sew3 0;     sysfault(2);
     jl      -2        ;
                       ; find coresize:
     rl  w1  i2        ;   addr:=max core size+2;
     al  w0  -1        ;
j0:  ws  w1  i1        ; next module: addr:=addr-size core module;
                       ;   write(addr,-1);
     do  w0  x1        ;   read(addr,word);
     di  w3  x1        ;   if word<>-1
     sn  w0  -1        ;   or exception=parity error then
     sx      2.111     ;     goto next module;
     jl      j0        ;
     wa  w1  i1        ;   top addr:=addr+size core module;
                       ; check core for initialisation:
     do  w1  0         ;   initiate word(0,2,4,6) of memory;
     do  w1  2         ;
     do  w1  4         ;
     do  w1  6         ;
     al  w2  x1        ;   addr:=top addr;
j1:  al  w2  x2-2048   ; check: addr:=addr-size core module;
     di  w0  x2        ;   read(addr,word);
     sx      2.111     ;   if exception=parity error then
     jl      j2        ;     goto initialize;
     sl  w2 (i1)       ;   if addr<size core module then
     jl      j1        ;     goto check;
     jl      j4        ;   goto end;
                       ;
j2:  ld  w0  -100      ; initialize:
     rs  w0  b6        ;   coreflag:=changed;
     al  w2  b1        ;
j3:  ds  w0  x2+2      ;   for addr:=top(loader) step 4 until top addr do
     al  w2  x2+4      ;     word(addr,addr+2):=0,0;
     se  w2  x1        ;
     jl      j3        ;
j4:                    ; end:
     sh  w1  0         ;   if coresize=8megabytes then
     al  w1  x1-2      ;     top:=top-2;
     gp  w1  a2        ;   coresize:=top;
     rl  w0  a6        ;
     sn  w0  a7-a4<3   ;   if word(8) points out the device number 4 then
     jl      j5        ;     device addr:= device addr(disc)
     rl  w0  b4        ;     else device addr:= device addr(fpa);
     rs  w0  b3        ;
j5:  al  w0  b39       ; start channelprogram used to initialize the
     rs  w0  a7+0      ; first four words of core memory
     al  w2  b40+6     ;
     jl  w3  n0        
     jl      -128      ; sysfault(128)
     rl  w0  a6        ; if device number = 4 then
     sn  w0  a7-a4<3   ;
     jl      m2        ;    goto discload
     jl      m4        ;    else goto fpaload;

i0:  -1-1<23>4         ; status bit4 (blocklength error)
i1:  16<11             ; core module:=16 k words
i2:  8.6777 7776+2     ; max coresize+2
e.

\f


; finis.
b.j1 w.
m5:                    ; finis:
     al  w1  7         ;
j0:  al  w1  x1-1      ;   clear interrupts(0:6);
     gp  w1  a3        ;
     se  w1  0         ;
     jl      j0        ;
     rl  w0  b5        ; enter monitor:
     rs  w0  p4+2      ;   insert loadflag in monitor;
     jl      p4+6      ;   enter monitor in +6;
e.
\f


; execute chpg.
; the procedure starts the channelprogram on the device defined in b3,
; awaits an interrupt for a certain time given by the 'max delay', 
; checks the status delivered in the std status area,
; and returns.
; the procedure return to
;   link+0    in case of errors (w0 = error cause)
;   link+2    in case of normal termination.
; error cause
;      1     exception when starting the channelprogram
;      2     timeout in waiting for the interrupt
;      3     statuserror, which means
;                 top(chpg)<>awaited value
;                 remaining character count<>0
;                 current status(bit0)<>0
;                 event status<>0
;
;        call          return
; w0     -             destroyed or error cause
; w1     -             destroyed
; w2     top(chpg)     destroyed
; w3     link          unchanged
b.i4,j4 w.
n0:  rs  w2  i1        ; execute chpg: save chpg top;
     al  w1  -1        ;
     al  w2  -1        ;
     rs  w2  a11       ;   interrupt word:=-1;
     ds  w2  a9+2      ;
     ds  w2  a9+6      ;   std status area:=-1,-1,-1,-1;
     do     (b3)       ;   start chpg;
     sx      2.111     ;   if ex<>2.000 then
     jl      j1        ;     goto error1;
     al  w1  0         ;   unit:=time of loop (appr. 12.5 microsec);
j0:  al  w1  x1+1      ;   for time:=unit step unit until max delay do
     sl  w1 (i0)       ;     if interrupt then
     jl      j2        ;     goto after interrupt;
     sn  w2 (a11)      ; time expired:
     jl      j0        ;   return to error2;
     dl  w1  a9+2      ; after interrupt:
     sn  w0 (i1)       ;   if next chpg command<>top(chpg)
     se  w1  0         ;   or rem char count<>0
     jl      j3        ;   or curr status(bit0)<>0
     dl  w1  a9+6      ;   or event status<>0 then
     sl  w0  0         ;     goto error3;
     se  w1  0         ;
     jl      j3        ;
     jl      x3+2      ; ok: return to link+2;

j1:  am      1-2       ; error1: errorcause:=1;
j2:  am      2-3       ; error2: errorcause:=2;
j3:  al  w0  3         ; error3: errorcause:=3;
     jl      x3+0      ;   return to link;

i0:  10 000*80         ; max delay:=10 000 msec (unit: 12.5 microsec)
i1:  0                 ; top(chpg)
e.


; procedure set position.
; this procedure computes the cylinder, head and sector number from
; the logical segment number.
; the parameters 'segments per cylinder' , 'segments per track'
; and 'screw' is used.
;        call:         return:
; w0                   destroyed
; w1                   destroyed
; w2     segmentno     destroyed
; w3     link          destroyed
b.w.
n1:  ld  w1  -100      ; set position:
     wd  w2  b31       ;   w2:=cylinder;
     wd  w1  b32       ;   w1:=head;
     sz  w2  2.1       ;   w0:=sector;
     wa  w0  b33       ;   if cylinder odd then
     sl  w0 (b32)      ;     sector:=(sector+screw) mod sectors per track;
     ws  w0  b32       ;
     ls  w2  8         ;
     lo  w1  4         ;   position1:=cylinder<8+head;
     ls  w0  16        ;   position2:=sector<16+0;
     rs  w1  b30+0     ;
     rs  w0  b30+2     ;   position:=position0, position1;
     jl      x3        ; exit: return;
e.

\f



0, r.(:a10+512-k:)/2-19+1 ; fill up

b.i0 w.

i0:  0, r.8            ; register dump

; interrupt stack:
     0                 ; monitor element: (end status)
     i0                ;                  reg dump
     0                 ;                  exception
     0                 ;                  escape
     m0                ;                  monitor call
     0                 ;                  external interrupt

     1<23              ; user element:    monitor status
     i0                ;                  reg dump
     0                 ;                  exception
     0                 ;                  escape

e.

     jd      -1<11+0   ; last word in first segment: change to monitor mode and goto start load;

b1=k/4*4               ; top(loader)

e.                     ; end of load segment;

e.

e.
end
▶EOF◀