[2.0.x] Configure stepper drivers per axis#11264
[2.0.x] Configure stepper drivers per axis#11264thinkyhead merged 2 commits intoMarlinFirmware:bugfix-2.0.xfrom
Conversation
|
@teemuatlut may I close my pull request? |
a9f1788 to
68b4875
Compare
|
Yes, I believe so. |
|
@teemuatlut : This PR does not impact the stepper ISR, i have no problems with it. |
|
Currently in upstream we have a condition for the step width: |
68b4875 to
c3789ed
Compare
Marlin/src/inc/SanityCheck.h
Outdated
There was a problem hiding this comment.
Is this sanity-check obsolete already, or is it just now becoming obsolete with this PR?
There was a problem hiding this comment.
It's mostly just shuffling the code around to bring more sense into it. Nothing is being removed.
Marlin/src/inc/SanityCheck.h
Outdated
There was a problem hiding this comment.
Does this TMC_Z_CALIBRATION test get replaced elsewhere, or is TMC_Z_CALIBRATION being dropped?
c3789ed to
221466f
Compare
There was a problem hiding this comment.
I see in a few configurations that ENDSTOP_INTERRUPTS_FEATURE is being disabled. Is this because the pins that go with these configs are not interrupt-capable?
There was a problem hiding this comment.
Not intentional. I'll need to redo the search&replace operation.
|
Overall it looks very good. It's much better than the previous method of configuration, with the details now hidden from the user and a much more expressive connection between stepper drivers. This will get merged pretty soon, methinks. |
23dadfd to
8a2c9ae
Compare
Co-Authored-By: teemuatlut <teemu.mantykallio@live.fi>
8a2c9ae to
fbcdf5e
Compare
|
@teemuatlut - FYI it looks like the new |
|
So it seems. Must be because for whatever reason the endstop inverting is turned on by default. I don't know why that should be the case. |
Builds upon #11133
Configuration_adv.hto override the parsed driver IC defaults.TMC5130. However this PR doesn't yet move Marlin to the library that supports the driver.TMC2130andTMC2130_STANDALONE. The way I see it, the default use case for that driver is in configured mode and using standalone mode is a special case. In standalone mode only the stepper timings are affected and they pretty much act the same asTMC2100as far as Marlin is concerned.I decided to use the Allegro drivers as the default to match what is the most common configuration in the user base. Specifying any drivers is not forced but will default to DRV8825 configuration, except for DIR delay. This could be improved, or force defining at least one driver (unless overriden in _adv.h).
I think the main question is if we know the parameters different drivers require, which should be used as the default? I think we should not use 0 delays as there is no driver compatible with such timings.
However, this doesn't take into account the natural delay there is no matter what we do.
This also leads to a more general configuration change that affects the stepper ISR. Perhaps we should no longer check if
MINIMUM_STEPPER_PULSEis defined, because from hereon it always is, and rather check if the defined pulse width is greater than 20 for example. @ejtagle ?The compile time driver IC macros:
AXIS_DRIVER_TYPE(A, T)Check if an axis
Ahas a driver typeTassociated with it.HAS_DRIVER(T)Check if the user has driver type
Tin any of the axis enabled.HAS_TRINAMICCheck if any supported Trinamic drivers are enabled in any axis.
AXIS_IS_TMC(A)Check if the specified axis
Ahas a supported Trinamic driver enabled.