Description of commands, Command: run – Rockwell Automation 1771-DB Basic Module User Manual - Series A User Manual

Page 43

Advertising
background image

Operating Functions

Chapter 5

5–6

The

following sections list and describe the commands you can

use with the BASIC Module.

Action Taken:

After you type RUN, all variables are set equal to

zero,

all BASIC evoked interrupts are cleared and program

execution begins with the first line number of the selected program. The
RUN command and the

GOTO statement are the only way you can place

the BASIC Module

interpreter into the RUN mode from the

COMMAND mode. You can terminate program execution

at any time by

typing a Control C on

the console device.

Variations:

Some BASIC interpreters allow a line number to follow the

RUN command

(i.e. RUN 100). The BASIC Module does not permit

this variation on the RUN command. Execution begins with the first line
number. To obtain a function similar to the RUN[ln num] command,

use

the GOTO[ln

num] statement in the direct mode. See statement

GOTO.

Example:

u10 FOR I=1 TO 3

u20 PRINT I

u30 NEXT I

u40 END

uRUN

1
2
3

READY

u

5.3
Description of Commands

5.3.1
Command: RUN

Advertising