From cd793384a47b987b0e3e1a2ea272b6a0d3ccb9aa Mon Sep 17 00:00:00 2001 From: Rogerio Goncalves Date: Sun, 22 Dec 2024 22:34:21 -0300 Subject: [PATCH] docs: references to tmc2160 (#496) --- docs/Config_Reference.md | 24 ++++++++++++------------ docs/Features.md | 4 ++-- docs/TMC_Drivers.md | 14 +++++++------- klippy/extras/tmc5160.py | 2 +- 4 files changed, 22 insertions(+), 22 deletions(-) diff --git a/docs/Config_Reference.md b/docs/Config_Reference.md index 29bfa8e15..144487a45 100644 --- a/docs/Config_Reference.md +++ b/docs/Config_Reference.md @@ -4386,17 +4386,17 @@ run_current: ### [tmc5160] -Configure a TMC5160 stepper motor driver via SPI bus. To use this -feature, define a config section with a "tmc5160" prefix followed by -the name of the corresponding stepper config section (for example, -"[tmc5160 stepper_x]"). +Configure a TMC5160 or TMC2160 stepper motor driver via SPI bus. +To use this feature, define a config section with a "tmc5160" prefix +followed by the name of the corresponding stepper config section +(for example, "[tmc5160 stepper_x]"). ``` [tmc5160 stepper_x] cs_pin: -# The pin corresponding to the TMC5160 chip select line. This pin -# will be set to low at the start of SPI messages and raised to high -# after the message completes. This parameter must be provided. +# The pin corresponding to the TMC5160 or TMC2160 chip select line. +# This pin will be set to low at the start of SPI messages and raised +# to high after the message completes. This parameter must be provided. #spi_speed: #spi_bus: #spi_software_sclk_pin: @@ -4504,8 +4504,8 @@ sense_resistor: #driver_BBMCLKS: 4 #driver_BBMTIME: 0 #driver_FILT_ISENSE: 0 -# Set the given register during the configuration of the TMC5160 -# chip. This may be used to set custom motor parameters. The +# Set the given register during the configuration of the TMC5160 or +# TMC2160 chip. This may be used to set custom motor parameters. The # defaults for each parameter are next to the parameter name in the # above list. #⚠️driver_s2vs_level: 6 # Short to Supply tolerance, from 4 to 15 @@ -4516,9 +4516,9 @@ sense_resistor: #diag0_pin: #diag1_pin: # The micro-controller pin attached to one of the DIAG lines of the -# TMC5160 chip. Only a single diag pin should be specified. The pin -# is "active low" and is thus normally prefaced with "^!". Setting -# this creates a "tmc5160_stepper_x:virtual_endstop" virtual pin +# TMC5160 or TMC2160 chip. Only a single diag pin should be specified. +# The pin is "active low" and is thus normally prefaced with "^!". +# Setting this creates a "tmc5160_stepper_x:virtual_endstop" virtual pin # which may be used as the stepper's endstop_pin. Doing this enables # "sensorless homing". (Be sure to also set driver_SGT to an # appropriate sensitivity value.) The default is to not enable diff --git a/docs/Features.md b/docs/Features.md index a656a80c4..03a527e31 100644 --- a/docs/Features.md +++ b/docs/Features.md @@ -131,8 +131,8 @@ Kalico supports many standard 3d printer features: speed can be monitored on fans that have a tachometer. * Support for run-time configuration of TMC2130, TMC2208/TMC2224, - TMC2209, TMC2240, TMC2660, and TMC5160 stepper motor drivers. There - is also support for current control of traditional stepper drivers + TMC2209, TMC2240, TMC2660, TMC5160 and TMC2160 stepper motor drivers. + There is also support for current control of traditional stepper drivers via AD5206, DAC084S085, MCP4451, MCP4728, MCP4018, and PWM pins. * Support for common LCD displays attached directly to the printer. A diff --git a/docs/TMC_Drivers.md b/docs/TMC_Drivers.md index 00829f7d7..50515f8c1 100644 --- a/docs/TMC_Drivers.md +++ b/docs/TMC_Drivers.md @@ -156,7 +156,7 @@ also find more details on limitations of this setup. A few prerequisites are needed to use sensorless homing: 1. A stallGuard capable TMC stepper driver (tmc2130, tmc2209, tmc2660, - or tmc5160). + tmc5160 or tmc2160). 2. SPI / UART interface of the TMC driver wired to micro-controller (stand-alone mode does not work). 3. The appropriate "DIAG" or "SG_TST" pin of TMC driver connected to @@ -231,7 +231,7 @@ home_current: 1 [stepper_x] endstop_pin: tmc2130_stepper_x:virtual_endstop -homing_retract_dist: 10 +homing_retract_dist: 10 ... ``` @@ -261,7 +261,7 @@ command to set the highest sensitivity. For tmc2209: ``` SET_TMC_FIELD STEPPER=stepper_x FIELD=SGTHRS VALUE=255 ``` -For tmc2130, tmc5160, and tmc2660: +For tmc2130, tmc5160, tmc2160, and tmc2660: ``` SET_TMC_FIELD STEPPER=stepper_x FIELD=sgt VALUE=-64 ``` @@ -345,7 +345,7 @@ necessary to run the tuning process again. #### Using Macros when Homing Unlike Klipper, in Kalico, you do not need macros for -sensorless homing management. Homing current is handled by the TMC block, +sensorless homing management. Homing current is handled by the TMC block, homing retract distance is used to define a minimum homing distance (which can also be manually configured) which is used for sensorless homing verification as well as post home retract. In depth guide @@ -459,8 +459,8 @@ wiring or an incorrect Kalico configuration of the UART pin settings. ### I keep getting "Unable to write tmc spi 'stepper_x' register ..." errors? -This occurs when Kalico is unable to communicate with a tmc2130 or -tmc5160 driver. +This occurs when Kalico is unable to communicate with a tmc2130, tmc5160 or +tmc2160 driver. Make sure that the motor power is enabled, as the stepper motor driver generally needs motor power before it can communicate with the @@ -492,7 +492,7 @@ state. It's also possible that a **TMC reports error** shutdown occurs due to SPI errors that prevent communication with the driver (on tmc2130, -tmc5160, or tmc2660). If this occurs, it's common for the reported +tmc5160, tmc2160, or tmc2660). If this occurs, it's common for the reported driver status to show `00000000` or `ffffffff` - for example: `TMC reports error: DRV_STATUS: ffffffff ...` OR `TMC reports error: READRSP@RDSEL2: 00000000 ...`. Such a failure may be due to an SPI diff --git a/klippy/extras/tmc5160.py b/klippy/extras/tmc5160.py index 78bca1cf2..7e114109d 100644 --- a/klippy/extras/tmc5160.py +++ b/klippy/extras/tmc5160.py @@ -1,4 +1,4 @@ -# TMC5160 configuration +# TMC5160/TMC2160 configuration # # Copyright (C) 2018-2019 Kevin O'Connor #