1 CLEAR
        format CLEAR

   Clears the screen of a crt.
1 Commands
   Commands for FDMP may be abbreviated to the fewest necessary 
   characters to produce an unambiguous command.  If FDMP does not
   understand something, it will tell you so, indicating what portion
   of the command line is in error.  
   FDMP always translates commands into upper case, except for those 
   portion of lines enclosed in double (") quotation marks.  If the 
   user wanted to do an ascii search over an entire file for the
   string ABCDEF, he could enter either:

     SEARCH FOR ABCDEF or search for abcdef or search for "ABCDEF"

   Note that SEARCH FOR "abcdef" would not work, because FDMP would
   leave the text string inside the double quotes alone.  Do not 
   put commands or macro names or macro definitions in double quotes
   (i.e., FDMP understands the command clear or CLEAR but not "clear").
   The double quotes should be used only for search or replacement 
   strings.
1 CONVERT
        format CONVERT TO FIXED <record length in longwords>
               CONVERT TO SEGMENTED
               CONVERT TO VARIABLE

   Takes the current OPENed file and converts it to the specified
   file type.  If FIXED is specified, a record length for each
   record must be specified.  Note that this length specified
   is in longwords (bytes/4).  When converting to FIXED, if
   records from the input file are too long, they will be truncated
   on output, and an error message will be output.  When converting
   to VARIABLE, and the input file records are greater than 32,764
   bytes, an error message will be output, and record will NOT be
   output.  The file created will have the same name as the input
   file, but the extension will be .CVT (to indicate a converted
   file.)
1 DEFINE
        format DEFINE MACRO <macro name> <definition>

   Defines and labels a macro by which a the dumps are done.
   Up to 20 macros may defined.  Once created, a macro is
   referred to by its name.  See HELP MACRO for more information
   on the format and names of macros.
1 DISPLAY
         format DISPLAY ON
                DISPLAY OFF

   Enables or disables the display of the actual contents of the 
   data record.   DISPLAY is ON by default. 
1 DO
        format DO <DCL command>
   Creates a sub-process to execute any valid DCL command.  Any output
   from the execution of the command returns to your terminal.  When
   execution is complete, you will be returned to FDMP.  The DCL
   command is limited to 132 characters.
   Note that execution might take a while, as the sub-process inherits
   all logical names, your global symbol definitions, and your current
   default directory.  This means you can use your own symbol definitions
   and logical names in the command.  If the command is preceded by
   an at (@) sign, a command file (default extension .COM) will be
   executed.
   Also note that executing a command in the sub-process CANNOT affect
   the attributes of the parent (i.e., you cannot use SET DEFAULT in
   a sub-process to change your default directory you are in which
   you are executing FDMP).
1 DUMP
        format DUMP [record-range] [USING <macro name>]

   Does the actual dumping (or displaying) of the contents of the data 
   file.  If range is not given, then the whole file is dumped. 
2 record-range
   A range of numbers may have any of the following formats:

                100[:]                     a single record
                100:200                    the records 100 to 200
                                           inclusively.  No spaces allowed.
2 USING
   The USING modifier tells which macro definition FDMP is to use to
   display the contents of the records.  The macro name should be
   unique.  
1 ECHO
        format ECHO ON
               ECHO OFF

   Enables or disables the displaying of the commands that are currently
   being read in from a command file.  See READ for more details.  ECHO
   is OFF by default.
1 EDIT
        format EDIT record-range [USING <macro name>]
 
   Edits a range of records using the current (or specified) macro 
   definition.  Valid sub-commands while in EDIT are as follows:
   
        ABORT, DELETE, EXIT, QUIT, REPLACE, VIEW
2 record-range
   A range of numbers may have any of the following formats:

                100[:]                     a single record
                100:200                    the records 100 to 200
                                           inclusively.  No spaces allowed.
2 field-range
   A range of numbers may have any of the following formats:

                100[:]                     a single record
                100:200                    the records 100 to 200
                                           inclusively.  No spaces allowed.
2 ABORT
        format ABORT

    Aborts the editing of the current record and all subsequent records
    being edited.  Same effect as if the user entered QUIT as the only
    command for each of the records he is editing.  Note that this 
    command has NO affect on records already having been modified and
    these modifications saved by an EXIT.
2 DELETE
        format DELETE field-range
  
    Deletes a range of field entries from the record as specified
    by the current editing macro definition.
2 EXIT
        format EXIT

    Directs FDMP to write out the modified record contents to a 
    work file which FDMP uses to record changes made to the file.
    These modified records are incorporated into the new file 
    created when FDMP is EXITed.  When FDMP is EXITed, the last 
    modification to a given record is the only one used in the
    new file.  The ONLY way to get FDMP to make any changes and 
    create a new file is to record each individual record change 
    by issuing the EXIT command. 
2 QUIT
        format QUIT

    Aborts editing of the current record.
2 REPLACE
        format REPLACE [qualifier] field-range WITH substitution

   Replaces the specified fields in the record with the substitution.
   Valid qualifiers are /ASCII, /OCTAL, /BYTE, /WORD, /LONG, /FLOAT,
   /DOUBLE, and /HEX.  If a qualifier is not given, /FLOAT is assumed.
   The substitution string must be valid for the given mode of
   replacement (i.e. REPLACE/OCTAL 1:3 WITH 8 will result in an
   input conversion error).  To prevent the upcasing of the substitution,
   enclose it in double (") quotation marks.  Blanks are always
   ignored in numeric constants.  Floating values that exceed the
   range defined for FORTRAN F and D values will also result in 
   an input conversion error.
3 QUALIFIER_INFO
/ASCII
   The /ASCII switch tells FDMP to accept the substitution character
   for character.  The replacement begins at the value specified
   in the field range, and its length is the length of the replacement.
   Spaces are allowed in the substitution.  The substitution may be
   up to 255 characters in length.  One byte is substituted for each
   character in the input string.
/BYTE
   The /BYTE switch tells FDMP to accept the value as a signed byte.
   One byte is replaced for each replacement done in the record.
/DOUBLE
   The /DOUBLE switch tells FDMP to accept the value as a double-
   precision floating point number.  Eight bytes are replaced for
   each substitution.
/FLOAT
   The /FLOAT switch tells FDMP to accept the value as a single-
   precision floating point number.  Four bytes are replaced for
   each substitution.
/HEX
   The /HEX switch tells FDMP to accept the value as an unsigned
   hexadecimal constant.  Four bytes are replaced for each 
   substitution.
/LONG
   The /LONG switch tells FDMP to accept the value as a signed
   I*4 constant.  Four bytes are replaced for each substitution.
/OCTAL
   The /OCTAL switch tells FDMP to accept the value as an unsigned
   octal byte.  One byte is replaced for each substitution.
/WORD
   The /WORD switch tells FDMP to accept the value as a signed
   I*2 constant.  Two bytes are replaced for each substitution.
2 VIEW
        format VIEW

   Displays the current record being edited.  Useful if the user has
   gotten help or something and the current record has scrolled off
   of the screen.
1 EXIT
        format EXIT

   Exits FDMP, creating a new file with the same name as the input file
   if any editing has been done.  Use QUIT to exit FDMP with no new
   file.
1 FULLSCR
        format FULLSCR ON
               FULLSCR OFF

   Enables or disables the use of a 'full-screen' display of the
   data records.  FULLSCR is only valid for VT100 family terminals.
   FULLSCR is OFF by default.
1 HELP
        format HELP [keyword]
               HELP keyword...

   Obtains help for the user on using FDMP.  Type HELP OVERVIEW for
   a brief description of FDMP.
1 LOGGING
        format LOGGING ON
               LOGGING OFF
   
   Enables the saving in a log file (called FDMP.LOG) all the the
   valid commands entered during the session.  LOGGING is OFF by
   default.
1 MACRO
   Macros are definitions of by which FDMP dumps records of the data
   file.  Up to 20 macroes may be defined at once.
2 NAMES
   Macro names may be from 1 to 255 characters in length, and must
   consist of the letters A-Z (lowercase is translated to uppercase
   on input), the numbers 0-9, and the special characters _ and $.
   A blank terminates the name.
2 DEFINITIONS
   A macro definition may be from 1-255 characters in length.  Its
   format is similar to a FORTRAN format statement.  Commas and
   blanks may be inserted but are ignored.  The carriage return
   terminates the definition.  The definition may also include a
   repeat operation in parentheses, but only one level is understood.
   The valid characters in the definition are:

                      X          skips one byte in the record
                      A          translates 1 byte as ascii, which,
                                 if unprintable, will be a '.'
                      B          returns a signed byte
                      D          returns a double precision (real*8) 
                                 floating point number
                      F          returns a single precision (real*4)
                                 number
                      H          returns a hexadecimal longword 
                      L          returns a signed longword
                      O          returns a byte in octal
                      W          returns a signed word (2 bytes)

      See the sub-topic "Special characters" for additional dumping
   formats.
3 Examples
   To define a macro to dump the STE header record, one might use 
   the following command:
 
         DEFINE MACRO STE_HEAD 80A,3W,2F,6W

   To define a macro to read the header of the transmission loss
   file from PE, one might use:

         DEFINE MACRO PE_HEAD 40(2A,2X),9A,2F,2L,6F

   Then the user could enter the command:

         DUMP 1 USING PE_HEAD

3 Special Characters
  There are 2 characters for special interpretation of data fields.
  These are U and Z.  When placed in front of the L, W, or B codes,
  these codes act as modifiers to the standard interpretation.

        ZB dumps one byte (8 bits) in binary
        ZW dumps one word (16 bits) in binary
        ZL dumps one longword (32 bits) in binary

        UB dumps one unsigned byte, rather than signed
        UW dumps one unsigned word, rather than signed
        UL dumps one unsigned longword, rather than signed
  
  Repeat counts may be specified as needed (e.g. 4ZL will dump 4 
  longwords in binary).
1 OPEN
        format OPEN [/VARIABLE] <file specification>

   Opens a file for viewing.  The file specification is mandatory
   and must be 63 characters or less in length.  A file must be
   open to use it.  The VARIABLE qualifier indicates that the
   file that is OPENed is to be interpreted as having VARIABLE
   type records, instead of SEGMENTED records.  See the FDMP
   user's manual for more information on the differences in
   these records.
1 OVERVIEW
   FDMP is a program for the inspection and editing of FORTRAN 
   unformatted data files.  It operates on files consisting
   of either variable, segmented (FORTRAN default) or fixed length 
   record files.  It can dump files with records of any length,
   assuming the virtual memory is available.  It cannot edit
   files that have records greater than 32768 bytes, however.
   The user has a choice of formats in
   which to display the file.  The program supports different
   data types in one record, and will skip values also.  A 
   'full-screen' dump is available, as well as the saving of the
   dumped records on a disk file suitable for printing.  The user
   may select to view only the length of the records, the actual
   contents of the record on the terminal, or sending the results
   to a disk file.  
1 PRINT
        format PRINT ON
               PRINT OFF

   Enables or disables the saving of the contents of the records
   on a disk file.   PRINT is OFF by default.
1 QUIT
        format QUIT

   Exits the program.
1 READ
        format READ <file specification>
   
   Reads in commands from the named file instead of the terminal.
   Useful for defining commonly used macros, etc.  Any valid
   command may be in the command file, with one command on a line.
1 REMOVE
        format REMOVE MACRO <macro name>
               REMOVE ALL

   Removes a macro definition from the program.  If the name given
   matches more than one name on the list (e.g. name 'ABC' would 
   match macro names 'ABC123' and 'ABCDEF'), all matches are removed.
   REMOVE ALL removes all macro definitions.
1 REVERSE
        format REVERSE ON
               REVERSE OFF
   If REVERSE is on, causes FDMP to reverse the order of bytes that 
   are read in.  If editing and REVERSE is ON, unedited records from
   the original data file will be reversed, so the output file will
   have all bytes reversed.  REVERSE is OFF by default.
1 SEARCH
        format 
        SEARCH [/COMPLETE] [qualifier] [record-range] FOR search-string
   
   Causes FDMP to search over the specified record range for a
   particular value.  The record number and byte position are displayed
   for the first match in the record, and if DISPLAY is on, the 
   record is displayed also.  Specifying COMPLETE instructs FDMP to
   report all matches in the record of the search-string.  By default,
   FDMP only reports the first match found in the record.
   Valid qualifiers are /ASCII, /OCTAL, /BYTE, /WORD, /LONG, /FLOAT,
   /DOUBLE, and /HEX.  If a qualifier is not given, /ASCII is assumed.
   The search-string must be valid for the given mode of
   replacement (i.e. SEARCH/OCTAL 1:3 FOR 8 will result in an
   input conversion error).  Blanks are always ignored in numeric 
   constants.  Floating values that exceed the range defined for 
   FORTRAN F and D values will also result in an input conversion error.
   Note that matches must be EXACT; i.e., a double precision search
   must match all 8 bytes.  ASCII searches for uppercase, unless
   the search-string is enclosed by double quotation  (") 
   marks.  If record-range is not given, the whole
   file is searched.
2 QUALIFIER_INFO
/ASCII
   The /ASCII switch tells FDMP to accept the search-string character
   for character.  Spaces are allowed in the substitution.  The 
   search string may be up to 255 characters in length.  
/BYTE
   The /BYTE switch tells FDMP to accept the value as a signed byte.
/DOUBLE
   The /DOUBLE switch tells FDMP to accept the value as a double-
   precision floating point number.  
/FLOAT
   The /FLOAT switch tells FDMP to accept the value as a single-
   precision floating point number.  
/HEX
   The /HEX switch tells FDMP to accept the value as an unsigned
   hexadecimal constant.
/LONG
   The /LONG switch tells FDMP to accept the value as a signed
   I*4 constant.  
/OCTAL
   The /OCTAL switch tells FDMP to accept the value as an unsigned
   octal byte.  
/WORD
   The /WORD switch tells FDMP to accept the value as a signed
   I*2 constant.  
1 SHOW
        format SHOW MACRO <macro name>
               SHOW ALL
               SHOW FILE
               SHOW FLAGS
               SHOW CURRENT

   Shows the name and current definition of the macros.  If the name 
   given matches more than one name on the list (e.g. name 'ABC' would 
   match macro names 'ABC123' and 'ABCDEF'), all matches are displayed.
   SHOW FILE shows the name of the current OPENed file.  If one is not
   OPEN, there is no output.  SHOW FLAGS displays the current values
   of all of FDMP'S operating flags as TRUE or FALSE.  SHOW CURRENT
   displays the current macro definition in use.
1 SUMMARY
        format SUMMARY ON
               SUMMARY OFF

   Enables or disables the displaying of the length of each record in
   bytes.   SUMMARY is OFF by default.
