Skip to content
Home » Documentation Home » Firmware Update & Settings

Firmware Update & Settings

The firmware is located on the control board. The controller used on most cheap laser engravers is based on an Arduino Uno architecture, since the first boards used genuine Arduino Uno boards with CNC-shields attached. Though, the microcontroller is an ATMega328 that is already shipped with an Arduino bootloader (you don’t need to take care of this technical stuff). Not only the parameters can be changed here, but the whole firmware can be exchanged / changed. Since it is an open project, anyone can make their own changes to the firmware and upload it. I recommend everyone to install the latest version of grbl (1.1h). There are several ways to do this, the easiest is via LaserGRBL (two firmware versions are already included here). But it also works via command line or Arduino IDE.

In most newer models, the ATMega328 has been replaced by an ESP32 chip. This chip is much faster and offers WLAN and Bluetooth functionality, among other things. The ESP32 chip requires a different firmware, so another section is created for it below. However, within this firmware a port of the original grbl implementation is still used, so there is usually no difference from a usage perspective.

If you need to make custom modifications to the firmware, you need to compile it using the Arduino IDE. The way how to do it is explained on the grbl wiki ( If you have a standard setup, you can select the already compiled versions provided with LaserGRBL.

Myths about microcontrollers and firmware updates

I constantly read statements about the firmware which, to my knowledge, are wrong. This is why I wanted to clarify a few things:

  • The EEPROM (non-volatile memory of the controller) has limited write cycles
    • Right. BUT: the EEPROM of ATMega microcontrollers has a lifetime of 100,000 write cycles. So if you rewrite your memory daily, you can do it for 270 years until you break it. SO: don’t care about it!
  • The EEPROM does not save settings correctly
    • Entirely wrong. Once written, the settings are stored and can’t get corrupted. 99.99% of users that tell me the controller does not save their settings did not press the SAVE or WRITE button in the control software. Just changing values and clicking OK in the dialog window does not necessarily mean that the settings are written into the memory. Take care of this.
  • Flashing firmware can break your controller
    • Partly correct. Of course, you can break your controller by flashing wrong firmware. BUT as long as you just use standard flash tools and do not alter the fuses settings (if you don’t know what this is, you most likely won’t alter them), you can always re-flash the controller with a new firmware. If you overwrite the bootloader of the controller, you can’t flash directly via USB anymore, but the MKS-DLC boards offer an ISP connector to flash the controller manually. In my whole career, I just broke 1 controller completely (and I flashed thousands). So, the chance you do it is minimal.
  • You can reset the controller by pressing the RESET button on the main board.
    • Wrong. This reset button just does a reboot of the controller. Nothing is reset or set to default values.

Update process (8Bit processors, S6-S9)


The following descriptions refer to lasers with Arduino or ATmega microcontrollers. This means the mainboards of S6 and S9. The S10 and S30 lasers have a new mainboard with an ESP32 chip, which can NOT be flashed with the following methods. (for those, see next sections)

Major steps

1. Save settings first!
2. Do firmware update
3. Check settings and restore if needed

Saving settings

Saving settings is important once you flash the firmware, since some values might be reset to factory settings while flashing. It is even recommended to reset to factory defaults after flashing and then replace changed values by your backup.

Save settings via LaserGRBL

First, you need to connect to the laser by selecting the correct COM port and click on the connection icon.

Select GRBL -> GRBL configuration
Click on Export or note down the values.
The output should look like this. (Values might be different!)

Pre-compiled firmware upload via LaserGRBL

If you just want to upgrade to the latest available grbl firmware, you can use precompiled firmware images (.hex files) that are delivered with LaserGRBL. You even have two options available, either if you have a standard setup without end stops or if you have end stops and can use automatic homing. More information at the LaserGRBL firmware flash page.


Step-per-step screenshots:

Click on Tools -> Flash Grbl Firmware
As target you select “Arduino Uno”
Select a firmware (v1.1h either with or w/o homing)
Check the COM port
Click OK
A command window opens showing the flash progress

Firmware for Sculpfun lasers

Since a few default settings of grbl do not correspond to those of the Sculpfun lasers, I compiled my own version of the firmware, which is as close as possible to the firmware that can be installed via LaserGRBL, but all default settings are optimized for the Sculpfun lasers. Note: there was a minor change, the homing of individual axis has been enabled now. That’s why it’s called “v2” now.

List of changes

The following changes have been made compared to the standard firmware:

//Optimize Homing
#define HOMING_CYCLE_0 ((1<<X_AXIS)|(1<<Y_AXIS))  // Homes both X-Y in one cycle. 
#define N_HOMING_LOCATE_CYCLE 2 // improve repeatability
#define HOMING_FORCE_SET_ORIGIN // set the machine origin at the homed location
#define HOMING_SINGLE_AXIS_COMMANDS // Enables single axis homing commands. $HX, $HY, and $HZ for X, Y, and Z-axis homing.
//Enable second pin for relay control
#define ENABLE_M7 // Enables a second coolant control pin

//Firmware default values
  #define DEFAULT_X_STEPS_PER_MM 80.0
  #define DEFAULT_Y_STEPS_PER_MM 80.0
  #define DEFAULT_Z_STEPS_PER_MM 80.0
  #define DEFAULT_X_MAX_RATE 6000.0 // mm/min
  #define DEFAULT_Y_MAX_RATE 6000.0 // mm/min
  #define DEFAULT_Z_MAX_RATE 6000.0 // mm/min
  #define DEFAULT_X_ACCELERATION (500.0*60*60) // 10*60*60 mm/min^2 = 10 mm/sec^2
  #define DEFAULT_Y_ACCELERATION (500.0*60*60) // 10*60*60 mm/min^2 = 10 mm/sec^2
  #define DEFAULT_Z_ACCELERATION (500.0*60*60) // 10*60*60 mm/min^2 = 10 mm/sec^2
  #define DEFAULT_X_MAX_TRAVEL 410.0 // mm NOTE: Must be a positive value.
  #define DEFAULT_Y_MAX_TRAVEL 400.0 // mm NOTE: Must be a positive value.
  #define DEFAULT_Z_MAX_TRAVEL 800.0 // mm NOTE: Must be a positive value.
  #define DEFAULT_SPINDLE_RPM_MAX 1000.0 // rpm
  #define DEFAULT_SPINDLE_RPM_MIN 0.0 // rpm
  #define DEFAULT_STATUS_REPORT_MASK 1 // MPos enabled
  #define DEFAULT_ARC_TOLERANCE 0.002 // mm
  #define DEFAULT_REPORT_INCHES 0 // false
  #define DEFAULT_INVERT_ST_ENABLE 0 // false
  #define DEFAULT_INVERT_LIMIT_PINS 0 // false
  #define DEFAULT_SOFT_LIMIT_ENABLE 0 // false
  #define DEFAULT_HARD_LIMIT_ENABLE 0  // false
  #define DEFAULT_INVERT_PROBE_PIN 0 // false
  #define DEFAULT_LASER_MODE 1 // false
  #define DEFAULT_HOMING_ENABLE 0  // false
  #define DEFAULT_HOMING_DIR_MASK 0 // move positive dir
  #define DEFAULT_HOMING_FEED_RATE 150.0 // mm/min
  #define DEFAULT_HOMING_SEEK_RATE 1000.0 // mm/min
  #define DEFAULT_HOMING_DEBOUNCE_DELAY 250 // msec (0-65k)
  #define DEFAULT_HOMING_PULLOFF 1.0 // mm

Download: v1.1h-custom-S6S9v2.hex

The file can be installed in several ways. I would consider the following two to be the easiest.

Installation via LaserGRBL

To enable LaserGRBL to offer the firmware in its dialog window, it must be moved into the firmware directory within LaserGRBL.

Installation via Xloader

There is a small tool, XLoader, which can be used to upload the hex files without any other tools. I have prepared an archive here that already contains the correct firmware: Download XLoader. With this, you can upload the firmware directly. The firmware file and the COM port must still be selected accordingly.

Flashing via Xloader application

Regardless of which method was selected, the firmware should then report with the version string “grbl 1.1h_S6S9universal”. Now all settings should be reset to the factory defaults, this is done with the command “$RST=*”. Thereafter, the parameters can be adjusted to the personal preferences again or restored from the backup.

If you have now misconfigured your parameters, you can always return to the Sculpfun defaults with the command “$RST=*” and have a running machine again.

Self-compiled firmware using Arduino IDE

Since I am used to compiling my own firmware via Arduino IDE, PlatformIO or just command line, I normally use this process. The process to prepare the firmware and upload it to the controller is described very well at the grbl homepage: Compiling grbl

After the files are installed as Arduino-library, there are three files that are interesting: config.h, defaults.h and cpu_map.h. cpu_map.h is just for information, which Arduino pins are mapped to which functions. Of course, you can adapt those to your needs. Defaults.h contains the default settings that are loaded if you reset the controller to firmware defaults. I use this to define my personal defaults and don’t have to care about saving them each time I change the firmware.

The most interesting file is config.h. Here you can set every setting you might need. This includes adding additional functionality, inverting logic pins, or adjusting parameters. After changing the parameters as you like, you do an upload using the Arduino IDE.

LightBurn recently released a video guide on how to install the self-compiled firmware on a Sculpfun laser:

Rebooting the controller

As stated before, a reboot can be issued by pressing the reset button on the main board (if there is one). Obviously, you can also reboot the controller by power cycling it. BE AWARE: nearly all main boards of diode lasers (and 3D printers as well) have an electrical connection between the USB connection and the microcontroller. If you just turn off the main power switch and leave the USB connection active (PC is turned on and providing power through USB)—the microcontroller IS NOT TURNED OFF! It is still running and using power from USB. So, it does no reboot cycle. [You can check this out by only connecting the USB cable and then use LightBurn or LaserGRBL to connect to your laser. This will work. You can also alter settings and save them. You can check the state of limit switches and all periphery. Only the motors and laser do not work because they need extra power.] So if you really want to reboot your controller, you need to turn off main power and also cut the USB connection. Then you have a clean reboot.

If you want to avoid this, you can also disconnect the supply voltage (VCC, the 5V line, usually red cable) from the USB cable. Then data can still be transferred, but without the main power supply, the microcontroller will also turn off.

[Update April 2022] There appears to be a new version of the motherboard, XY DLC V1.1. Here, it appears to me that this has already been changed, and the microcontroller is switched off completely when the main switch is pressed. Cool!

Firmware update ESP32 (S10-S30)


The official firmware image for the S10 is now available! You can download the file here: Download-Link (be aware that the file naming is a little strange).

Update! The firmware for the S30 series has also been released! You can download it here: Download-Link (after flashing, all settings are reset to default, so make sure to back up before).

The S10 laser does not have an ATmega microcontroller on the mainboard like the other lasers, but an ESP32 chip. This is not relevant for most users, but the ESP represents a different (newer) generation of chip. Among other things, it supports Wi-Fi, but this is not currently enabled. I assume that this functionality will be integrated at some time. The chip is much more powerful than the old generation and can therefore work at higher speeds. But since almost all firmwares for the ESP32 chips currently only use a port of the old grbl code, the improvements are still very limited.

For the update, a separate tool is needed that I have seen so far only for Windows systems. Here is the download link. Those with a Mac will have to resort to virtualization like Parallels or a Windows machine. In the following series of pictures, the upload is explained. Be sure to back up your firmware settings if you changed any values!


  • It is best to connect ONLY the USB cable, DO NOT connect the power supply or leave the small switch in the OFF position. The controller is powered via the USB cable and may not reset properly if external power is on. Note: Depending on the board, this varies. For the S30, the power supply must be ON.
  • After flashing, all settings are reset to factory defaults. Therefore, also in this case, make a backup of the settings before! (E.g., with LaserGRBL, as described above, this also works for the S10).
  • After the successful flashing, unplug the USB cable once and plug it in again so that the controller restarts (therefore do not connect another power cable, then it will not restart).

Now the laser should connect again as usual.

Recommended Firmware Settings (all models)

If you want to change a setting, you can do this via the console by entering the parameter, followed by an equal sign and the corresponding value, and then pressing Enter. The controller should answer with OK.

Example of setting the $131 parameter

You can display all current parameters by typing “$$” and pressing enter. LightBurn and LaserGRBL also have graphical dialogs to change these settings (“Machine Settings” in LightBurn and “grbl Configuration” in LaserGRBL).

The following table lists my recommended settings for the S6/S9 lasers. The “standard”-column lists the values that are set standard in the grbl firmware. The “S6/S9”-column shows the recommended / required settings for S6/S9. The third column lists changes that are required if you activate homing functionality. If there is no value in a column, the standard value is used!

#StandardChanges SculpfunChanges HomingS30 (Pro Max)ExplanationComment
$010Step pulse, microseconds
$125Step idle delay, milliseconds
$20Step port invert, mask
$304Direction port invert, maskHere the motors of the axes can be turned around if necessary (e.g. if you have to turn the whole frame) [Values: 0-3]
$40Step enable invert, boolean
$500/1 1Limit pins invert, booleanDepending on switches. Some limit switches have inverted behavior, this can be compensated here.
$60Probe pin invert, boolean
$1010/1Status report, maskDepending on workspace configuration, see article about limit switches.
$110.010Junction deviation, mm
$120.002Arc tolerance, mm
$130Report inches, boolean
$20011Soft limits, boolean
$2100Hard limits, boolean
$221011Homing cycle, boolean
$23000-7 7Homing dir invert, maskDepending on position of switches; see guide for homing
$2425.00075.000200Homing feed, mm/min
$25500.0001000.0001500Homing seek, mm/min
$26250Homing debounce, milliseconds
$271.0001.0001.000Homing pull-off, mmReturn distance into the workspace after reaching the home position
$301000Max spindle speed, RPM
$310Min spindle speed, RPM
$320111Laser mode, boolean
$100250.00080.00080.00080X steps/mmCan be calibrated even more precisely as required
$101250.00080.00080.00080Y steps/mmsee above
$102250.000Z steps/mm
$110500.0005000.0005000.0006000X Max rate, mm/minOften, 6000 is also entered here. I still want to make a measurement to the real maximum achievable value.
$111500.0005000.0005000.0006000Y Max rate, mm/min
$112500.000Z Max rate, mm/min
$12010.000250.000250.000500X Acceleration, mm/sec^21000 is often entered here. In my view, this is clearly too high. However, 500 is usually still possible.
$12110.000250.000250.000500Y Acceleration, mm/sec^2see above
$12210.000Z Acceleration, mm/sec^2
374 (Pro Max)
X Max travel, mmMay vary according to conditions
362 (Pro Max)
Y Max travel, mmsee above
$132200.000Z Max travel, mm
Values for the grbl settings. In the columns, only the changed values that are relevant are printed.

25 thoughts on “Firmware Update & Settings”

  1. How can I determine the firmware version currently installed on the Sculpfun S10 to see if it needs to be updated?

    1. It depends. Not all versions seem to report this. But usually, you can see a date string after connecting to the laser. This date gives a hint. If it is before 07-2022, you might upgrade.

    1. Not really. I think it should be, but people reported that it does not work. I didn’t have the chance to try yet. I will post an update once I did. Maybe tomorrow.

  2. I have the following laser equipment:
    SCULPFUN S10 10W laser engraving cutter, 0.08mm high precision 32-bit motherboard (MKS ESP32/DLC32 CPU 32 bit).
    Firmware version 1.1.2022072601
    Is there a new firmware, that fits my 10W laser?
    Finn Eriksen Denmark

    1. Hi Finn!
      I understand that you use the MKS DLC32 board? Then the only updates available are in the MKS GitHub repository. You can replace the firmware with the FluidNC firmware, if you want to go open source.

  3. I have just assembled the S10 with 10w laser and sculpfun limit switches, motherboard DLC 32 v1.0.
    No Firmware has been flashed to the machine as yet, and I’m not sure what firmware I need to load in for the motherboard & limit switches.
    I’m using lasergrbl & Carveco software

    My thanks in advance

  4. Bonjour
    Je possède une Sculptfun S9, par erreur j’ai effacé le Firmware mais quand je veux le réinjecter j’ai ce message :
    (Impossible de se connecter au périphérique Espressif : délai d’attente de l’en-tête du paquet expiré)
    J’ai essayé : changé les bauds, connectée avant et après ordi, moteurs branchés et débranchés, effectué un reset sur la carte toujours le même message.
    Merci pour une aide SVP

  5. Merci pour vos explications j’ai enfin réussi à réinstaller le firmware via :
    Xloader et v1.1h-custom-S6S9v2.hex.
    Je suis surpris que l’explication donnée par Scultfun ne fonctionne pas.
    Encore merci.
    Henri Guillaudeau

  6. Hi Melvin.
    Anna from Sculpfun after-sales service sent me a new board to replace the one that has been giving me some problems on my Sculpfun S9.
    I followed your guide step by step on the subject and when trying to install the firmware but i during the process i get the message: “Failed to connect to Expressif device: Timed out waiting for packet header
    What am I doing wrong?
    Thank you.

    1. Just answering here for completeness (was discussed via PM): seems the board is not recognized correctly, or the firmware is broken, and the bootloader does not work anymore.

  7. Bonjour,
    j’avais le même problème, j’ai fais ceci:
    Réinstaller le firmware via :
    Xloader et v1.1h-custom-S6S9v2.hex.

    1. There is no second x-axis connector, there are two y axis-connectors. You can’t use those ports differently because they are controlled simultaneously. For a z-axis, you need a third stepper driver. No way around it.

  8. Ok, what about adding a Z-Axis driver? As a mod. If there is an ESP IC maybe there are pinouts available? I don’t even mind using some generic GCode firmware…
    Eventually a completely external solution would also be acceptable. Use the frame, motors and blower…

Leave a Reply

Your email address will not be published.

This site uses Akismet to reduce spam. Learn how your comment data is processed.