; HP-IB 7970E Offline Diagnostic (D7970). ; Using DUS revision 2913. echo echo echo echo echo -------------------------------------- echo D7970 - HP-IB 7970E Offline Diagnostic echo -------------------------------------- echo echo Configuring the simulation environment. ; Configure the diagnostic environment. ; ; DUS is operating with the first set of four tape units set for bus address 0 ; and attached to the GIC on channel 9. We define a second tape unit set and ; attach it to the same GIC as bus address 1. set MA COUNT=2 set MAB BUS=1,REALTIME set MAB0 REEL=600 set MAB1 REEL=600 set MAB2 REEL=600 set MAB3 REEL=600 ; Run the HP-IB 7970E diagnostic. echo echo Starting diagnostic sections 1-3. echo echo ":" reply "AID\r" go until "\r\n> " ; reply "LOAD D7970S13\r" ; Fix Step 305 bug. ; ; Step 305 tests the End/Abort command option by starting a 1024-byte Write ; Record burst-mode operation and, while it is executing, issuing an HIOP ; instruction that aborts the DMA transfer. Then, while the tape is still ; writing (with data underrun), it issues the End/Abort command and then reads ; the status and expects the unit to be online with no other status. ; ; The bug is in AID. When it encounters the HIOP command, it executes an HIOP ; instruction but also marks the device to reject any further interrupts. The ; problem is that if the HIOP occurs in the middle of a burst, the channel will ; not halt until the burst is complete and the channel program reaches the ; following WAIT instruction. If this occurs, HIOP returns CCG to indicate that ; the program will halt later, and when it does halt, an interrupt request is ; asserted. But because the HIOP executor has marked the device as "finished," ; the interrupt causes an AID error, "Interrupt from Illegal Device." This ; error has been reproduced on a Series 37, so it is not a simulator fault. ; ; The workaround, located just before the End/Abort channel program is initiated, ; clears the "bad interrupt" reserved variable that causes the AID error. go until "0 " ; reply '7862 LET BADINTP:=0\r' ; Execute diagnostic sections 1-3. go until "0 " ; reply "RUN\r" go until "7970E channel number? " ; reply "9\r" go until "7970E device number? " ; reply "1\r" go until "Number of passes\r\n? " ; reply "1\r" ; Respond to "Mount a tape with write ring on each unit to be tested." ; "Set others offline, type go." attach -N MAB0 scratch.0.tape attach -N MAB1 scratch.1.tape attach -N MAB2 scratch.2.tape attach -N MAB3 scratch.3.tape go until ">" ; reply "GO\r" ; Respond to "Unit 0 will be tested." ; "Unit 1 will be tested." ; "Unit 2 will be tested." ; "Unit 3 will be tested." ; " If OK type 0, else 1? " go until "? " ; reply "0\r" ; Respond to "To output messages to: LP type 0, console 1? " go until "? " ; reply "1\r" ; Exit sections 1-3. go until "\r\n>" ; reply "EXIT\r" ; Execute diagnostic sections 4-5. echo echo echo Starting diagnostic sections 4-5. echo echo ">" go until "0 " ; reply "LOAD D7970S45\r" go until "?" ; reply "YES\r" ; Fix Step 504 bug. ; ; Step 504 executes 100 sets of Write Record, Read Record Backward, and Read ; Record commands in a loop, interleaving each set among the tested units. ; After each unit has performed a Write Record set and a Read Record set, the ; data read is compared to the data written, and any discrepancies are reported. ; After each Write Record set, a buffer comparison is made, and the read buffer ; is zeroed in preparation for the next read. ; ; The bug is in the diagnostic. For the first ten iterations, the comparison ; is skipped to give each unit a chance to write and read. But the read buffer ; clear is performed after every write. So with three units defined, the ninth ; iteration performs a Read Record set on unit 1, a Read Record Backward set on ; unit 2, and a Write Record operation on unit 3. The unit 1 set filled the ; read buffer, but the unit 3 set cleared it. ; ; The tenth iteration starts with a Write Record operation on unit 1, and then ; a buffer comparison is made. However, because the read buffer was cleared at ; the end of the ninth iteration, the comparison fails, and errors are ; reported. ; ; The fix moves the read buffer clear from after the Write Record operation to ; just prior to the Read Buffer operation. That way, the buffer is not zeroed ; until just before it is refilled. go until "7880 " ; reply "MODIFY 7435/7445\r" go until "0\r\n " ; reply "R7331\r" go until "0\r\n " ; reply "\r" go until "0\r\n " ; reply "R7332\r" go until "0\r\n " ; reply "\r" go until "5\r\n " ; reply "R7333\r" go until "5\r\n " ; reply " R7331\r" go until "1\r\n " ; reply "\r" go until "80 " ; reply "RUN\r" ; Run the diagnostic. go until "7970E channel number? " ; reply "9\r" go until "7970E device number? " ; reply "1\r" go until "Number of passes? " ; reply "1\r" ; Respond to "Mount a tape with write ring on each unit to be tested." ; "Set others offline, type go." go until ">" ; reply "GO\r" ; Respond to "Unit 0 will be tested." ; "Unit 1 will be tested." ; "Unit 2 will be tested." ; "Unit 3 will be tested." ; " If OK type 0, else 1? " go until "? " ; reply "0\r" ; Respond to "To output messages to: LP type 0, console 1? " go until "? " ; reply "1\r" ; Exit sections 4-5. go until "\r\n>" ; reply "EXIT\r" ; Execute diagnostic sections 6 and 8. echo echo echo Starting diagnostic sections 6 and 8. echo echo ">" go until "0 " ; reply "LOAD D7970S68\r" go until "?" ; reply "YES\r" go until "0 " ; reply "RUN\r" go until "7970E channel number? " ; reply "9\r" go until "7970E device number? " ; reply "1\r" ; Respond to "SECTION 6 (Interactive). Enter: 0-Execute, 1-Skip" ; "? " go until "? " ; reply "0\r" ; Respond to "Put a magnetic tape with write ring onto unit under test" ; " and push LOAD, ON-LINE and UNIT#0" go until ">" echo echo echo sim> attach -N MAB0 scratch.0.tape echo sim> go echo attach -N MAB0 scratch.0.tape echo ">" reply "GO\r" ; Respond to "Reset any another tape unit connected to the same controller" go until ">" set MAB1 OFFLINE set MAB2 OFFLINE set MAB3 OFFLINE reply "GO\r" ; Respond to "Push RESET" go until ">" echo echo echo sim> set MAB0 OFFLINE echo sim> go echo set MAB0 OFFLINE echo ">" reply "GO\r" ; Respond to "Push ON-LINE" go until ">" echo echo echo sim> set MAB0 ONLINE echo sim> go echo set MAB0 ONLINE echo ">" reply "GO\r" ; Respond to "Push UNIT 1" go until ">" echo echo echo sim> detach MAB0 echo sim> attach MAB1 scratch.0.tape echo sim> go echo detach MAB0 attach MAB1 scratch.0.tape echo ">" reply "GO\r" ; Respond to "Push RESET" go until ">" echo echo echo sim> set MAB1 OFFLINE echo sim> go echo set MAB1 OFFLINE echo ">" reply "GO\r" ; Respond to "Push ON-LINE" go until ">" echo echo echo sim> set MAB1 ONLINE echo sim> go echo set MAB1 ONLINE echo ">" reply "GO\r" ; Respond to "Push UNIT 2" go until ">" echo echo echo sim> detach MAB1 echo sim> attach MAB2 scratch.0.tape echo sim> go echo detach MAB1 attach MAB2 scratch.0.tape echo ">" reply "GO\r" ; Respond to "Push RESET" go until ">" echo echo echo sim> set MAB2 OFFLINE echo sim> go echo set MAB2 OFFLINE echo ">" reply "GO\r" ; Respond to "Push ON-LINE" go until ">" echo echo echo sim> set MAB2 ONLINE echo sim> go echo set MAB2 ONLINE echo ">" reply "GO\r" ; Respond to "Push UNIT 3" go until ">" echo echo echo sim> detach MAB2 echo sim> attach MAB3 scratch.0.tape echo sim> go echo detach MAB2 attach MAB3 scratch.0.tape echo ">" reply "GO\r" ; Respond to "Push RESET" go until ">" echo echo echo sim> set MAB3 OFFLINE echo sim> go echo set MAB3 OFFLINE echo ">" reply "GO\r" ; Respond to "Push ON-LINE" go until ">" echo echo echo sim> set MAB3 ONLINE echo sim> go echo set MAB3 ONLINE echo ">" reply "GO\r" ; Respond to "Push UNIT 0,1,2, and 3" go until ">" echo echo echo sim> detach MAB3 echo sim> attach MAB0 scratch.0.tape echo sim> detach MAB0 echo sim> attach MAB1 scratch.0.tape echo sim> detach MAB1 echo sim> attach MAB2 scratch.0.tape echo sim> detach MAB2 echo sim> attach MAB3 scratch.0.tape echo sim> go echo detach MAB3 attach MAB0 scratch.0.tape detach MAB0 attach MAB1 scratch.0.tape detach MAB1 attach MAB2 scratch.0.tape detach MAB2 attach MAB3 scratch.0.tape echo ">" reply "GO\r" ; Respond to "Push UNIT 0" go until ">" echo echo echo sim> detach MAB3 echo sim> attach MAB0 scratch.0.tape echo sim> go echo detach MAB3 attach MAB0 scratch.0.tape echo ">" reply "GO\r" ; Respond to "Push UNIT 1" go until ">" echo echo echo sim> detach MAB0 echo sim> attach MAB1 scratch.0.tape echo sim> go echo detach MAB0 attach MAB1 scratch.0.tape echo ">" reply "GO\r" ; Respond to "Push UNIT 2" go until ">" echo echo echo sim> detach MAB1 echo sim> attach MAB2 scratch.0.tape echo sim> go echo detach MAB1 attach MAB2 scratch.0.tape echo ">" reply "GO\r" ; Respond to "Push UNIT 3" go until ">" echo echo echo sim> detach MAB2 echo sim> attach MAB3 scratch.0.tape echo sim> go echo detach MAB2 attach MAB3 scratch.0.tape echo ">" reply "GO\r" ; Respond to "Please remove write ring and remount tape." go until ">" echo echo echo sim> detach MAB3 echo sim> attach -R MAB3 scratch.0.tape echo sim> go echo detach MAB3 attach -R MAB3 scratch.0.tape echo ">" reply "GO\r" ; Respond to "Check if RESET light is ON! Then:" ; ; "Put tape with write ring onto drive, and push LOAD, ON-LINE" ; "and UNIT 0" ; ; The diagnostic has issued a Rewind Offline command, and the tape is moving. ; Before dismounting the tape to add the write ring, we must wait for the rewind ; to complete. As the simulator has no method of doing this, we wait for a ; period of time consistent with the rewind distance to ensure that the tape has ; stopped before we dismount and remount the tape. go until ">" go for 5 seconds echo echo echo sim> detach MAB3 echo sim> attach MAB0 scratch.0.tape echo sim> go echo detach MAB3 attach MAB0 scratch.0.tape echo ">" reply "GO\r" ; Respond to "Is tested Unit#0 MASTER? (Y/N)" ; "? " go until "\r\n? " ; reply "Y\r" ; Respond to "Turn-OFF the power on tape unit" go until ">" set MAB0 OFFLINE reply "GO\r" ; Respond to "Turn-ON the power on tape unit and push LOAD and ON-LINE" go until ">" reset -P MAB set MAB0 ONLINE reply "GO\r" ; Section 6 is complete, and the diagnostic returns to start it again. ; ; Respond to "SECTION 6 (Interactive). Enter: 0-Execute, 1-Skip" ; "? " go until "? " ; reply "1\r" ; Respond to "SECTION 7 (Maintenance WRITE/READ). Enter: 0-Execute, 1-Skip" ; "? " go until "? " ; reply "1\r" ; Respond to "SECTION 8 (Tape Media Test). Enter: 0-Execute, 1-Skip" ; "? " go until "? " ; reply "0\r" ; Respond to "Put a magnetic tape with WRITE RING onto unit under test" ; " and push LOAD, ON-LINE and UNIT#0" go until ">" ; reply "GO\r" ; Respond to "Reset any another tape unit connected to the same controller" go until ">" ; reply "GO\r" ; Respond to "Test Section 8 (Steps 801-814) is complete" go until ">" ; reply "GO ,,1\r" ; Exit go until "0 " ; reply "EXIT\r" ; End the of diagnostic. ; ; Respond to "Confirm you want to ERASE the current program(Y or N)?" go until "?" ; reply "YES\r" go until ":" ; Restore the hardware configuration. detach MAB0 delete scratch.0.tape delete scratch.1.tape delete scratch.2.tape delete scratch.3.tape set MA COUNT=1