Browse
(440) 299-7778
Menu
(440) 299-7778
One-year parts and labor warranty30-day money-back guaranteeEnglishEspañolContact

The text of a manual · part 11 of 16

PDT 3200 Technical Reference Guide: Chapter 5 ROM-DOS Commands, pages 103 to 112

Pages 103 to 112 of 158, from PDT 3200 Technical Reference Guide

The original document is the PDF (941 KB). This is its text as extracted, unedited; tables and drawings read best in the PDF, and each page heading opens it at that page.

For the Symbol PDT-3200

Page 103

Chapter 5: ROM DOS Commands

Command Type Purpose

FILES CONFIG.SYS

The maximum number of Þles that may be open at one time can be modiÞed using the FILES command.

Syntax FILES = number

Remarks The number of Þles includes the standard Þles stdin, stdout, stderr, stdprn, and stdaux. The minimum this value may be set to is 8, the maximum is 255. All other values are ignored.

Example FILES = 10

This example causes the maximum for open Þles to be ten.

5-51

Page 104

PDT 3200 Technical Reference Guide

Command Type Purpose

FIND External

FIND is a Þlter to display only lines that contain a speciÞed string. The input to FIND may come from a Þle, or it may be piped in from another Þlter or a DOS command.

Syntax FIND [/option] match-string [filename]

Options The /C option causes FIND to only display the count of lines found with the speciÞed string. The /N option causes FIND to display the line number of the line found containing the string. The /V option causes FIND to display the lines that do not contain the string. The match-string argument speciÞes the word or group of characters to search for. The filename argument speciÞes the Þle or group of Þles to search in. The complete drive and path can be speciÞed. Wildcard characters can be used in the Þlename.

Examples The following example shows each line in the Þle JUNK.C that contains the matchstring ÒprintfÓ. FIND printf junk.c

The following example shows each line in a directory listing that contains a DIR. The command Þrst executes a DOS DIR command with the output piped into the FIND command. The FIND command then displays each line that contains the ÒDIRÓ string. dir ≠ FIND DIR

The following example give a count of the lines in the Þle MANUAL.TXT that contain the string ROM-DOS.

5-52

Page 105

Chapter 5: ROM DOS Commands

FIND /C ROM-DOS MANUAL.TXT .....MANUAL.TXT: 105

5-53

Page 106

PDT 3200 Technical Reference Guide

Command Type Purpose

FOR Internal Batch Subcommand

FOR allows repeated execution of a ROM-DOS command applied to a set of Þles.

Syntax FOR %%variable IN (set) DO command %%variable

Remarks In execution, this command attaches the variable as an identiÞer to each Þle in the set of Þles described. It then applies the command to each of these identiÞed Þles. The set may be an exact list of complete Þle names, or a global Þle speciÞcation using wildcard characters. The FOR subcommand can be used directly on the command line as well as within a batch Þle. To use on the command line, substitute a single percent (%) symbol for the double percent signs (%%).

Examples FOR %%N IN (Q1.TXT Q2.TXT) DOPRINT %%N

This command will print only the Þles Q1.TXT and Q2.TXT. FOR %%N IN (*.TXT) DO PRINT %%N

This command will print all Þles, in the current default directory, with a .TXT extension.

5-54

Page 107

Chapter 5: ROM DOS Commands

Command Type Purpose

GOTO Internal Batch Subcommand

The GOTO subcommand transfers control to another line of the batch Þle.

Syntax GOTO label

Remarks The label is another line in the batch Þle consisting of a string up to eight characters long. The label may be an environment variable. If the speciÞed label is not found, then the batch Þle terminates with the error message Label not found.

Examples GOTO MESSAGE

This command will move the control of execution within the batch Þle to a line that says: MESSAGE

Note: A batch Þle label must be preceded by a colon (:).

5-55

Page 108

PDT 3200 Technical Reference Guide

Command Type Purpose

HELP Internal

Provides on-line help of each ROM-DOS command.

Syntax HELP <command>

Remarks HELP serves as a memory aid. For complete information about ROM-DOS commands, always consult this manual. HELP for each command can also be displayed by entering /? following the command name. The Þle COMMAND.HLP must be available to use this command.

Examples To list the help of the DIR command you can type: HELP DIR or DIR /?

All available batch Þle commands are also listed by HELP.

5-56

Page 109

Chapter 5: ROM DOS Commands

Command Type Purpose

IF Internal Batch Subcommand

The IF subcommand allows conditional execution of commands.

Syntax IF [NOT] condition command

Remarks The condition may be any one of the following: ERRORLEVEL number string1 == string2 EXIST [d:][path]filename

If the condition is true then the command is executed, otherwise the command is bypassed and the next command in the batch Þle is executed. The [NOT] option will test the opposite of any of the conditions. The ERRORLEVEL number is true if the last program to execute had an exit code equal or greater than number. Using the [NOT] option with this condition will test if the exit code is less than the number argument. The condition string1 == string2 is only true when string1 and string2 are identical. The strings must match exactly; uppercase/lowercase mismatches are not allowed. Applying the [NOT] option will create a condition that is true only when the strings are not identical. The EXIST condition is true if the speciÞed Þlename is found. Wildcard characters are allowed in the Þlename. The [NOT] EXIST condition will be true if the Þlename cannot be found.

Examples IF ERRORLEVEL 15 GOTO :EXIT

This command will GOTO the :EXIT label if the ERRORLEVEL was equal to or greater than 15.

5-57

Page 110

PDT 3200 Technical Reference Guide

IF %1 == CONFIG.SYS PRINT %1

This command will print the Þle stored as the %1 parameter only if its exact name is CONFIG.SYS. IF NOT EXIST OLD COPY CONFIG.SYS OLD

If there is not a Þle named OLD, this command will copy CONFIG.SYS to OLD.

5-58

Page 111

Chapter 5: ROM DOS Commands

Command Type Purpose

INCLUDE CONFIG.SYS

The INCLUDE command can be used to include the contents of one conÞguration block into another. The instructions from the originating instruction block, as well as the included block, will be carried out. This command can only be used within a CONFIG.SYS conÞguration block.

Syntax INCLUDE = blockname

Remarks This command is useful for sets of instructions common to several system conÞgurations. The commands can be deÞned once in a single conÞguration block and then inserted into other conÞguration blocks via the INSERT command. Please refer to the section on Using Multiple ConÞgurations for more details.

Examples : : [MISC] device=mouse.sys device=c:\netword\loadnet.sys [WORDPROC] files=20 buffers=10 set path=c:\bin;c:\wp;c:\dict

5-59

Page 112

PDT 3200 Technical Reference Guide

INCLUDE=MISC

If ÒWORDPROCÓ was chosen from a CONFIG.SYS menu, the instructions in the conÞguration block labeled [WORDPROC] would be carried out. The instructions in the INCLUDED block labeled [MISC] would also be implemented as part of the [WORDPROC] block of instructions.

5-60