User Manual

TMCM-3230 TMCL
Firmware Manual Firmware Version V1.07 | Document Revision V1.05 2017-OCT-10
42 / 103
3.6.16 JC (Jump conditional)
The JC instruction enables a conditional jump to a xed address in the TMCL program memory, if the
specied condition is met. The conditions refer to the result of a preceding comparison. Please refer to
COMP instruction for examples. This command is intended for standalone operation only.
Internal function:
The TMCL program counter is set to the value passed to this command if the status
ags are in the appropriate states.
Related commands: JA, COMP, WAIT, CLE.
Mnemonic: JC <condition>, <label>
Binary Representation
Instruction Type Motor/Bank Value
21 0 ZE - zero 0 (dont care) <jump address>
1 NZ - not zero
2 EQ - equal
3 NE - not equal
4 GT - greater
5 GE - greater/equal
6 LT - lower
7 LE - lower/equal
8 ETO - time out error
9 EAL - external alarm
10 EDV - deviation error
11 EPO - position error
Example
Jump to the address given by the label when the position of motor #0 is greater than or equal to 1000.
1
GAP 1, 0 // get actual position of motor 0
COMP 1000 //compare actual value with 1000
3
JC GE, Label //jump to Lable if greter or equal to 1000
...
5
Label: ROL 0, 1000
©2017 TRINAMIC Motion Control GmbH & Co. KG, Hamburg, Germany
Terms of delivery and rights to technical change reserved.
Download newest version at www.trinamic.com