AN2364 Freescale Semiconductor / Motorola, AN2364 Datasheet - Page 9

no-image

AN2364

Manufacturer Part Number
AN2364
Description
Using the Table Stepper Motor TPU Function (TSM) with the MPC500 Family
Manufacturer
Freescale Semiconductor / Motorola
Datasheet
4.1.1
This 16-bit parameter contains the desired position (destination) of the stepper motor. The CPU can write
DESIRED_POSITION at any time. If the motor is not already moving, then a host service request (HSR)
type %11 must be issued to the master channel to initiate the move. The range for DESIRED_POSITION
is $0000 to $FFFF.
4.1.2
This 16-bit parameter is maintained by the TPU. It contains the current position of the stepper motor. The
parameter is incremented or decremented for each completed step depending on the direction of the step. In
this way CURRENT_POSITION tracks the movement of the motor. The motor stops when it has
decelerated
CURRENT_POSITION is updated after the relevant step has completed, but the exact timing of the update
cannot be predicted due to the service scheme of the TPU. For this reason when CURRENT_POSITION is
read while the motor is moving, there can be an error of +/- 1 step. After the TPU has issued the interrupt
request at the end of the move, CURRENT_POSITION will be accurate.
CURRENT_POSITION should be initialized by the CPU as part of the function initialization.
4.1.3
This 8-bit parameter, initialized by the CPU, defines the length of the acceleration table. The valid range for
TABLE_SIZE is 1 to maximum. In local table configuration, maximum is 16 in two channel mode. In local
table configuration and four channel mode, the maximum is 48. In split table configuration, the maximum
is 64 in two channel mode and 96 in four channel mode. Note that maximum will be reduced if a consecutive
channel, that would have been a slave parameter table channel, is programmed as another TSM master
channel or to run another TPU function. TABLE_SIZE should not be written while the motor is moving.
4.1.4
This 8-bit parameter is used by the TPU as a pointer into the acceleration parameter table. Update timing is
not specified for TABLE_INDEX and it is not recommended for interpretation by the user. TABLE_INDEX
should be written to zero by the CPU during initialization and then never written again. Writing
TABLE_INDEX while the motor is running will result in indeterminate operation.
4.1.5
This bit flag is used internally by the TPU to track slew rate operation. Update timing is not specified for
BIT_S and it is not recommended for interpretation by the user. BIT_S should be written to zero by the CPU
during initialization and then never written again.
4.1.6
This 15-bit parameter is written by the CPU. It determines the slew rate (maximum stepping speed) of the
stepper motor. The value programmed into SLEW_PERIOD determines the step period in TCR1 clocks
during the constant speed part of a move. The valid range for SLEW_PERIOD is from one to
START_PERIOD, although in practice the minimum sustainable SLEW_PERIOD will be determined by
TPU latency and motor characteristics. SLEW_PERIOD should not be changed while the motor is moving.
MOTOROLA
DESIRED_POSITION
CURRENT_POSITION
TABLE_SIZE
TABLE_INDEX
BIT_S
SLEW_PERIOD
to
the
start/stop
Freescale Semiconductor, Inc.
Using the Table Stepper Motor TPU Function
For More Information On This Product,
rate
Go to: www.freescale.com
and
CURRENT_POSITION
TSM Function Parameters Address Maps
=
DESIRED_POSITION.
9

Related parts for AN2364