aboutsummaryrefslogtreecommitdiffstats
path: root/klippy/extras/z_tilt.py
Commit message (Collapse)AuthorAgeFilesLines
* toolhead: Rename _full_flush() to flush_step_generation() and use globallyKevin O'Connor2019-11-211-0/+4
| | | | | | | Update code that modifies the low-level kinematics handlers to first call toolhead.flush_step_generation(). Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
* mcu: Remove set_ignore_move()Kevin O'Connor2019-11-061-4/+4
| | | | | | | Update callers of set_ignore_move() to use the trapq system to set a stepper to ignore moves. Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
* z-tilt: Unresolved symbol fixedPetri Honkala2019-09-241-1/+2
| | | | Signed-off-by: Petri Honkala <cruwaller@gmail.com>
* z_tilt: Support retriesfess2019-06-181-0/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Support retrying Z_TILT_ADJUST a configurable number of times to a configurable tolerance both in the config or as parameters. - By default keeps original behavior of no retries. - Adds parameters RETRIES and RETRY_TOLERANCE to QUAD_GANTRY_LEVEL gcode. - adds config options retries and retry_tolerance to uad_gantry_level] - issues an error if we are getting worse intead of approaching tolerance - issues an error if retries were requested but we did not reach the tolerance in the specified number of retries the minimum change should be a single z step for those probing 2 points for 2 stepper motors and 3 for 3 stepper motors. at one point it was suggested to use the amount of z adjustment instead of the range of the probed points as a trigger for retry. I've chosen not to do this. using z adustment in these cases means the minimum unit of change is related to the angle created by the probed points and the distance to stepper motor and can be more than a couple steps which is rather unintuitive. for the case when someone is using more probed points than z steppers the probed points range will have some fixed minimum value that can't be reduced which is also unintuitive but that case should idealy be the rarer case, and the user can learn to set a higher tolerance that matches their probing setup. Signed-off-by: John "Fess" Fessenden <fess@fess.org>
* z_tilt: Add RetryHelperfess2019-06-181-0/+44
| | | | | | | add RetryHelper class in prep for implementing retries for both z_tilt and quad_gantry_level Signed-off-by: John "Fess" Fessenden <fess@fess.org>
* z_tilt: Separate z adjustment code to new ZAdjustHelper classKevin O'Connor2019-06-171-56/+63
| | | | | | Introduce a new class to perform the low-level Z stepper adjustments. Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
* z_tilt: minimum points 2fess2019-05-211-1/+1
| | | | | | | | | | | | "The z_tilt_adjust was coded to require 3 points because the original intent was for railcore-xl and voron. Since then, a number of users have started using z_tilt_adjust for prusa i3 style printers with dual z steppers. That's fine, but we just haven't gotten around to removing the superfluous check in the code." -- Kevin O'Connor remove that check. Signed-off-by: John "Fess" Fessenden <fess@fess.org>
* probe: ProbePointsHelper adjustable minimum pointsfess2019-05-211-0/+1
| | | | | | | | Factor out minimum required points check for ProbePointsHelper in prep for setting different values for quad_gantry_level and z_tilt_adjust Signed-off-by: John "Fess" Fessenden <fess@fess.org>
* z_tilt: bugfix for final correction of z-offsetArne Jansen2019-03-101-1/+1
| | | | | | | | | | The z_adjust offset provided to adjust_steppers is calculated given the steppers adjust exactly according to the given x_adjust/y_adjust. As the algorithm eliminates an offset that is common to all steppers, this offset must be taken into account in the final correction. Signed-off-by: Arne Jansen <arne@die-jansens.de> Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
* gcode: Change respond_info() to log by defaultKevin O'Connor2019-03-041-1/+0
| | | | | | | It makes sense to log most respond_info() content, so do that by default. Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
* klippy: Convert printer_state("connect") to an event handlerKevin O'Connor2019-01-081-3/+2
| | | | | | | Convert all users of the printer_state("connect") handler to register a "klippy:connect" event handler instead. Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
* z_tilt: unresolved reference fixedPetri Honkala2019-01-081-1/+1
| | | | Signed-off-by: Petri Honkala <cruwaller@gmail.com>
* z_tilt: Wrap lines to 80 columnsKevin O'Connor2018-10-011-1/+2
| | | | Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
* z_tilt: Take into account probe xy offset when calculating z_adjustKevin O'Connor2018-10-011-7/+13
| | | | Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
* probe: Support manual probing at runtimeKevin O'Connor2018-10-011-1/+1
| | | | | | | | Don't require the config file to specify manual probing. Instead, allow the user to select manual probing on each ProbePointsHelper invocation. Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
* probe: Implement ProbePointsHelper get_probed_position() locallyKevin O'Connor2018-10-011-5/+2
| | | | | | | | Now that all users of ProbePointsHelper use the same get_probed_position() code, it is possible to implement that locally within the ProbePointsHelper class. Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
* bed_mesh: move probe x and y offsets to the [probe] moduleArksine2018-08-191-1/+2
| | | | | | All probe offsets are now passed to the finalize() callback in the ProbePointsHelper Class. Signed-off-by: Eric Callahan <arksine.code@gmail.com>
* kinematics: Convert get_rails() method to get_steppers()Kevin O'Connor2018-07-161-6/+3
| | | | | | | All callers of get_rails() actually just want the steppers, so return them directly. Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
* z_tilt: Don't default "points" parameter to "z_positions" parameterKevin O'Connor2018-07-151-2/+1
| | | | | | | | It's rare to have all the Z stepper locations directly under the printable surface, so using z_positions for points is not a good default. Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
* probe: Rename get_position() callback to get_probed_position()Kevin O'Connor2018-06-221-1/+1
| | | | | | | The different uses of get_position() can be confusing, so choose a different name for the ProbePointsHelper callback. Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
* delta: Rename get_position() to calc_position()Kevin O'Connor2018-06-221-1/+1
| | | | | | | | Calculating the cartesian position from the stepper positions can be complex and cpu intensive, so rename it to calc_position() to be more descriptive. Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
* stepper: Replace PrinterHomingStepper with PrinterRailKevin O'Connor2018-06-221-2/+1
| | | | | | | | Update the code to use the term "rail" when dealing with a motor controlled "axis". A rail has a series of steppers and endstops that control that motor controlled "axis". Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
* stepper: Don't peak into PrinterStepper membersKevin O'Connor2018-06-221-4/+4
| | | | | | | Add additional wrapper functions so that no outside callers need to peak into the member variables of PrinterStepper. Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
* stepper: Add a get_name() method to PrinterStepperKevin O'Connor2018-06-221-1/+1
| | | | Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
* z_tilt: Add support for Z_TILT_ADJUSTKevin O'Connor2018-05-221-0/+109
Add new module to support independent adjustments to multiple Z steppers to account for bed tilt. Signed-off-by: Kevin O'Connor <kevin@koconnor.net>