Page 1 of 2

Post processing variables

Posted: Thu Dec 29, 2022 6:05 am
by Khaos
Hi,

i tryed to find a list of all the variables available in the post-processing scripts. Sadly I wasn't successfull in my search.

Can you please point me in the right direction?

Re: Post processing variables

Posted: Fri Dec 30, 2022 12:13 pm
by S3D-Jason
We are actively working on more documentation for these variables.

Are there any variables you need to know right now that I can help with?

Re: Post processing variables

Posted: Mon Jan 02, 2023 4:37 am
by blj1884
Yes, I would like to know if there is an,

if layer = 1 then "gcode to run"

I want to adjust flow for first layer, then change it back after.

OR, have a first layer setting for flow? I know, first layer width, but that doesn't give "me" control on flow directly so I can have a "tune"-able machine setting. Does that make since?

Thank you

Re: Post processing variables

Posted: Tue Jan 03, 2023 10:31 am
by S3D-Jason
blj1884 wrote: Mon Jan 02, 2023 4:37 am Yes, I would like to know if there is an,

if layer = 1 then "gcode to run"

I want to adjust flow for first layer, then change it back after.

Sure - you could try placing this in the Pre Layer Change script:

{IF "[current_layer_number] == 1"}M221 S120 ; increase flow rate by 20% for layer 1
{IF "[current_layer_number] == 2"}M221 S100 ; reset flow rate to 100% for layer 2 and beyond

Re: Post processing variables

Posted: Wed Jan 04, 2023 5:24 pm
by Smoky312
I'm looking for a post processing variable for the prime pillar. I'm using a prime pillar infill percentage of 10% which is now selectable but is for the whole pillar. With a tool change I want the pillar infill switching to 100% for that layer to completely wash my single extruder.

Re: Post processing variables

Posted: Fri Jan 06, 2023 6:28 am
by blj1884
Thank you! :)

Re: Post processing variables

Posted: Tue Jan 10, 2023 8:50 am
by S3D-Jason
Smoky312 wrote: Wed Jan 04, 2023 5:24 pm I'm looking for a post processing variable for the prime pillar. I'm using a prime pillar infill percentage of 10% which is now selectable but is for the whole pillar. With a tool change I want the pillar infill switching to 100% for that layer to completely wash my single extruder.
I don't think you can change the infill percentage through the gcode scripts. However, you could probably use Tools > Variable Settings Wizard to accomplish the same thing. Just create a new zone where you want to use the higher prime pillar infill percentage.

Re: Post processing variables

Posted: Wed Jan 11, 2023 3:03 pm
by Smoky312
Making a new process for every tool change is too much work for some models.


But would it be possible to implement this feature into the application: Every tool change, set prime pillar infill to 100% and when tool change complete, back to preset infill percentage(like 5 or 10%)?
That would safe a lot of time and filament.

Re: Post processing variables

Posted: Fri Jan 13, 2023 10:51 am
by S3D-Jason
Smoky312 wrote: Wed Jan 11, 2023 3:03 pm But would it be possible to implement this feature into the application: Every tool change, set prime pillar infill to 100% and when tool change complete, back to preset infill percentage(like 5 or 10%)?
That would safe a lot of time and filament.
That would be a great idea to add to the Feature Request subforum! That way we can see how many other users are interested in it.

Re: Post processing variables

Posted: Thu Jan 26, 2023 11:56 am
by S.Oesterle
Hello,

I'm searching for a way of changing the G-Code conditionally with post-processing.
S3D-Jason wrote: Tue Jan 03, 2023 10:31 am Sure - you could try placing this in the Pre Layer Change script:

{IF "[current_layer_number] == 1"}M221 S120 ; increase flow rate by 20% for layer 1
{IF "[current_layer_number] == 2"}M221 S100 ; reset flow rate to 100% for layer 2 and beyond
This looks very interesting!


The firmware I'm using differentiates between travel movement and action movement by use of G0 and G1 respectively. The G0 and G1 commands are handled differently within the firmware in terms of velocity, acceleration and the transition from one to the other.

That's why I would want to change G1 to G0 for every line that is not using the E-dimension.

So

Code: Select all

G1 X123.235 Y112.592 E639.7060
G1 X126.912 Y157.073 F6000
G1 X130.566 Y175.831
would become

Code: Select all

G1 X123.235 Y112.592 E639.7060
G0 X126.912 Y157.073 F6000
G0 X130.566 Y175.831

Is that possible with use of {IF ...} and {REPLACE ..} or are there any other commands that I could use?