Wizard of Odd codex

💠Laissez Les Bon Code Roulez💠

User Tools

Site Tools


utilities:nosutils:tdisassemble.tassemble

This is an old revision of the document!


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 the ControlFile
  • 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 and gzip 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=rec00001 ;::n::::::ipl::::::: 480 bytes,block = 1 FILE=rec00002 ;::n::::::cd7::::::: 924 bytes,block = 2 FILE=rec00003 ;::n::::::cd6::::::: 930 bytes,block = 3 FILE=rec00004 ;::n::::::cd3::::::: 819 bytes,block = 4 FILE=rec00005 ;::n::::::cd4::::::: 939 bytes,block = 5 FILE=rec00006 ;::n::::::cd5::::::: 954 bytes,block = 6 FILE=rec00007 ;::n::::::cd2::::::: 924 bytes,block = 7 FILE=rec00008 ;::n::::::cd1::::::: 945 bytes,block = 8 FILE=rec00009 ;::n::::::plt::::::: 135 bytes,block = 9 FILE=rec00010 ;::n::::::edc::::::: 480 bytes,block = 10 FILE=rec00011 ;::n::::::ccd::::::: 1260 bytes,block = 11 FILE=rec00012 ;::n::::::ioq::::::: 3810 bytes,block = 12 FILE=rec00013 ;::n::::::app::::::: 2100 bytes,block = 13 ... FILE=rec02672 csorts::::(* --- cso 2310 bytes,block = 4020 FILE=rec02673 complex ::(* --- com 1185 bytes,block = 4021 FILE=rec02674 csimage ::(* --- csi 345 bytes,block = 4022 FILE=rec02675 csort ::::(* --- cso 2535 bytes,block = 4023 FILE=rec02676 double::::(* --- dou 699 bytes,block = 4024 FILE=rec02677 dump::::::(* --- dum 279 bytes,block = 4025 FILE=rec02678 fread ::::(* --- fre 495 bytes,block = 4026 ... FILE=rec05272 ;::n::::::loader:::: 43005 bytes,block = 9548 FILE=rec05273 ;::n::::::loadc::::: 3399 bytes,block = 9549 FILE=rec05274 ;::n::::::loadg::::: 8679 bytes,block = 9552 FILE=rec05275 ;::n::::::loads::::: 18699 bytes,block = 9557 FILE=rec05276 ;::n::::::loadz::::: 35214 bytes,block = 9567 FILE=rec05277 ;::n::::::loadm::::: 14739 bytes,block = 9571 FILE=rec05278 ;::n::::::loadu::::: 33549 bytes,block = 9580 FILE=rec05279 ;::n::::::loaduc:::: 3519 bytes,block = 9581 FILE=rec05280 ;::n::::::loadum:::: 10149 bytes,block = 9584 FILE=rec05281 ;::n::::::trap:::::: 17055 bytes,block = 9589 FILE=rec05282 ;::n::::::segres:::: 4824 bytes,block = 9591 EOR00 record 022567 oct 9591 dec 0 bytes,block = 9592 EOR00 record 022570 oct 9592 dec 0 bytes,block = 9593 EOR00 record 022571 oct 9593 dec 0 bytes,block = 9594 EOR00 record 022572 oct 9594 dec 0 bytes,block = 9595 FILE=rec05283 ;::n::::::mrec:::::: 20274 bytes,block = 9601 EOR00 record 022601 oct 9601 dec 0 bytes,block = 9602 EOR00 record 022602 oct 9602 dec 0 bytes,block = 9603 EOR00 record 022603 oct 9603 dec 0 bytes,block = 9604 FILE=rec05284 ;::n::::::pip::::::: 3780 bytes,block = 9605 ... FILE=rec05769 ;::n::::::kermit:::: 100170 bytes,block = 11911 FILE=rec05770 ;::n::::::krm0100::: 12264 bytes,block = 11915 FILE=rec05771 ;::n::::::krm0200::: 10590 bytes,block = 11918 FILE=rec05772 ;::n::::::krm0300::: 7674 bytes,block = 11920 FILE=rec05773 ;::n::::::krm0400::: 17565 bytes,block = 11925 FILE=rec05774 ;::n::::::krm0500::: 31779 bytes,block = 11934 FILE=rec05775 ;::n::::::krm0600::: 8469 bytes,block = 11937 FILE=rec05776 ;::n::::::krm0700::: 7869 bytes,block = 11940 FILE=rec05777 ;::n::::::krm1000::: 4185 bytes,block = 11942 FILE=rec05778 ;::n::::::krm1100::: 7935 bytes,block = 11945 FILE=rec05779 ;::n::::::krm1101::: 10770 bytes,block = 11948 FILE=rec05780 ;::n::::::krm1102::: 1434 bytes,block = 11949 FILE=rec05781 ;::n::::::krm1103::: 22530 bytes,block = 11955 FILE=rec05782 ;::n::::::krm1104::: 24210 bytes,block = 11962 FILE=rec05783 ;::n::::::krm1200::: 8145 bytes,block = 11965 FILE=rec05784 ;::n::::::krm1300::: 16950 bytes,block = 11970 EOR00 record 027302 oct 11970 dec 0 bytes,block = 11971 FILE=rec05785 ;::n::::::htf::::::: 223500 bytes,block = 12030 FILE=rec05786 ;::n::::::nbf::::::: 71205 bytes,block = 12049 FILE=rec05787 ;::n::::::nsquery::: 160629 bytes,block = 12091 FILE=rec05788 ;::n::::::rexec::::: 175344 bytes,block = 12137 FILE=rec05789 ;::n::::::rexecs:::: 165435 bytes,block = 12181 FILE=rec05790 ;::n::::::smtpi::::: 190515 bytes,block = 12231 FILE=rec05791 ;::n::::::smtps::::: 162180 bytes,block = 12274 EOR00 record 027762 oct 12274 dec 0 bytes,block = 12275 FILE=rec05792 .proc,gplot*i,obey=( 270 bytes,block = 12276 FILE=rec05793 .proc,cpm80*i,:::::: 1764 bytes,block = 12277 FILE=rec05794 .proc,intrp80*i,:::: 1215 bytes,block = 12278 FILE=rec05795 .proc,mac80*i,:::::: 459 bytes,block = 12279 FILE=rec05796 .proc,plm80*i,:::::: 849 bytes,block = 12280 FILE=rec05797 .proc,spss*i,i=(*f,* 210 bytes,block = 12281 EOR00 record 027771 oct 12281 dec 0 bytes,block = 12282 EOR00 record 027772 oct 12282 dec 0 bytes,block = 12283 EOR00 record 027773 oct 12283 dec 0 bytes,block = 12284 EOR00 record 027774 oct 12284 dec 0 bytes,block = 12285 FILE=rec05798 ;::n::::::system:::: 25620 bytes,block = 12292 EOR17 record 030004 oct 12292 dec 0 bytes,block = 12293 EOF 5799 LABEL="EOF1UNLABELED. 000100010001000222310LLA:: 012293NOS 2.8-051 " 0 bytes,block = 0 EOF 5799 EOF 5799 EOF 5799

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.

C:/inetpub/codex.sjzoppi.com/data/pages/utilities/nosutils/tdisassemble.tassemble.txt · Last modified: 2023/01/20 14:50 by site_admin