User manual

PD-1021 TMCL Firmware V1.19 Manual (Rev. 1.01 / 2012-JUL-30) 18
www.trinamic.com
3.5 Commands
The module specific commands are explained in more detail on the following pages. They are listed
according to their command number.
3.5.1 ROR (rotate right)
With this command the motor will be instructed to rotate with a specified velocity in positive direction
(increasing the position counter).
Like on all other TMCL modules, the motor will be accelerated or decelerated to the speed given with the
command. The speed is given in microsteps per second (pps). For conversion of this value into rounds
per minute etc. please refer to chapter 4.1, also.
The range is -268.435.455… +268.435.454.
Internal function: First, velocity mode is selected. Then, the velocity value is transferred to axis
parameter #0 (target velocity).
Related commands: ROL, MST, SAP, GAP
Mnemonic: ROR 0, <velocity>
Binary representation:
INSTRUCTION NO.
TYPE
MOT/BANK
VALUE
1
(don't care)
0*
<velocity>
-268.435.455…
+268.435.454
*motor number is always O as the module supports just one axis
Reply in direct mode:
STATUS
VALUE
100 OK
(don't care)
Example:
Rotate right, velocity = 10000
Mnemonic: ROR 0, 10000
Binary:
Byte Index
0
1
2
3
4
5
6
7
Function
Target-
address
Instruction
Number
Type
Motor/
Bank
Operand
Byte3
Operand
Byte2
Operand
Byte1
Operand
Byte0
Value (hex)
$01
$01
$00
$00
$00
$00
$27
$10