![SIASUN GCR Series Скачать руководство пользователя страница 64](http://html.mh-extra.com/html/siasun/gcr-series/gcr-series_user-manual_1263477064.webp)
60
List Constant:
A list is a collection of constants. The length of a list is arbitrary. The list supports
only arithmetic constant. [680.760, 185.767, 372.607, -130.145, 33.706, 154.567],
for example.
The main role of list constants in the system is to initialize the array when the array
is defined. List constants also can be arguments transfer to functions or assign
values to an array of the same length.
String Constant:
A string constant is a collection of characters. It ends with ‘\0’. The length of a
string constant is the number of characters in the constant plus one. For example,
"siasun robot", a string constant, actually contains 13 characters. String constants
can be used to define character array variables or used as arguments transfer to
functions.
Special constants:
[POSE] is a special constant. The elements of it have the same value of 0. It is used
for the pose variable initialization or parameter assignment.
8.2.3 Variables
A variable is usually represented by a unique identifier in the system.
Common Variables
a = 123;
# a is an int variable. It is initialized to 123.
b = 11.23;
# b is a float variable. It is initialized to 11.23.
c = True;
# c is an int variable. It is initialized to 1.
d = False;
# d is an int variable. It is initialized to 0.
Pose Variable
The pose type is an array with 6 float data that represent the pose of the joint of the
robot.
p = [POSE];
# p is a pose variable. It is initialized to all 0.
p = [1, 2, 3, 4, 5, 6]; # p is a pose variable. It is initialize [1,2,3,4,5,6].
p = [1, 2];
# p is a pose variable. It is initialize [1,2,0,0,0,0].
After using [ ] to define a variable, the variable is of
Pose type, its length is six and is not changed by the
length of the initial definition list. Please pay attention
while using [ ].
String Variable
s = “siasun”;
# s is a string variable and has a length of 7, including the terminating '\0’ character.
Array Variable
a1 = Array(8, INT);
Содержание GCR Series
Страница 41: ...37 6 Robot Programming 6 1 Create program Click Create Program and enter a program name ...
Страница 47: ...43 The functions illustrate below are functions for IO The function illustrate below are logic function ...
Страница 51: ...47 6 6 Example Add a movej and movel node respectively Then add a MoveC node and set it s sub nodes position ...
Страница 53: ...49 ...
Страница 86: ...82 signal_name It represents the name of the modbus node Return Value none Example modbus_delete_signal mbus1 ...