beautypg.com

ProSoft Technology MVI56-BAS User Manual

Page 205

background image

MVI56-BAS ♦ ControlLogix Platform

BASIC-52 Implementation

BASIC Module (DB/BAS Compatible)

User Manual

ProSoft Technology, Inc.

Page 205 of 234

December 13, 2011

Operator /
Statement

Description

Example

FREE

Returns the number of RAM bytes

available to the user

PRINT FREE

TAB()

#

It directs the operator to PRT2

PRINT# A
GET# A
INPUT# "Weight?",W

@

It directs the operator to PRT1

PRINT# B
GET# B
INPUT@ "Length?",L

BRKPNT

CALL

Allows the user to reference functions
that are not supported directly in

BASIC.

CALL 37

CLEAR

Resets all variables, interrupts and

stacks

CLEAR

CLEARI

Resets all interrupts

CLEARI

CLEARS

Resets all stacks

CLEARS

CLOCK0

Disables the internal BASIC real time
clock. CLOCK0 is mainly used in

conjunction with the TIME operator

and the ONTIME statement.

CLOCK0

CLOCK1

Enables the internal BASIC real time
clock. CLOCK1 is mainly used in

conjunction with the TIME operator

and the ONTIME statement.

CLOCK1

CLRERR

Clears the previous error stored after

a ONERR statement

CLRERR

CONT

Resumes a program execution after a
BRKPNT [Ctrl-C], or a STOP

statement

CONT

DATA

Stores information that will not change

for the READ statement.

DATA 5,6,13,24,-17

DIM

Reserves memory for matrices

DIM A(25)

DO/UNTIL

Set up a loop control within a module
program. The loop is executed until

the condition is TRUE

10 DO
20 A=A+1
30 UNTIL A=4

DO/WHILE

Set up a loop control within a module
program. The loop is executed while

the condition is TRUE

10 DO
20 A=A+1
30 WHILE A<4

EDIT

Edits the program line number

currently in RAM

EDIT 10

END

Terminates program execution

END

EOF

Checks if a PRT input buffer is empty IF(EOF) THEN …

ERASE

Erase the current program stored in

ROM mode

ERASE