beautypg.com

ProSoft Technology MVI56-BAS User Manual

Page 189

background image

MVI56-BAS ♦ ControlLogix Platform

BASIC CALLs Syntax

BASIC Module (DB/BAS Compatible)

User Manual

ProSoft Technology, Inc.

Page 189 of 234

December 13, 2011

If using an internal string the BASIC program must monitor the second character

which contains the transaction number which is incremented at every successful

transaction (from 0 to 255)
C = word offset in destination file. The offset for an internal string is always 2,

because each string has the following structure:

If using the input image file as the destination file the offset should be a minimum

of 2, because the first 2 words are reserved.
D = string number. This parameter is only used if the destination file selected is

an internal string
E = maximum word length. Any packets received which contains more than this

parameter is rejected.
F = CALL 118 status. It can assume one of the following values:
0 = successful
1 = disabled
2 = invalid parameter
3 = DF1 port is not enabled
4 = selected DF1 port is not enabled
5 = string is not dimensioned

Example:

.
.
.
90 PUSH 1,1,0,0,20: CALL 118: POP STATUS
100 IF(STATUS<>0) THEN PRINT "Unsuccessful CALL 118 Setup"
110 REM CALL 118 remains active as long as BASIC
120 REM continues to RUN.
.
.
.

9.9.3 DF1 Background CALLs

CALL 118: Receive DF1 or DH-485 Unsolicited Write

Use CALL 118 to allow the MVI56-BAS to receive write command from remote

DF1 devices such as PLC-2, PLC-3, PLC-5 or from the DH-485 network. The

following WRITE commands are accepted:
PLC (word range writes)
PLC (typed writes)
PLC (unprotected writes)
SLC 5/02 (unprotected writes)