Reference Manual

Turbo PMAC/PMAC2 Software Reference
Turbo PMAC Program Command Specification 410
On-line commands ABS, INC
Program commands {axis}{data}, {axis}{data}{vector}{data}, INC
ADDRESS
Function: Motor/Coordinate System Modal Addressing
Type: PLC programs 1 to 31 only
Syntax: ADDRESS [#{constant}][&{constant}]
ADR [#{constant}][&{constant}]
where:
{constant} following the # character is an integer constant from 1 to 32 representing the motor
number to be addressed;
{constant} following the & character is an integer constant from 1 to 16 representing the
coordinate system number to be addressed
This statement, when executed, sets the motor and/or coordinate system that will be addressed by this
particular PLC program when it COMMANDs motor- or coordinate-system-specific commands with no
addressing in those commands. The addressed coordinate system also controls which set of Q-variables is
accessed, even for ATAN2 functions, which automatically use Q0.
This command does not affect host addressing, the addressing of other PLC programs, or the selection of
the control panel inputs. The addressing stays in effect until another ADDRESS statement supersedes it.
Default addressing at power-on/reset is #1 and &1.
In motion programs, there is no modal addressing for COMMAND statements; each COMMAND statement
must contain the motor or coordinate system specifier within its quotation marks. A motion program
operates on the Q-variables of the coordinate system executing the program automatically.
Examples:
ADDRESS &4
ADR #2
ADDRESS &2#2
ADR#1 ; Modally address Motor 1
CMD"J+" ; This will start Motor 1 jogging
CMD"#2J+" ; This will start Motor 2 jogging
CMD"J/" ; This will stop Motor 1
See Also:
Addressing Modes (Talking To Turbo PMAC)
Q-Variables (Program Computational Features)
Program commands ADDRESS#P, ADDRESS&P, COMMAND, Q{constant}={expression}
ADDRESS#P{constant}
Function: Select program’s addressed motor
Type: PLC programs 1 to 31 only
Syntax: ADDRESS#P{constant}
ADR#P{constant}
where:
{constant} is an integer from 0 to 8191 representing the P-variable number whose value
determines the motor to be addressed
This statement, when executed, selects the motor that will be addressed by this particular PLC program
when it issues motor-specific commands with subsequent COMMAND statements. The statement specifies
the number of a P-variable whose value determines which motor is addressed. For example, if variable
P7 had a value of 10, the statement ADDRESS#P7, when executed, would select Motor 10.