UART This! Serial Control of Stepper Motors With the TMC2208, Ramps 1.4 and Marlin

Introduction: UART This! Serial Control of Stepper Motors With the TMC2208, Ramps 1.4 and Marlin

About: I'm a former electrical engineer who's changed careers and become a physical therapist. I still have a passion for tech though, as well as healthcare now.

Most people who are involved with DIY 3D printers or just like tinkering with a Maker-Grade commercial printer, will have heard of the Trinamic series of stepper motor driver chips. These little chips are making waves throughout the consumer and prosumer 3D printer markets due to their astonishing ability to render a 3D printer practically silent.

The TMC2208 is also used by the German manufacturer Watterott in their SilentStepStick stepper motor driver product series. However, there is very little information written in layman's/Maker's terms regarding how to actually wire up this stepper motor driver board, to a traditional Ramps 1.4 to 1.6 style Arduino shield, in order to use the feature of serial communications over UART to control the stepper motors. In this Instructable, I will try to alleviate this by taking you through a step-by-step setup of how to use a TMC2208 based SilentStepStick in a UART configuration on your 3D printer.

EDIT-August 2018: When I originally wrote this Instructable, the default Pin assignments within Marlin were different from what they are now. The photo above shows my Y-cables in different positions to what they would be now, in the current version of Marlin. See Step 10 for details on how to find these current Pin assignments.

Teacher Notes

Teachers! Did you use this instructable in your classroom?
Add a Teacher Note to share how you incorporated it into your lesson.

Step 1: Why Write This Instructable?

