User's Manual

PMAC User Manual
Setting Up PMAC Commutation 93
For example:
M171->TWR:0,2 ;Resolver at multiplexer address 0, location 2 at that
; address on an Acc-8D Opt 7 board
M171->Y:$FFD0,0,16,U ;16-bit parallel absolute sensor at first Acc-14 Port A
Next, manually run the stepper motor phasing search, using on-line commands. The point of this
sequence is to force the motor into the zero-point of the phasing cycle. At this point, read the absolute
sensor using the M-variable we have defined. Use Motor 1 for the example. The exact sequence depends
on the phase angle value in Ix72.
For I172 = 64 (4-phase) or 85 (3-phase):
#1O0 ; Open-loop command of zero magnitude
I129=-2000 I179=2000 ; Force motor to preliminary position
I129=0 ; Now force motor to zero-point of phase cycle Ix29 can
; be set to non-zero value here if the current loop
; bias has been evaluated, in which case Ix29 is set
; to the value that forces zero current through the
; phase. For I172 = 192 (4-phase) or 171 (3-phase):
#1O0 ; Open-loop command of zero magnitude
I129=2000 I179=-2000 ; Force motor to preliminary position
I129=0 ; Now force motor to zero-point of phase cycle
; See note above on phase current bias
At this point, read the absolute position sensor by querying the M-variable value. For example:
M171 ; Ask for value of M171
475 ; PMAC responds
Take the value PMAC returns, negate it, multiply it by Ix70, and put the resulting value in Ix75.
Continuing our example, if I170=1, issue the command:
I175=-475
If I170=2, issue the command:
I175=-950
Final Preparations
To finish the preparation for the absolute phasing read, a few more things must be done. Remove the
remaining phase offset by setting Ix79 back to 0; prevent any phasing-search move by setting Ix73 and
Ix74 to 0, and/or removing the phasing-search PLC program; define the address for the absolute phase
position read by setting Ix81; and decide whether to enable the motor immediately on power-up/reset by
setting Ix80. To continue the example:
I179=0 ; Remove phase bias (or set to bias for zero current)
I173=0 ; Disable phasing search
I174=0 ; Disable phasing search
I180=1 ; Enable motor immediately on power-up reset
I181=$020100 ; Read R/D at location 2 ($02) of multiplexer
; address 0 ($0100) for initial phase position or
I181=$10FFD0 ; Read 16 bits ($10) of parallel data from Port A
; of 1st Acc-14 ($FFD0) for initial phase position
Trying Absolute Phasing
Now try the setup by issuing the $ motor-reset command. If the phasing works well, the motor should
move easily in both directions with small open-loop commands. If the servo loop has been tuned
reasonably, the motor can now job in both directions as well, but poor jogging performance could be due
to a poorly tuned servo loop, especially if the open-loop commands work well.