GCode changing when I save the file

Hello,
I have a problem when I edit my power and speed setting in LightBurn and than save it as a GCode the power and speed setting change when the new GCode file is saved. When it’s in LightBurn format file the power and speed setting are correct but once I save the file as a GCode to connect to my machine it changes the settings for some reason. How can I solve this?

If you’re referring to power, it’s defined according to S-value Max.
e.g. S-value max = 1000, 20% power outputs as 200.

Hey,
I’m not referring to the s value.
When I’m doing a layer and then I set the setting of power and speed for that layer and then I save the file as a gcode the power and speed changes.


look in the first image when it’s LightBurn format the speed is 180 and the power is 100.00.
And then I save it as g code to print it and the speed and power change.

Here it changes to speed 6000 and power 20.00 when I try to edit the power and speed as a gcode file and save it again it still doesn’t change.

6000/20 is the Lightburn default layer setting. When you say you save as Gcode and it changes, does it change on the screen before your eyes or are you closing Lightburn and this is what shows up when you bring the gcode file back in?
When you open the gcode file in a text editor what does it show?

When I open the gcode in a text editor the power I want is showing, but when I open the gcode file in LightBurn it shows 6000/20

That is correct. Lightburn doesn’t read the gcode settings, it only interprets the graphics and only as one layer. If you want to save the file and maintain all settings when you reopen it, save it as a Lightburn file.

Curious as to why you’re saving as gcode, your screenshot shows you’re connected to the laser. Why not use the start button?

1 Like

I tried connecting the laser it doesn’t work when I press the start button, so how can I save the setting when I transfer it to gcode?

Save it as a Lightburn file, then save gcode. If you need to edit, open the Lightburn file and make changes and resave.

I tried doing that but the g code file still goes back to default 6000/20

No it doesn’t. You said if you open it in a text editor it is correct. That is the gcode your machine sees.

You cannot open gcode file in Lightburn and have it bring settings with it.

Also, when opening a Lightburn file, you have to use the open command, NOT import. If you import, it does not bring settings in and goes to default settings.

2 Likes

You’re on Windows and COM1, in laser window select the correct com port to send the job directly to the laser.

Read the following doc:

Longer 5 review:

1 Like

The LBRN2 file is the Lightburn DESIGN file.
The GC (NC or TXT) file is the raw GCode commands to the controller. Unless you overwrite it with a new version, it is carved in granite.