Datasheet

TMC5062 DATASHEET (Rev. 1.11 / 2017-MAY-16) 74
www.trinamic.com
THE ENCODER COUNTER X_ENC
The encoder counter X_ENC holds the current encoder position ready for read out. Different modes
concerning handling of the signals A, B, and N take into account active low and active high signals
found with different types of encoders. For more details please refer to the register mapping in
section 6.3.
THE REGISTER ENC_STATUS
The register ENC_STATUS holds the status concerning the event of an encoder clear upon an N
channel signals. The register ENC_LATCH stores the actual encoder position on an N signal event.
15.1 Encoder Timing
The encoder inputs use analog and digital filtering to ensure reliable operation even with increased
cable length. The maximum continuous counting rate is limited by input filtering to 2/3 of f
CLK
.
Encoder interface timing
AC-Characteristics
clock period is t
CLK
Parameter
Symbol
Conditions
Min
Typ
Max
Unit
Encoder counting frequency
f
CNT
<2/3 f
CLK
f
CLK
A/B/N input low time
t
ABNL
3 t
CLK
+20
ns
A/B/N input high time
t
ABNH
3 t
CLK
+20
ns
A/B/N spike filtering time
t
FILTABN
Rising and falling
edge
3 t
CLK
15.2 Setting the Encoder to Match Motor Resolution
Encoder example settings for motor parameters: USC=256 µsteps, 200 fullstep motor
Factor = FSC*USC / encoder resolution
ENCODER EXAMPLE SETTINGS FOR A 200 FULLSTEP MOTOR WITH 256 MICROSTEPS
Encoder resolution
Required encoder factor
Comment
200
256
360
142.2222
= 9320675.5555 / 2^16
= 1422222.2222 / 10000
No exact match possible!
500
102.4
= 6710886.4 / 2^16
= 1024000 / 10000
Exact match with decimal setting
1000
51.2
Exact match with decimal setting
1024
50
4000
12.8
Exact match with decimal setting
4096
12.5
16384
3.125
Example:
The encoder constant register shall be programmed to 51.2 in decimal mode. Therefore, set


 
15.3 Closing the Loop
Depending on the application, an encoder can be used for different purposes. Medical applications
often require an additional and independent monitoring to detect hard or soft failure. Upon failure,
the machine can be stopped and restarted manually. Less critical applications may use the encoder to
detect failure, stop the motors upon step loss and restart automatically. A different use of the encoder