K12MIT on PDP-12

Christian Corti cc at informatik.uni-stuttgart.de
Fri Nov 26 03:43:07 CST 2021


On Thu, 25 Nov 2021, Christian Corti wrote:
> Just tried without SerialDisk... no difference. K12MIT is broken on the 
> PDP-12.

I've found the bug. Charles Lasner broke PDP-12 support (and probably also 
older PDP-8 models like 8/I) with his additions to support the DECmate 
family. The location is at 0206, labelled SETBAUD. This should be a NOP on 
standard systems, but is overlayed by an IOT to set the baud rate on a 
DECmate 1. This results in a 6413 instruction (because I have assembled it 
for the second serial port on 40/41). This instruction always skips (as 
the transmitter done flag is always set), thus jumping into a 4411 that is 
the address of a CRLF to be printed but executed as a JMS into nirvana.
The very same code runs fine on a PDP-8/E with a KL8/E interface that 
apparently either ignores this instruction or, by other means, has the 
flag cleared.

If patching location 0206 to 7000 (NOP), K12MIT will run on a PDP-12.

Sending files works, but receiving seems to be broken. Most of the times, 
the sending Kermit aborts the transfer to the PDP-12 with a 
out-of-window-NACK error (confirmed by looking at the protocol debug log). 
K12MIT sends a NACK to a previous packet that it already ACK'ed *after* 
receiving the next data packet.

Here's the code fragment:

1827   000200  5777  CLOOP,  JMP I   (INITIALIZE)    /**** INITIALIZED **** CLA CLL          /024 CJL
1828   000201  4577          JMS I   [CRESET]        /RESET CONSOLE ROUTINE STUFF
1829   000202  3002          DCA     ABFLAG          /CLEAR ABORT FLAG                       /044 CJL
1830   000203  3105          DCA     REMWAIT         /CLEAR REMOTE FLOW CONTROL WAIT         /049 CJL
1831   000204  4324  CLDMZAP,JMS     DMINIT          /INITIALIZE DECMATE PORT                /048 CJL
1832
1833                 /       THE  PREVIOUS  INSTRUCTION  IS  FOR  DECMATE  OPERATION  ONLY.    THE  DEFAULT
1834                 /       INSTRUCTION IS FOR KL8 INTERFACES ONLY.
1835
1836           0204          *CLDMZAP                /OVERLAY DECMATE CODE                   /048 CJL
1837
1838   000204  7000  CLDMZAP,NOP                     /DON'T INITIALIZE DECMATE PORT          /048 CJL
1839   000205  1007          TAD     RATE            /GET BAUD RATE
1840   000206  6363  SETBAUD,MSB                     /SET REMOTE BAUD RATE                   /050 CJL
1841
1842                 /       THE PREVIOUS INSTRUCTION IS FOR DECMATE II OPERATION ONLY.      /050 CJL
1843
1844           0206          *SETBAUD                /OVERLAY DECMATE II CODE                /050 CJL
1845
1846   000206  7000  SETBAUD,NOP                     /NOT APPLICABLE ON DECMATE I            /050 CJL
1847
1848                 /       THE  PREVIOUS  INSTRUCTION  IS  FOR DECMATE I OPERATION  ONLY.    THE  DEFAULT
1849                 /       INSTRUCTION IS FOR KL8 INTERFACES ONLY.
1850
1851           0206          *SETBAUD                /OVERLAY DECMATE I CODE                 /050 CJL
1852
1853   000206  6413  SETBAUD,RSBIOT                  /SET REMOTE BAUD RATE                   /050 CJL
1854   000207  4576          JMS I   [SCRIBE]        /DO A                                   /025 CJL
1855   000210  4411          CRLF                    /<CR>, <LF>                             /025 CJL
1856   000211  4576          JMS I   [SCRIBE]        /GIVE THEM THE                          /025 CJL
1857   000212  4457          PRMTMSG                 /PROMPT MESSAGE                         /025 CJL
1858   000213  4776          JMS I   (LININP)        /GET INPUT LINE FROM USER


Christian


More information about the cctech mailing list