diff --git a/MatterControl.Printing/Settings/PrinterSettings.cs b/MatterControl.Printing/Settings/PrinterSettings.cs index 79d70a4bc..bf0352c70 100644 --- a/MatterControl.Printing/Settings/PrinterSettings.cs +++ b/MatterControl.Printing/Settings/PrinterSettings.cs @@ -138,8 +138,9 @@ namespace MatterHackers.MatterControl.SlicerConfiguration SettingsKey.has_z_probe, SettingsKey.has_z_servo, SettingsKey.has_conductive_nozzle, + SettingsKey.conductive_probe_min_z, SettingsKey.measure_probe_offset_conductively, - SettingsKey.conductive_pad_position, + SettingsKey.conductive_pad_center, SettingsKey.heat_extruder_before_homing, SettingsKey.inactive_cool_down, SettingsKey.include_firmware_updater, diff --git a/MatterControl.Printing/Settings/SettingsKey.cs b/MatterControl.Printing/Settings/SettingsKey.cs index 7a56514e0..9c38b7592 100644 --- a/MatterControl.Printing/Settings/SettingsKey.cs +++ b/MatterControl.Printing/Settings/SettingsKey.cs @@ -124,8 +124,9 @@ namespace MatterHackers.MatterControl.SlicerConfiguration public const string has_z_probe = nameof(has_z_probe); public const string has_z_servo = nameof(has_z_servo); public const string has_conductive_nozzle = nameof(has_conductive_nozzle); + public const string conductive_probe_min_z = nameof(conductive_probe_min_z); public const string measure_probe_offset_conductively = nameof(measure_probe_offset_conductively); - public const string conductive_pad_position = nameof(conductive_pad_position); + public const string conductive_pad_center = nameof(conductive_pad_center); public const string heat_extruder_before_homing = nameof(heat_extruder_before_homing); public const string inactive_cool_down = nameof(inactive_cool_down); public const string include_firmware_updater = nameof(include_firmware_updater); diff --git a/MatterControl.Printing/Settings/SliceSettingsFields.cs b/MatterControl.Printing/Settings/SliceSettingsFields.cs index 8c931d1a4..73d10e723 100644 --- a/MatterControl.Printing/Settings/SliceSettingsFields.cs +++ b/MatterControl.Printing/Settings/SliceSettingsFields.cs @@ -925,14 +925,24 @@ namespace MatterHackers.MatterControl.SlicerConfiguration }, new SliceSettingData() { - SlicerConfigName = SettingsKey.conductive_pad_position, - PresentationName = "Conductive Pad Position".Localize(), - HelpText = "The position of the conductive pad used for nozzle probing.".Localize(), + SlicerConfigName = SettingsKey.conductive_pad_center, + PresentationName = "Conductive Pad Center".Localize(), + HelpText = "The center of the conductive pad used for nozzle probing.".Localize(), DataEditType = DataEditTypes.VECTOR2, ShowAsOverride = true, DefaultValue = "0,0", ShowIfSet = "!has_hardware_leveling&has_z_probe&has_conductive_nozzle&measure_probe_offset_conductively", - UiUpdate = UiUpdateRequired.SliceSettings, + RebuildGCodeOnChange = false + }, + new SliceSettingData() + { + SlicerConfigName = SettingsKey.conductive_probe_min_z, + PresentationName = "Conductive Probe Min Z".Localize(), + HelpText = "The minimum z to allow the probe to go to before the test is stopped and marked as failing. This is used to ensure the printer is not damaged.".Localize(), + DataEditType = DataEditTypes.DOUBLE, + ShowAsOverride = true, + DefaultValue = "-1", + ShowIfSet = "!has_hardware_leveling&has_z_probe&has_conductive_nozzle&measure_probe_offset_conductively", RebuildGCodeOnChange = false }, new SliceSettingData() diff --git a/MatterControl.Printing/Settings/SliceSettingsLayouts.cs b/MatterControl.Printing/Settings/SliceSettingsLayouts.cs index 2a6c5e25d..42e302ed7 100644 --- a/MatterControl.Printing/Settings/SliceSettingsLayouts.cs +++ b/MatterControl.Printing/Settings/SliceSettingsLayouts.cs @@ -310,7 +310,8 @@ namespace MatterHackers.MatterControl.SlicerConfiguration SettingsKey.z_servo_depolyed_angle, SettingsKey.z_servo_retracted_angle, SettingsKey.measure_probe_offset_conductively, - SettingsKey.conductive_pad_position, + SettingsKey.conductive_pad_center, + SettingsKey.conductive_probe_min_z, }), ("Behavior", new[] { diff --git a/MatterControlLib/ConfigurationPage/PrintLeveling/LevelingPlan.cs b/MatterControlLib/ConfigurationPage/PrintLeveling/LevelingPlan.cs index 5048d58b7..b06c31401 100644 --- a/MatterControlLib/ConfigurationPage/PrintLeveling/LevelingPlan.cs +++ b/MatterControlLib/ConfigurationPage/PrintLeveling/LevelingPlan.cs @@ -55,7 +55,7 @@ namespace MatterHackers.MatterControl.ConfigurationPage.PrintLeveling if (printer.Settings.GetValue(SettingsKey.has_conductive_nozzle) && printer.Settings.GetValue(SettingsKey.measure_probe_offset_conductively)) { - return printer.Settings.GetValue(SettingsKey.conductive_pad_position); + return printer.Settings.GetValue(SettingsKey.conductive_pad_center); } return printer.Settings.GetValue(SettingsKey.print_center); diff --git a/MatterControlLib/ConfigurationPage/PrintLeveling/WizardPages/ConductiveProbeFeedback.cs b/MatterControlLib/ConfigurationPage/PrintLeveling/WizardPages/ConductiveProbeFeedback.cs index acba2c1f4..0801c17a2 100644 --- a/MatterControlLib/ConfigurationPage/PrintLeveling/WizardPages/ConductiveProbeFeedback.cs +++ b/MatterControlLib/ConfigurationPage/PrintLeveling/WizardPages/ConductiveProbeFeedback.cs @@ -104,7 +104,7 @@ namespace MatterHackers.MatterControl.ConfigurationPage.PrintLeveling case State.WaitingForEndstopStatusOk: // found the ok of the M119 command // move down more - if (nozzleCurrentPosition.Z < -2) + if (printer.Connection.CurrentDestination.Z < printer.Settings.GetValue(SettingsKey.conductive_probe_min_z)) { // we have gone down too far // abort with error diff --git a/Submodules/agg-sharp b/Submodules/agg-sharp index 2c3522274..5f2b43aa8 160000 --- a/Submodules/agg-sharp +++ b/Submodules/agg-sharp @@ -1 +1 @@ -Subproject commit 2c35222744ad55c281c24f6c98c4515cff43f577 +Subproject commit 5f2b43aa87d2edb0b3b13617d52706597cbbda17