Fix of the wipe tower priming towers. The priming towers were printed

at the homing height on the MK2MM printer, not at the 1st layer height.
This commit is contained in:
bubnikv 2017-12-13 15:35:00 +01:00
parent 38ecfa8467
commit 08b74f8caf

View file

@ -501,7 +501,6 @@ void GCode::_do_export(Print &print, FILE *file)
fprintf(file, "\n");
}
// Write some terse information on the slicing parameters.
{
const PrintObject *first_object = print.objects.front();
const double layer_height = first_object->config.layer_height.value;
const double first_layer_height = first_object->config.first_layer_height.get_abs_value(layer_height);
@ -518,7 +517,6 @@ void GCode::_do_export(Print &print, FILE *file)
fprintf(file, "; first layer extrusion width = %.2fmm\n", region->flow(frPerimeter, first_layer_height, false, true, -1., *first_object).width);
fprintf(file, "\n");
}
}
// Prepare the helper object for replacing placeholders in custom G-code and output filename.
m_placeholder_parser = print.placeholder_parser;
@ -718,6 +716,7 @@ void GCode::_do_export(Print &print, FILE *file)
// Prusa Multi-Material wipe tower.
if (has_wipe_tower && ! layers_to_print.empty()) {
m_wipe_tower.reset(new WipeTowerIntegration(print.config, *print.m_wipe_tower_priming.get(), print.m_wipe_tower_tool_changes, *print.m_wipe_tower_final_purge.get()));
write(file, m_writer.travel_to_z(first_layer_height + m_config.z_offset.value, "Move to the first layer height"));
write(file, m_wipe_tower->prime(*this));
// Verify, whether the print overaps the priming extrusions.
BoundingBoxf bbox_print(get_print_extrusions_extents(print));