Full Lightburn Control Guide

Latest results with 40W laser using Lightburn Marlin configuration and then Lightburn GRBL configuration.
*EDIT ignore this > Laser did not fire for either configuration.
Was actually firing (@ 0.5%), but I couldn’t see that from where I was viewing.

GCode output for both scenarios:

Lightburn Marlin Configuration:

Start GCode
M425 X0.02 Z0.02 F1 S0
M106 P0 S255
M3 S0

End Gcode
M5
G0 Z330 F6000

Stream:
Starting stream
M425 X0.02 Z0.02 F1 S0
M106 P0 S255
M3 S0
G21
G90
M8
M05
G0 X31.056 Y19.225 F3000
G0 Z0
Layer Title
G1 X30.084 Y19.933 F1000 I S2.5
G1 X29.131 Y20.664
G1 X28.195 Y21.418
set air pump switch: open
G1 X27.279 Y22.193
.
.
.
G1 X31.056 Y19.225
M9
M05
G90
M5
G0 Z330 F6000
set air pump switch: close
Stream completed in 0:19
close Laser control

Lightburn GRBL Configuration:

Start GCode
M106 P0 S255
M3 S0

End GCode
M5
G0 Z330 F6000

Stream:
Starting stream
M106 P0 S255
M3 S0
G00 G17 G40 G21 G54
G90
M8
M5
G0 X31.056Y19.225
G0 Z0
Layer Title
M3
G1 X30.084Y19.933S2.5F1000
G1 X29.131Y20.664
G1 X28.195Y21.418
G1 X27.279Y22.193
set air pump switch: open
G1 X26.381Y22.989
.
.
.
G1 X31.056Y19.225
M5
M9
G1 S0
G90
M5
G0 Z330 F6000
M2
set air pump switch: close
echo:Unknown command: “M2”
Stream completed in 0:19
close Laser control

1 Like

I don’t have a 40W, so I’m not sure. Maybe rerun the firmware upgrade via USB while the 40W is plugged in to update the module firmware?

2 Likes

OMG!
I feel like such an idiot!!!
It actually had been working, but the power was so low that I couldn’t see the output from where I was viewing from.
SMH !!

2 Likes

slow clap :smiley_cat: Least you figured it out.

First test using 40W.
Simple circle and text with outline using Lightburn/Marlin profile (inline mode).
MDF
1000 speed, 5% power
12 minutes time.

2 Likes

Hi Skreelink… what is a “pull-off for homing”? my search of that term did not yield results except for your post here. Thanks!

When the machine homes, you’ll see it (normally) move quickly to the homing switch. Once it trips the switch the first time, it’ll pull the head back (or pull-off) and then move back into the switch again much slower for better accuracy.

The faster you hit the switch, the more inertia the bed/toolhead have and will move ever so slightly further even after the switch is tripped. This is why a second or third tap at a slower speed is done. If you don’t have enough pull-off distance, the travel might be longer than the switch actuation distance. This instead of pulling off to click again, it pulls back, but the switch is still active so it reads it as hit again wherever the first one did.

This causes the homing position to move around at random. It depends on where the switch hit, and sometimes it might back off enough for a full re-tap, maybe it won’t. I found this to be the case and increased the distance it pulls back to ensure it always had enough room for that next tap.

1 Like

Hello, I installed latest firmware from snapmaker and trying the inline function in lightburn… basically testing with 10W. when I click on frame to check the boudaries, the laser doesn’t turn on. The tickbox is checked in the settings.
Do you have same behaviour on your side?

Thanks

I don’t use the framing function, nor a direct cable connection. Maybe input M3 S0 in the console first, then hit the framing button to make sure the laser is brought online.

I have my machine set up as a Marlin machine in Lightburn (USB). 40W unit, Move/Power @ 0.5%, Frame works with just the Frame button and also Frame +Shift. This works in both normal mode and dev mode on the touchscreen.

Starting stream
G00 G17 G40 G21 G54
G90
G1 X101 Y1F3000 I S1.3
G1 Y101
G1 X1
G1 Y1
M05
G0
G90
Stream completed in 0:08
close Laser control

@Skreelink in the newest firmware update there are som laser related changes - does any of this affect using Lightburn with Snapmaker?

They actually fixed up the firmware where the custom firmware is no longer required. So you can use the stock firmware with lightburn just fine.

Thanks for the quick reply!
I thought that was the previous one, but I’m referring to this from todays release:

M3/M4 Gcode update
    Support for M3/M4 to turn Trapizoid Power on or off (in Marlin definition). This differs from standard Marlin, which configures LASER_POWER_TRAP when compiling firmware. The M3/M4 definition will now favor grbl.
    Marlin’s M3 I and M4 I switching between Continuous Inline Mode and Dynamic Inline Mode is currently not supported. It is important to note that Marlin’s definition of Dynamic Inline Mode is not the same as Grbl’s definition of Dynamic Laser Power Mode.
G0/G1 Gcode update
    In both M3 and M4, the laser is turned off when using the G0 movement.
    Both Marlin and GRBL types of Inline Mode.

Maybe they’re just documenting the previous changes, but I don’t know enough about the GCode side of this to tell.

Oh, I missed that. Theoretically, those two changes should make it work better, as it’s closer to GRBL than before. I’ll have to test more to see if standard GRBL is better than GRBL-M3 and see if M4 actually works as it should. It should turn the laser power down when decelerating to keep from burning the corners.

1 Like

Which is better to use for the 40w laser marlin or GRBL also with this work for the Artisan
Thanks

I’m not sure which one is “better” with the new firmware (Snapmaker2_V1.18.0) as I haven’t installed it yet. But FWIW, I prefer the Marlin configuration as it is closer to the Snapmaker’s native language. Further testing will shed light on this as mentioned in the previous messages above.

Will this work for the artisan?
Gcode
Put the stream in end gcode line or somewhere else

No, do not use these GCode’s. They are only the list of results when operating the Frame function in Lightburn when using the Marlin vs. the GRBL configurations.

Thanks for letting me know

A question to those who are using the 40w laser, with the device setup as Snapmaker Marlin. I’ve modified the start GCode that I was using with the 10W (GRBL-M3) to set the 40w calibrated focus length (in my case Z83.4). This works if the material is less than 5mm, however anything thicker and the laser will run into it when it’s sets the Z coordinates since the material thickness isn’t factored into the start gcode. Not an issue for the 10w because of its size and focus height.

I can work round it at the moment as I’m only doing test cuts on 12mm oak but would like to use the full bed eventually without having to manually change the start gcode everytime although I suspect this will be the only way (material thickness would be set to zero)

As an aside is anyone seeing M8/M9 not being generated when air assist is set to yes? Still looking into this