mirror of
https://github.com/SoftFever/OrcaSlicer.git
synced 2025-07-07 23:17:35 -06:00
ENH: support force cooling for outer wall only
For PA-cf material, forcing cooling for all outer wall and using lower fan speed for infill and inner wall can get more high strength. Add this cooling strategy. When set overhang fan threshold to be 0%, then bridge and all outer wall will be force to cool with the overhang fan speed. Signed-off-by: salt.wei <salt.wei@bambulab.com> Change-Id: Ideed1ac8690f1eeb68aad760678db76bb4dae8ec
This commit is contained in:
parent
5aee1505a6
commit
47302b0cf9
6 changed files with 57 additions and 23 deletions
|
@ -15,13 +15,13 @@
|
||||||
"290"
|
"290"
|
||||||
],
|
],
|
||||||
"fan_max_speed": [
|
"fan_max_speed": [
|
||||||
"40"
|
"30"
|
||||||
],
|
],
|
||||||
"fan_min_speed": [
|
"fan_min_speed": [
|
||||||
"10"
|
"10"
|
||||||
],
|
],
|
||||||
"fan_cooling_layer_time": [
|
"fan_cooling_layer_time": [
|
||||||
"6"
|
"5"
|
||||||
],
|
],
|
||||||
"full_fan_speed_layer": [
|
"full_fan_speed_layer": [
|
||||||
"2"
|
"2"
|
||||||
|
|
|
@ -20,6 +20,12 @@
|
||||||
"nozzle_temperature_initial_layer": [
|
"nozzle_temperature_initial_layer": [
|
||||||
"280"
|
"280"
|
||||||
],
|
],
|
||||||
|
"overhang_fan_threshold": [
|
||||||
|
"0%"
|
||||||
|
],
|
||||||
|
"overhang_fan_speed": [
|
||||||
|
"40"
|
||||||
|
],
|
||||||
"filament_type": [
|
"filament_type": [
|
||||||
"PA-CF"
|
"PA-CF"
|
||||||
],
|
],
|
||||||
|
|
|
@ -19,23 +19,23 @@
|
||||||
"8"
|
"8"
|
||||||
],
|
],
|
||||||
"fan_max_speed": [
|
"fan_max_speed": [
|
||||||
"40"
|
"30"
|
||||||
],
|
],
|
||||||
"fan_min_speed": [
|
"fan_min_speed": [
|
||||||
"10"
|
"10"
|
||||||
],
|
],
|
||||||
"fan_cooling_layer_time": [
|
"fan_cooling_layer_time": [
|
||||||
"6"
|
"5"
|
||||||
],
|
],
|
||||||
"full_fan_speed_layer": [
|
"full_fan_speed_layer": [
|
||||||
"2"
|
"2"
|
||||||
],
|
],
|
||||||
"compatible_printers": [
|
"compatible_printers": [
|
||||||
"Bambu Lab X1 Carbon 0.4 nozzle",
|
"Bambu Lab X1 Carbon 0.4 nozzle",
|
||||||
"Bambu Lab X1 Carbon 0.6 nozzle",
|
"Bambu Lab X1 Carbon 0.6 nozzle",
|
||||||
"Bambu Lab X1 Carbon 0.8 nozzle",
|
"Bambu Lab X1 Carbon 0.8 nozzle",
|
||||||
"Bambu Lab X1 0.4 nozzle",
|
"Bambu Lab X1 0.4 nozzle",
|
||||||
"Bambu Lab X1 0.6 nozzle",
|
"Bambu Lab X1 0.6 nozzle",
|
||||||
"Bambu Lab X1 0.8 nozzle"
|
"Bambu Lab X1 0.8 nozzle"
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
|
|
|
@ -3674,11 +3674,21 @@ std::string GCode::_extrude(const ExtrusionPath &path, std::string description,
|
||||||
|
|
||||||
std::string comment;
|
std::string comment;
|
||||||
if (m_enable_cooling_markers) {
|
if (m_enable_cooling_markers) {
|
||||||
if (EXTRUDER_CONFIG(enable_overhang_bridge_fan) &&
|
if (EXTRUDER_CONFIG(enable_overhang_bridge_fan)) {
|
||||||
(path.get_overhang_degree() > EXTRUDER_CONFIG(overhang_fan_threshold) || is_bridge(path.role())))
|
//BBS: Overhang_threshold_none means Overhang_threshold_1_4 and forcing cooling for all external perimeter
|
||||||
gcode += ";_OVERHANG_FAN_START\n";
|
int overhang_threshold = EXTRUDER_CONFIG(overhang_fan_threshold) == Overhang_threshold_none ?
|
||||||
else
|
Overhang_threshold_none : EXTRUDER_CONFIG(overhang_fan_threshold) - 1;
|
||||||
|
if ((EXTRUDER_CONFIG(overhang_fan_threshold) == Overhang_threshold_none && path.role() == erExternalPerimeter) ||
|
||||||
|
path.get_overhang_degree() > overhang_threshold ||
|
||||||
|
is_bridge(path.role()))
|
||||||
|
gcode += ";_OVERHANG_FAN_START\n";
|
||||||
|
else
|
||||||
|
comment = ";_EXTRUDE_SET_SPEED";
|
||||||
|
}
|
||||||
|
else {
|
||||||
comment = ";_EXTRUDE_SET_SPEED";
|
comment = ";_EXTRUDE_SET_SPEED";
|
||||||
|
}
|
||||||
|
|
||||||
if (path.role() == erExternalPerimeter)
|
if (path.role() == erExternalPerimeter)
|
||||||
comment += ";_EXTERNAL_PERIMETER";
|
comment += ";_EXTERNAL_PERIMETER";
|
||||||
}
|
}
|
||||||
|
@ -3742,10 +3752,22 @@ std::string GCode::_extrude(const ExtrusionPath &path, std::string description,
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (m_enable_cooling_markers)
|
if (m_enable_cooling_markers) {
|
||||||
gcode += (EXTRUDER_CONFIG(enable_overhang_bridge_fan) &&
|
if (EXTRUDER_CONFIG(enable_overhang_bridge_fan)) {
|
||||||
(is_bridge(path.role()) || path.get_overhang_degree() > EXTRUDER_CONFIG(overhang_fan_threshold))) ?
|
//BBS: Overhang_threshold_none means Overhang_threshold_1_4 and forcing cooling for all external perimeter
|
||||||
";_OVERHANG_FAN_END\n" : ";_EXTRUDE_END\n";
|
int overhang_threshold = EXTRUDER_CONFIG(overhang_fan_threshold) == Overhang_threshold_none ?
|
||||||
|
Overhang_threshold_none : EXTRUDER_CONFIG(overhang_fan_threshold) - 1;
|
||||||
|
if ((EXTRUDER_CONFIG(overhang_fan_threshold) == Overhang_threshold_none && path.role() == erExternalPerimeter) ||
|
||||||
|
path.get_overhang_degree() > overhang_threshold ||
|
||||||
|
is_bridge(path.role()))
|
||||||
|
gcode += ";_OVERHANG_FAN_END\n";
|
||||||
|
else
|
||||||
|
gcode += ";_EXTRUDE_END\n";
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
gcode += ";_EXTRUDE_END\n";
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
this->set_last_pos(path.last_point());
|
this->set_last_pos(path.last_point());
|
||||||
return gcode;
|
return gcode;
|
||||||
|
|
|
@ -259,12 +259,14 @@ static const t_config_enum_values s_keys_map_ForwardCompatibilitySubstitutionRul
|
||||||
CONFIG_OPTION_ENUM_DEFINE_STATIC_MAPS(ForwardCompatibilitySubstitutionRule)
|
CONFIG_OPTION_ENUM_DEFINE_STATIC_MAPS(ForwardCompatibilitySubstitutionRule)
|
||||||
|
|
||||||
static const t_config_enum_values s_keys_map_OverhangFanThreshold = {
|
static const t_config_enum_values s_keys_map_OverhangFanThreshold = {
|
||||||
|
{ "0%", Overhang_threshold_none },
|
||||||
{ "5%", Overhang_threshold_1_4 },
|
{ "5%", Overhang_threshold_1_4 },
|
||||||
{ "25%", Overhang_threshold_2_4 },
|
{ "25%", Overhang_threshold_2_4 },
|
||||||
{ "50%", Overhang_threshold_3_4 },
|
{ "50%", Overhang_threshold_3_4 },
|
||||||
{ "75%", Overhang_threshold_4_4 },
|
{ "75%", Overhang_threshold_4_4 },
|
||||||
{ "95%", Overhang_threshold_bridge }
|
{ "95%", Overhang_threshold_bridge }
|
||||||
};
|
};
|
||||||
|
CONFIG_OPTION_ENUM_DEFINE_STATIC_MAPS(OverhangFanThreshold)
|
||||||
|
|
||||||
// BBS
|
// BBS
|
||||||
static const t_config_enum_values s_keys_map_BedType = {
|
static const t_config_enum_values s_keys_map_BedType = {
|
||||||
|
@ -628,15 +630,18 @@ void PrintConfigDef::init_fff_params()
|
||||||
def = this->add("overhang_fan_threshold", coEnums);
|
def = this->add("overhang_fan_threshold", coEnums);
|
||||||
def->label = L("Cooling overhang threshold");
|
def->label = L("Cooling overhang threshold");
|
||||||
def->tooltip = L("Force cooling fan to be specific speed when overhang degree of printed part exceeds this value. "
|
def->tooltip = L("Force cooling fan to be specific speed when overhang degree of printed part exceeds this value. "
|
||||||
"Expressed as percentage which indicides how much width of the line without support from lower layer");
|
"Expressed as percentage which indicides how much width of the line without support from lower layer. "
|
||||||
|
"0% means forcing cooling for all outer wall no matter how much overhang degree");
|
||||||
def->sidetext = L("");
|
def->sidetext = L("");
|
||||||
def->enum_keys_map = &s_keys_map_OverhangFanThreshold;
|
def->enum_keys_map = &ConfigOptionEnum<OverhangFanThreshold>::get_enum_values();
|
||||||
def->mode = comAdvanced;
|
def->mode = comAdvanced;
|
||||||
|
def->enum_values.emplace_back("0%");
|
||||||
def->enum_values.emplace_back("5%");
|
def->enum_values.emplace_back("5%");
|
||||||
def->enum_values.emplace_back("25%");
|
def->enum_values.emplace_back("25%");
|
||||||
def->enum_values.emplace_back("50%");
|
def->enum_values.emplace_back("50%");
|
||||||
def->enum_values.emplace_back("75%");
|
def->enum_values.emplace_back("75%");
|
||||||
def->enum_values.emplace_back("95%");
|
def->enum_values.emplace_back("95%");
|
||||||
|
def->enum_labels.emplace_back("0%");
|
||||||
def->enum_labels.emplace_back("10%");
|
def->enum_labels.emplace_back("10%");
|
||||||
def->enum_labels.emplace_back("25%");
|
def->enum_labels.emplace_back("25%");
|
||||||
def->enum_labels.emplace_back("50%");
|
def->enum_labels.emplace_back("50%");
|
||||||
|
|
|
@ -157,7 +157,8 @@ enum DraftShield {
|
||||||
|
|
||||||
// BBS
|
// BBS
|
||||||
enum OverhangFanThreshold {
|
enum OverhangFanThreshold {
|
||||||
Overhang_threshold_1_4 = 0,
|
Overhang_threshold_none = 0,
|
||||||
|
Overhang_threshold_1_4,
|
||||||
Overhang_threshold_2_4,
|
Overhang_threshold_2_4,
|
||||||
Overhang_threshold_3_4,
|
Overhang_threshold_3_4,
|
||||||
Overhang_threshold_4_4,
|
Overhang_threshold_4_4,
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue