FIX: modify the max volumetric speed of default fliament
Signed-off-by: qing.zhang <qing.zhang@bambulab.com> Change-Id: I6c84b35d0b4a663a3f2fdd96ce2fa5a7dd3208b7
This commit is contained in:
parent
9e89a1e10e
commit
9c32cff1dd
|
@ -1075,11 +1075,12 @@ void PrintConfigDef::init_fff_params()
|
|||
def->label = L("Max volumetric speed");
|
||||
def->tooltip = L("This setting stands for how much volume of filament can be melted and extruded per second. "
|
||||
"Printing speed is limited by max volumetric speed, in case of too high and unreasonable speed setting. "
|
||||
"Zero means no limit");
|
||||
"Can't be zero");
|
||||
def->sidetext = L("mm³/s");
|
||||
def->min = 0;
|
||||
def->max = 50;
|
||||
def->mode = comAdvanced;
|
||||
def->set_default_value(new ConfigOptionFloats { 0. });
|
||||
def->set_default_value(new ConfigOptionFloats { 2. });
|
||||
|
||||
def = this->add("filament_minimal_purge_on_wipe_tower", coFloats);
|
||||
def->label = L("Minimal purge on wipe tower");
|
||||
|
|
|
@ -141,6 +141,26 @@ void ConfigManipulation::check_bed_temperature_difference(int bed_type, DynamicP
|
|||
}
|
||||
}
|
||||
|
||||
void ConfigManipulation::check_filament_max_volumetric_speed(DynamicPrintConfig *config)
|
||||
{
|
||||
//if (is_msg_dlg_already_exist) return;
|
||||
//float max_volumetric_speed = config->opt_float("filament_max_volumetric_speed");
|
||||
|
||||
float max_volumetric_speed = config->has("filament_max_volumetric_speed") ? config->opt_float("filament_max_volumetric_speed", (float) 0.5) : 0.5;
|
||||
// BBS: limite the min max_volumetric_speed
|
||||
if (max_volumetric_speed < 0.5) {
|
||||
const wxString msg_text = _(L("Too small max volumetric speed.\nReset to 0.5"));
|
||||
MessageDialog dialog(nullptr, msg_text, "", wxICON_WARNING | wxOK);
|
||||
DynamicPrintConfig new_conf = *config;
|
||||
is_msg_dlg_already_exist = true;
|
||||
dialog.ShowModal();
|
||||
new_conf.set_key_value("filament_max_volumetric_speed", new ConfigOptionFloats({0.5}));
|
||||
apply(config, &new_conf);
|
||||
is_msg_dlg_already_exist = false;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
void ConfigManipulation::update_print_fff_config(DynamicPrintConfig* config, const bool is_global_config)
|
||||
{
|
||||
// #ys_FIXME_to_delete
|
||||
|
|
|
@ -76,6 +76,7 @@ public:
|
|||
void check_nozzle_temperature_range(DynamicPrintConfig* config);
|
||||
void check_nozzle_temperature_initial_layer_range(DynamicPrintConfig* config);
|
||||
void check_bed_temperature_difference(int bed_type, DynamicPrintConfig* config);
|
||||
void check_filament_max_volumetric_speed(DynamicPrintConfig *config);
|
||||
|
||||
// SLA print
|
||||
void update_print_sla_config(DynamicPrintConfig* config, const bool is_global_config = false);
|
||||
|
|
|
@ -2646,6 +2646,8 @@ void TabFilament::update()
|
|||
if (m_preset_bundle->printers.get_selected_preset().printer_technology() == ptSLA)
|
||||
return; // ys_FIXME
|
||||
|
||||
m_config_manipulation.check_filament_max_volumetric_speed(m_config);
|
||||
|
||||
m_update_cnt++;
|
||||
|
||||
update_description_lines();
|
||||
|
|
Loading…
Reference in New Issue