MODULE Module for Stepper Motors TMCM-1070 TMCL™ Firmware Manual Firmware Version V1.01 | Document Revision V1.1 • 2017-Mar-02 TMCM-1070 is an easy to use stepper motor driver module. The module is controlled via a step and direction interface. One configuration pin selects the current control mode between stealthChop™ for absolute silent motor control and spreadCycle™ for high speed. A TTL UART interface allows for more advanced configuration and permanent parameter storage via TMCL™-IDE.
TMCM-1070 TMCL™ Firmware Manual • Firmware Version V1.01 | Document Revision V1.1 • 2017-Mar-02 2 / 38 Contents 1 Features 1.1 stallGuard2 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1.2 coolStep . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 4 5 5 2 First Steps with TMCL 2.1 Basic Setup . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2.
TMCM-1070 TMCL™ Firmware Manual • Firmware Version V1.01 | Document Revision V1.1 • 2017-Mar-02 3 / 38 10.5 Disclaimer: Life Support Systems . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 36 10.6 Disclaimer: Intended Use . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 36 10.7 Collateral Documents & Tools . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 37 11 Revision History 38 11.1 Document Revision . . . . . . . . . . .
TMCM-1070 TMCL™ Firmware Manual • Firmware Version V1.01 | Document Revision V1.1 • 2017-Mar-02 1 4 / 38 Features The TMCM-1070 is a single axis controller/driver module for 2-phase bipolar stepper motors with state of the art feature set. It is highly integrated, offers a convenient handling and can be used in many decentralized applications. The module has been designed for coil currents up to 1A RMS and 24V DC supply voltage.
TMCM-1070 TMCL™ Firmware Manual • Firmware Version V1.01 | Document Revision V1.1 • 2017-Mar-02 1.1 5 / 38 stallGuard2 stallGuard2 is a high-precision sensorless load measurement using the back EMF of the coils. It can be used for stall detection as well as other uses at loads below those which stall the motor. The stallGuard2 measurement value changes linearly over a wide range of load, velocity, and current settings. At maximum motor load, the value reaches zero or is near zero.
TMCM-1070 TMCL™ Firmware Manual • Firmware Version V1.01 | Document Revision V1.1 • 2017-Mar-02 2 6 / 38 First Steps with TMCL In this chapter you can find some hints for your first steps with the TMCM-1070 and TMCL. You may skip this chapter if you are already familiar with TMCL and the TMCL-IDE. Things that you will need • Your TMCM-1070 module. • A 5V TTL-UART cable. • A power supply (24V DC) for your TMCM-1070 module. • The TMCL-IDE 3.
TMCM-1070 TMCL™ Firmware Manual • Firmware Version V1.01 | Document Revision V1.1 • 2017-Mar-02 7 / 38 Number Axis Parameter Description Range [Units] Default Access 6 Maximum current Motor current used when motor is running. The maximum value is 31 which means 100% of the maximum current of the module. 0 . . . 31 24 RWE 7 Standby current The current used when the motor is not running. The maximum value is 31 which means 100% of the maximum current of the module.
TMCM-1070 TMCL™ Firmware Manual • Firmware Version V1.01 | Document Revision V1.1 • 2017-Mar-02 3 8 / 38 TMCL and the TMCL-IDE — An Introduction As with most TRINAMIC modules the software running on the microprocessor of the TMCM-1070 consists of two parts, a boot loader and the firmware itself. Whereas the boot loader is installed during production and testing at TRINAMIC and remains untouched throughout the whole lifetime, the firmware can be updated by the user.
TMCM-1070 TMCL™ Firmware Manual • Firmware Version V1.01 | Document Revision V1.1 • 2017-Mar-02 Info Note 3.1.1 9 / 38 The checksum is calculated by accumulating all the other bytes using an 8-bit addition. When using the CAN interface, leave out the address byte and the checksum byte. With CAN, the CAN-ID is used as the module address and the checksum is not needed because CAN bus uses hardware CRC checking.
TMCM-1070 TMCL™ Firmware Manual • Firmware Version V1.01 | Document Revision V1.1 • 2017-Mar-02 10 / 38 TMCL Reply Format Bytes Meaning 1 Reply address 1 Module address 1 Status (e.g. 100 means no error) 1 Command number 4 Value (MSB first!) 1 Checksum Table 3: TMCL Reply Format The checksum is also calculated by adding up all the other bytes using an 8-bit addition. Do not send the next command before having received the reply! Info Note 3.2.
TMCM-1070 TMCL™ Firmware Manual • Firmware Version V1.01 | Document Revision V1.1 • 2017-Mar-02 3.3 11 / 38 TMCL Command Overview This sections gives a short overview of all TMCL commands. 3.3.
TMCM-1070 TMCL™ Firmware Manual • Firmware Version V1.01 | Document Revision V1.1 • 2017-Mar-02 12 / 38 3.4.2 I/O Port Commands These commands control the external I/O ports and can be used in direct mode as well as in standalone mode. I/O Port Commands Mnemonic Command number Meaning GIO 15 Get input Table 7: I/O Port Commands ©2017 TRINAMIC Motion Control GmbH & Co. KG, Hamburg, Germany Terms of delivery and rights to technical change reserved. Download newest version at www.trinamic.
TMCM-1070 TMCL™ Firmware Manual • Firmware Version V1.01 | Document Revision V1.1 • 2017-Mar-02 3.5 13 / 38 Detailed TMCL Command Descriptions The module specific commands are explained in more detail on the following pages. They are listed according to their command number. 3.5.1 SAP (Set Axis Parameter) With this command most of the motion control parameters of the module can be specified. The settings will be stored in SRAM and therefore are volatile.
TMCM-1070 TMCL™ Firmware Manual • Firmware Version V1.01 | Document Revision V1.1 • 2017-Mar-02 3.5.2 14 / 38 GAP (Get Axis Parameter) Most motion / driver related parameters of the TMCM-1070 can be adjusted using e.g. the SAP command. With the GAP parameter they can be read out. In standalone mode the requested value is also transferred to the accumulator register for further processing purposes (such as conditional jumps).
TMCM-1070 TMCL™ Firmware Manual • Firmware Version V1.01 | Document Revision V1.1 • 2017-Mar-02 3.5.3 15 / 38 STAP (Store Axis Parameter) This command is used to store TMCL axis parameters permanently in the EEPROM of the module. This command is mainly needed to store the default configuration of the module. The contents of the user variables can either be automatically or manually restored at power on.
TMCM-1070 TMCL™ Firmware Manual • Firmware Version V1.01 | Document Revision V1.1 • 2017-Mar-02 3.5.4 16 / 38 RSAP (Restore Axis Parameter) With this command the contents of an axis parameter can be restored from the EEPROM. By default, all axis parameters are automatically restored after power up. An axis parameter that has been changed before can be reset to the stored value by this instruction.
TMCM-1070 TMCL™ Firmware Manual • Firmware Version V1.01 | Document Revision V1.1 • 2017-Mar-02 3.5.5 17 / 38 SGP (Set Global Parameter) With this command most of the module specific parameters not directly related to motion control can be specified and the TMCL user variables can be changed. Global parameters are related to the host interface, peripherals or application specific variables. The different groups of these parameters are organized in banks to allow a larger total number for future products.
TMCM-1070 TMCL™ Firmware Manual • Firmware Version V1.01 | Document Revision V1.1 • 2017-Mar-02 3.5.6 18 / 38 GGP (Get Global Parameter) All global parameters can be read with this function. Global parameters are related to the host interface, peripherals or application specific variables. The different groups of these parameters are organized in banks to allow a larger total number for future products. Currently, bank 0 is used for global parameters, and bank 2 is used for user variables.
TMCM-1070 TMCL™ Firmware Manual • Firmware Version V1.01 | Document Revision V1.1 • 2017-Mar-02 3.5.7 19 / 38 GIO (Get Input) With this command the status of the available general purpose outputs of the module can be read. The function reads a digital or an analog input port. Digital input ports will read as 0 or 1. In standalone mode the requested value is copied to the accumulator register for further processing purposes such as conditional jumps.
TMCM-1070 TMCL™ Firmware Manual • Firmware Version V1.01 | Document Revision V1.1 • 2017-Mar-02 Reply (Status=no error, Value=302) Field Value Host address 02h Target address 01h Status 64h Instruction 0Fh Value (Byte 3) 00h Value (Byte 2) 00h Value (Byte 1) 01h Value (Byte 0) 2Eh Checksum A5h Bank 0 – Digital Inputs The digital input states can be accessed in bank 0.
TMCM-1070 TMCL™ Firmware Manual • Firmware Version V1.01 | Document Revision V1.1 • 2017-Mar-02 3.5.8 21 / 38 Customer specific Command Extensions (UF0. . . UF7 – User Functions) These commands are used for customer specific extensions of TMCL. They will be implemented in C by Trinamic. Please contact the sales department of Trinamic Motion Control GmbH & Co KG if you need a customized TMCL firmware. Related commands: none. Mnemonic: UF0. . .
TMCM-1070 TMCL™ Firmware Manual • Firmware Version V1.01 | Document Revision V1.1 • 2017-Mar-02 4 22 / 38 Axis Parameters Most motor controller features of the TMCM-1070 module are controlled by axis parameters. Axis parameters can be modified or read using SAP, GAP, AAP, STAP and RSAP commands. This chapter describes all axis parameters that can be used on the TMCM-1070 module.
TMCM-1070 TMCL™ Firmware Manual • Firmware Version V1.01 | Document Revision V1.1 • 2017-Mar-02 23 / 38 Number Axis Parameter Description Range [Units] Default Access 138 CoolConf Access to the COOLCONF register (0x6D of the TMC5130) for the Coolstep Configuration. Use STGP and RSGP to access the stored value in the EEPROM. 0 . . . 4294967295 33011 RWE 139 CHOPConf Access to the CHOPCONF register (0x6C of the TMC5130) for the Chopper Configuration (excluded Microstep Configuration).
TMCM-1070 TMCL™ Firmware Manual • Firmware Version V1.01 | Document Revision V1.1 • 2017-Mar-02 24 / 38 Number Axis Parameter Description Range [Units] Default Access 170 smartEnergy hysteresis Sets the distance between the lower and the upper threshold for stallGuard2 reading. Above the upper threshold the motor current becomes decreased. Hysteresis: ([AP172] + 1) * 32. Upper stallGuard threshold: ([AP172] + [AP170] + 1) * 32 0 . . .
TMCM-1070 TMCL™ Firmware Manual • Firmware Version V1.01 | Document Revision V1.1 • 2017-Mar-02 25 / 38 Number Axis Parameter Description Range [Units] Default Access 182 smartEnergy threshold speed Above the speed which corresponds to this TSTEP value, coolStep becomes enabled. 0 . . . 1048575 0 RWE 206 Load value Actual current control scaling for monitoring smart energy current scaling or automatic current scaling. 0 . . .
TMCM-1070 TMCL™ Firmware Manual • Firmware Version V1.01 | Document Revision V1.1 • 2017-Mar-02 5 26 / 38 Global Parameters The following sections describe all global parameters that can be used with the SGP, GGP, AGP, STGP and RSGP commands. Global parameters are grouped into banks: • Bank 0: Global configuration of the module. 5.1 Bank 0 Parameters with numbers from 64 on configure stuff like the serial address of the module RS485 baud rate or the CAN bit rate.
TMCM-1070 TMCL™ Firmware Manual • Firmware Version V1.01 | Document Revision V1.1 • 2017-Mar-02 27 / 38 Number Global Parameter Description Range [Units] Default Access 132 Tick timer TMCL tick timer. 0 . . . 4294967295 0 RW Table 10: All Global Parameters of the TMCM-1070 Module in Bank 0 ©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 Read entire documentation.
TMCM-1070 TMCL™ Firmware Manual • Firmware Version V1.01 | Document Revision V1.1 • 2017-Mar-02 6 28 / 38 Module Specific Configuration This section explains how to use the two digital inputs of the TMCM-1070. It also describes the default configuration for microstep resolution and interpolation as well as for current setting. 6.1 Digital Inputs The TMCM-1070 includes two digital inputs: ENABLE and CHOP. The ENABLE input is a low active input which powers the motor when the ENABLE is not set.
TMCM-1070 TMCL™ Firmware Manual • Firmware Version V1.01 | Document Revision V1.1 • 2017-Mar-02 6.3 29 / 38 Reset to Factory Defaults The TMCM-1070 provides a functionality to restore all parameters to their factory default values. When the module is still off, connect the SWIO and SWCLK programming pins, located on the bottom of the module, with each other. Then, turn the power on. The module will write now the default values to the EEPROM.
TMCM-1070 TMCL™ Firmware Manual • Firmware Version V1.01 | Document Revision V1.1 • 2017-Mar-02 30 / 38 Figure 4: TMCL-IDE Plugin: Tab StealthChop The last tab “Coolstep” is shown on Figure 5. To configure CoolStep, we offer a more advanced plugin (click on “coolStep” on the plugin list of the module). The exceptions are parameters 22 and 182, Threshold Speed and Deactivation Threshold Speed respectively.
TMCM-1070 TMCL™ Firmware Manual • Firmware Version V1.01 | Document Revision V1.1 • 2017-Mar-02 7 31 / 38 Hints and Tips This chapter gives some hints and tips on using the functionality of TMCL, for example how to use and parameterize the built-in reference search algorithm or using an incremental encoder. You will also find basic information about stallGuard2™ and coolStep™ in this chapter. 7.1 stallGuard2 The module is equipped with motor driver chips that feature load measurement.
TMCM-1070 TMCL™ Firmware Manual • Firmware Version V1.01 | Document Revision V1.1 • 2017-Mar-02 7.2 32 / 38 coolStep This section gives an overview of the coolStep related parameters. Please bear in mind that the figure only shows one example for a drive. There are parameters which concern the configuration of the current. Other parameters are there for velocity regulation and for time adjustment. Figure 6 shows all the adjustment points for coolStep.
TMCM-1070 TMCL™ Firmware Manual • Firmware Version V1.01 | Document Revision V1.1 • 2017-Mar-02 Number Axis Parameter Description I6 Absolute maximum current The maximum value is 255. This value means 100% of the maximum current of the module. The current adjustment is within the range 0. . . 255 and can be adjusted in 32 steps (0. . . 255 divided by eight; e.g. step 0 = 0. . . 7, step 1 = 8. . . 15 and so on).
TMCM-1070 TMCL™ Firmware Manual • Firmware Version V1.01 | Document Revision V1.1 • 2017-Mar-02 8 34 / 38 Figures Index 1 2 3 stallGuard2 Load Measurement as a Function of Load . . . . . . . . . . . . 5 Energy Efficiency Example with coolStep 5 TMCL-IDE Plugin: Tab Current . . . . . 29 ©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 Read entire documentation.
TMCM-1070 TMCL™ Firmware Manual • Firmware Version V1.01 | Document Revision V1.1 • 2017-Mar-02 9 35 / 38 Tables Index 1 2 3 4 5 6 7 8 Most important Axis Parameters . TMCL Command Format . . . . . . TMCL Reply Format . . . . . . . . . TMCL Status Codes . . . . . . . . . Overview of all TMCL Commands . Parameter Commands . . . . . . . I/O Port Commands . . . . . . . . All TMCM-1070 Axis 0 Parameters . . . . . . . . . . . . . . . . 7 8 10 10 11 11 12 25 ©2017 TRINAMIC Motion Control GmbH & Co.
TMCM-1070 TMCL™ Firmware Manual • Firmware Version V1.01 | Document Revision V1.1 • 2017-Mar-02 10 36 / 38 Supplemental Directives 10.1 Producer Information 10.2 Copyright TRINAMIC owns the content of this user manual in its entirety, including but not limited to pictures, logos, trademarks, and resources. © Copyright 2017 TRINAMIC. All rights reserved. Electronically published by TRINAMIC, Germany.
TMCM-1070 TMCL™ Firmware Manual • Firmware Version V1.01 | Document Revision V1.1 • 2017-Mar-02 37 / 38 or of any other nature are made hereunder with respect to information/specification or the products to which information refers and no guarantee with respect to compliance to the intended use is given. In particular, this also applies to the stated possible applications or areas of applications of the product.
TMCM-1070 TMCL™ Firmware Manual • Firmware Version V1.01 | Document Revision V1.1 • 2017-Mar-02 11 11.1 38 / 38 Revision History Document Revision Version Date Author Description V0.8 2016-APR-22 BS Exported from xml. V0.9 2016-MAI-03 BS Added APs, GPs and IOs. Common documentation structure. V1.0 2016-SEP-16 BS Corrected introduction. Included module specific configuration section. V1.1 2016-NOV-22 BS Adapted information for reduced TMCL structure.