TMCM-343_11 TRINAMIC | Alldatasheet

Document overview

  • Manufacturer or author: Provided By ALLDATASHEET.COM(FREE DATASHEET DOWNLOAD SITE)
  • PDF pages: 27

Technical content

MODULES FOR STEPPER MOTORS MODULES TRINAMIC Motion Control GmbH & Co. KG Hamburg, Germany www.trinamic.com V 1.07 HARDWARE MANUAL + + TMCM-343 3-axis stepper controller / driver 300mA up to 1.1A RMS nominal supply: 8V… 34V DC TMCL™ / CANopen firmware + +

TMCM-343 Hardware Manual (V1.07 / 2011-JUN-08) 2 Copyright © 2011, TRINAMIC Motion Control GmbH & Co. KG Table of contents

TMCM-343 Hardware Manual (V1.07 / 2011-JUN-08) 4 Copyright © 2011, TRINAMIC Motion Control GmbH & Co. KG

1 Life support policy

TRINAMIC Motion Control GmbH & Co. KG does not authorize or warrant any of its products for use in life support systems, without the specific written consent of TRINAMIC Motion Control GmbH & Co. KG. Life support systems are equipment intended to support or sustain life, and whose failure to perform, when properly used in accordance with instructions provided, can be reasonably expected to result in personal injury or death. © TRINAMIC Motion Control GmbH & Co. KG 2011 Information given in this data sheet is believed to be accurate and reliable. However neither responsibility is assumed for the consequences of its use nor for any in fringement of patents or other rights of third parties, which may result from its use. Specifications are subject to change without notice.

TMCM-343 Hardware Manual (V1.07 / 2011-JUN-08) 5 Copyright © 2011, TRINAMIC Motion Control GmbH & Co. KG

2 Features

The TMCM -343 is a compact and versatile triple axis 2 -phase stepper motor controller and driver module. It provides a complete motion control solution at a very small size for embedded applications. Using the integrated additional I/Os it even can do complete system control applications. The board can be connected to a baseboard or customized electronics wi th a pin connector. The TMCM-343 comes with the PC based software development environment TMCL -IDE. Using predefined TMCL™ (Trinamic Motion Control Lang uage) high level commands like move to position or constant rotation rapid and fast development of motio n control applications is guaranteed. Host communication is possible via the serial UART interface (e.g. using a n RS232 or RS485 level shifter) or via CAN. All time critical operations, e.g. ramp calculation are performed onboard. A user TMCL ™ program can be stored in the on board EEPROM for stand -alone operation. The firmware of the module can be updated via the serial interface. With the optional stallGuardTM feature it is possible to detect overload and stall of the motor.

Applications

 Controller/driver board for control of up to 3 axes  Versatile possibilities of applications in stand alone or PC controlled mode Motor type  Coil current from 300mA to 1.1A RMS (1.5A peak)  8V to 34V nominal supply voltage Highlights  Automatic ramp generation in hardware  stallGuardTM option for sensorless motor stall detection  Full step frequencies up to 20kHz  On the fly alteration of motion parameters (e.g. position, velocity, acceleration)  Local reference move using sensorless stallGuardTM feature or reference switch  Coil current adjustable by software  Up to 64 times microstepping  TRINAMIC driver technology: No heat sink required  Adjustment possibilities. Therefore this module offers solutions for a great field of demands Software  Stand-alone operation using TMCL™ or remote controlled operation  TMCL™ program storage: 16 KByte EEPROM (2048 TMCL™ commands)  PC-based application development software TMCL-IDE included  Special firmware for CANopen protocol support also available Other  68 pin connector carries all signals  RoHS compliant latest from 1 July 2006  Size: 80 x 50mm²

TMCM-343 Hardware Manual (V1.07 / 2011-JUN-08) 6 Copyright © 2011, TRINAMIC Motion Control GmbH & Co. KG

4 Order codes

Order code Description Dimensions TMCM-343 (-option) 3-axis controller/driver module 1.1A, 34V 80 x 55 x 8 mm3 Products related to TMCM-343 BB-303 (-option) Baseboard for TMCM-343 80 x 50 x 15 mm3 BB-323-03 Baseboard for TMCM-343 96.5 x 79 x 60 mm3 TMCM-323 3-axis encoder 80 x 53 x 8 mm3 TMCM-EVAL Evaluation baseboard 160 x 100 x 24 mm3 Options for TMCM-343 -H horizontal pin connector (standard) -V vertical pin connector (on request) Table 4.1: Order codes

TMCM-343 Hardware Manual (V1.07 / 2011-JUN-08) 7 Copyright © 2011, TRINAMIC Motion Control GmbH & Co. KG

5 Electrical and mechanical interfacing

5.1 Dimensions

