
AMIS-30624 I
2
C Microstepping Motordriver
Data Sheet
19
15.1.2. Dual Positioning
A
SetDualPosition
command allows the user to perform positioning using two different velocities. The first motion is done with the
specified Vmin and Vmax velocities in the
SetDualPosition
command, with the acceleration (deceleration) parameter already in
RAM, to a position Pos1[15:0] also specified in
SetDualPosition
.
A second relative motion to a position Pos1[15:0] + Pos2[15:0] is done at the specified Vmin velocity in the
SetDualPosition
command (no acceleration). Once the second motion is achieved, the ActPos register is reset to zero, whereas TagPos register is not
changed.
Figure 8:Dual Positioning
Remark
: This operation cannot be interrupted or influenced by any further command unless the conditions exist to cause a
motor
shutdown
or by a HardStop command. Sending a
SetDualPosition
command while a motion is already ongoing is not
recommended.
Notes:
(0)
The
priority encoder
describes the management of states and commands. All notes below are to be considered illustrative.
(1)
The last
SetPosition
command issued during a DualPosition sequence will be kept in memory and executed afterwards. This also applies to the commands
SetMotorParam
and
GotoSecurePosition
.
(2)
Commands such as
GetFullStatus1
or
GetFullStatus2
will be executed while a Dual Positioning is running.
(3)
A DualPosition sequence starts by setting TagPos register to SecPos value, provided secure position is enabled otherwise TagPos is reset to zero.
(4)
The acceleration/deceleration value applied during a DualPosition sequence is the one stored in RAM before the
SetDualPosition
command is sent. The
same applies for Shaft bit, but not for Irun, Ihold and StepMode, which can be changed during the Dual Positioning sequence.
(5)
The Pos1, Pos2, Vmax and Vmin values programmed in a
SetDualPosition
command apply only for this sequence. All further positioning will use the
parameters stored in RAM (programmed for instance by a former
SetMotorParam
command).
(6)
Commands
ResetPosition
,
SetDualPosition
, and
SoftStop
will be ignored while a DualPosition sequence is ongoing, and will not be executed afterwards.
(7)
A
SetMotorParam
command should not be sent during a
SetDualPosition
sequence.
(8)
If for some reason ActPos equals Pos1[15:0] at the moment the
SetDualPosition
command is issued, the circuit will enter in deadlock state. Therefore, the
application should check the actual position by a
GetFullStatus2
command prior to send the
SetDualPosition
command.
15.1.3. Position Periodicity
Depending on the stepping mode the position can range from –4096 to +4095 in half-step to –32768 to +32767 in 1/16
th
microstepping
mode. One can project all these positions lying on a circle. When executing the command
SetPosition
,
the position controller will
set the movement direction in such a way that the traveled distance is at a minimum.
Figure 9 illustrates that the moving direction going from
ActPos
= +30000 to
TagPos
= –30000 is clockwise.
If a counter clockwise motion is required in this example, several consecutive
SetPosition
commands can be used. For larger
movements, one could also use the command
RunVelocity
.
0
ActPos = +30000
TagPos = -30000
-10000
-20000
+10000
+20000
Motion direction
Figure 9: Motion Direction is Function on Difference Between ActPos and TagPos
Velocity
First motion
Second motion
PC20070221.1
Vmax
Vmin
27 ms
27 ms
R
t
P
P
P
AMI Semiconductor
– Apr. 2007, Rev 3.1, M-20664-003
www.amis.com