aboutsummaryrefslogtreecommitdiffstats
path: root/klippy/extras/tmc2209.py
Commit message (Collapse)AuthorAgeFilesLines
* tmc2209: Remove duplicate `pdn_disable` initializationAlex Voinea2023-03-151-1/+0
| | | Signed-off-by: Alex Voinea <voinea.dragos.alexandru@gmail.com>
* tmc: Beautify initialization codeAlex Voinea2023-03-071-1/+6
| | | | | Purely esthetic. Make all tmc driver init code similar to one another. The various fields were grouped based on the register which they affect or the function they perform. Signed-off-by: Alex Voinea <voinea.dragos.alexandru@gmail.com>
* tmc: Add support for a get_status() methodKevin O'Connor2021-08-301-0/+1
| | | | | | Export mcu_phase_offset and drv_status information. Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
* endstop_phase: Convert to using tmc mcu_phase_offsetKevin O'Connor2021-08-081-2/+1
| | | | | | | Now that the TMC drivers track the phase offset, use that to implement endstop phase. Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
* tmc: Move stepper phase reading code to TMCCommandHelper classKevin O'Connor2021-08-061-3/+2
| | | | Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
* tmc: Consistently use lower case for all TMC field namesKevin O'Connor2021-08-061-21/+21
| | | | | | | | | | | | The Trinamic specs aren't consistent with upper vs lower case, which can be confusing. Improve clarity by using lower case names consistently in the code. Register names will continue to use all upper case naming in the code. Update the SET_TMC_FIELD command to automatically convert field names to lower case. Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
* tmc2209: Set SENDDELAY=2 to avoid uart rx/tx errorsKevin O'Connor2021-07-231-0/+3
| | | | | | | | | | It looks like the tmc2209 chips have increased uart errors with the default SENDDELAY of zero. Increasing the SENDDELAY to two seems to work around this issue. Reported by @ReXT3D. Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
* tmc: Move SET_TMC_CURRENT command to TMCCommandHelper()Kevin O'Connor2021-02-271-2/+2
| | | | | | | Refactor the tmc driver implementations so that there is a single implementation of the SET_TMC_CURRENT command. Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
* tmc5160: diag0 support (#3159)Trevor Jones2020-08-091-2/+1
| | | | | Allow for diag0 only hardware to use sensorless homing. Signed-off-by: Trevor Jones <trevorjones141@gmail.com>
* extras: Use "from . import module" for relative importsKevin O'Connor2020-06-151-1/+1
| | | | | | Use alternate import syntax to improve Python3 compatibility. Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
* tmc2209: Add support for sensorless homingKevin O'Connor2019-08-191-1/+2
| | | | Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
* tmc_uart: Add support for configuring the uart address on tmc2209 chipsKevin O'Connor2019-07-311-1/+1
| | | | Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
* tmc: Configure "intpol" field from TMCMicrostepHelperKevin O'Connor2019-06-281-1/+0
| | | | Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
* tmc: Add support for virtual enable pinsKevin O'Connor2019-06-281-0/+2
| | | | | | | Add support for enabling the stepper via the communication channel. This improves support for boards with a shared enable line. Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
* tmc: Simplify internal DUMP_TMC interfaceKevin O'Connor2019-06-251-4/+1
| | | | | | | | Only the tmc2208 driver needs special read register translation logic. Rework the code so a default implementation is available for all the other drivers. Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
* tmc2209: Initial support for tmc2209 stepper driverStephan Oelze2019-06-231-0/+96
Signed-off-by: Stephan Oelze <stephan.oelze@gmail.com> Signed-off-by: Kevin O'Connor <kevin@koconnor.net>