Omron trajexia CJ1W-MCH72 Operation Manual page 156

Sysmac cj-series programmable controller
Hide thumbs Also See for trajexia CJ1W-MCH72:
Table of Contents

Advertisement

All BASIC commands
4-2-82 DRIVE_WRITE
!Caution
/i
Type
Axis command
Syntax
DRIVE_WRITE(parameter, size, value [,mode])
Description
The DRIVE_WRITE function writes to the specified parameter of the
Servo Driver via the MECHATROLINK-II bus. Upon successful execu-
tion, this command returns -1. If the command cannot be executed, the
value 0 is returned. The command is executed on the driver for the base
axis set with BASE. It can be changed using the AXIS modifier, as with
all other axis commands and parameters. For some parameters to be
written the driver needs to be powered off and on again. The
DRIVE_RESET command can be used for that purpose.
Note: This command waits for the response of the axis so, its execution
is slow and the time variable. Do not use this command together with
other commands that require quick execution.
Note: Executing a DRIVE_WRITE will temporarily disable the Servo
Driver Front Panel display.
Note: DRIVE_WRITE returns -1 on success. It also returns -1 with no
parameter read if the parameter number does not exist or has the wrong
size.
Arguments
parameter
The number of the parameter to write to. Note that the parameter
numbers are hexadecimal. The format of the data can be found in
the Refer to the Servo Driver manual for the format of the data.
size
SIze of the parameter is specified in bytes. For most parameters the
size is normally 2 bytes. Some special parameters may be 4 bytes
long. Sizes for each parameter can be found in the Servo Driver
manual.
value
The value to be written into driver parameter.
mode
The write mode. Possible values: 0 (or omitted) - write and store in
RAM; 1 - write and store in EPROM.
Example
IF DRIVE_WRITE($100,2,90) THEN
PRINT "The new speed loop gain is: 90"
ELSE
PRINT "The speed loop gain could not be written in RAM"
ENDIF
See also
DRIVE_READ, DRIVE_RESET, $ (HEXADECIMAL INPUT)
Be sure that no Parameter Unit or Personal Computer Software is connected to the
Servo Driver when executing this command. Otherwise the program task will be paused
until the connection of the other device to the Servo Driver is removed.
Section 4-2
145

Hide quick links:

Advertisement

Table of Contents
loading

Table of Contents