The 68 pin connector has a 2.0mm pitch. 2.2 1.250 46 39.1 36.9 24.4 21.94 R1.25 R1.1 R1.6 5.49.2 Figure 5.1: Front view of TMCM-343 (all values in mm) 6.7 Horizontal connector Header connector 9.7 Figure 5.2: Ordering options for the connector (all values in mm)

TMCM-343 Hardware Manual (V1.07 / 2011-JUN-08) 8 Copyright © 2011, TRINAMIC Motion Control GmbH & Co. KG

5.2 Connecting the module

The 68-pin connector provides communication to a host, configuration of the EEPROM and connection of motors as well as connection of reference switches. Pin 1 of this connector is located in the lower left corner on the top site, while the connector is pointing towards the user. Pin Direction Description Pin Direction Description

1 In +5VDC (+/- 5%) Imax=300mA 35 - Reserved

2 In GND 36 out Motor2 A0

3 In +5VDC (+/- 5%) 37 - Reserved

4 In GND 38 out Motor2 A1

5 In V_Motor (+7 to 34VDC) 39 - Reserved

6 In GND 40 out Motor2 B0

7 In V_Motor (+7 to 34VDC) 41 - Reserved

8 In GND 42 out Motor2 B1

9 In V_Motor (+7 to 34VDC) 43 - Reserved

10 In GND 44 in Shutdown

11 Out SPI Select 0 45 in General Purpose input 0

12 Out SPI Clock 46 out General Purpose output 0

13 Out SPI Select 1 47 in General Purpose input 1

14 In SPI MISO 48 out General Purpose output 1

15 Out SPI Select 2 49 in General Purpose input 2

16 Out SPI MOSI 50 out General Purpose output 2

17 In Reset, active low 51 in General Purpose input 3

18 Out Alarm 52 out General Purpose output 3

19 In Reference Switch Motor 0 right 53 in General Purpose input 4

20 Out Motor0 A0 54 out General Purpose output 4

21 In Reference Switch Motor 0 left 55 in General Purpose input 5

22 Out Motor0 A1 56 out General Purpose output 5

23 In Reference Switch Motor 1 right 57 in General Purpose input 6

24 Out Motor0 B0 58 out General Purpose output 6

25 In Reference Switch Motor 1 left 59 in General Purpose input 7

26 Out Motor0 B1 60 out General Purpose output 7

27 In Reference Switch Motor 2 right 61 in GND

28 Out Motor1 A0 62 in GND

29 In Reference Switch Motor 2 left 63 - Reserved

30 Out Motor1 A1 64 out RS485 Direction

31 - Reserved 65 in and out CAN -

32 Out Motor1 B0 66 in RS232 RxD

33 - Reserved 67 in and out CAN +

34 Out Motor1 B1 68 out RS232 TxD

Table 5.1: Pinout of the 68-Pin connector PCB 2 68 Figure 5.3: Pin order of the connector

TMCM-343 Hardware Manual (V1.07 / 2011-JUN-08) 9 Copyright © 2011, TRINAMIC Motion Control GmbH & Co. KG

5.3 Power supply requirements

Two different power supplies have to be provided for the TMCM -343: +5VDC for the controller part and +7… 34VDC for the motor supply. Please connect all listed pins for the power supply inputs and ground in parallel. It is recommended to use cap acitors of some 1000µF and a choke close to the module for the motor supply. This ensures a stable power supply and minimizes noise injected into the power supply cables. The choke especially becomes necessary in larger distributed systems using a common power supply. TMCM-343 V_ Motor (7...34V) GND C (> 1000µF) L Power Supply keep distance short Local +5V regulator supply for further modules on same base board Figure 5.4: Power supply requirements for TMCM-343 Especially in bus controlled systems (e.g. CAN or RS485) it is important to ensure a stable ground potential of a ll modules. The stepper driver modul es draw peak currents of some a mpere from the power supply. It has to be made sure, that this current does not cause a substantial voltage difference on the interface lines between the module and the master, as disturbed transmissions could result. The following hints help avoiding transmission problems in larger systems:  Use power supply filter capacitors of some 1000µF on the base board for each module in order to take over current spikes. A choke in the positive pow er supply line will prevent current spikes from changing the GND potential of the base board, especially when a central power supply is used.  Optionally use an isolated power supply for the TMCM -Modules (no earth connection on the power supply, in case the CAN master is not optically decoupled)  Do not supply modules which are mounted in a distance of more than a few meters with the same power supply.  For modules working on the same power supply (especially the same power supply as the master) use a straight and thick, low-resistive GND connection.  Use a local +5V regulator on each baseboard.

