User manual

TMCM-1180 and PD86-1180 TMCL Firmware V4.42 Manual (Rev. 1.08 / 2012-NOV-20) 15
www.trinamic.com
5.4.2 Parameter commands
These commands are used to set, read and store axis parameters or global parameters. Axis parameters can
be set independently for the axis, whereas global parameters control the behavior of the module itself. These
commands can also be used in direct mode and in standalone mode.
Mnemonic
Command
number
Meaning
SAP
5
Set axis parameter
GAP
6
Get axis parameter
STAP
7
Store axis parameter into EEPROM
RSAP
8
Restore axis parameter from EEPROM
SGP
9
Set global parameter
GGP
10
Get global parameter
STGP
11
Store global parameter into EEPROM
RSGP
12
Restore global parameter from EEPROM
5.4.3 I/O port commands
These commands control the external I/O ports and can be used in direct mode and in standalone mode.
Mnemonic
Command
number
Meaning
SIO
14
Set output
GIO
15
Get input
5.4.4 Control commands
These commands are used to control the program flow (loops, conditions, jumps etc.). It does not make
sense to use them in direct mode. They are intended for standalone mode only.
Mnemonic
Command
number
Meaning
JA
22
Jump always
JC
21
Jump conditional
COMP
20
Compare accumulator with constant
value
CLE
36
Clear error flags
CSUB
23
Call subroutine
RSUB
24
Return from subroutine
WAIT
27
Wait for a specified event
STOP
28
End of a TMCL program
5.4.5 Calculation commands
These commands are intended to be used for calculations within TMCL applications. Although they could
also be used in direct mode it does not make much sense to do so.
Mnemonic
Command
number
Meaning
CALC
19
Calculate using the accumulator and a
constant value
CALCX
33
Calculate using the accumulator and the
X register
AAP
34
Copy accumulator to an axis parameter
AGP
35
Copy accumulator to a global parameter
ACO
39
Copy accu to coordinate