-
How to drive a stepper motor with your Arduino Mega using a TMC5130-EVAL
Only a few wires including an SPI port are required to control TMC5130-EVAL with your Arduino. Here are the few steps required to get started. Preparation If your Arduino is a 5V type you have to resolder one resistor on the TMC5130-EVAL from position R3 to R8. This sets the logic level of the TMC5130 to +5V. While by default […]
-
TMCL: how to implement a for loop
This program demonstrates how to implement a for loop For more details look at TMCL_reference.pdf SGP 0, 2, 0 //set user variable #0 //for Loop forLoop: // add your code here // GGP 0, 2 //get user variable #0 to accu CALC ADD, 1 //add 1 to accu AGP 0, 2 //accu to user variable […]
-
TMCL: Interrupt Input Change
TMCL is the simple way to implement your motion control application. With this series of simple coding examples we want to provide you an easy start. This programs demonstrates how to the interupt on an input change. The behaviour of this program is the same as EX0008. Depending on the status of Port IN_0 is motor 0 turning right (IN_0 […]
-
TMCL: Using the stallGuard Interrupt
TMCL is the simple way to implement your motion control application. With this series of simple coding examples we want to provide you an easy start. This program demonstrates the stall detection with stallGuard2™. Motor 0 will run until it is stalled, then MCL program flow will be interrupted and the interrupt handling routine (here: returnToZero) will be called. After […]
-
TMCL: Door Contact with Position Mode
TMCL is the simple way to implement your motion control application. With this series of simple coding examples we want to provide you an easy start. This programs demontrates how to implement an application containing one or more parallel door contacts, e.g. automatic rolling window shade. The movement of the rolling window shade stops as soons as the door contact is […]
-
TMCL: Timer Interrupts
TMCL is the simple way to implement your motion control application. With this series of simple coding examples we want to provide you an easy start. This program demonstrates how to use the timer interrupt. To use this program connect LEDs to OUT_0 and OUT_1. The LED at Port OUT_1 is toggling at 2 Hz using the WAIT command. […]