TMC2209 stepper speed

RasFromSinno
Posts: 1
Joined: Tue Nov 28, 2023 10:18 am

TMC2209 stepper speed

Postby RasFromSinno » Tue Nov 28, 2023 12:24 pm

Hello everyone,

I'm experiencing a problem where I can not seem to run my stepper motor at any speed above around 250RPM.
I see this is a pretty common issue around the web, but I have not found any solution that actually fixes my problem.

My setup is as follows:
cool drawing.png
cool drawing.png (102.26 KiB) Viewed 2360 times
The stepper im using is a bipolar JoY-iT Nema11-02 motor, with the specs:
Rated voltage: 6.5V
Rated current: 0.67A
Phase resistance: 9.7ohm
Step angle: 1.8deg
Holding torque: 120mN.m
200 steps/rev
Rated for 3000rpm.

However, i have the same problem with a bigger Nema 14 (400mN.m, 4.2V, 1.5A) and Nema17 (3.4V, 1.7A).

Using the TMC2209 library by Peter Polidoro (https://github.com/janelia-arduino/TMC2209)
I'm setting the following things with the library:

Run-current = 100%
Hold-current = 5%
Enable CoolStep (2,0)
Disable analog current scaling
Enable automatic current scaling
Disable StealthChop
Reply delay = 2
StallGuard threshold = 0
StealthChop duration threshold = 0
Standstill mode = freewheeling
Microsteps per step = 1 (in order to disable microstepping, for torque reasons mainly)
CoolStep current increment = 0
Use external sense-resistors
Inverse motor direction
Enable automatic gradient adaptation

Then, for running the motor, i set vAct to a value that makes the motor run at 200 RPM, which works.
However, going above 250 makes it unstable, and not self-start, and above about 280 it just stops turning. This is the same for all motors.
It helps a little to lower the run-current, and i can reach somewhere around 300-320 rpm with that, however with reduced torque (as expected).
It also sometimes helps to change the start and end hysterises for SpreadCycle.
Using stealthchop or not makes little to no difference.

Using an oscilloscope, the output to my motor seems fine, and doesnt seemingly drop in voltage under load/higher current.
Measuring across my exteral sense resistors, or putting a meter in series with the motor, shows i use about 300mA per resistor (so per coil, 600mA in total) for the small 0.67amp motor.


My theory is I'm either not charging the coils fast enough (too low voltage) or I'm not discharging the coils fast enough (decay too slow, yet changing things like TBL, PWM offset, HSTRT and HEND doesn't seem to do much). But I'm not sure how to deal with either without burning out the motor.
Please help, and please let me know what more info y'all might need.

Thanks in advance,
Ras

Jac_2207
Posts: 1
Joined: Sun Mar 17, 2024 1:51 am

Re: TMC2209 stepper speed

Postby Jac_2207 » Sun Mar 17, 2024 2:10 am

Hi, your problem could be caused by multiple things. 1st you should connect pin 7 of the tmc2209 to 3.3V. That sets the driver permanently in spreadcycle mode, a way more precise and poerful method for smooth motion. If you do that, you deactivate the standard Stealthchopping mode, wich is good in most cases, to reduce the motor noise. The problem is, that only works well until a certain speed, then it breaks down. Sounds like what you described. All in all ist Spreadcycle better for most usages of the Tmc drivers. I would set Spreadcycle that way, because maybe via Uart it doesent work for you. Also to reach higher speeds with a stepper motor, you have to give it a higher Voltage. the Tmc2209 can take up to 28V, that isn`t to much but should increase your rpm capabilities. 3 last things, reduce your interpolation. Set a Microstep rate of 1/16 or 1/32. The lower it`s set, the more rpm get possible. But, if you set it to low, der Stepper will vibrate like crazy, so keep an eye on that. For high rpm`s, you should also increase the current, in best case you`re able to active cool the Stepper, so you can drive it at maximum current. The last thing is, you should use a step pulse duration, of around 0.1 Microsecond. That allows a smooth and really fast signal.

I hope that helped.

VG
Jacob

Who is online

Users browsing this forum: No registered users and 116 guests