User Manual

TMCM-3351 TMCL
Firmware Manual Firmware Version V1.11 | Document Revision V1.06 2019-APR-26
95 / 144
3.6.52 AAPX (Accu to Axis Parameter, Axis specied by X Register)
The AAPX command nearly works the same way as the AAP command, with the only exception that the
axis number is specied by the X register. This command is mainly intended for use in standalone mode.
Info
For a table with parameters and values which can be used together with this
command please refer to section 4.
Related commands: SAPX, GAPX.
Mnemonic: AAPX <parameter number>
Binary Representation
Instruction Type Motor/Bank Value
18 see chapter 4 (dont care) (dont care)
Reply in Direct Mode
Status Value
100 - OK dont care
Example
Loop over all motors, positon them at dierent speeds:
SGP 0, 2, 5 // initalize user variable 0 with 5 (used as loop counter)
2
CALCXV LOAD , 0 //set X register to 0
SGP 1, 2, 50 // initialize user variable 1 with 50
4
Loop:
6
GGP 1, 2 //copy user variable 1 to accu
CALCXV LOAD , 0 // copy user variable 0 (loop counter) to X register
8
AAPX 4 //set maximum positioning speed of motor
CALC LOAD , 51200 // initialize accu with target position
10
MVPXA ABS // position motor
WAIT TICKS , 0, 100 //wait 1 second
12
CALCV MUL , 1, 2 //multiply user variable 1 with 2
DJNZ 0, Loop // next iteration
©2019 TRINAMIC Motion Control GmbH & Co. KG, Hamburg, Germany
Terms of delivery and rights to technical change reserved.
Download newest version at www.trinamic.com