Reference Manual

PMAC 2 Software Reference
396 PMAC I/0 and Memory Map
PMAC I/O AND MEMORY MAP
This guide to PMAC’s memory and input and output registers is provided for user reference. The PMAC
architecture is very open, allowing the user to examine and use many internal registers for his own use.
Usually this is done through the use of M-variables, which point to locations in the memory-I/O space of
the PMAC processor. Once defined to point to the proper location, an M-variable can be treated as any
other variable for reading and writing.
Caution:
Certain registers that are under PMAC’s automatic control can cause problems if
the user writes to them directly – particularly those used in the servo calculations.
PMAC’s processor is the Motorola 56002 DSP. The 56002 has dual data buses, each 24 bits wide, so that
both operands in a calculation may be brought in simultaneously. Each bus has access to a 16-bit address
space (0000hex to FFFFhex) which provides 65,536 24-bit words. One bus and address space is called X,
and the other is called Y. Therefore, when specifying a single-word memory location, one must use X: or
Y: with the 16-bit address. PMAC’s input and output is mapped into the same address space with the
memory.
PMAC uses double-word memory for both extended fixed-point values and for floating-point values
(single words are always fixed point). In this memory map, the fixed-point double word locations are
specified by a D: (double), and the floating-point double-word locations are specified by an L: (long).
This matches the syntax of M-variable declarations for these registers. If an address is specified without
any prefix, it means that a special internal format is used to hold data in that word.
The user may specify PMAC addresses with either decimal or hexadecimal values; the hex values must be
preceded by a $ to be interpreted as hex. For example, Y:$FFC0 is the hexadecimal specification, and
Y:65472 is the decimal specification of the same word address.
M-variables are defined by providing the word address, the offset, the width, and the format (irrelevant
for bits). Refer to M-variables in the manual for details of the definition. Several M-variables were
defined at the factory to match to inputs and outputs. For instance, M11 thru M18 were assigned to
Machine Inputs 1 thru 8 (MI1-MI8), and M1 to M8 were assigned to Machine Outputs 1 thru 8 (MO1-
MO8). Example statements are as follows:
M11->Y:$FFC2,0,1
(Mach. In. 1: Offset 0, width 1)
M1->Y:$FFC2,8,1
(Mach. Out. 1: Offset 8, width 1)
M162->D:$002C
(Motor #1 Actual Position: fixed pt.)
M163->L:$081F
(C.S. 1 X-axis Position: floating pt.)