Comments (3)
Hey,
i guess you used Marlin with StallGuard on a 3D-printer (so a different setup).
I implemented the StallGuard-Feature while using pliers to "stall" the motor, which in my case worked perfectly.
I would suggest to test and determine the current first. Try to decrease the current until the motor starts to stall with your setup and the use like 10%-50% more current to reliable actuate the motor.
When you have determined your current you can try to find you StallGuard value.
In the set_vactual
function you can use the show_stallguard_result
parameter to print the stallguard result values while the motor is moving:
TMC2209_Raspberry_Pi/src/TMC_2209/TMC_2209_StepperDriver.py
Lines 835 to 876 in 457dcf2
In the datasheet of the TMC2209
https://www.trinamic.com/fileadmin/assets/Products/ICs_Documents/TMC2209_datasheet_rev1.08.pdf
on site 59 there are the following instructions:
INITIAL PROCEDURE FOR TUNING STALLGUARD SGTHRS
- Operate the motor at the normal operation velocity for your application and monitor SG_RESULT.
- Apply slowly increasing mechanical load to the motor. Check the lowest value of SG_RESULT
before the motor stalls. Use this value as starting value for SGTHRS (apply half of the value).- Now monitor the StallGuard output signal via DIAG output (configure properly, also set
TCOOLTHRS to match the lower velocity limit for operation) and stop the motor when a pulse is
seen on the respective output. Make sure, that the motor is safely stopped whenever it is stalled.
Increase SGTHRS if the motor becomes stopped before a stall occurs.- The optimum setting is reached when a stall is safely detected and leads to a pulse at DIAG in
the moment where the stall occurs. SGTHRS in most cases can be tuned for a certain motion
velocity or a velocity range. Make sure, that the setting works reliable in a certain range (e.g. 75%
to 150% of desired velocity) and also under extreme motor conditions (lowest and highest
applicable temperature).
from tmc2209_raspberry_pi.
hi christian,
awesome! this is really helpful. thank you very much. for my application - i was using a 3d printer board, but i only need one channel, and there's a raspi in the mix anyways - so it seems a waste to use a separate marlin board. i will try your suggestions, and hope i can lower my parts count :)
thanks!
.rm
from tmc2209_raspberry_pi.
Hey,
i will close this issue now.
If you have still problems with tuning StallGuard, feel free to reopen this issue.
from tmc2209_raspberry_pi.
Related Issues (20)
- Implementing CRC check for reply datagrams
- Destructor not beeing called
- change code to comply with Style Guide for Python Code
- Standstill current reduction not working (iHOLD) HOT 2
- TMC2209: after 10 tries not valid write access HOT 2
- Adding a function for continous turning HOT 3
- Do something else while running a stepper HOT 4
- positions being skipped (due to performance issues) HOT 3
- Stallguard fires right away HOT 4
- Connecting two tmc2209 to serial HOT 6
- about wiring diagram and wiring table HOT 3
- Compatible with Watterott TMC2209? HOT 7
- First vactual after TMC power-on is different than the rest HOT 1
- How to disable UART and use just STEP/DIR HOT 3
- When will version 0.4.3 be released HOT 2
- TWOTREES TMC2209 v2.0 passes tests but fails to energize stepper HOT 3
- Request: Replace logger print-statement with python logging library HOT 3
- RuntimeError when redoing homing after failed attempt HOT 5
- Add support for Raspberry Pi 5 HOT 17
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from tmc2209_raspberry_pi.