TMCM-343 Hardware Manual (V1.07 / 2011-JUN-08) 10 Copyright © 2011, TRINAMIC Motion Control GmbH & Co. KG TMCM-343 V_Motor (7...34V) GND L + Power supply keep distance short TMCM-343 V_Motor (7...34V) GND L keep distance short keep distance below a few meters with a single power supply CAN high CAN low CAN high CAN low other devices on CAN bus (incl. master) CAN high CAN low V_Motor (7...34V) GND L CAN_GND CAN_GND CAN_GND Figure 5.5: Power supply requirements for TRINAMIC modules in a bus system  In large systems it may make sense to use an optically decoupled CAN bus for each number of nodes, e.g. for each base board with a number of TMCM -34x modules, especially when a centralized power supply is to be used.  Be aware that different ground potentials of the C AN sender (e.g. a PC) and the power supply may damage the modules.  Please make sure that the GND lines of the CAN sender and the module(s) and power supplies are connected by a cable.

TMCM-343 Hardware Manual (V1.07 / 2011-JUN-08) 11 Copyright © 2011, TRINAMIC Motion Control GmbH & Co. KG

6 Operational ratings

The operational ratings show the intended or rather the characteristic range for the values and should be used as design values. In no case shall the maximum values be exceeded. Symbol Parameter Min Typ Max Unit VS DC Power supply voltage for operation 7 12 … 28 34 V V+5V +5V DC input (max. 50mA / no OUT load) 4.8 5.0 5.2 V ICOIL Motor coil current for sine wave peak (chopper regulated, adjustable via software) 0 0.3 … 1.5 1.5 A fCHOP Motor chopper frequency 36.8 kHz IS Power supply current (per motor) << ICOIL 1.4 * ICOIL A VINPROT Input volt age for StopL, StopR, GPI0 (internal protection diodes) VANA INx analog measurement range (resolution: 10bit / range: 0..1023) 0 ... 5.5 V VINLO INx, StopL, StopR low level input 0 0.9 V VINHI INx, StopL, StopR high level input (integrated 10k pull-up to +5V for Stop) 2 5 V IOUTI OUTx max +/ - output current (CMOS output) (sum for all outputs max. 50mA) +/-20 mA TENV Environment temperature at rated current (no cooling) -40 +80 °C Table 6.1: Operational ratings

TMCM-343 Hardware Manual (V1.07 / 2011-JUN-08) 12 Copyright © 2011, TRINAMIC Motion Control GmbH & Co. KG

7 Functional description

In Figure 7.1 the main parts of the TMCM -343 module are shown. The module mainly consists of a processor, a TMC428 motion controller, three TMC246 stepper motor driver s, t he TMCL ™ program memory (EEPROM) and the host interfaces RS232, RS485 and CAN. 7… 34V DC High Power Driver TMC246 µC TMCL Memory progammable Motion Controller with TMC428 Step Motor CAN RS232 or RS485 Please note, that the USB interface can be offered on demand. 16additional I/Os 3x2 Stop switches +5V TMCM-343 Step Motor Step Motor High Power Driver TMC246 High Power Driver TMC246 UART Special option: USB 5V DC Figure 7.1: Main parts of the TMCM-343

7.1 System architecture

The TMCM -343 integrates a microcontroller with the TMCL ™ (Trinamic Motion Control Language) operating system. The motion control real-time tasks are realized by the TMC428.

7.1.1 Microcontroller

On this module, the Atmel AT91SAM7X256 is used to run the TMCL ™ operating system and to control the TMC428. The CPU has 256KB flash memory and a 64KB RAM. The microcontroller runs the TMCL ™ (Trinamic Motion Control Language) operating system which makes it possible to execute TMCL ™ commands that are sent to the module from the host via the RS232, RS 485 and CAN inter face. The microcontroller interprets the TMCL ™ commands and controls the TMC428 which executes the motion commands. The flash ROM of the microcontroller holds the TMCL ™ operating system. The TMCL ™ operating system can be updated via the RS232 interface or via the CAN interface. Use the TMCL-IDE to do this.

7.1.2 EEPROM

To store TMCL ™ programs for stand -alone operation the TMCM -343 module is equipped with a 16kByte EEPROM attached to the microcontroller. The EEPROM can store TMCL ™ programs consisting of up to 2048 TMCL™ commands. The EEPROM is also used to store configuration data.

TMCM-343 Hardware Manual (V1.07 / 2011-JUN-08) 13 Copyright © 2011, TRINAMIC Motion Control GmbH & Co. KG

7.1.3 TMC428 motion controller

The TMC428 is a high -performance stepper motor control IC and can control up to three 2 -phase- stepper-motors. Motion parameters like speed or acceleration are s ent to the TMC428 via SPI by the microcontroller. Calculation of ramps and speed profiles are done internally by hardware based on the target motion parameters.

7.1.4 Stepper motor drivers

