; Rebuild system.
expect "\r\n." send "DELETE HDWCNF.MAC,TTYCNF.MAC,NETCNF.MAC\r"; continue
expect "\r\n." send "DELETE COMMON.REL,COMDEV.REL,COMMOD.REL\r"; continue
expect "\r\n." send "RUN MONGEN\r"; continue
expect "\r\n/" continue
expect "(PROMPT,SHORT,LONG)" send "PROMPT\r"; continue
expect "Which GEN(HDW,TTY,NET,F):" send -t after=10000 "HDW\r"; continue
expect "Output(DSK:HDWCNF.MAC):" send  -t after=10000 "\r"; continue
if "%CPU%" == "KA" 'expect "DECsystem10(1040,1050,1055,1070,1077,1080,1088,1091):" send "1050\r"; continue'
if "%CPU%" == "KI" 'expect "DECsystem10(1040,1050,1055,1070,1077,1080,1088,1091):" send "1070\r"; continue'
if "%CPU%" == "KL" 'expect "DECsystem10(1040,1050,1055,1070,1077,1080,1088,1091):" send "1091\r"; continue'
if "%CPU%" == "KA" 'expect "System name:" send "KA603\r"; continue'
if "%CPU%" == "KI" 'expect "System name:" send "KI603\r"; continue'
if "%CPU%" == "KL" 'expect "System name:" send "KL603\r"; continue'
if "%CPU%" == "KI" 'expect "Do you want the virtual memory facility" send "NO\r"; continue'
if "%CPU%" == "KL" 'expect "Do you want the virtual memory facility" send "YES\r"; continue'
if "%CPU%" == "KA" 'expect "CPU0 serial #" send "40\r"; continue'
if "%CPU%" == "KI" 'expect "CPU0 serial #" send "514\r"; continue'
if "%CPU%" == "KL" 'expect "CPU0 serial #" send "1025\r"; continue'
expect "# DK10's on CPU0" send  "1\r"; continue
expect "Exclude Monitor overhead from user run time(Y,N):" send "Y\r"; continue
if "%CPU%" == "KL" 'expect "EBOX/MBOX runtime accounting?(y,n):" send "N\r"; continue'
expect "High precision time accounting(Y,N):" send "N\r"; continue
expect "DK10 software(Y,N):" send "Y\r"; continue
if "%CPU%" != "KL" 'expect "Data Channels" send "1\r"; continue'
if "%CPU%" == "KL" 'expect "Data Channels" send "1\r"; continue'
if "%CPU%" != "KL" 'expect "Channel 0 Type (DF10,DF10C,DX10,RH20):" send "DF10\r"; continue'
if "%CPU%" == "KL" 'expect "Channel 0 Type (DF10,DF10C,DX10,RH20):" send "DF10\r"; continue'
if "%CPU%" == "KL" 'expect "Channel 1 Type (DF10,DF10C,DX10,RH20):" send "RH20\r"; continue'
if "%CPU%" == "KL" 'expect "Channel 2 Type (DF10,DF10C,DX10,RH20):" send "RH20\r"; continue'
if "%CPU%" != "KL" 'expect "# RC10s(0-2):" send "0\r" ; continue'
if "%CPU%" == "KL" 'expect "# RC10s(0-2):" send "0\r" ; continue'
if "%CPU%" != "KL" 'expect "# RH10S for RS04\'S(0-3):" send "0\r"; continue'
if "%CPU%" == "KL" 'expect "# RH10S for RS04\'S(0-3):" send "0\r"; continue'
if "%CPU%" != "KL" 'expect "# RH10S for RP04\'S, RP06\'S(0-3):" send "1\r"; continue'
if "%CPU%" == "KL" 'expect "# RH10S for RP04\'S, RP06\'S(0-3):" send "1\r"; continue'
if "%CPU%" == "KL" 'expect "# RH20S for RP04\'S, RP06\'S(0-1):" send "1\r"; continue'
expect "# Units on RPA(1-8):" send "8\r"; continue;
if "%CPU%" == "KL" 'expect "# Units on RPB(1-8):" send "8\r"; continue;'
if "%CPU%" != "KL" 'expect "# RP10s(0-3):" send "1\r"; continue'
if "%CPU%" != "KL" 'expect "# Units on DPA(1-8):" send "8\r"; continue'
if "%CPU%" != "KL" 'expect "# TM10Bs(0-2):" send "1\r"; continue'
if "%CPU%" != "KL" 'expect "# RH10\'s for TM02\'S (0-2):" send "0\r"; continue'
if "%CPU%" == "KL" 'expect "# TM10Bs(0-2):" send "0\r"; continue'
;if "%CPU%" != "KL" 'expect "# RH10\'s for TM02\'S (0-2):" send "1\r"; continue'
if "%CPU%" == "KL" 'expect "# RH20\'s for TM02\'S (0-1):" send "0\r"; continue'
if "%CPU%" == "KL" 'expect "# RH20\'s for TM02\'S (0-1):" send "0\r"; continue'
if "%CPU%" == "KL" 'expect "# RH20\'s for TM02\'S (0-1):" send "1\r"; continue'
;if "%CPU%" != "KL" 'expect "How many TM02\'s on RH10 # 0 (1-8):" send "1\r"; continue'
if "%CPU%" == "KL" 'expect "How many TM02\'s on RH20 # 2 (1-8):" send "1\r"; continue'
expect "How many drives on TM02 0 (1-8)" send "2\r"; continue
if "%CPU%" != "KL" 'expect "# TC10Cs(0-1):" send "0\r"; continue'
expect "# TM10As(0,0-2):" send "0\r"; continue
expect "# Units on MTA(1-8):" send "2\r"; continue
expect "For controller MTA" send "\r"; continue
expect "For controller MTA" send "0-1\r\r"; continue
expect "# Jobs(1-511):" send "16\r"; continue;
expect "Max. K of core For each job(0,0-256): " send "\r"; continue
expect "# K total system core" send "128\r"; continue
if "%CPU%" == "KL" 'expect "# DTEs on CPU0(2,1-4):" send "1\r"; continue'
if "%CPU%" == "KI" 'expect "Max. PAGES of core For each job" send "\r"; continue'
if "%CPU%" == "KL" 'expect "Max. PAGES of core For each job" send "\r"; continue'
expect "Clock ticks per second(60,50):" send "60\r"; continue
expect "# Real-time devices(0,0-77):" send "0\r"; continue
expect "Allow jobs to be locked in core(Y,N):" send "Y\r"; continue
if "%CPU%" == "KL" 'expect "# PAGES min guaranteed among jobs not locked in core" send "\r"; continue'
if "%CPU%" == "KI" 'expect "# PAGES min guaranteed among jobs not locked in core" send "\r"; continue'
if "%CPU%" == "KA" 'expect "# K min guaranteed among jobs not locked in core(0,0-256):" send "\r"; continue'
expect "# High priority queues(0,0-15):" send "\r"; continue
expect "CCL commands to stay in core(Y,N):" send "Y\r"; continue
expect "Meter(Y,N):" send "N\r"; continue
expect "SYSCHK(Y,N):" send "N\r"; continue
expect "MSGSER(Y,N):" send "N\r"; continue
expect "PSISER(Y,N):" send "N\r"; continue
expect "IPCF(Y,N):" send "N\r"; continue
expect "ENQ/DEQ(Y,N):" send "N\r"; continue
expect "# I/O Bus CDRs(1,0-2):" send "0\r"; continue
expect "CDP(Y,N):" send "N\r"; continue
expect "CP10D(Y,N):" send "N\r"; continue
expect "DIS(Y,N):" send "N\r"; continue
if "%CPU%" == "KL" 'expect "# line printers on the master front end on " send "0\r"; continue'
if "%CPU%" == "KL" 'expect "# card readers on the master front end on" send "0\r"; continue'
expect "LPT0 Lower case(Y,N):" send "Y\r"; continue
expect "PLTS(0,0-2):" send "0\r"; continue
expect "# TD10s(1,0-2):" send "0\r"; continue
expect "I/O Bus LPTs(1,0-3):" send "0\r"; continue
expect "PLTS(0,0-2):" send "0\r"; continue
expect "PTP(Y,N):" send "N\r"; continue
expect "PTR(Y,N):" send "N\r"; continue
expect "# PTYs(20,0-510):" send "\r"; continue
expect "DC44(Y,N):" send "N\r"; continue
expect "# of DA28s(0,0-4):" send "0\r"; continue
expect "# DAS78'S(0,0-8):" send "0\r"; continue
expect 'Decimal "symbol,value"' send "LIMLVL,2\rSTDENS,3\rFLCDEF,0\r\r"; continue
expect 'Octal "symbol,value"' send "\r"; continue
expect 'SIXBIT "symbol,value"' send "\r"; continue
expect 'Type "device-mnemonic,PI-channel" for special devices' send "\r"; continue
expect 'Type "device-mnemonic,PI-channel,no.-of-devices"' send "\r"; continue
expect 'Type "device-mnemonic,PI-channel,highest-ac-to-save"' send "\r"; continue
expect "Which GEN(HDW,TTY,NET,F):" send "TTY\r"; continue
expect "Output(DSK:TTYCNF.MAC):" send "\r"; continue
if "%CPU%" == "KA" 'expect "DECsystem10(1040,1050,1055,1070,1077,1080,1088,1091):" send "1050\r"; continue'
if "%CPU%" == "KI" 'expect "DECsystem10(1040,1050,1055,1070,1077,1080,1088,1091):" send "1070\r"; continue'
if "%CPU%" == "KL" 'expect "DECsystem10(1040,1050,1055,1070,1077,1080,1088,1091):" send "1091\r"; continue'
expect "How many DC10s(1,0-2):" send "0\r"; continue
expect "How many DC68s(1,0-2):" send "0\r"; continue
expect "How many DC76s(1,0-8):" send "0\r"; continue
if "%CPU%" == "KL" 'expect "# terminals on the master front end on" send "16\r"; continue'
expect "OPR octal line #" send "CTY\r"; continue
expect "Data set lines" send "\r"; continue
expect "Lines with hardware tabs" send "\r"; continue
expect "Remote lines" send "\r"; continue
expect "Local copy lines" send "\r"; continue
expect "Half duplex lines" send "\r"; continue
expect "Slaves" send "\r"; continue
expect "Lines with hardware form feed" send "\r"; continue
expect "Lines which run INITIA at startup" send "\r"; continue
expect "Filler class codes(M-N,P)" send "\r"; continue
expect "Which GEN(HDW,TTY,NET,F):" send "NET\r"; continue
expect "Output(DSK:NETCNF.MAC):" send "\r"; continue
expect "Network software(Y,N):" send "N\r"; continue
expect "Which GEN(HDW,TTY,NET,F):" send "F\r"; continue
expect "Output(DSK:F.MAC):" send "\r"; continue
if "%CPU%" == "KA" 'expect "Feature set(TINY,KALUG,KILUG,KAFULL,KIFULL,KLFULL):" send " KAFULL\r"; continue'
if "%CPU%" == "KI" 'expect "Feature set(TINY,KALUG,KILUG,KAFULL,KIFULL,KLFULL):" send " KIFULL\r"; continue'
if "%CPU%" == "KL" 'expect "Feature set(TINY,KALUG,KILUG,KAFULL,KIFULL,KLFULL):" send " KLFULL\r"; continue'
expect "Standard setting(YES,NO,LIST,EXPLAIN):" send " YES\r"; continue
expect "Which GEN(HDW,TTY,NET,F):" send "\3"; continue
expect "\r\n." send "COMPILE F/COMP,S/COMP,NETPRM/COMP,HDWCNF+NETCNF+TTYCNF+<COMMON,COMDEV,COMNET,COMMOD>\r"; continue
expect "\r\n." send "R LINK\r"; continue
if "%CPU%" == "KA" 'expect "\r\n*" send "/NOINITIAL /HASH:6000 MONKA/SAV,MONKA/MAP = /LOCALS -\r/MAXCOR:60K -\r,COMMON,COMDEV,COMMOD,TOPA10 /SEARCH /GO\r"; continue'
if "%CPU%" == "KI" 'expect "\r\n*" send "/NOINITIAL /HASH:6000 MONKI/SAV,MONKI/MAP = /LOCALS -\r/MAXCOR:60K -\r,COMMON,COMDEV,COMMOD,TOPI10 /SEARCH /GO\r"; continue'
if "%CPU%" == "KL" 'expect "\r\n*" send "/NOINITIAL /HASH:6000 MONKL/SAV,MONKL/MAP = /LOCALS -\r/MAXCOR:80K -\r,COMMON,COMDEV,COMMOD,TOPW10 /SEARCH /GO\r"; continue'
