bruce356
Posts: 7
Joined: Tue Feb 09, 2016 7:29 pm

Layer Change Script Tab

Hi, I want to print the first layer at a specific extrusion rate (in my case 80%) and the remainder of the print at 100%.
How would I do this without creating multiple processes, it is such a simple thing to do with other slicers and should not require creating 2 processes.
regards - bruce
CompoundCarl
Posts: 2005
Joined: Wed Aug 05, 2015 7:23 am

Re: Layer Change Script Tab

There's a lot of different ways to do this. If you're using a printer that speaks normal gcode, you can just use the real-time extrusion override knobs in the Machine Control Panel to adjust the extrusion rate as it's printing. I like doing that since I can actually adjust it in real-time (for example, extrude a bit more if it's having trouble sticking).

You can also use the global z-axis offset to move the nozzle higher above the bed for the first layer. That will have the same affect as lowering the extrusion amount for this layer.

Typically, people want MORE plastic extruded on the first layer, but there's a few ways you could do it if you really want less plastic for some reason
bruce356
Posts: 7
Joined: Tue Feb 09, 2016 7:29 pm

Re: Layer Change Script Tab

CompoundCarl wrote:There's a lot of different ways to do this. If you're using a printer that speaks normal gcode, you can just use the real-time extrusion override knobs in the Machine Control Panel to adjust the extrusion rate as it's printing. I like doing that since I can actually adjust it in real-time (for example, extrude a bit more if it's having trouble sticking).

You can also use the global z-axis offset to move the nozzle higher above the bed for the first layer. That will have the same affect as lowering the extrusion amount for this layer.

Typically, people want MORE plastic extruded on the first layer, but there's a few ways you could do it if you really want less plastic for some reason

Hi CompoundCarl, thanks for the reply, yes I can stand by my printer and make adjustments manually on the GLCD (Marlin Firmware on Rambo Board) as layer changes but that is for me a waste of my time if it can be done automatically in the G-code (without having to manually edit the G-code). I have tried using scripts in "commands for post processing" under the scripts tab but have not been very successful as I am not a coder, this simple instruction should not be so hard to incorporate.

Yes I could raise Z but I want to use my existing calibrated first layer Z height.

Could you please explain “there’s a few ways you could do it" much appreciated.

Thanks again and regards - bruce
CompoundCarl
Posts: 2005
Joined: Wed Aug 05, 2015 7:23 am

Re: Layer Change Script Tab

Well the reality is that you're trying to do something quite odd. You're wanting to extrude LESS material on the first layer, which is opposite of what most people do. So I'm not surprised there isn't an option for that.

Perhaps you should first explain WHY you want to extrude LESS plastic on the first layer. Perhaps the real issue is somewhere else...
bruce356
Posts: 7
Joined: Tue Feb 09, 2016 7:29 pm

Re: Layer Change Script Tab

Hi, I do not think it is odd, Kisslicer has no problem in handling such a simple requirement,
Kisslicer start G-code:-
; *** G-code Prefix ***
G90 ; absolute mode
M190 S70 ; Warm up Bed and wait till it's warm
G28 ; Home
G29 ; Auto Bed Levelling
M204 S1000 ; Set Default acceleration
M221 S80 ; First Layer Filament feed reduced to 80%
; *** Main G-code ***
G92 E0
; BEGIN_LAYER_OBJECT z=0.23
M109 S206 ; Stops printing and waits to reach temperature.
; M104 S206 ; Continues printing while new set temp is reached.
G92 E0

G1 X128.5 Y165.55 Z0.525 E0 F12000
G1 X128.5 Y165.55 Z0.225 E0 F6000

Now S3D start G-Code:-
G90
M190 S60
M104 S207 T0
M109 S207 T0
G28 ; home all axes
G29 ; Check bed level
M204 S1000 ; Set Default acceleration
M221 S80 ; First Layer Filament feed rate reduced to 80%
G92 E0
G1 E-0.8000 F1800
G1 Z0.450 F1800
M117 Layer 1, Z=0.2
M221 S100 ; Reset Filament Feed Rate to 100% for rest of print.
T0
G92 E0

G1 X93.015 Y136.304 E0.0089 F1500
G1 X131.985 Y136.304 E1.3855

In both slicer examples M221 S** is placed into the "Starting Script" and "Layer Change Script", only S3D cancels out the "Starting Script" entry with M221 S80 with the "Layer Change Script" entry M221 S100 before layer 1 printing starts. So I end up with 100% feed rate on layer 1 and all subsequent layers.

Kisslicer correctly places the M221 S100 instruction just before the start of layer 2. This gives me an 80% feed rate on layer 1 and 100% feed rate from layer 2 onwards.
CompoundCarl
Posts: 2005
Joined: Wed Aug 05, 2015 7:23 am

Re: Layer Change Script Tab

You can do the same thing in S3D using their replace commands. In the "commands for post processing" section, you just put a line like this:
{REPLACE "; layer 2, Z = 0.4" "M221 S100\n; layer 2, Z = 0.4"}

You just need to double check what the Z-height is at layer 2 and edit that line accordingly (I had a first layer height of 100%, so mine was really easy)
Fred B
Posts: 30
Joined: Thu Jan 22, 2015 7:07 pm

Re: Layer Change Script Tab

Will Simplify save default printer settings that include two processes?

If you could save the processes and have them default each time it would be more useful. This gives you control over a lot more than just the extrusion without the time spent to create a new process.
bruce356
Posts: 7
Joined: Tue Feb 09, 2016 7:29 pm

Re: Layer Change Script Tab

Thanks CompoundCarl for the reply, yes that works on its own, but I already have :-
{REPLACE "; layer" "M117 Layer"}
{REPLACE " Z = " " Z="}
in post processing to show layers on my GLCD, (copied from the forum).

When I add your script I get the following (just an excerpt) :-
; G-Code generated by Simplify3D(R) Version 3.0.2
; Feb 13, 2016 at 6:46:22 PM
; Settings Summary
; processName,Process1
; createMB5G,0
; postProcessing,{REPLACE "M221 S100
M117 Layer 2, Z=0.4" "M221 S100\nM221 S100
M117 Layer 2, Z=0.4"},,{REPLACE "M117 Layer" "M117 Layer"} ,{REPLACE " Z=" " Z="}
; defaultSpeed,4800

I would have expected a semicolon in front of the M117**** so high up (at begining) in the G-Code.
Does it not matter or is there a way around.
Regards - bruce
bruce356
Posts: 7
Joined: Tue Feb 09, 2016 7:29 pm

Re: Layer Change Script Tab

Hi Fred B, thanks for your imput, I was trying to avoid that because if I understand it correctly I then have to nominate a layer height for each process.

Process 1 would be constant (one layer only) but process 2 the number of layers would vary with each printing job.

Or am I looking at this in the wrong way?

regards - bruce
dsiegfried
Posts: 26
Joined: Sun Oct 15, 2017 10:50 pm

Re: Layer Change Script Tab

You guys are making this way more complicated than you need to.
On the Layer Tab, there are first layer settings on the right. If you want to extrude the first layer at 80%, just put 80 in the field for "First Layer Width".

Done.

Return to “General Discussion and Tips”