On the TMCM-343 modules the TMCM246 chips are used. These chips have the stallGuard™ feature. As the power dissipation of TMC246 chips is very low no heat sink or cooling fan is needed. The temperature of the chips does not get high. The coils will be switched off automatically when the temperature or the current exceeds the limits and a utomatically switched on again when the values are within the limits again. The TMCM-343 module is equipped with a circuit that extends the microstep resolution of the TMC246 chips to true 64 times microstepping. The maximum peak coil current of each stepper motor driver chip is 1500mA.

7.2 Power supply

Two different power supplies have to be provided for the TMCM -343: +5VDC for the module functionality and +7 … 34VDC for the motor supply. Please use all listed pins for the power supply inputs and ground parallel. Pin Function 1, 3 +5V DC (+/- 5%), Imax = 50mA power supply 2, 4 Ground 5, 7, 9 +7… 34V DC motor power supply 6, 8, 10 Ground Table 7.1: Pinning of power supply

7.3 Motor connection

Never connect or d isconnect the motors while the TMCM -343 Module is switched on. Doing this will destroy the driver ICs! The TMCM-343 controls up to three 2-phase stepper motors. Table 7.2 shows how to connect the three motors with the 68-pin connector: Pin Number Direction Name Motor Numbers and Coils 20 out Motor0_A0 Motor #0, Coil A0 22 out Motor0_A1 Motor #0, Coil A1 24 out Motor0_B0 Motor #0, Coil B0 26 out Motor0_B1 Motor #0, Coil B1 28 out Motor1_A0 Motor #1, Coil A0 30 out Motor1_A1 Motor #1, Coil A1 32 out Motor1_B0 Motor #1, Coil B0 34 out Motor1_B1 Motor #1, Coil B1 36 out Motor2_A0 Motor #2, Coil A0 38 out Motor2_A1 Motor #2, Coil A1 40 out Motor2_B0 Motor #2, Coil B0 42 out Motor2_B1 Motor #2, Coil B1 Table 7.2: Pinout for motor connections

TMCM-343 Hardware Manual (V1.07 / 2011-JUN-08) 14 Copyright © 2011, TRINAMIC Motion Control GmbH & Co. KG Pin 2 Pin 1 Pin 67Pin 68 A0A1 MOTOR A0A1 MOTOR A0A1 MOTOR Pin 20 Pin 22 Pin 24 Pin 26 Pin 28 Pin 30 Pin 32 Pin 34 Pin 36 Pin 38 Pin 42 Pin 40 TMCM-343 Figure 7.2: Connecting the motors

7.4 Host communication

The communication to a host takes place v ia one or more of the onboard interfaces. The module provides a range of dif ferent interfaces, like CAN, RS232, and RS 485. The following chapters explain how the interfaces are connected with the 68-pin connector. 7.4.1 CAN 2.0b Pin Direction Name Limits Description 65 in and out CAN - -8… +18V CAN input/output

67 In and out CAN + -8… +18V CAN input/output

Table 7.3: Pinout for CAN connection Pin 2 Pin 1 Pin 67: CAN++ Pin 65: CAN-- Host CAN+ CAN-- TMCM-343 68-Pin -Connector Figure 7.3: Connecting CAN

TMCM-343 Hardware Manual (V1.07 / 2011-JUN-08) 15 Copyright © 2011, TRINAMIC Motion Control GmbH & Co. KG

7.4.2 RS232

Pin Direction Name Limits Description 66 in RxD TTL RS232 receive data 68 out TxD TTL RS232 transmit data 2, 4, 6, 8, 10 in GND 0V Connect to ground Table 7.4: Pinout for RS232 connection The module only provides a serial interface at TTL level. For using RS232 a suitable level shifter has to be added by the user (e.g. MAX202). Pin 66: RS232_RxD Pin 68: RS232_TxD Pin 2 Pin 1 Pin61: GND TMCM-343 68-Pin -Connector Host TxD RxD GND level shifter (e.g . MAX 202) TTL Figure 7.4: Connecting RS232

7.4.3 RS485

Pin Number Direction Name Limits Description

64 Out RS485_DIR TTL

Driver/receiver enable for RS485 transceiver. 0: receiver enable 1: driver enable

66 In RxD TTL RS485 receive data

68 Out TxD TTL RS485 transmit data

2, 4, 6, 8, 10 In GND 0V Connect to ground Table 7.5: Pinout for RS485 connection The TMCM-343 module only provides a serial interface at TTL level. To use RS485 a suitable RS485 transceiver (like MAX485) has to be added by the user. Pin 61: GND TxD RxD DIR RS485+ RS485- GND TxD RxD DIR RS485+ RS485- GND Transceiver e.g . MAX 485 Transceiver e.g . MAX 485 Pin 64: RS485_ DIRECTION Pin 66: RS232_RxD Pin 68: RS232_TxD Pin 2 Pin 1 TxD RxD DIR GND HOST TMCM-343 68-Pin -Connector Figure 7.5: Connecting RS485