With these TMC2208-based SilentStepSticks, the only option really discussed anywhere on the web is for direct plug-and-play replacement of the Pololu A4988 drivers (which doesn't give you the benefits of the UART serial communication for control over your stepper motors), but the TMC2208 driver is actually capable of three different modes of operation in controlling the stepper motors of your 3D printer:

  • Legacy mode: Direct plug-in replacement for the Pololu A4988 on a Ramps 1.4 - 1.6 style board
  • Standalone mode (no active serial communications) with the STEP/DIR settings being preset by setting the OTP (One Time Programmable) bits
  • Active STEP/DIR Driver with full UART serial control giving full diagnostics and control over the stepper motors

Mode 1 (Legacy Mode): this has already been discussed in the opening paragraph of this Instructable, basically solder on header pins, stick on a heat sink so it looks just like a Pololu A4988 board, and plug it into the Ramps board.

Mode 2 (Standalone Mode): This mode has been explained very well by YouTube creator Keith Young in which he shows you how to solder the header pins to the SilentStepStick board and then set/program the OTP (one-time programmable) bits to change the chip from stealthChop2 mode to spreadCycle mode.

Note, these OTP bits are truly one-time programmable. Once you "set" these bits you make a permanent change in the silicon of the chip and this cannot be reversed. So I would recommend operating these chips in the default stealthChop2 mode for a while, to see if you get any skipped steps, before considering changing them to the spreadCycle mode by setting these OTP bits.

Mode 3 (Active STEP/DIR Driver): This mode is what this Instructable is all about. YouTube creator Alex Kenis has put out a great video on this option in which he explores the best micro-step settings in firmware and driver voltage levels (12V vs 24V), to get the most torque from your motors.(edit: Alex Kenis put out an update video on this process and goes into a lot more detail)

The intent of this Instructable is to expand upon his work (in terms of explanation) and make it more approachable to the less technical Makers out there. In short, Mode 3 allows the TMC2208-based SilentStepStick to be actively/dynamically controlled through UART (serial communications) by firmware (Marlin in this case).

You don't have to fiddle with jumpers to set your micro-steps, just change it in the firmware, and you can dynamically change the amount of current going to each stepper motor (no more adjusting that small potentiometer on the driver board) just by sending a GCode command (M906).

BENEFITS OF MODE 3

  • Motor current can be set arbitrarily through the firmware
  • Micro-steps can be set arbitrarily through the firmware (up to 256 real micro-steps)
  • Real and interpolated micro-steps can be combined to achieve max torque
  • Firmware can switch the stepper motors between stealthChop2 and spreadCycle mode on the fly via UART (sect. 1.4 of datasheet, so no need to set those OTP bits)
  • Motor standby current can be reduced dynamically (via UART) when the motor is not moving (sect. 1.6 of datasheet)

...just to name a few benefits

One more bit of explanation before I get into this in detail. For those who haven't realized this yet, there are two companies involved here:

  1. Trinamic who actually design and make the TMC2208 chip, and
  2. Watterott who use the TMC2208 chip on their SilentStepStick stepper motor driver board

So let's get into it...

Step 2: Supplies and Tools

Here are the basic tools and supplies you will need to complete this Instructable. Mostly, these items are needed to make the Y-cable required for the UART communication between the SilentStepStick and the Ramps board.

NOTE: the following links are shortened URLs, they are NOT affiliate links.

Supplies

  • Heat shrink tubing, approx. 5cm (2") in length and 3mm (3/16") in diameter for each Y-cable. If you don't have any heat shrink tubing at all, I suggest getting a pack of it in various sizes for future projects (see photo).
  • Metal Dupont connectors (female), along with 1-pin and 2-pin plastic housings for each Y-cable. Again, get a pack that includes both male and female connectors and a variety of plastic housings
  • Wire: I used 22AWG or 0.326mm2 (10cm for each Y-cable)
  • 1KOhm resistor (the tolerance of the resistor doesn't matter), one resistor is needed for each Y-cable
  • Heat sinks: both the Pololu and taller SilentStepStick varieties. You'll need one of each for each stepstick you are using.
  • Watterott V2 Protector Boards (U.S), Europe or Female riser header pins (not shown: to elevate the SilentStepSticks enough to get a small heat sink underneath)
  • Optional: The heat sinks should come with thermal adhesive tape already applied. If not then you can get some here.

Tools

Step 3: SilentStepStick Jumper Pads

By default, the UART pin on the Trinamic TMC2208 chip is not connected to the header pin(s) of the Watterott SilentStepStick. In order to make this physical connection from the chip to the header pin we need to solder a jumper between the jumper pads on the bottom of the SilentStepStick board. You can see these solder pads in the Fritzing and photographic images above.

There have been several versions of the Watterott TMC2208 board, with some having only two jumper pads. On the iteration I have (and that shown in the photos in this Instructable), there are three pads grouped together. The center pad is the direct connection back to the TMC2208 chip. The two pads on either side connect directly to the header pin they are closest to. The silkscreen side of the board has these two header pins labeled collectively as PDN UART.

They are both available to be used as the PDN_UART line, because neither pin is used by the Arduino Mega for the Pololu A4988 drivers. So Watterott has decided to designate both header pins as being available for solder connection to the TMC2208 PDN_UART pin of the chip.

We only need one of these two header pins for our UART serial connection, so you can either solder the center pad to the left or right pad, or to both. If you only solder to one side, then you must remember to solder the header pin for that side pointing up, so you can attach your UART jumper wire to it later. If you want to eliminate any chance of mistake, then just solder all three pads together. That way it doesn't matter which header pin you solder pointing up, as they will both work.

Step 4: SilentStepStick Header Pins

Now that the jumper pads are soldered we can solder the header pins in place (if your board didn't already come with the header pins attached). According to the Trinamic TMC2208 datasheet (page 5), a benefit to using the chip configured as Option 3 (UART) is that all control lines (EN, DIAG, INDEX, MS1, MS2, and analog current setting VREF) are replaced by the one UART line, and therefore are configured through, and controlled by, firmware.

So technically speaking, the only header pins actually required on this side of the SilentStepStick board are the Dir (direction), Step, and PDN_UART pins. The PDN_UART pin will need to be soldered pointing up so you can attach the jumper wire to the Ramps board; however, in reality, the EN pin must be soldered down as well. I give credit to Instructables member crzcrz for pointing this out to me.

If the EN header pin is not soldered in, then no enable signal is sent to the TMC2208 chip, and your motors will not turn on. I'm not sure if this is an issue with the current version of Marlin (1.1.8 as of the time of writing this Instructable) or with the latest version of the Watterott 2208 boards. I'll update this 'ible once I find out more. Regardless, just remember to also solder on the EN header pin. The images above are correct. If you want to play it completely safe, then just solder on all of the header pins, with the PDN UART pin pointing up, and the others pointing down.

Step 5: Heat Sinks

These TMC2208 chips run hot (as do any of the stepper driver chips that are sinking close to an amp or more of current). These chips have built-in thermal protection, but that means your stepper motors will lose steps if these chips get too hot (and the thermal protection turns on), thereby ruining your print.

So do yourself a favor and put plenty of heat sink surface area on these chips. In the video referenced previously by Alex Kenis he uses two heat sinks and also puts a fan on his Ramps board. I have used my chips with only one Pololu type heat sink on top, along with a fan, and I still lost steps about two hours into a print (motor current set to 800ma in Marlin). So I now also use two heat sinks (see photos above) on mine, with a fan, and everything runs very well.

The top heat sink is 9mm x 9mm x 12mm and the bottom heat sink is a typical Pololu A4988 heat sink measuring approx. 9mm x 9mm x 5mm. In order to allow space for the bottom heat sink, the SilentStepStick needs to be put onto either the Watterott V2 Protector Board or a line of female riser pins, to raise it up enough to clear the pins on the Ramps board underneath.

Watterott makes the specialized "V2 Protector" riser board, which uses a Schottky diode, to ensure the driver chips are powered in the correct sequence, between the VIO (logic level 3.3V/5V) and VM (12v/24v supply) voltages. At the time of writing this Instructable, I didn't have any of these diode protector boards available to me, so I just used some female risers, and it worked without a problem.

I have since purchased some of the V2 Protector boards and now use them, simply because they are cheap insurance against burning up your TMC2208 stepsticks. Just be aware that without these V2 protector boards, if you manually move your axes around quickly, the back EMF produced within the stepper motors could be substantial and could feed back into the stepsticks and destroy the logic circuitry in the TMC2208 chip. So if you decide not to get the V2 Protector Boards, just move the axis slowly to minimize the amount of back EMF produced.

Both the female risers and V2 Protector Boards fit VERY tightly on the Ramps board, so install them first, like you see in the photo, then plug your stepsticks into the risers.

Step 6: Connection to Ramps Board

Looking at the image above from Watterott, we can see that in order for the SilentStepStick to communicate with the Ramps board via UART, there needs to be a one wire connection from the UART pin on the SilentStepStick. That one wire then splits into two lines (Rx and Tx) for connection to the Ramps board, with the Tx (transmit) connection being made through a 1K Ohm resistor.

The way I chose to make my Y-cable places the split from the one wire into the two wires, near the AUX2 header pins on the Ramps board. For those experienced makers out there, you will have no problem making this cable. For the new Makers, I'll explain step-by-step how I made my Y-cables.

The single wire connects to the SilentStepStick, and the double wire end connects to the Ramps board. The 1K Ohm resistor is covered with the blue heat shrink tubing.

ALTERNATIVELY (use two cables):
If your TMC2208 SilentStepStick has three solder pads on the bottom of the board, you can solder all three jumper pads together, which ties both associated PDN_UART header pins together on the SilentStepStick, and you can put both header pins pointing up. Since both header pins are physically tied together, you don't have to make a "Y" cable. Just solder a 1KOhm resister in line with one of the cables (for the Tx line), plug that Tx wire into one of the two available header pins on the SilentStepStick, and use a second plain wire to go from the Rx pin on the Ramps board to the second header pin on the SilentStepStick.

Just ensure you keep track of the Tx and Rx pins on the Ramps board, making sure both cables go to the same SilentStepStick.

Step 7: Prep the Wire and Resistor

Cut The Wire To Length

  • Get some small gauge wire (I used approx. 22AWG or 0.326mm2), and cut a piece 10cm long
  • From this 10cm piece, cut off a short piece 28mm (or approx. 1 1/8") long, then strip some of the insulation jacket off of both ends.
  • Get a 1K Ohm resistor and cut one lead to 12mm (approx. ½") in length. This cut end will be crimped and soldered to a female Dupont connector.


Attach The Dupont Connectors

  • Crimp a female Dupont connector to one end of the wire
  • Crimp and solder a female Dupont connector to the cut lead of the 1K Ohm resistor. I soldered the connector on because the resistor lead was so thin I wasn't able to get a firm connection with crimping alone.

Step 8: Combine the Two Leads

  • Push both Dupont connectors into the 2-pin female plastic housing
  • Slip a bit of heat shrink tubing over the resistor to prevent accidental shorts (and thus signal injections) from the environment.
  • Twist the end of the wire and other lead of the resistor together, and then fold the remaining lead of the resistor back to form a hook.

Step 9: Soldering the Y-cable

  • Take the remainder of the original 10cm long wire and strip one end, then fold this stripped end back to make a hook
  • Hook this wire over the hook you made from the resistor lead, and pinch down to lock them together
  • Solder the two halves together.

For those new to soldering, I like to use a solder flux pen to apply a little liquid solder to the connection. It makes the process so much faster and cleaner. I use this in addition to flux core solder wire, because the liquid solder really pulls the solder in between the individual strands of wire.

  • Lastly, push a bit of heat shrink tubing over this connection to reinforce it

The last step will be to cut the single wire to length, strip the wire, crimp on a Dupont connector and attach that end to the SilentStepStick, but the "hard" part of making the Y-cable is complete.

Step 10: Firmware (Marlin 1.1.8): Pins.h File

Within Marlin, the pins.h file identifies which pins on the Ramps board are to be the receive and transmit pins for the UART software serial connection. By default, these pins are located within the AUX-2 header on the Ramps board. In the image above, you can see these header pins along with the default motor/axis they are assigned to in Marlin 1.1.8.

To find this section in the pins.h file, just open the file in a decent text editor like NotePad++ or Atom, and search for "HAVE_TMC2208". If you wish to change the pin numbers, that go to each axis, the pins.h file is where you make this change. The graphic above, of the Ramps board, shows the default pin assignments within the pins.h file in Marlin 1.1.8.

Plug each Y-cable from the respective set of header pins, in the AUX2 header, to the corresponding SilentStepStick PDN_UART pin. Be sure you put the resistor side of the Y-Cable on the Tx (Transmit) pin.

Since writing this Instructable, I have added a 5th SilentStepStick driver to my Ramps board (for a second Z-Axis motor), and have chosen to use pins 57 and 58 from the AUX1 header for this UART connection (see graphic above).

Step 11: Firmware (Marlin 1.1.8): Configuration_adv.h File

If you decide not to adjust the pins.h file, and just go with the default pin assignments in the AUX2 header, then the only file you will need to modify is the configuration_adv.h file. In this file, you need to turn on/activate the section for the TMC2208 so Marlin will begin communicating with the SilentStepStick over the UART serial interface.

You can open the configuration_adv.h file either in the Arduino IDE or using a text editor such as Notepad++ or Atom. Once open, follow these steps to activate the TMC2208 feature:

Part 1: Activate the TMC2208 feature

  • search for "HAVE_TMC2208"
  • Remove the two "//" that are at the start of this line (this "uncomments" the line, and makes it active)


Part 2: Tell Marlin which axes have stepsticks

A few lines further down you will find separate lines for each of the axes of the machine

  • Uncomment the line for each axis you want to use a TMC2208 SilentStepStick on

The next area further down (stepper driver settings) is where we can specify how the stepper driver controls the motors.

Part 3A: Stepper driver settings (hold current and step interpolation)

  • Hold current: this value is set from 0.0 to 1.0 and establishes how much current is used by the stepper motors when they are not moving, i.e. on hold. The range of 0.0 to 1.0 changes the normal run current from 0-100%. The default value is 0.5 (50%).
  • Step interpolation: setting this to "true" turns on 256 step interpolation. When we combine this step interpolation with the physical micro-step settings (talked about next), we can maximize the torque delivered by the stepper motors.

Part 3B: Stepper driver settings (motor run current and physical micro-steps)

  • Motor Current: here you can specify how much current your individual stepper motors will use while they are running. Prior to UART serial control, you had to use a small screwdriver and physically adjust the small potentiometer on the stepstick driver board. Well, not anymore, just make the change here in firmware. Even better, you can send the GCode command M906 from your printer software and dynamically change the run current while the printer is operating.
  • Micro-steps: this is where you set the physical/real micro-steps of your motors. You can set these from 0-256 real micro-steps, but the most torque is produced when this value is set to 4 (1/4 stepping...see below).

In the video by Alex Kenis, he tested torque values of a motor under different configurations and found that the motor produced the most torque when the TMC2208 SilentStepSticks were run in the following configuration:

  • powered from a 24v source
  • Step Interpolation was made "true" (Part 3A above)
  • real micro-steps were set to 4 (for 1/4 stepping)
  • Mode of operation was set to stealthChop (as opposed to spreadCycle mode)


Part 4: enable stealthChop mode

  • Uncomment the line that says "#define STEALTHCHOP" in order to enable the stealthChop mode


Part 5: enable Hybrid mode (switches dynamically between stealthChop and spreadcycle modes)

  • The last portion of this section will be to uncomment/enable the line that says "#define HYBRID_THRESHOLD"
  • You can adjust the speed values to specify at what speed the driver switches from stealthChop mode to spreadCycle mode and back again.

Part 6 (not pictured): add the TMC2208 library to your Arduino IDE so Marlin can use this library when compiling.

  • In your Arduino IDE, go the "Sketch" menu, down to "Include Library" and finally choose "Manage Libraries..."
  • In the Library Manager window that opens, type "2208" in the search box, and the library file for the TMC2208 will appear
  • Click on the "TMC2208Stepper" result and you should see an Install button appear, just click that to install the library

Re-calibrate the Printer

Lastly, if you change your micro-steps, from what you were using previously, then you will need to re-calibrate your printer (all motors) by opening the configuration.h file in Marlin, going to the section "@section motion", and changing the steps/mm numbers in this line:

#define DEFAULT_AXIS_STEPS_PER_UNIT { 40, 40, 200, 48.2 }

NOTE: these are my values for my printer, you will need to establish your own values based on your printer and what micro-step values you are using, because the firmware will be using these values to send a certain amount of steps/mm for each axes movement. But, if your stepper driver is driving the stepper motors at a different steps/mm count (because your micro-step settings are now different), then your printer's resolution will not be accurate.

Step 12: Firmware (Marlin 1.1.9): Pins.h File

This is an update of this Instructable to account for the changes in Marlin with release 1.1.9

Of particular note, the developers changed the default pin assignments for the SilentStepStick axes. See the graphic above for the default 1.1.9 pin assignments for each axis. Since writing this Instructable, I have added a 5th SilentStepStick driver to my Ramps board (for a second Z-Axis motor), and have chosen to use pins 57 and 58 from the AUX1 header for this UART connection (see graphic above).

Step 13: Firmware (Marlin 1.1.9): Configuration.h File

In Marlin 1.1.9 the developers moved the stepper driver selection section from the Configuration_adv.h file into the Configuration.h file. They also expanded on how you can identify what type of mode you are operating the SilentStepStick in, by typing:

  • TMC2208 -- to indicate you want to control the SilentStepStick via UART
  • TMC2208_STANDALONE -- to not use UART control and instead use the TMC2208 SilentStepStick in the same manner as you would a standard Pololu A4988, in other words plug-in-play

configuration.h

Within the configuration.h file, search for "stepper drivers". This should bring you to the correct section of the file. By default, all potential stepper motors are identified as using the Pololu A4988 driver.

For each axis and extruder you plan on using a TMC2208 SilentStepStick on, change the A4988 to either TMC2208 or TMC2208_STANDALONE.

I operate five SilentStepSticks. You can see how I have set up my configuration.h file above.

This is the only change you will need to make within the configuration.h file, in order to use the TMC2208 SilentStepSticks. Now move on to the next step to set up the configuration_adv.h file.

Step 14: Firmware (Marlin 1.1.9): Configuration_adv.h File

Within the configuration_adv.h file you will set up everything, just as in Step 11 of this Instructable, except for specifying which axes and extruders use the TMC2208 driver, as this was moved to the configuration.h file (see Step 13). Nothing else has changed in this configuration_adv.h file--related to the TMC2208 drivers.

To find this section, just search for "section tmc_smart".

Step 15: Finish!

Whew! You finally made it. Now plug in your Ramps board, flash your firmware and try it out.

For those who noticed that I had Fritzing parts for the Ramps board and the TMC2208 SilentStepStick board, and wondered where I got them from, well, nowhere. I had to make them for this Instructable. At the time of writing this Instructable, the Fritzing site "sign-up" page was broken, and I was unable to create an account in order to upload my Fritzing files, so I am attaching them to this Instructable for those who want to import them into your Fritzing projects.

Be the First to Share

    Recommendations

    • Sculpting Challenge

      Sculpting Challenge
    • 3D Printed Contest

      3D Printed Contest
    • Motor Vehicle Contest

      Motor Vehicle Contest

    70 Discussions

    0
    recoil6
    recoil6

    5 months ago

    Thank you for the fantastic tutorial. Does Marlin 2.0 use the same pins as 1.1.9? I can't find a pins.h file in Marlin-bugfix-2.0.x. It be awesome to add information for Marlin-bugfix-2.0.x. Thanks!

    0
    Eddiiie
    Eddiiie

    8 months ago

    Hello,
    Great write up! Can you confirm pins 57/58 are working for you? I get all 0's no matter which UART I assign to those pins.
    .
    Marlin 1.1.9 Bugfix

    0
    KiwiDust
    KiwiDust

    Reply 16 days ago

    No these pins are incorrect. the RX pin must use a interrupt capable pin. "only the following can be used for RX: 10, 11, 12, 13, 14, 15, 50, 51, 52, 53, A8 (62), A9 (63), A10 (64), A11 (65), A12 (66), A13 (67), A14 (68), A15 (69)."

    0
    bcarlson320
    bcarlson320

    Question 7 months ago

    After completing this will I be able to adjust my microstep via Gcode or would I still have to reflash the firmware if I wish to change the micro steps?

    0
    Bowlcut
    Bowlcut

    Question 9 months ago on Step 4

    Should the pins on the 2208s look like this for the ramps 1.6+/re-arm or can I leave all the pins and just add the one riser pin to the PDN? I know you mention that those aren't needed for Marlin 1.1.8 becuase they'll be controlled through firmware and the UART but since I'm using the 2.0x for 32bit Re-Arm and I'm using the ramps 1.6+ (which claims to be better designed for the TMC drivers) should I remove those 4 pins still?
    https://cdn.instructables.com/FDV/5T26/JHATJPW2/FD...

    0
    weruminger
    weruminger

    11 months ago

    Great instruction. I did need 30Min to let it fly. Thanks a lot. b.t.w. i'm usingthe great marlin FW notonly for printer but also to control a Telescope. there for the TMC 2208 are a great enhancement.

    0
    bigsub
    bigsub

    11 months ago

    Hello, is it mandatory to remove MS1/MS2 pins? I read on the net about the possibility that pin 66 is used for other scopes. Now I'm trying to put 4 fysetc tmc2208 in uart on a mks gen l board, and Marlin 1.1.9 but I don't be sure that they are working well.
    What do you think about this M122 response, please? It seems that E0 is not communicating, because the pin 66 is busy:

    M43 P66
    PIN: 66 Port: K4 (A12) MAX6675_SS Input = 0
    . E0_SERIAL_RX_PIN Input = 0


    M122
    X Y Z E0
    Enabled true true true false
    Set current 700 700 700 600
    RMS current 673 673 673 1049
    MAX current 949 949 949 1479
    Run current 21/31 21/31 21/31 18/31
    Hold current 10/31 10/31 10/31 9/31
    CS actual10/31 10/31 10/3 10/31
    PWM scale 12 12 12 0
    vsense 1=.18 1=.18 1=.18 0=.325
    stealthChop true true true false
    msteps 16 16 8 256
    tstep 1048575 1048575 1048575 0
    pwm
    threshold 76 76 65 60
    [mm/s] 130.95 130.62 30.41 481.03
    OT prewarnfalsefalsefalsefalse
    OT prewarn has
    been triggeredfalsefalsefalsefalse
    off time5550
    blank time24242416
    hysteresis
    -end222-3
    -start3331
    Stallguard thrs
    DRVSTATUSXYZE0
    stst X X X
    olb
    ola
    s2gb
    s2ga
    otpw
    ot
    157C
    150C
    143C
    120C
    s2vsa
    s2vsb
    Driver registers:X = 0xC0:0A:00:00
    Y = 0xC0:0A:00:00
    Z = 0xC0:0A:00:00
    E0 = 0x00:00:00:00

    0
    valiobg
    valiobg

    1 year ago

    To anyone who wants to use TMC2208 with Marlin 1.1.8 - don't waste your time ! There are several bugs in this version of Marlin, which make it impossible to use tmc2208 in UART mode. Use 1.1.9 instead. I have JGAurora A5 with MKS GEN L board. I installed 2 TMC2208 - for X and Y in UART mode and one in OTP programmed mode in Spreadcycle for E0. I spent 2 days struggling to get them work with 1.1.8 with no success. I flashed Marlin 1.1.9 and everything worked.

    0
    hinkey
    hinkey

    Reply 11 months ago

    New to this 3d printing - bought a wanhao 1.3 now going to upgrade to re-arm / ramps 1.6 plus and TMC2208 any guidelines / tips. thanks :)

    0
    AnthonyH3
    AnthonyH3

    Question 11 months ago

    Can the steppers run on higher voltage, I have my ground and van pin shoulder in on the top so I can run 24v to them. Will this still work if I use uart ?

    0
    AnthonyH3
    AnthonyH3

    1 year ago

    Does it matter if the stepper jumpers are in or out ?

    0
    AnthonyH3
    AnthonyH3

    Reply 11 months ago

    Thanks. Thanks what I was talkiyabout

    0
    seansadler
    seansadler

    Reply 1 year ago

    Ummmm, I'm not sure what you mean by "in or out". Are you talking about the jumpers for setting the microsteps on the RAMPS board? If so, then the only thing that matters is that the jumper is shorting together the two header pins

    1
    김원빈
    김원빈

    Question 1 year ago

    Hello, I have a mks gen 1.4 with 4 TMC 2208 1.2 .
    So I setup used your guide. But It moved more.
    If i moved 10 mm, It moved 20mm. How can i solve this problem.
    thx.
    20:00:46.433 : N20 M122*16
    20:00:46.443 : XYZE0
    20:00:46.459 : Enabledfalsefalsefalsefalse
    20:00:46.475 : Set current800800800800
    20:00:46.491 : RMS current1436143614361436
    20:00:46.527 : MAX current2025202520252025
    20:00:46.527 : Run current25/3125/3125/3125/31
    20:00:46.527 : Hold current12/3112/3112/3112/31
    20:00:46.543 : CS actual0/310/310/310/31
    20:00:46.559 : PWM scale0000
    20:00:46.591 : vsense0=.3250=.3250=.3250=.325
    20:00:46.608 : stealthChopfalsefalsefalsefalse
    20:00:46.640 : msteps256256256256
    20:00:46.656 : tstep0000
    20:00:46.656 : pwm
    20:00:46.656 : threshold98986584534
    20:00:46.688 : [mm/s]1613.521613.5248.0630.00
    20:00:46.704 : OT prewarnfalsefalsefalsefalse
    20:00:46.704 : OT prewarn has
    20:00:46.719 : been triggeredfalsefalsefalsefalse
    20:00:46.735 : off time0000
    20:00:46.751 : blank time16161616
    20:00:46.767 : hysteresis
    20:00:46.783 : -end-3-3-3-3
    20:00:46.799 : -start1111
    20:00:46.799 : Stallguard thrs
    20:00:46.799 : DRVSTATUSXYZE0
    20:00:46.831 : stst
    20:00:46.847 : olb
    20:00:46.879 : ola
    20:00:46.895 : s2gb
    20:00:46.927 : s2ga
    20:00:46.943 : otpw
    20:00:46.959 : ot
    20:00:46.992 : 157C
    20:00:47.008 : 150C
    20:00:47.040 : 143C
    20:00:47.056 : 120C
    20:00:47.056 : s2vsa
    20:00:47.056 : s2vsb
    20:00:47.072 : Driver registers:X = 0x00:00:00:00
    20:00:47.072 : Y = 0x00:00:00:00
    20:00:47.072 : Z = 0x00:00:00:00
    20:00:47.098 : E0 = 0x00:00:00:00

    0
    seansadler
    seansadler

    Answer 1 year ago

    Hello,
    It seems you have the incorrect value in your "configuration.h" file. Open the configuration.h file and search for "movement settings". Within that section look for "#define DEFAULT_AXIS_STEPS_PER_UNIT". This is where you define how many steps your stepper motor should move in order to travel 1 mm of distance.
    If you are wanting the axis to move 10mm, but instead it is moving 20mm, then the value you have listed in this section is twice what it should be. Reduce your value by half and try again.
    The equation to figure out exactly how many steps you should have is this:

    Correct Step Value= Desired mm of travel * (current step value/current mm of travel)

    So, for example, if your current step value is 40, and this is causing the axis to move 20mm, but you really want it to move only 10mm, then the equation would look like this:

    Correct Step Value=10mm*(40/20mm)
    Correct Step Value=20

    I have attached a screenshot of what this section looks like in my own setup.

    Capture.JPG
    0
    אסףר
    אסףר

    1 year ago

    First, tanks seansadler for the detail instruction. It was very useful for me 

    Second, for those how use MKS Gen 1.4 board with 5 TMC2208 stepper drivers (like I am) the above designation pin number does not work for you. To be able to receive response from all stepper to M122 command you will need to arrange the first 4 steppers UART pins as shown in the attach image (from the previous revision of this instruction) and use the communication pins of SERVO1 for the 5th stepper (pin 6 to Tx and pin 11 to Rx).

    image2.JPGimage.JPGMKS_GEN-PIN.PNG
    0
    seansadler
    seansadler

    Reply 1 year ago

    Thank you for sharing this!

    0
    RyanF197
    RyanF197

    Reply 1 year ago

    Hello. Thank you for the tutorial. I was able to get all my tmc2208 drivers working on my mks gen l board. I am looking at adding a 5th driver for dual z axes. Will the pins above work or, better yet, would I be able to use two of the pins from the unused AUX-3?

    0
    seansadler
    seansadler

    Reply 1 year ago

    Sorry for the late reply. I don't have a MKS board so I can't offer an opinion, other than to say look at the pin assignments in the Marlin PINS file for your board and search for the pin numbers in the AUX 3 header to see which pins aren't being used, then try it. If the stepper motor doesn't behave correctly, then the pin combination is not available for use (even if the pin numbers aren't specifically being used in the PINS header file).