Programmable SyncPos motion controller
MG.10.J8.02 – VLT is a registered Danfoss trade mark
112
Software Reference
■
■
■
■
■
E R R N O
ERRNO is a system variable which is available in all
the programs, and contains the momentary error
code. All error codes are explained in the chapter
Messages and Error Reference.
If, at the time of inquiry no error has occurred, then
ERRNO will contain a 0.
Summary
System variable with the actual error code
Syntax
res = ERRNO
Command group
I/O
Cross Index
ON ERROR GOSUB, ERRCLR
Messages and Error reference
Syntax-Example
PRINT ERRNO /* display actual error code */
Program sample
ERROR_01.M, IF_01.M, INDEX_01.M
■
■
■
■
■
EXIT
EXIT ends a program where active positioning pro-
cedures are being carried out to the end.
The EXIT command is especially intended for use in
an error treatment routine, and permits an unplan-
ned program termination in the case of an un-cor-
rectable error occurrence.
After an abort with EXIT, programs marked with
"AUTOSTART“ will start up again automatically if
SET PRGPAR = –1.
Summary
Premature program termination
Syntax
EXIT
NB!
A program should only be terminated in the
case of a serious error, e.g. when reacting to
a limit switch.
Cross Index
ON ERROR GOSUB, SET PRGPAR, "AUTOSTART"
Syntax-Example
EXIT
/* Program termination */
Program sample
EXIT_01.M, ERROR_01.M, GSVEL_01.M
■
■
■
■
■
GET
Reads the value of an axis parameter, a global
parameter or an user parameter of the SyncPos
option.
Global and axis parameter are addressed with a
code, for example KPROP (11) for the
Proportional
Proportional
Proportional
Proportional
Proportional
factor
factor
factor
factor
factor,
,
,
,
,
KDER (12) for the
Derivative Factor
Derivative Factor
Derivative Factor
Derivative Factor
Derivative Factor
or
POSERR (15) for the
T
T
T
T
Tolerated position error
olerated position error
olerated position error
olerated position error
olerated position error
. A
complete list of the codes can be found in the
Parameter reference.
User parameter are addressed with a number, 130
– 229. See also the Parameter reference for
details.
Summary
Reads an axis parameter, a global parameter or an
user parameter
Syntax
res = GET par
Parameter
par = parameter identification
Return value
res = parameter value
Command group
PAR
Cross Index
SET, GETVLT, SETVLT, LINKGPAR, LIN KAXPAR
Parameter reference
Syntax-Example
PRI NT GET POSLI MIT
/* Print-out positive positioning limit */
posdiff = GET POSERR
/* Read actual setting tolerated position error */
Syntax-Example
PRI NT GET I_B REAK /* reads input for abort */
Program sample
G ETP_01.M