TMCM-343 Hardware Manual (V1.07 / 2011-JUN-08) 16 Copyright © 2011, TRINAMIC Motion Control GmbH & Co. KG 7.5 stallGuard™ - sensorless motor stall detection The TMCM-343 modules are equipped with the s tallGuard™ feature. The stallGuard™ feature makes it possible to detect if the mechanical load on a stepper motor is too high or if the traveler has been obstructed. The load value can be read using a TMCL ™ command or the module can be programmed so that the motor will be stopped automatically when it has been obstructed or the load has been too high. stallGuard™ can also be used for finding the reference position wi thout the need for a reference switch: Activate stallGuard™ and then let the traveler run against a mechanical obstacle that is placed at the end of the way. When the motor has stopped it is definitely at the end of its way, and this point can be used as the reference position. For using stallGuard™ in an actual application, some manual tests should be done first, because the stallGuard™ level depends upon the motor velocities and on the occurrence of resonances. Mixed decay should be switched off while stallGuard is in use in order to get usable results. Value Description 0 stallGuard™ function is deactivated (default) 1… 7 Motor stops when stallGuard™ value is reached and position is not set zero. Table 7.6: stallGuard™ parameter SAP 205 To activate the stallGuard™ feature use the TMCL ™ command SAP 205 and set the stallGuard™ threshold value according to Table 7.6. The actual load valu e is given by GAP 206. The TMCL -IDE has some tools which let you try out and adjust the stallGuard™ function in an easy way. They can be found at stallGuard™ in the Setup menu and are described in the following chapters. Please refer to the TMCM-341/342/343 TMCL™ Firmware Manual for further information about working with TMCL-IDE. 7.5.1 stallGuard™ adjusting tool The stallGuard™ adjusting tool helps to find the necessary motor parameters when stallGuard™ is to be used. This function can only be used when a module is connected that features stallGuard™. This is checked when the stallGuard™ adjusting tool is selected in the Setup menu. After this has been successfully checked the stallGuard™ adjusting tool is displayed. First, select the axis that is to be used in the Motor area. Now you can enter a veloc ity and an acceleration value in the Drive area and then click Rotate Left or Rotate Right . Clicking one of these button s will send the necessary commands to the module so that the motor star ts running. The red bar in the stallGuard™ area on the right side of the windows displays the actual load va lue. Use the slider to set the stallGuard™ threshold value. If the load value reaches this value the motor stops. Clicking the Stop button also stops the motor. Figure 7.6: stallGuard™ adjusting tool All commands necessary to set the values entered in this dialogue are displayed in the Commands area at the bottom of the window. There, they can be selected, copied and pasted into the TMCL ™ editor.

TMCM-343 Hardware Manual (V1.07 / 2011-JUN-08) 17 Copyright © 2011, TRINAMIC Motion Control GmbH & Co. KG 7.5.2 stallGuard™ profiler The stallGuard™ profiler is a utility that helps you find the best parameters for using stall detection. It scans through given velocities and shows which velocities are the best ones. Similar to the stallGuard™ adjusting tool it can only be used togeth er with a module that supports stallGuard™. This is checked right after the stallGuard™ profiler has been selected in the Setup menu. After this has been successfully checked the stallGuard™ profiler window will be shown. First, select the axis that is to be used. Then, enter the Start velocity and the End velocity. The start velocity is used at the beginning of the profile recording. The recording ends when the end velocity has been reached. Start velocity and end velocity must not be equal. After you h ave enter ed these parameters, click the Start button to start the stallGuard™ profile recording. Depending on the range between start and end velocity this can take several minutes, as the load value for every velocity va lue is measured ten times. The Actual velocity value shows the velocity that is currently being tested and so tells you the progress of the profile recording. You can also abort a profile recording by clicking the Abort button. The result can also be exported to Excel or to a text file by using the Export button. Figure 7.7: The stallGuard™ profiler

7.5.2.1 The result of the stallGuard™ profiler

The result is shown as a graphic in the stallGuard™ profiler window. After the profile recording has finished you can scroll through the profile graphic using the scroll bar below it. The scale on the vertical axis shows the load value: A higher value means a higher load. The scale on the horizontal axis is the velocity scale. The color of each line shows the standard deviation of the ten load values that have been measured for the velocity at that point. Th is is an indicator for the vibration of the motor at the given velocity. There are three colors used:  Green: The standard deviation is very low or zero. This means that there is effectively no vibration at this velocity.  Yellow: This color means that there might be some low vibration at this velocity.  Red: The red color means that there is high vibration at that velocity.

7.5.2.2 Interpreting the result

In order to make effective use of the stallGuard™ feature you should choose a velocity where the load value is as low as possible and where the color is green. The very best velocity values are those where the load value is zero (areas that do not show any green, yellow or red line). Velocities shown in yellow can also be used, but with care as they might caus e problems (maybe the motor stops even if it is not stalled). Velocities shown in red should not be chosen. Because of vibration the load value is often unpredictable and so not usable to produce good results when using stall detection. As it is very sel dom that exactly the same result is produced when recording a profile with the same parameters a second time, always two or more profiles should be recorded and compared against each other.

