Reference Manual

PMAC 2 Software Reference
PMAC On-Line Command Specification 253
Remarks
This command assigns the value on the right side of the equals sign to the specified M-
variable(s). It does not assign a definition (address) to the M-variable(s); that is done with
the M{constant}->{definition command.
If a motion or PLC program buffer is open when this command is sent to PMAC, it will be
entered into the buffer for later execution.
Example
M1=1
M9=M9 & $20
M102=-16384
M1..8=0
See Also
M-Variables (Computational Features)
On-line commands M{constant}, M{constant}->{definition}
Program commands M{constant}, M{constant}={expression}
M{constant}->
Function
Report current M-variable definition(s)
Scope
Global
Syntax
M{constant}[..{constant}]->
where:
{constant} is an integer from 0 to 1023 representing the number of the M-variable;
the optional second {constant} must be at least as great as the first {constant} – it
represents the number of the end of the range;
Note:
No spaces are permitted between the M-variable name and the
“arrow” double character in this command.
Remarks
This command causes PMAC to report the definition (address) of the specified M-variable or
range of M-variables. It does not cause PMAC to report the value of the M-variable{s); that
is done with the M{constant} command.
When I9 is 0 or 2, only the definition itself (e.g. Y:$FFC2,0) is returned. When I9 is 1or 3,
the entire definition statement (e.g. M11->Y:$FFC2,0) is returned.
Example
M1->.................. ; Host requests definition
Y:$FFC2,8...... ; PMAC’s response
M101..103->
X:$C001,24,S
Y:$C003,8,16,S
X:$C003,24,S
See Also
M-Variables (Computational Features)
On-line commands M{constant}, M{constant}->{definition},
M{constant}={expression}
Program command M{constant}={expression}
M{constant} ->*
Function
Self-Referenced M-Variable Definition
Scope
Global
Syntax
M{constant}[..{constant}]->*
where:
{constant} is an integer from 0 to 1023 representing the number of the M-variable;