aboutsummaryrefslogtreecommitdiffstats
path: root/klippy/extras
diff options
context:
space:
mode:
authorKevin O'Connor <kevin@koconnor.net>2018-03-12 18:48:44 -0400
committerKevin O'Connor <kevin@koconnor.net>2018-03-17 13:47:31 -0400
commit1dda4628a019b6f2f96ef3873dd6985b472074e5 (patch)
tree3b104b8f2d16b4897304b4ca2e8a860663ba70cf /klippy/extras
parent36612fd5441b60f9979c0ee966667ede9b779a1d (diff)
downloadkutter-1dda4628a019b6f2f96ef3873dd6985b472074e5.tar.gz
kutter-1dda4628a019b6f2f96ef3873dd6985b472074e5.tar.xz
kutter-1dda4628a019b6f2f96ef3873dd6985b472074e5.zip
bed_tilt: Require at least 3 probing points for bed_tilt_calibrate
Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
Diffstat (limited to 'klippy/extras')
-rw-r--r--klippy/extras/bed_tilt.py2
1 files changed, 2 insertions, 0 deletions
diff --git a/klippy/extras/bed_tilt.py b/klippy/extras/bed_tilt.py
index a6254a29..c8a577a3 100644
--- a/klippy/extras/bed_tilt.py
+++ b/klippy/extras/bed_tilt.py
@@ -39,6 +39,8 @@ class BedTiltCalibrate:
for p in points]
except:
raise config.error("Unable to parse bed tilt points")
+ if len(self.points) < 3:
+ raise config.error("Need at least 3 points for bed_tilt_calibrate")
self.speed = config.getfloat('speed', 50., above=0.)
self.horizontal_move_z = config.getfloat('horizontal_move_z', 5.)
self.probe_z_offset = config.getfloat('probe_z_offset', 0.)