Air Assist is off (searched and replaced all "runBlower Value=“1” with "runBlower Value=“0”)
Sorry, the second (bottom) one is for the end gcode. I’m fixing it now.
And the M107 you highlighted in blue is something we’d always output anyways if you have the air assist turned off - it’s not part of the start/end scripts.
How one should go about controlling Air Assist not from cut settings but using Start/End gcodes if M107 is by default part of the code regardless Air Assist is on and/or off in cut settings?
You can’t. Start/End gcode is meant for other stuff that LightBurn doesn’t already control - such as turning a relay controlled exhaust on.
This new feature is not to replace existing functionality but instead of allow you to handle things not currently covered by existing functionality.
Serious question: why would you want to control air assist separately from the cut settings?
I was waiting for start/end gcode to be added for almost a year just so i can start air assist and blower few seconds before job starts, and wait few seconds from the moment job ends to shut these off.
Serious question: Why always output M107? and How come I see M107 at the beginning of the code?
Ok, I tuned Air Assist on and no more M107 at the beginning of the code.
Still…
Because that is the Smoothieware Air Assist (or fan for 3D printers) off command. With gcode devices you never want to assume the state something is in (such as air assist) and you can’t really ask the device what state it is in. So if the user selects air assist off in the cut settings we will make sure it’s turned off by emitting M107
When you turn air assist on you will not see M107 anymore because we place M106 at the beginning of the gcode which turns air assist on.
To do what you want to do, leave air assist on in your cur settings. But then also add M106 to your start gcode with a delay maybe (if that’s what you are going for). Now, at the end of the job we will turn it off with M107 (Again, it’s a matter of ensuring we leave it in a known state) but in your end gcode you could just do something like:
M106
G4 P10 ; delay 10 seconds
M107
It will immediately turn back on (you may not even notice it going off), wait 10 seconds, then turn off again.
Alternatively, you are using a smoothieware board - if you want to remove any control of such things from LightBurn, move air assist control to a different gcode command in your config. That way our M106/M107 commands won’t do anything and then you can put your own gcode in the start/end blocks.
I might just do that.
P10 is 10 millisecond.
S4 is 4 seconds.
In grbl mode (which is generally required for using LightBurn), P is also seconds. But yes, either would work.
Replacing M106 & M107 with M96 & M97 respectively did the trick.
.# Switch modules
.# Switch module for fan control
switch.fan.enable true # Enable this module
switch.AirAssist.enable true
switch.AirAssist.output_pin 2.4 #EH1 24V
.# switch.AirAssist.input_on_command M106 #Calling this command sets the switch ON
.# switch.AirAssist.input_off_command M107 #Calling this command sets the switch OFF
switch.AirAssist.input_on_command M96 #Calling this command sets the switch ON
switch.AirAssist.input_off_command M97 #Calling this command sets the switch OFF
This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.