English
Language : 

TMC4361A Datasheet, PDF (144/229 Pages) TRINAMIC Motion Control GmbH & Co. KG. – SPI Interfaces for SPI motor stepper drivers.
TMC4361A Datasheet | Document Revision 1.20 • 2016-NOV-10
144/229
Encoder
Misalignment
Compensation
A) 8
6
If the encoder is installed correctly, the encoder values form a circle for one motor
revolution. Thus, the deviation ENC_POS_DEV between real position ENC_POS und
internal position XACTUAL forms a constant function over the whole motor revolution.
Consequently, the resulting form of a deficiently installed encoder is oval-shaped. This
system failure results in a new function of ENC_POS_DEV that is similar to a sine
function. In Figure 58 A below, the position deviation is shown as function of one
motor revolution, which comprises 51200 microsteps.
TMC4361A provides an option to compensate this kind of misalignment by adding a
triangular shape function that counteracts the system error. This can improve the
encoder value evaluation significantly. Per default, this function is constant at 0.
In order to setup the triangular compensation function, do as follows:
Action:
 Set proper ENC_COMP_XOFFSET register 0x7D (15:0).
 Set proper ENC_COMP_YOFFSET register 0x7D (23:16).
 Set proper ENC_COMP_AMPL register 0x7D (31:24).
Result:
ENC_COMP_XOFFSET is 16-bit register which represents a numeral figure between 0
and 1. The resulting offset on the abscissa is calculated by:
XOFF_LOW = ENC_COMP_XOFFSET · microsteps/rev / 65536.
A triangular function is generated, which has its lowest point at
(XOFF_LOW; ENC_COMP_YOFFSET).
The peak is shifted at a distance of half a revolution. The peak coordinate
(XOFF_PEAK;YOFF_PEAK) is calculated as follows:
XOFF_PEAK = ENC_COMP_XOFFSET · microsteps/rev / 65536 + microsteps/rev / 2.
YOFF_PEAK = ENC_COMP_YOFFSET + ENC_COMP_AMPL.
In Figure 58 A, the red line illustrates this compensation function.
Internally, the triangular function is added to the ENC_POS value. As a result, the
position deviation is harmonized as a function of the motor revolution; which can be
seen in Figure 58 B.
B) 8
6
4
AMPL
4
2
XOFF
0
0
10000
-2
YOFF
-4
20000
30000
40000
µsteps
50000
2
0
0
-2
-4
µsteps
10000 20000 30000 40000 50000
-6
position deviation
-6
compensation function
-8
-8
position deviation
Figure 61: Triangular Function that compensates Encoder Misalignments
© 2015 TRINAMIC Motion Control GmbH & Co. KG, Hamburg, Germany — Terms of delivery and rights
to technical change reserved. Download newest version at: www.trinamic.com .
Read entire documentation; especially the “Supplemental Directives” on page 223.
 MAIN MANUAL 