Valid Range Of Variables; Valid Range Of Dynamic (Array) Variables; Valid Range Of Static Variables - Omron SCARA YRCX Series Programming Manual

Robot controller
Hide thumbs Also See for SCARA YRCX Series:
Table of Contents

Advertisement

11

Valid range of variables

1
11.1
2
3
4
MEMO
5
11.2
6
3-18
Chapter 3 Variables

Valid range of dynamic (array) variables

Dynamic (array) variables are divided into global variables and local variables, according to their
declaration position in the program. Global and local variables have different valid ranges.
Variable Type
Explanation
Global variables
Variables are declared outside of sub-procedures (outside of
program areas enclosed by a SUB statement and END SUB
statement). These variables are valid throughout the entire program.
Local variables
Variables are declared within sub-procedures and are valid only in
these sub-procedures.
• For details regarding arrays, refer to Chapter 3 "5 Array variables".
• A variable declared at the program level can be referenced from a sub-procedure without
being passed along as a dummy argument, by using the SHARED statement (for details, refer to
Chapter 8 "111 SHARED").

Valid range of static variables

Static variable data is not cleared when a program reset occurs. Moreover, variable data can be
changed and referenced from any program.
The variable names are determined as shown below (they cannot be named as desired).
Variable type
Variable name
Integer variable
SGIn (n: 0 to 31)
Real variable
SGRn (n: 0 to 31)

Advertisement

Table of Contents
loading

Table of Contents