Find; Read; Write; Rewind - IBM 5100 Maintenance Information Manual

Hide thumbs Also See for 5100:
Table of Contents

Advertisement

C ""
--
(
(
Find
The find operation locates specific files on the tape.
This must be done before any records can be read from
or written to a file.
To perform the find operation, the tape adapter sends
commands to the tape unit to move the tape and select
the format track (channel 0). The format track indicates
when there is a header record on the data track (channel
1). (A header record contains information about the file;
that is, type of file, file number, and file size.) As the
tape moves, the data and clock signals are detected
from the format track by the tape control card. The tape
adapter generates an interrupt to the controller for each
data bit (every 31.25 /Ls) until a sync byte (hex E7) is
found.
The next byte read from the format track is the record
type, which indicates whether the record is a header
record or a data record.
If the record type byte indicates a data record, the
controller continues to read format records until the
record type byte indicates a header record.
When a header record is indicated, the controller sends
instructions to the tape adapter to read the data track.
The data track is read 1 bit at a time until a sync byte
(hex E7) is found, then it is read 1 byte at a time.
The file number of the header record is read to
determine if this is the file specified. If the file is not
the correct file, instructions are issued by the controller
to continue the search for the correct file.
Read
During a read operation the controller sends instructions
to the tape adapter to search for the user specified file.
After the file is found, the remaining format records and
data records in the file are read.
Format records contain the record sequence number.
The controller verifies that the records are read in the
proper sequence.
Each data record contains data and 2 CRC bytes. The
CRC in the data record is compared to a CRC generated
by the microprogram. If the CRCs are not equal, an
error existed when the data record was read.
Write
During a write operation, the controller sends
instructions to the tape adapter to search for the user
specified file (refer to Search under Operations in this
section). The user must ensure that the specified file
was previously marked and that the file is large enough
to save the user specified information. After the file is
found, the data track is written (the format track is not
written except during a mark operation) with the user
specified information.
The controller formats each data record correctly (refer
to Tape Encoding and Formats in this section) and
instructs the tape unit to read each data record after it
is written to check for a CRC error.
The controller writes a hex 42 in the record type byte of
the last data record to indicate that this record is the
end of the data.
Rewind
The tape unit rewinds when it is given a run and a (not)
forward command. Reverse (clockwise) tape direction
continues until the load point hole is detected, which
indicates that the beginning of tape was found. Reverse
tape motion then stops and forward tape motion begins
to move the load point hole (that coasted past the BOT
LED-PTX when going in reverse) to the forward side of
the BOT LED- PTX. The forward motion moves the tape
only a few inches. The tape is now positioned correctly
to read the first file.
Backspace
During a backspace operation, tape movement is in the
reverse (clockwise) direction. The tape unit reads the
format track backwards until a record byte indicating a
header is read. Then the tape unit stops tape movement
in position to read the entire file.
Tape
4-39

Hide quick links:

Advertisement

Table of Contents
loading

Table of Contents