TMCM-343 Hardware Manual (V1.07 / 2011-JUN-08) 18 Copyright © 2011, TRINAMIC Motion Control GmbH & Co. KG

7.6 Reference switches

With reference switches, an interval for the movement of the motor or the zero point can be defined. Also a step loss of the system can be detected, e.g. due to overloading or manual interaction, by using a travel-switch. Pin Direction Name Limits Description 19 in STOP0R TTL Right reference switch input for Motor #0 21 in STOP0L TTL Left reference switch input for Motor #0 23 in STOP1R TTL Right reference switch input for Motor #1 25 in STOP1L TTL Left reference switch input for Motor #1 27 in STOP2R TTL Right reference switch input for Motor #2 29 in STOP2L TTL Left reference switch input for Motor #2 Table 7.7: Pinout reference switches 10k pull-up resistors for reference switches are included on the module.

7.6.1 Left and right limit switches

The TMCM-343 can be configured so that a motor has a left and a right limit switch (Figure 7.8). The motor stops when the traveler has reached one of the limit switches. left stop switch right stop switch REF_L_x REF_R_x motor traveler Figure 7.8: Left and right limit switches

7.6.2 Triple switch configuration

It is possible to program a tolerance range around the reference switch position. This is useful for a triple switch configuration, as outlined in Figure 7.9. In that configuration two switches are used as automatic stop switches, and one additional switch is used as the reference switch between the left stop switch and the right stop switch. The left stop switch and the reference switch are wired together. The center switch (travel switch) allows for a monitoring of the axis in order to detect a step loss. left stop switch motor traveler REF_L_x right stop switch REF_R_x reference switch Figure 7.9: Limit switch and reference switch

TMCM-343 Hardware Manual (V1.07 / 2011-JUN-08) 19 Copyright © 2011, TRINAMIC Motion Control GmbH & Co. KG

7.6.3 One limit switch for circular systems

If a circular system is used ( Figure 7.10), only one reference switch is necessary, because there are no end-points in such a system. motor ref switch REF_L_x eccentric Figure 7.10: One reference switch

7.7 Serial peripheral interface (SPI)

On-board communication is performed via the Se rial Peripheral Interface (SPI). The microcontroller acts as master. For adaptation to user requirements, the u ser has access to this interface via the 68 - pin connector. Furthermore three chip select lines can be used for addressing of external devices. Pin Direction Name Limits Description 11 out SPI_SEL0 TTL Chip Select Bit0 13 out SPI_SEL1 TTL Chip Select Bit1 15 out SPI_SEL2 TTL Chip Select Bit2 12 out SPI_CLK TTL SPI Clock 14 in SPI_MISO TTL SPI Serial Data In 16 out SPI_MOSI TTL SPI Serial Data Out Table 7.8: Pinout SPI

7.8 Additional inputs and outputs

The module is equipped with eight TTL input pins and eight TTL output pins, which are accessible via the 68-pin connector. The input pins can also be used as analogue inputs. Pin Direction Name Limits Description 45 in INP_0 TTL digital and analogue input pin 0, input 47 in INP_1 TTL digital and analogue input pin 1, input 49 in INP_2 TTL digital and analogue input pin 2, input 51 in INP_3 TTL digital and analogue input pin 3, input 53 in INP_4 TTL digital and analogue input pin 4, input 55 in INP_5 TTL digital and analogue input pin 5, input 57 in INP_6 TTL digital and analogue input pin 6, input 59 in INP_7 TTL digital and analogue input pin 7, input 46 out Out_0 TTL digital output pin 0, output 48 out Out_1 TTL digital output pin 1, output 50 out Out_2 TTL digital output pin 2, output 52 out Out_3 TTL digital output pin 3, output 54 out Out_4 TTL digital output pin 4, output 56 out Out_5 TTL digital output pin 5, output 58 out Out_6 TTL digital output pin 6, output 60 out Out_7 TTL digital output pin 7, output Table 7.9: Additional I/O pins

7.9 Miscellaneous connections

TMCM-343 Hardware Manual (V1.07 / 2011-JUN-08) 20 Copyright © 2011, TRINAMIC Motion Control GmbH & Co. KG Pin Direction Name Limits Description 17 in Reset TTL Reset, active low 18 out Alarm TTL Alarm, active high 44 in Shutdown TTL Emergency stop Table 7.10: Miscellaneous connections The functionality of the shutdown pin is configurable using in TMCL ™ with global parameter 80 (please see the TMCM-341/342/343 TMCL™ Firmware Manual for information on this).

7.10 Microstep resolution

