
BASIC commands
PROGRAMMING MANUAL
68
Revi
si
on 3.0
3.2.80 DPOS
/i
3.2.81 DRIVE_ALARM
/i
4
Outputs 0 to 7 (not used on Trajexia)
5
Outputs 8 to 15
6
Outputs 16 to 23
7
Outputs 24 to 31
Type
Axis parameter (read-only)
Syntax
DPOS
Description
The
DPOS
axis parameter contains the demand position in user units, which
is generated by the move commands in servo control. When the controller is
in open loop (
SERVO=OFF
), the measured position (
MPOS
) will be copied to
the
DPOS
in order to maintain a 0 Following Error.
The range of the demand position is controlled with the
REP_DIST
and
REP_OPTION
axis parameters. The value can be adjusted without doing a
move by using the
DEFPOS
command or
OFFPOS
axis parameter.
DPOS
is
reset to 0 at start-up.
Arguments
N/A
Example
>> PRINT DPOS AXIS(0)
34.0000
The above line will return the demand position in user units.
See also
AXIS
,
DPOS
,
DEFPOS
,
DEMAND_EDGES
,
FE
,
MPOS
,
REP_DIST
,
REP_OPTION
,
OFFPOS
,
UNITS
.
value
Description
Type
Axis command
Syntax
DRIVE_ALARM(VR)
Description
The DRIVE_ALARM function reads the current alarm of the Servo Driver that
is connected to the Trajexia system via MECHATROLINK-II. Upon successful
execution, the command returns -1 and stores the value in the VR memory
location specified by the VR parameter. If the command cannot be executed,
the value 0 is returned. The command is executed on the driver for the base
axis set by BASE. The base axis can be changed with the AXIS modifier, as
with all the other axis commands and parameters.
This command waits for the response from the axis, The execution of the
command can be slow and variable in time. If you require a quick response
do not use this command.
Arguments
•
VR
The alarm value is stored on the VR address on successful execution.
Example
IF NOT DRIVE_ALARM(10) AXIS(2) THEN
PRINT "Failed to read alarm for Servo Driver"
ELSE
IF VR(10) = 0 THEN
PRINT "Servo driver healthy"
ELSE
PRINT "Servo alarm code: "; VR(10)
ENDIF
ENDIF
This example reads an alarm of the Servo Driver driving axis 2 and present
that information to the user.
See also
N/A
I52E-EN-03.book Seite 68 Freitag, 29. Juni 2007 11:55 11