User`s manual

4.0 - Programming PMAC
Page - 30
4.2 - Buffered (Program) Commands
As their name implies, buffered commands are not acted on immediately, but held for later execution. PMAC has many
program buffers -- 256 regular motion program buffers, 8 rotary motion program buffers (1 for each coordinate system), and
32 PLC program buffers. Before commands can be entered into a buffer, that buffer must be opened (e.g. OPEN PROG 3,
OPEN PLC 7). Each program command is added onto the end of the list of commands in the open buffer; if you wish to
replace the existing buffer, use the CLEAR command immediately after opening to erase the existing contents before
entering the new ones. After finishing entering the program statements, use the CLOSE command to close the opened
buffer.
4.3 - COMPUTATIONAL FEATURES
4.3.1 - I-variables
I-Variables (initialization, or setup variables) determines the personality of the card for a given application. They are at
fixed locations in memory and have pre-defined meanings. Most are integer values, and their range varies depending on the
particular variable. There are 1024 I-variables, from I0 to I1023, and they are organized as follows:
I0 -- I79: General card setup
I80 -- I99: Geared Resolver setup
I100 -- I184: Motor #1 setup
I185 -- I199: Coordinate System 1 setup
I200 -- I284: Motor #2 setup
I285 -- I299: Coordinate System 2 setup
...
I800 -- I884: Motor #8 setup
I885 -- I899: Coordinate System 8 setup
I900 -- I979: Encoder 1 - 16 setup
I980 -- I1023: Reserved for future use
Values assigned to an I-variable may be either a constant or an expression. The commands to do this are on-line
(immediate) if no buffer is open when sent, or buffered program commands is a buffer is open.
Examples:
I120 = 45
I120 = (I120+P25*3)
For I-variables with limited range, an attempt to assign an out-of-range value does not cause an error. The value is
automatically "rolled over" to within the range by modulo arithmetic (truncation). For example, I3 has a range of 0 to 3 (4
possible values). The command I3=5 would actually assign a value of 5 modulo 4 = 1 to the variable.
On PMACs with battery-backed RAM, most of the I-variable values can be stored in a 2K x 8 EEPROM IC with the SAVE
command. These values are safe here even in the event of a battery-backed RAM failure, so the basic setup of the board is
not lost. After a new value is given to one of these I-variables, the SAVE command must be issued in order for this value to
survive a power-down or reset.
The I-variables that are not saved to EEPROM are held in battery-backed RAM. These variables do not require a SAVE
command to be held through a power-down or reset, and the previous value is not retained anywhere. These variables are:
I19-I44, Ix13, Ix14.
On PMACs with flash memory backup (those with Option 4A, 5A, or 5B), all of the I-variable values can be stored in the
flash memory with the SAVE command. If there is an EEPROM IC on the board, it is not used. After a new value is given
to any I-variable, the SAVE command must be issued in order for this value to survive a power-down or reset.
Default values for all I-variables are contained in the manufacturer-supplied firmware. They can be used individually with
the I{constant}=* command, or in a range with the I{constant}..{constant}=* command. Upon board re-
initialization by the $$$*** command or by a reset with E51 in the non-default setting, all default settings are copied from
the firmware into active memory. The last saved values are not lost; they are just not used.
4.3.2 - P-Variables