The TMCM-343 supports a true 64 microstep resolution. To meet your needs, the microstep resolution can be set using the TMCL™ software. The default setting is 64 microsteps , which is the highest resolution. For setting the microstep resolution with the TMCL™ firmware use instruction 5: SAP, type 140: microstep resolution. You can find the appropriate value in Table 7.11. Value microsteps

0 Do not use: for fullstep please see fullstep threshold

Table 7.11: Microstep resolution setting

TMCM-343 Hardware Manual (V1.07 / 2011-JUN-08) 21 Copyright © 2011, TRINAMIC Motion Control GmbH & Co. KG

8 Putting the TMCM-343 into operation

On the basis of a small example it is shown step by step how the TMCM -343 is set into operation. Experienced users could skip this chapter and proceed to chapter 9. Example: The following application is to implement with the TMCL-IDE Software development environment in the TMCM -343 module. For data transfer between th e host PC and the module the RS232 interface is employed. A formula how speed is converted into a physical unit like rotations per seconds can be found in chapter Calculation: Velocity and acceleration vs. microstep and fullstep frequency.  Turn Motor 0 left with speed 500  Turn Motor 1 right with speed 500  Turn Motor 2 with speed 500, acceleration 5 and move between position +10000 and –10000. Step 1: Connect the RS232 Interface as specified in 7.7. Step 2: Connect the motors as specified in 7.3. Step 3: Connect the power supply. +5 VDC to pins 1 or 3 Ground to pins 2, 4, 6, 8 or 10 Step 4: Connect the motor supply voltage +10 to 30 VDC to pins 5, 7, 9 Step 5: Switch on the power supply and the motor supply. An on-board LED should start to flash. This indicates the correct configuration of the microcontroller. Step 6: Start the TMCL -IDE Software development environment. Open file test2.tmc. The following source code appears on the screen: A description for the TMCL commands can be found in Appendix A. Step 7: Click on Icon Assemble to convert the TMCL™ into machine code. Then download the program to the TMCM-343 module via the Icon Download. Step 8: Press Icon Run. The desired program will be executed. Please refer to the TMCM -341/342/343 TMCL™ Firmware Manual for further information about the commands. The next chapter discusses additional operations to turn the TMCM -343 into a high performance motion control system. //A simple example for using TMCL™ and TMCL-IDE ROL 0, 500 //Rotate motor 0 with speed 500 WAIT TICKS, 0, 500 MST 0 ROR 1, 250 //Rotate motor 1 with 250 WAIT TICKS, 0, 500 MST 1 SAP 4, 2, 500 //Set max. Velocity SAP 5, 2, 50 //Set max. Acceleration Loop: MVP ABS, 2, 10000 //Move to Position 10000 WAIT POS, 2, 0 //Wait until position reached MVP ABS, 2, -10000 //Move to Position -10000 WAIT POS, 2, 0 //Wait until position reached JA Loop //Infinite Loop

TMCM-343 Hardware Manual (V1.07 / 2011-JUN-08) 22 Copyright © 2011, TRINAMIC Motion Control GmbH & Co. KG

9 Migrating from the TMCM -303 to the

