A Post Processing Script for Slic3r based Slicers and Klipper Printers.
This 3D Printing Concept is Based on my personal approach and with a minimum of Delphi programming skills.
This Script is free and open source, created to prove the effectiveness of automatic nozzle temperature change during 3D printing in order to get the best Quality/Speed Optimization, but it is not intended to be a definitive solution as I believe that integrating this concept in slicers will be more effective.
Hoping to soon find this concept in current slicers, because I think this will be the future of 3D printing.
SB53 G-Code Flow/Temperature Controller V1.0 (3 Aug 2024)
The script operation consists of varying the temperature according to the average flow rate during printing time, then limit the speed in the G-Code to feat the recommended flow rate for the reached temperature.
Klipper_Estimator Script is required for time estimation using Klipper Look-Ahead kinematics, and must be in the same Folder with this Script (Included Klipper_Estimator.exe V 3.7.3).
The script can be used as a normal program by opening the SB53-Systems.exe file and opening a GCode manually, or by adding it as a post-processing script in the Slicer.
It is also recommended to add in the slicer Klipper_Estimator.exe path after this script to rewrite the new estimated time into the G-Code.
D:\SB53_G-Code_Flow_Temperature_Controller_V1.0\SB53-Systems.exe;
D:\SB53_G-Code_Flow_Temperature_Controller_V1.0\Klipper_Estimator.exe --config_file D:\SB53_G-Code_Flow_Temperature_Controller_V1.0\config.json post-process;
To have a best Speed/Quality Optemization, the Slicer Profil must be set for Max Speed and Max Flow Rate, the Nozzle temperature is not important because it will be reset in the script and the print speed will be regulated to the temperature.
Example below with my max 200mm/s Printer speed :
Note that :
- The script only reduces the speeds above the recommended speed, lower speeds will be kept as in the G-Code.
- Hotend PID cannot be changed when printing in Klipper, I recommend using PID values for a temperature between 70-90% of the maximum temperature.
- PA can be regulated in the script according to the temperature or not by unchecking the Adjust PA option befor generating the G-Code, and use the fixed PA from the Slicer or Klipper.
- Changing the PA during printing causes a delay in execution and forms bubbles in the walls, the Script is programed to change PA only in Sparse infill, Internal solid infill, Support and Internal Bridge.
- Changing the initial layer temperature is important, and cannot be done in different print start macro, this macro must be in the form below
PRINT_START (instructions) EXTRUDER_TEMP=XXX (...next instructions)OrPRINT_START EXTRUDER_TEMP=[nozzle_temperature_initial_layer] BED_TEMP=[bed_temperature_initial_layer_single]
PRINT_START BED_TEMP=[bed_temperature_initial_layer_single] EXTRUDER_TEMP=[nozzle_temperature_initial_layer]
- This Script does not accept G2 and G3 in G-Code.
- Time Estimation is based in Klipper Look-ahead kinematics (may not be compatible with Marlin or Others).
- Reading or generating large G-Code files with this Script can takes up to 2 minutes, depending in your CPU.
- Generated G-Code are 30% to 80% larger than the original one due to Temp and Speed adjustment (can be optimized).
- This Script is currently only available for Windows OS.
The script will open once you Print or Export the G-Code from the Slicer and ask the user whether the script will be applied or not.
If yes: the first execution, Klipper_Estimator script requires a file containing the maximum limits of the printer (config .json), can be obtained by specifying the IP address of the printer or by choosing a file locally. If the printer is not the same you must change this file, then click the PROCEED button again.
The Filament Type and these specific parameters are chosen automatically by the script if (PLA, PETG, ABS, TPU, ASA, HIPS), You need to set the appropriate values according to your extruder limits, then save the changes for next uses.
You need to refresh the view if you make changes in the the script before generating the G-Code, then Save and Close.
Below the Generated G-Code for 0.2mm Layer Height
Next the Generated G-Code for 0.3mm Layer Height
- Printers with higher accelerations and lower heating/cooling time will have a better result with this approach because it allows for better flow stabilization.
- The speed of the outer wall is always higher than the speed of the inner wall because of the deferent Line width.
- With a resonable Edeal Flow/Temperature calibration, the same good quality is achieved with the majority of filament brands, without any changes in the script.
Be responsible and careful with this Script by using reasonable values and monitoring the behavior of your printer.
I look forward to your feedback and remain available and open to new proposals.
Happy Smart 3D Printing :-)
By Salim BELAYEL.
Developed in June 2024 with Delphi 12 Community Edition.
Email : [email protected]
If you find my work worthy, Bay me a coffee. Thank you.