Reference Manual
PMAC 2 Software Reference
PMAC On-Line Command Specification 271
This effect of this command differs from that of the OPEN ROTARY command. After the
OPEN ROTARY command, ASCII text commands that can be buffered motion program
commands are entered into the internal rotary program buffer, as well as binary-format
commands (if I57=1). After the OPEN BINARY ROTARY command, no ASCII text
commands can be entered into the internal rotary buffers. If a text command can be
interpreted as an on-line command, it is executed immediately. If it cannot be interpreted as
an on-line command, it is rejected with an error.
No other program buffers (PLC, fixed or rotary motion) may be open when the command is
sent (PMAC will report ERR007 if I6=1 or 3). It is a good idea always to precede an OPEN
command with a CLOSE command to make sure no other buffers have been left open.
When the rotary buffers are open for binary entry only, bit 6 of Y:$0003 (a new status bit –
part of the 11
th
digit reported in response to the ??? global status query command) is set to 1.
However, bits 19 and 18 of this word (part of the 8
th
digit reported) – Motion Buffer Open
and Rotary Buffer Open – are left at 0 to keep ASCII commands out of this buffer.
The binary rotary buffers can be closed for entry with the CLOSE command.
See Also
I-variable I57
On-line commands CLOSE, OPEN ROTARY, ???
OPEN PLC
Function
Open a PLC program buffer for entry
Scope
Global
Syntax
OPEN PLC {constant}
where:
• {constant} is an integer from 0 to 31 representing the PLC program to be opened
Remarks
This command causes PMAC to open the specified PLC program buffer for entry and
editing. This permits subsequent program lines that are valid for a PLC to be entered into
this buffer. When entry of the program is finished, the CLOSE command should be used to
prevent further lines from being put in the buffer.
No other program buffers (PLC, fixed or rotary motion) may be open when this command is
sent (PMAC will report ERR007 if I6=1 or 3). It is a good idea always to precede an OPEN
command with a CLOSE command to make sure no other buffers have been left open.
PLCs 0-15 can be protected by password. If the PLC is protected by password, and the
proper password has not been given, PMAC will reject this command (reporting an ERR002
if I6=1 or 3).
Opening a PLC program buffer automatically disables that PLC program. Other PLC
programs and motion programs will keep executing. Closing the PLC program buffer after
entry does not re-enable the program. To re-enable the program, the ENABLE PLC
command must be used, or PMAC must be reset (with a saved value of I5 permitting this
PLC program to execute).
Example
CLOSE ............... ; Make sure other buffers are closed
DELETE GATHER ; Make sure memory is free
OPEN PLC 7 ... ; Open buffer for entry, disabling program
CLEAR ............... ; Erase existing contents
IF (M11=1) ... ; Enter new version of program...
...
CLOSE ............... ; Close buffer at end of program
ENABLE PLC 7 ; Re-enable program