Merge pull request #4983 from larsbrubaker/master

Make the minimum conductive probe height a variable
This commit is contained in:
Lars Brubaker 2021-02-16 08:13:44 -08:00 committed by GitHub
commit 02cf64df32
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
7 changed files with 23 additions and 10 deletions

View file

@ -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,

View file

@ -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);

View file

@ -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()

View file

@ -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[]
{

View file

@ -55,7 +55,7 @@ namespace MatterHackers.MatterControl.ConfigurationPage.PrintLeveling
if (printer.Settings.GetValue<bool>(SettingsKey.has_conductive_nozzle)
&& printer.Settings.GetValue<bool>(SettingsKey.measure_probe_offset_conductively))
{
return printer.Settings.GetValue<Vector2>(SettingsKey.conductive_pad_position);
return printer.Settings.GetValue<Vector2>(SettingsKey.conductive_pad_center);
}
return printer.Settings.GetValue<Vector2>(SettingsKey.print_center);

View file

@ -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<double>(SettingsKey.conductive_probe_min_z))
{
// we have gone down too far
// abort with error

@ -1 +1 @@
Subproject commit 2c35222744ad55c281c24f6c98c4515cff43f577
Subproject commit 5f2b43aa87d2edb0b3b13617d52706597cbbda17