Migrating TMCM-303 applications to the TMCM -343 is easy, as the TMCM -343 can replace a T MCM-303 without problems. The connector of the TMCM -343 is identical to the connector of the TMCM -303, so that a TMCM -343 can just be plugged into the slot for a TMCM -303 (it can also use the same base boards as the TMCM -303). Also the TMCL ™ firmware of the TMCM -343 is highly compatible with the TMCM-303. However there are some slight differences that have to be observed (due to the fact that the TMCM - 343 has some enhancements compared to the TMCM-303):  Speed of TMCL™ program execution: TMCL™ programs run up twenty times faster than on the TMCM-303 module. In general, the developer of a TMCL ™ program should not make assumptions about command execution times.  Axis parameters 6 and 7 (run current and stand by current): The range of these par ameters is now 0… 255 and no longer 0… 1500. These parameter settings must be adapted.  Axis parameters 194 and 195: The reference search speeds are now specified directly (1 … 2047) and no longer as fractions of the maximum positioning speed. These settings have to be adapted.  MVP COORD: The parameter of the MVP COORD command is different (to make it compatible with the six axis modules). Please see the TMCM -341/342/343 TMCL™ Firmware Manual for details. The usage of the MVP COORD command also has to be adapted.  Default CAN bit rate: the default CAN bit rate of the TMCM -343 module (e.g. after resetting it to factory default settings) is 1000kBit/s (in contrast to 250kBit/s on the TMCM-303. All other TMCL™ commands and parameters are the same as with the TMCM-303.

TMCM-343 Hardware Manual (V1.07 / 2011-JUN-08) 23 Copyright © 2011, TRINAMIC Motion Control GmbH & Co. KG

10 TMCM-343 operational description

10.1 Calculation: Velocity and acceleration vs. microstep and fullstep frequency The values of the parameters sent to the TMC428 d o not have typical motor values like rotations per second as velocity. But these values can be calcul ated from the TMC428 -parameters as shown in this document. The parameters for the TMC428 are: Signal Description Range fCLK clock-frequency 16 MHz velocity - 0… 2047 a_max maximum acceleration 0… 2047 pulse_div divider for the velocity. The higher the value is, the less is the maximum velocity default value = 0 0… 13 ramp_div divider for the acceleration. The higher the value is, the less is the maximum acceleration default value = 0 0… 13 Usrs microstep-resolution (microsteps per fullstep = 2usrs) 0… 7 (a value of 7 is internally mapped to 6 by the TMC428) Table 10.1: TMC428 velocity parameters The microstep-frequency of the stepper motor is calculated with 3220482 velocity]Hz[f]Hz[usf div_pulse CLK with usf: microstep-frequency To calculate the fullstep-frequency from the microstep -frequency, the microstep -frequency must be divided by the number of microsteps per fullstep. usrs2 ]Hz[usf]Hz[fsf  with fsf: fullstep-frequency The change in the pulse rate per time unit (pulse frequency change per second – the acceleration a) is given by 29div_rampdiv_pulse max CLK afa  This results in acceleration in fullsteps of: usrs2 aaf  with af: acceleration in fullsteps

TMCM-343 Hardware Manual (V1.07 / 2011-JUN-08) 24 Copyright © 2011, TRINAMIC Motion Control GmbH & Co. KG Example: Signal value f_CLK 16 MHz velocity 1000 a_max 1000 pulse_div 1 ramp_div 1 usrs 6 Hz31.122070 3220482 1000MHz16msf 1  Hz34.1907 31.122070]Hz[fsf 6  s MHz21.119 1000)Mhz16(a 2911 s MHz863.1 s MHz21.119 af 6  Calculation of the number of rotations: A stepper motor has e.g. 72 fullsteps per rotation. 49.2672 34.1907 rotationperfullsteps fsfRPS  46.158972 6034.1907 rotationperfullsteps

TMCM-343 Hardware Manual (V1.07 / 2011-JUN-08) 25 Copyright © 2011, TRINAMIC Motion Control GmbH & Co. KG

11 TMCL™

TMCL™, the TRINAMIC Motion Control Language, is described in separate documentation s, which refer to the specific products (e.g. TMCM -341/342/343 TMCL™ Firmware Manual). The manuals are provided on the TMC TechLibCD and on www.trinamic.com. Please refer to these sources for updated data sheets and application notes. The TMC TechLib CD includes data sheets, application notes, and schematics of evaluation boards, software of evaluation boards, source code examples, parameter calculation spreadsheets, tools, and more.

12 CANopen

The TMCM -343 module can also be used with the CANopen protocol. For this purpose, a special CANopen firmware has to be installed. To do that, download the latest version of the TMCM -343 CANopen firmware from the Trinamic website or use the version provide d on the TechLib CD and install it using the firmware update function of the TMCL -IDE (Setup/Install OS). The TMCM-343 module is then ready to be used with CANopen. Please see the specific CANopen manual provided on the TRINAMIC website and on the TechLibCD on how to use the TMCM -343 module with the CANopen protocol.

TMCM-343 Hardware Manual (V1.07 / 2011-JUN-08) 26 Copyright © 2011, TRINAMIC Motion Control GmbH & Co. KG

13.1 Document revision

Version Date Author Description 1.00 2008-MAY-19 OK Some figures corrected 1.01 2009-DEC-15 OK Migration and CANopen chapters added 1.02 2009-MAY-08 OE Dimension Figure extended 1.04 2009-JUN-12 OK Chapter 5.5. corrected 1.05 2010-FEB-24 SD Dimensions corrected, minor changes 1.06 2010-MAR-02 SD New front page, analog measurement range in chapter 6 completed 1.07 2011-JUN-08 SD Minor changes Table 13.1: Document revision

13.2 Hardware revision

Version Comment Description

1.00 Initial release First version of new generation TMCM-343

1.01 Actual version

Table 13.2: Hardware revision

13.3 Firmware revision

Version Comment Description

4.07 Initial release Please refer to the TMCM -341/342/343 TMCL™

4.20 Actual release

Table 13.3: Firmware revision

TMCM-343 Hardware Manual (V1.07 / 2011-JUN-08) 27 Copyright © 2011, TRINAMIC Motion Control GmbH & Co. KG

14 References

[TMCM-343] TMCM-343 Hardware Manual on www.trinamic.com [QSH-4218] QSH-4218 Manual on www.trinamic.com [TMCM-323] TMCM-323 Hardware Manual on www.trinamic.com [TMCM-EVAL] TMCM-EVAL Hardware Manual on www.trinamic.com