This is an old revision of the document!
Table of Contents
Tape (Dis)Assembly
The TDisassemble
and TAssemble
subcommands are complementary functions to each other.
TDisassemble
decomposes NOS blocked tape records
into workstation-based files. These files (and the resulting recipe
/map
file generated by TDisassemble
may then be used as input to the TAssemble
subcommand which will
reconstitute the tape.
TDisassemble
These subcommand are replacements for the old tools which convert .TAP
images into individual files from a NOS I-format image and vice-versa.
nosicreate
tapextractIrec
tapextractSIrec
tapgenIrec
tapgenSIrec
gettap
The general form of the TAssemble
subcommand is:
nosutils tassemble -c<ControlFile> <TapeFileName>
The general form of the TDisassemble
subcommand is:
nosutils tdisassemble -c<ControlFile> -d<OutputDirectory> [-4 | -D] <TapeFileName>
Where:
ControlFile
specifies the name of the text file containing the “recipe” needed to reconstruct the tape from individual host-based files.TapeFileName
specifies the name of the.TAP
file to be generated from theControlFile
OutputDirectory
specifies the name of the directory from/into which the files will be imported/exported.
Examples: TDisassemble / TAssemble
The following are annotated examples of round-trip Disassemble/Assemble of a Deadstart Tape. The following are assumed:
- The
nosutils
andgzip
commands are located in the PATH. - There already exists a target directory
ds.files
. - The user is familar with the structure of ANSI-labeled tapes.
All three of these examples are performed as written here and the same directory may be used because the
Invoke TDisassemble
with the default option of simple binary file extraction from the tape:
nosutils tdisassemble -dds.files -cdeadstart.recipe.txt ds.tap
With the above options, the files(records) are extracted from the deadstart tape called ds.tap
and each file(record) found is written to the directory ds.files
with a filename prefix rec
. Each recnnnnn
file (with no file extension) is a packed image exactly as written to the .tap
file image (2, big-endian, 60-bit words per 15 bytes).
nosutils tdisassemble -4 -dds.files -cdeadstart.recipe.4.txt ds.tap
With the above options, the files(records) are extracted from the deadstart tape called ds.tap
and each file(record) found is written to the directory ds.files
with a filename prefix rec
. Each recnnnnn
file (with a .b64
extension) is an image of little-endian 64-bit words containing each 60-bit value as written to the .tap
file image (1, 60-bit word per 8 bytes).
nosutils tdisassemble -D -dds.files -cdeadstart.recipe.D.txt ds.tap
With the above options, the files(records) are extracted from the deadstart tape called ds.tap
and each file(record) found is written to the directory ds.files
with a filename prefix rec
. Each recnnnnn
file (with a .txt
extension) is an image of CDC Display Code representing each 6-bit value as an 8-bit ASCII character.
In each case above, the text (recipe) file deadstart.recipe(.4 | .D).txt
is written which describes the 'recipe' needed to reconstruct the tape image, verbatim.
Internal Checksums/Sequence numbers
When written to individual files, all sequencing/checksum information is stripped from the records and those are rewritten during TAssemble
.
Recipe File Format
Each tape record is written to a host file and a record is written to the recipe file which tells the TAssemble
subcommand how to re-build the tape image.
"legacy" Support
The original command-line utilities only supported the binary file(record) extraction to host files (no file extension). The two additional formats have been added to nosutils
and will not be recognized/supported by the older individual command-line utilities.
The recipe file resembles the following for the sample deadstart tape, which was generated by the first example above.
FILE= | FILEDC= | FILE64=
The statements FILE=
or FILEDC=
or FILE64=
indicate the name of the input file in the local directory, or in that directory indicated using the -d
switch. This filename must contain no spaces and all information following the first space is treated as “comments”.
For each file, the TDisassemble
function writes a 20 character (2-CM Words) Display Code translation as an eye-catcher along with other data such as the number of bytes (decimal) found in the block, and the block number (decimal).
EOR
The EOR
record is indicated only by the presence of the first three characters EOR
. The remainder of the line is considered “commentary”. TDisassemble
writes the two-digit checksum “level” number, the octal and decimal record number, as well as the block sequence number for information only.
EOF
The EOF
record is indicated only by the presence of the first three characters EOF
. The remainder of the line is considered “commentary”. TDisassemble
writes the relative file number (decimal) following the characters EOF
.
LABEL=
The LABEL=
statement is a double-quote (“), quoted string containing the actual ANSI label string (80-characters). Any characters following the final double-quote mark are considered to be “commentary”.
TAssemble
TAssemble
is the functional inverse of TDisassemble and accepts the -d
(Input directory) switch and the -c
control/recipe file input switch ( required ).
Examples
To invert the TDisassemble
examples above, the commands are simple:
nosutils tassemble -dds.files -cdeadstart.recipe.txt dsX.tap
nosutils tassemble -dds.files -4 -cdeadstart.recipe.txt ds4.tap nosutils tassemble -dds.files -D -cdeadstart.recipe.txt dsD.tap
If none of the files contained in directory ds.files
was modified, each of the above commands should generate a tape which is a binary duplicate of the original input tape ds.tap
.