Power PMAC MACRO User Manual
Power PMAC MACRO User Manual
Power PMAC MACRO User Manual
^5February 5, 2014
Copyright Information
© 2012 Delta Tau Data Systems, Inc. All rights reserved.
This document is furnished for the customers of Delta Tau Data Systems, Inc. Other uses are
unauthorized without written permission of Delta Tau Data Systems, Inc. Information contained in this
manual may be updated from time-to-time due to product improvements, etc., and may not conform in
every respect to former issues.
To report errors or inconsistencies, call or email:
Delta Tau Data Systems, Inc. Technical Support
Phone: (818) 717-5656
Fax: (818) 998-7807
Email: support@deltatau.com
Website: http://www.deltatau.com
Operating Conditions
All Delta Tau Data Systems, Inc. motion controller products, accessories, and amplifiers contain static
sensitive components that can be damaged by incorrect handling. When installing or handling Delta Tau
Data Systems, Inc. products, avoid contact with highly insulated materials. Only qualified personnel
should be allowed to handle this equipment.
In the case of industrial applications, we expect our products to be protected from hazardous or
conductive materials and/or environments that could cause harm to the controller by damaging
components or causing electrical shorts. When our products are used in an industrial environment, install
them into an industrial electrical cabinet or industrial PC to protect them from excessive or corrosive
moisture, abnormal ambient temperatures, and conductive materials. If Delta Tau Data Systems, Inc.
products are directly exposed to hazardous or conductive materials and/or environments, we cannot
guarantee their operation.
REVISION HISTORY
REV. DESCRIPTION DATE CHG APPVD
0 Manual Creation 12/21/2012 DCDP SS
1 Corrected mistakes in Gate2 Clock Example 10/16/13 DCDP SM
Added new MACRO commands to Quick
2 1/15/14 DCDP EL
Reference
Power PMAC MACRO User Manual
Table of Contents
INTRODUCTION......................................................................................................................... 1
CONFIGURING GATE3 MACRO WITH POWER PMAC ................................................... 2
Clock Signals .................................................................................................................................. 2
Phase and Servo Clock Direction .............................................................................................. 2
Phase Clock Frequency.............................................................................................................. 2
Servo Clock Frequency .............................................................................................................. 3
Hardware Clock Frequencies .................................................................................................... 4
Example Clock Settings .............................................................................................................. 4
MACRO Communication Registers ............................................................................................... 5
Nodes and Addressing ................................................................................................................ 5
Input Registers ........................................................................................................................... 6
Output Registers ......................................................................................................................... 6
Data Organization within Servo Nodes ..................................................................................... 7
MACRO Communication Setup Instructions ................................................................................. 9
Enabling MACRO Nodes ........................................................................................................... 9
Configuring MACRO Modes .................................................................................................... 11
MACRO Error Testing Variables ............................................................................................ 14
Example MACRO Communication Setup................................................................................. 14
CONFIGURING GATE2 MACRO WITH POWER PMAC ................................................. 15
Clock Signals ................................................................................................................................ 15
Gate2[i].PwmPeriod: MaxPhase Clock Frequency Control ................................................... 15
Gate2[i].PhaseClockDiv: Phase Clock Frequency Control .................................................... 15
Gate2[i].ServoClockDiv: Servo Clock Frequency Control ..................................................... 16
Sys.ServoPeriod ....................................................................................................................... 16
Sys.PhaseOverServoPeriod...................................................................................................... 16
Example Clock Settings ............................................................................................................ 16
MACRO Communication Registers ............................................................................................. 17
Nodes and Addressing .............................................................................................................. 17
Data Organization within Servo Nodes ................................................................................... 19
MACRO Communication Setup Instructions ............................................................................... 21
Enabling MACRO Nodes ......................................................................................................... 21
Configuring MACRO Modes .................................................................................................... 22
MACRO Error Testing Variables ............................................................................................ 24
Example MACRO Communication Setup................................................................................. 24
POWER PMAC MACRO COMMANDS ................................................................................ 25
Online MACRO Commands Quick Reference ............................................................................. 25
Examples of Commands Using Symbolic Variables ................................................................ 30
Supported Power PMAC MACRO Registers ............................................................................... 31
1
Power PMAC MACRO User Manual
INTRODUCTION
This is the User Manual for the software setup of all Power PMAC MACRO Ring Controllers. It is
divided into two sections, Gate2 and Gate3.
Introduction 1
Power PMAC MACRO User Manual
Upon reinitialization of a Power PMAC UMAC system (by means of the $$$*** command most
typically), the CPU will automatically set up the lowest-numbered DSPGATE3 IC found as the source of
the system clock signals. It does this by setting Gate3[i].PhaseServoDir for this IC to 0, indicating that
this IC is the clock source. It sets Gate3[i].PhaseServoDir for all of the other ICs it finds to 3, so that
they will receive their phase and servo clock signals from the source IC.
For ICs that are receiving external phase clock signals, it is best to set Gate3[i].PhaseFreq to the same
value as the system clock frequency (i.e. the source IC’s phase clock frequency), or as close as possible.
These ICs are locked to the received system clock frequency by a digital phase-locked loop inside the IC,
but this circuit works best if the internal frequency is as close as possible to the received frequency.
It is possible to divide down the received phase clock frequency by a factor of 2, 3, or 4 by setting
Gate3[i].PhaseClockDiv to 1, 2, or 3, respectively. This is rarely done, however – the only real reason is
that doing so supports lower PWM frequencies on this IC.
Similarly, for the IC that is outputting its phase clock signal to the system, it is possible to multiply the
output phase clock frequency by a factor of 2, 3, or 4 by setting Gate3[i].PhaseClockMult to 1, 2, or 3,
respectively. This also is rarely done, and is done only for reasons of providing more flexibility in the
setting of PWM frequencies.
( )[ ]
[]
( )[ ]
or,
( )[ ]
( )[ ]
( [] )
For ICs receiving an external servo clock signal, the setting of this element does not really matter, but
users should set it to the same value as on the IC that is generating the system clock signals.
The global setup element Sys.ServoPeriod (in milliseconds) must be set to the inverse of the system
servo-clock frequency expressed in kHz. This parameter tells the trajectory interpolation algorithms how
far to advance the commanded motion equations each servo cycle. It can be set as follows:
( [] )
[]
The global setup element Sys.PhaseOverServoPeriod must be set to indicate the ratio between phase and
servo periods according to the following formula:
[]
Each of these parameters can take a value “n” from 0 to 15, specifying a frequency division factor of 2n
from the source clock frequency. For the first five of the listed clock frequencies, the source clock
frequency is 100 MHz, so the possible frequencies are 100 MHz, 50 MHz, 25 MHz, 12.5 MHz, etc.,
down to about 3 kHz. These parameters each have a default value of 5 (except for Gate3[i].FiltClockDiv,
which has a default setting of 4, which yields 6.25 MHz) for a division factor of 32, yielding a 3.125 MHz
frequency for their clock signal. This frequency is suitable for most applications. For these five clock
signals, the following table shows the possible settings of Gate3[i].xxxClockDiv and the frequencies they
produce:
For the secondary filtering clock, the source frequency is the encoder sampling clock, which has already
performed a primary filtering function. This parameter has a default value of 4 for a division factor of 32,
yielding a default 195.3 kHz frequency for the secondary digital delay filter.
// Hardware Clocks
Gate3[0].AdcAmpClockDiv=5; // Bit clock for amplifier A/D converters, 3.125 MHz
Gate3[0].AdcEncClockDiv=5; // Bit clock for encoder A/D converters, 3.125 MHz
Gate3[0].DacClockDiv=5; // Bit clock for D/A converters, 3.125 MHz
Gate3[0].PfmClockDiv=5; // Clock for PFM pulse-generation circuits, 3.125 MHz
Gate3[0].EncClockDiv=5; // Sampling clock for encoder and discrete-input circuits, 3.125 MHz
Gate3[0].FiltClockDiv=4; // Secondary filtering clock for discrete inputs, 6.25 MHz
Auxiliary nodes are Master/Control registers and are for internal firmware use.
Servo nodes carry information such as feedback, commands, and flags for motor
control.
I/O nodes are by default unoccupied and are user configurable for transferring
miscellaneous data.
Each motor that the ring controller controls requires one servo node, and therefore one ACC-5E3 can
control a maximum of 16 motors. The number of I/O nodes used depends on what I/O devices ACC-5E3
is controlling over the MACRO ring. A visual representation of the nodes’ individual functionality is
given below:
I/O Nodes
Node 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0
Auxiliary
Nodes Servo Nodes
Each node consists of 8 registers: four 32-bit “Input” registers, which can be accessed by the structure
Gate3[i].MacroInA[j][k] for bank A and Gate3[i].MacroInB[j][k] for bank B, and four 32-bit “Output”
registers, which can be accessed by the Power PMAC structures Gate3[i].MacroOutA[j][k] for bank A
and Gate3[i].MacroOutB[j][k] for bank B.
Input Registers
Gate3[i].MacroInA[j][k] accesses input data register k of node j of MACRO bank A in the IC. The data
register index k has a range of 0 to 3. The node index j has a range of 0 to 15. This bank has a master
number on the MACRO ring that is set by bits 28 – 31 of the saved setup element
Gate3[i].MacroEnableA. The input data in all four registers for the node j is automatically received and
latched every phase cycle if bit (j + 8) of Gate3[i].MacroEnableA is set to 1.
In the original MACRO protocol, only the high 24 bits of Gate3[i].MacroInA[j][0] are received over the
ring, and only the high 16 bits of Gate3[i].MacroInA[j][1], Gate3[i].MacroInA[j][2], and
Gate3[i].MacroInA[j][3] are received over the ring. In the new MACRO2 protocol, all 32 bits of all 4
node registers are received over the ring. However, as of this manual’s revision date, no MACRO Station
products yet utilize the MACRO2 protocol.
When the node is used for automatic servo control, saved setup element EncTable[i].pEnc will probably
be set to Gate3[i].MacroInA[j][0].a, and Motor[x].pEncStatus (and other associated address variables)
will be probably be set to Gate3[i].MacroInA[j][3].a. In this case, automatic Power PMAC tasks will
read from these registers, and in general, user application code does not need to read from these registers.
In the DSPGATE3 IC, these are separately addressed registers from the corresponding output values in
Gate3[i].MacroOutA, so it is not possible to write to these elements. In the older DSPGATE2 ICs, the
separate output and input values share a register.
Output Registers
Gate3[i].MacroOutA[j][k] is the output data register k of node j of MACRO bank A in the IC. The data
register index k has a range of 0 to 3. The node index j has a range of 0 to 15. This bank has a master
number on the MACRO ring that is set by bits 28 – 31 of saved setup element Gate3[i].MacroEnableA.
The output data in all four registers for the node j is automatically transmitted every phase cycle if bit (j +
8) of Gate3[i].MacroEnableA is set to 1.
In the original MACRO protocol, only the high 24 bits of Gate3[i].MacroOutA[j][0] are transmitted
over the ring, and only the high 16 bits of Gate3[i].MacroOutA[j][1], Gate3[i].MacroOutA[j][2], and
Gate3[i].MacroOutA[j][3] are transmitted over the ring. In the new MACRO2 protocol, all 32 bits of all
4 node registers are transmitted over the ring. However, as of this manual’s revision date, no MACRO
Station products yet utilize the MACRO2 protocol.
When the node is used for automatic servo control, saved setup element Motor[x].pDac will probably be
set to Gate3[i].MacroOutA[j][0].a, and Motor[x].pEncCtrl will be probably be set to
Gate3[i].MacroOutA[j][3].a. In this case, automatic Power PMAC tasks will write to these registers, and
in general, user application code should not write to these registers.
In the DSPGATE3 IC, it is possible to read back what has been written to these registers, as the
corresponding inputs are in separate registers Gate3[i].MacroInA[j][k]. In the older DSPGATE2 ICs, the
separate output and input values share a register, so it is not possible to read back the output values
written to the registers.
Then, the contents of each servo node are arranged in each MACRO bank as follows:
MACRO Bank A
Node Structure Bit 31 Bit 0
MACRO Bank B
Node Structure Bit 31 Bit 0
Since no Gate3-style MACRO Station products have yet been developed, this is the only node
arrangement available until future developments.
I/O Nodes can be arranged in any way desired, and as such, this
manual does not have any section describing any specific data
arrangement structure within I/O nodes.
Note
The 4-bit component MacroMasterNumA specifies the number of the master address for all 16 “A” nodes
in the IC. This 4-bit value, along with the 4-bit node number, will be transmitted as part of the header byte
for each node packet.
The 4-bit component MacroSyncNodeA specifies the number of the “sync packet” node. If this IC is not
acting as the synchronizing master for the ring, and is not receiving the phase clock signal directly from
another IC in the same device, receipt of a data packet for this node will cause an internal synchronizing
signal to be generated, keeping this IC properly locked to the ring timing.
The 16-bit component MacroNodeEnaA specifies which “A” nodes are enabled on the ring. Bit n controls
node n; a value of 0 in the bit disables the node; a value of 1 in the bit enables the node.
Gate3[i].MacroEnableB is a 32-bit word that configures the master address, the sync packet node
number, and the active nodes for the first set of MACRO interfaces (“B”) for the IC. It is composed of the
following components (which cannot be accessed as independent elements):
The 4-bit component MacroMasterNumB specifies the number of the master address for all 16 “B” nodes
in the IC. This 4-bit value, along with the 4-bit node number, will be transmitted as part of the header byte
for each node packet.
The 4-bit component MacroSyncNodeB specifies the number of the “sync packet” node. If this IC is not
acting as the synchronizing master for the ring, and is not receiving the phase clock signal directly from
another IC in the same device, receipt of a data packet for this node will cause an internal synchronizing
signal to be generated, keeping this IC properly locked to the ring timing.
The 16-bit component MacroNodeEnaB specifies which “B” nodes are enabled on the ring. Bit n controls
node n; a value of 0 in the bit disables the node; a value of 1 in the bit enables the node.
The 8-bit component MacroMasterChkDisA specifies whether the IC will check the master number for
the highest-numbered eight “A” nodes on the IC. Bit n of the component (which is bit n+8 of the full-
word element) controls Node n+8 of the IC. If the bit is 0, the IC will check the master number of the
incoming packet for the matching node number, so the packet can be used for point-to-point
communication across the ring. If the bit is 1, the IC will not check the master number of the incoming
packet for the matching node number, so the packet can be used for “broadcast” purposes.
The 1-bit component MacroSyncEnaA specifies whether the IC’s phase clock will be synchronized by the
receipt of the specified “sync packet” or not. If it is set to 0, no synchronization will be performed; if it is
set to 1, the IC’s phase clock timer will be synchronized to the timing of the receipt of the sync packet on
the ring. This bit is not used if the IC is the synchronizing master for the ring, or if it is receiving the
phase clock from another IC in the same device.
The 1-bit component MacroSyncRcvdA is a read-only status bit that is set to 1 when the specified sync
packet is received. It is automatically set to 0 when this register is read, so it indicates to the processor
whether a sync packet has been received since the last time the register was read. The 2-bit component
MacroStationTypeA specifies the function of the station containing this IC on the MACRO ring. Its
possible values specify the following frequencies:
0: Slave
1: Master
2: (Reserved for future use)
3: Synchronizing master
The 1-bit component MacroUnderrunErrA is a read-only status bit that is set to 1 when the IC receives a
data packet with too few bytes in it. It is automatically set to 0 when this register is read, so it indicates to
the processor whether an underrun error has occurred since the last time the register was read.
The 1-bit component MacroParityErrA is a read-only status bit that is set to 1 when the IC receives a data
packet with a parity or CRC check error. It is automatically set to 0 when this register is read, so it
indicates to the processor whether a parity/CRC error has occurred since the last time the register was
read.
The 1-bit component MacroCodeErrA is a read-only status bit that is set to 1 when the IC receives a data
packet with an illegally coded byte in it. It is automatically set to 0 when this register is read, so it
indicates to the processor whether a coding error has occurred since the last time the register was read.
The 1-bit component MacroOverrunErrA is a read-only status bit that is set to 1 when the IC receives a
data packet with too many bytes in it. It is automatically set to 0 when this register is read, so it indicates
to the processor whether an overrun error has occurred since the last time the register was read.
Gate3[i].MacroModeB is the full-word element that comprises the control and status components for the
first set of MACRO interfaces (“B”) for the IC. It is composed of the following components (which
cannot be accessed as independent elements):
The 8-bit component MacroMasterChkDisB specifies whether the IC will check the master number for
the highest-numbered eight “B” nodes on the IC. Bit n of the component (which is bit n+8 of the full-
word element) controls Node n+8 of the IC. If the bit is 0, the IC will check the master number of the
incoming packet for the matching node number, so the packet can be used for point-to-point
communication across the ring. If the bit is 1, the IC will not check the master number of the incoming
packet for the matching node number, so the packet can be used for “broadcast” purposes.
The 1-bit component MacroSyncEnaB specifies whether the IC’s phase clock will be synchronized by the
receipt of the specified “sync packet” or not. If it is set to 0, no synchronization will be performed; if it is
set to 1, the IC’s phase clock timer will be synchronized to the timing of the receipt of the sync packet on
the ring. This bit is not used if the IC is the synchronizing master for the ring, or if it is receiving the
phase clock from another IC in the same device.
The 1-bit component MacroSyncRcvdB is a read-only status bit that is set to 1 when the specified sync
packet is received. It is automatically set to 0 when this register is read, so it indicates to the processor
whether a sync packet has been received since the last time the register was read. The 2-bit component
MacroStationTypeB specifies the function of the station containing this IC on the MACRO ring. Its
possible values specify the following frequencies:
0: Slave
1: Master
2: (Reserved for future use)
3: Synchronizing master
The 1-bit component MacroUnderrunErrB is a read-only status bit that is set to 1 when the IC receives a
data packet with too few bytes in it. It is automatically set to 0 when this register is read, so it indicates to
the processor whether an underrun error has occurred since the last time the register was read.
The 1-bit component MacroParityErrB is a read-only status bit that is set to 1 when the IC receives a data
packet with a parity or CRC check error. It is automatically set to 0 when this register is read, so it
indicates to the processor whether a parity/CRC error has occurred since the last time the register was
read.
The 1-bit component MacroCodeErrB is a read-only status bit that is set to 1 when the IC receives a data
packet with an illegally coded byte in it. It is automatically set to 0 when this register is read, so it
indicates to the processor whether a coding error has occurred since the last time the register was read.
The 1-bit component MacroOverrunErrB is a read-only status bit that is set to 1 when the IC receives a
data packet with too many bytes in it. It is automatically set to 0 when this register is read, so it indicates
to the processor whether an overrun error has occurred since the last time the register was read.
Macro.TestPeriod
This is the period in servo cycles at which PMAC checks for errors on the MACRO ring. The
recommended value for this variable is 10/Sys.ServoPeriod, which produces a period of 10 milliseconds.
Macro.TestMaxErrors
This is the maximum error count PMAC can receive in one test period (whose duration is specified by
Macro.TestPeriod) before triggering a fault. The formula for computing this variable is as follows:
Macro.TestReqdSynchs
This is the number of sync packets in one period (whose duration is specified by Macro.TestPeriod) that
PMAC must receive before triggering an error. The formula for computing this variable is as follows:
- .
Sys.WpKey=0;
Gate2[i].PwmPeriod
Gate2[i].PhaseClockDiv
Gate2[i].ServoClockDiv
To set Gate2[i].PwmPeriod for a desired “MaxPhase” clock frequency, the following formula
can be used:
[ ]
[]
[ ]
[ ]
[]
[ ]
At the default value of 0 (divide by 1) and the default MaxPhase frequency of 9.04 kHz, this sets
a phase clock frequency of 9.04 kHz (110 μsec period).
[ ]
[]
[ ]
At the default value of 3 (divide by 4) and the default phase clock frequency of 9.04 kHz, this
sets a servo clock frequency of 2.26 kHz (442 μsec period).
The following diagram shows the relationship between the PWM counter, whose
period/frequency is set by the Gate2[i].PwmPeriod parameter, the resulting MaxPhase clock
signal, and the phase and servo clock signals that are derived from MaxPhase.
Sys.ServoPeriod
You must set Sys.ServoPeriod according to the following formula:
( [] )( [] )( [] )
Sys.PhaseOverServoPeriod
Set Sys.PhaseOverServoPeriod according to the following formula:
[]
Each motor that the ring controller controls requires one servo node, and therefore one ACC-5E can
control a maximum of 16 motors. The number of I/O nodes used depends on what I/O devices ACC-5E is
controlling over the MACRO ring. A visual representation of the nodes’ individual functionality is given
below:
I/O Nodes
Node 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0
Auxiliary
Nodes Servo Nodes
Gate2[i].Macro[j][k] is the input/output data register k of node j of the MACRO bank in the IC. The data
register index k has a range of 0 to 3. The node index j has a range of 0 to 15. This bank has a master
number on the MACRO ring that is set by bits 20 – 23 of saved setup element Gate2[i].MacroEnable.
The output data in all four registers for the node j is automatically sent, and the input data in all four
registers is received every phase cycle if bit j of Gate2[i].MacroEnable is set to 1.
These are 24-bit elements in the Script environment. Gate2[i].Macro[j][0] has real ring data in all 24
bits, while Gate2[i].Macro[j][1], Gate2[i].Macro[j][2], and Gate2[i].Macro[j][3] only have real ring
data in the high 16 bits.
Note that the output and input registers share an element – a write operation to the element accesses the
output register, and this value will be sent out across the ring; a read operation from the element accesses
the input register, getting a value that has been received from across the ring. This means that it is not
possible to read back an output value that has been written to one of these elements.
When the node is used for automatic servo control, saved setup element Motor[x].pDac will probably be
set to Gate2[i].Macro[j][0].a, and Motor[x].pEncCtrl will be probably be set to Gate2[i].Macro[j][3].a.
In this case, automatic Power PMAC tasks will write to these registers, and in general, user application
code should not write to these registers.
In the C-language environment, these are 32-bit elements, with the real data in the high 24 or 16 bits, so
you must be careful to appropriately mask and shift to read from or write to the appropriate bits in these
words.
Then, the contents of each servo node are arranged in each MACRO bank as follows when the Ring
Controller is receiving data from the rest of the Stations on the MACRO ring, as viewed in Script:
MACRO Input
Node Structure Bit 23 Bit 0
MACRO Output
24 bits of servo output command in Analog Output Mode/
Gate2[i].Macro[j][0] 24 bits of DACA output in UV Commutation Mode/
24 bits of PWMA command in Direct PWM Mode
Not Used in Analog Output Mode/
Gate2[i].Macro[j][1] 16 bits of DACB command in UV Commutation Mode/ 8 bits of 0
16 bits of PWMB command in Direct PWM Mode
Not Used in Analog Output Mode/
Gate2[i].Macro[j][2] Not Used in UV Commutation Mode/ 8 bits of 0
16 bits of PWMC command in Direct PWM Mode
Since no Gate3-style MACRO Station products have yet been developed, this is the only node
arrangement available until future developments.
I/O Nodes can be arranged in any way desired, and as such, this
manual does not have any section describing any specific data
arrangement structure within I/O nodes.
Note
Bits 0 to 15 are individual control bits for the matching node number 0 to 15. If the bit is set to 1, the node
is activated; if the bit is set to 0, the node is de-activated.
If the MACRO IC is a master station (likely) as determined by Gate2[i].MacroMode, it will send out a
packet for each activated node every ring cycle (every phase cycle). When it receives a packet for an
activated node, it will latch in that packet and not pass anything on.
If the MACRO IC is a slave station (unlikely but possible) as determined by Gate2[i].MacroMode, when
it receives a packet for an activated node, it will latch in the contents of that packet into its read registers
for that node address, and automatically substitute the contents of its write registers into the packet.
If a node is disabled, whether master or slave, it will still latch in the contents of a packet it receives, but it
will also pass on the packet unchanged. This feature is particularly useful for the MACRO broadcast
feature, in which multiple stations need to receive the same packet.
Bits 16–19 together specify the slave number part of the packet address (0–15) that will cause a sync lock
pulse on the card, if this function is enabled by Gate2[i].MacroMode. This function is useful for a Power
PMAC that is a slave or non-synchronizing master on the ring, to keep it locked to the synchronizing
master. If the master address check for this node is disabled with Gate2[i].MacroMode, only the slave
number must match to create the sync lock pulse. If the master address check is left enabled, the master
number part of the packet address must match the master number for the card, as set in bits 20–23 of
Gate2[i].MacroEnable.
If this card is the synchronizing master, this function is not enabled, so the value of these bits does not
matter; they can be left at the default of 0.
Bits 20–23 specify the master number for the MACRO IC (0–15). Each MACRO IC on a ring must have
a separate master number, even multiple MACRO ICs on the same Turbo PMAC2 Ultralite. The number
must be specified whether the card is used as a master or a slave.
In most applications, the only important configuration bits are bits 4, 5, and 7. In every MACRO ring,
there must be one and only one synchronizing master station (each MACRO IC counts as a separate
station; only one MACRO IC on any card in the ring can be a synchronizing master station). For this
MACRO IC, bits 4 and 5 should be set (1), but bit 7 should be clear (0). This results in a value of $30, or
$xx30 if any of the high bits are to be set.
If there are more than one MACRO ICs acting as masters on the ring, the others should not be
synchronizing masters, but they should be set up as regular (non-synchronizing) masters. If they are
receiving the phase clock signal directly from the synchronizing master IC, bit 4 should be set (1), and
bits 5 and 7 should be clear (0). This results in a value of $10, or $xx10 if any of the high bits are set.
If they are not receiving the phase clock signal directly from the synchronizing master IC, they should
enable “sync node phase lock” to stay synchronized with the synchronizing master by receipt of the “sync
packet”. For these MACRO ICs, bit 4 should be set (1), bit 5 should be clear (0), and bit 7 should be set
(1), resulting in a value of $90, or $xx90 if any of the high bits are to be set.
Bits 8–15 can be set individually to disable the “master address check” for their corresponding node
numbers. This capability is for multi-master broadcast and synchronization. If the master address check is
disabled, only the slave node number part of the packet address must match for a packet to be latched in.
In this way, the synchronizing master can send the same data packet to multiple other master and slave
stations. This common packet can be used to keep multiple stations synchronized using the sync lock
function enabled with bit 7 of Gate2[i].MacroMode; the packet number is specified in
Gate2[i].MacroEnable (packet 15 is suggested for this purpose).
Macro.TestPeriod
This is the period in servo cycles at which PMAC checks for errors on the MACRO ring. The
recommended value for this variable is 10/Sys.ServoPeriod, which produces a period of 10 milliseconds.
Macro.TestMaxErrors
This is the maximum error count PMAC can receive in one test period (whose duration is specified by
Macro.TestPeriod) before triggering a fault. The formula for computing this variable is as follows:
Macro.TestReqdSynchs
This is the number of sync packets in one period (whose duration is specified by Macro.TestPeriod) that
PMAC must receive before triggering an error. The formula for computing this variable is as follows:
- .
CSGlobal Variables
csglobal myqvar, myqarray(16);
Ptr Variables
ptr mymvar->*, mymarray(16)-> u.user:200+;