I have a weird thing going on, my 10w laser doesn’t go down to material thickness, unless I type in the g-code for the test square manually from luban console.
I went through the thread and made sure to check the absolute coordinates and other related settings are correct.
Don’t have the usb cable to connect to the machine, so I used the drag and drop method (can’t have empty spaces in the path to the script/file tho).
Went through:
- Full Lightburn Control Guide
- Accurate, Repeatable Laser Guide
- Working camera capture with Lightburn
- Guide: Automatic Start via Drag/Drop
Running firmware:
-
Snapmaker2_V1.15.20
-
with - Full Lightburn Control Guide - #143 by Skreelink
- Marlin SM2-4.5.30-SKREE
- Compiled: Feb 23 2023, 18:49:01
- PACKAGE: Snapmaker_V4.5.30-SKREE
My test g-code from LightBurn
; LightBurn 1.3.01
; GRBL-M3 (1.1e or earlier) device profile, absolute coords
; Bounds: X0 Y0 to X8.89 Y10
;USER START SCRIPT
M106 P0 S255 ; This line is spit out by Luban and Snapmaker settings in Lightburn, so I include it.
G28 ; Safety home, incase you forgot after power on.
G53 ; Changes to Machine Coords.
G0 Z30.6 F6000 ; IMPORTANT, the Z value here is your LASER HEIGHT on the touchscreen.
G54 ; Changes back to Work Coords
G92 Z0 ; This sets Z Work Origin to 0, making your laser height as 0.
G0 Z300 ; Moves the toolhead back up out of the way.
G53 ; Back to machine coords!
G0 X0 Y0 F6000 ; IMPORTANT, this is the offset you found following my laser guide!
G54 ; Oops, we're back in work coords.
G92 X0 Y0 ; Yep, we gotta set 0,0 on X,Y as well!
M3 S0 ; This is a safety line, it brings the laser online at 0 power, basically a ready state.
;USER START SCRIPT
G00 G17 G40 G21 G54
G90
; Cut @ 6000 mm/min, 75% power
M8
M5
G0 X0Y0
G0 Z3
; Layer InnerLine
M3
G1 Y10S191.3F6000
G1 X8.889
G1 Y0
G1 X0
M5
M9
G1 S0
G90
; return to user-defined finish pos
G0 X0 Y350
;USER END SCRIPT
M5 ; Safety line, ensures the laser is offline and actually off.
G0 Z330 F6000 ; Custom line to rapid toss the toolhead up out of the way.
G0 Y350 ; Custom line to rapid the bed forward.
G28 ; Safety home, I've noticed sometimes my machine is offset if I don't home every now and then.
;USER END SCRIPT
M2
It looks like machine goes to aprox. double the Z30.6 and is trying to engrave.
Same things happens if I send using Luban, send using Drag’n’Drop method with batch script, if I upload via USB drive.
Unless I type every line of g-code above - then it works like it should.
Any idea what I might be missing besides being on latest firmware? They did a bit of bug fixing related to 10w laser there.
UPD - SOLUTION => Full Lightburn Control Guide - #161 by Skreelink