This firmware is being put out as a courtesy for people who want to use the MKS SGen L V2 in their custom printer. Setup and usage of this firmware is *not* covered under the technical support any TH3D Products. Using the MKS SGen L V2 in a custom printer is an advanced setup for users who know what they are doing.
Important Information #
Stepper Drivers #
This firmware is set up to work with the MKS TMC2209 V2 or Watterott TMC2209 drivers in UART Mode. See pictures below if the text diagram is not clear.
Jumper Config O O O M0 O O O M1 O=O O M2 O O
Z Homing Direction #
This firmware only supports homing Z to the MIN position (not MAX) at this time.
MicroSD Card Flashing #
This board uses a MicroSD card to flash. If you are having issues getting the board to accept the firmware then see this page for details on making sure you are using the correct type and format of card: Flashing Firmware MicroSD Recommendations
Using the Firmware #
Opening the firmware in Visual Studio Code #
Once the files are extracted you will need to open the folder in Visual Studio Code. You must open the folder named Firmware and not any other one. Failure to open the firmware at the correct folder level will result in it not working.
First time using our firmware or having issues? Watch our video that is intended to clear up common mistakes people make when opening and using the firmware here: Unified 2 VSCode Tips for Noobs | EZTip #8 – YouTube
Once the folder is opened, you will expand the Marlin folder on the left and side and then double click on the file called “Configuration.h”. This file is where you will set up the firmware for your specific printer.
Editing The Configuration.h File #
In the configuration.h file there are printer models you can uncomment to tell the firmware what machine you are setting it up for. Uncomment means removing the // in front of a setting and you will be left with #define XXXXXX if an option is enabled.
There are many other options in the firmware for setting up upgrades, tuning, and other features. Read through the files configuration section to see all the features we’ve put in the firmware for you.
We have an article here with more details about the use of the configuration.h file.
Testing the Firmware Settings #
Once you have all the options you want and your printer model setting uncommented now it’s time to make sure it compiles with no issues. To do that just click the ✓ at the bottom-left of Visual Studio Code and it will build the firmware.
If the build succeeds it is ready for you to upload to your printer. You will know if it was successfully built because it will show a SUCCESS in green at the bottom of the window in Visual Studio Code.
Flashing the Firmware #
Upload the firmware to your board (SD Card Method) #
Now that we have the firmware tested we can upload it to your printer. Your particular printer uses a SD Card to upload it to the printer board. The firmware will be in a folder that matches the CPU name in .pio > build > CPUNAME. There will only be ONE folder in the Build folder so you just open that folder. Your folder name may be different from the picture shown below. You can open the folder by right-clicking on the folder for your board’s CPU and clicking “Reveal in File Explorer”.
Once you locate the .bin file for your board copy this to your SD card. This SD card MUST be formatted with FAT or FAT32 file system and most boards prefer a 4096 allocation byte size. Smaller cards (16GB or less) are better to use than larger ones for the best compatibility.
Power off your printer and put the SD card into your printer’s SD slot. Turn the power on. This will cause the printer to flash the firmware from the SD card to your printer CPU. This may take up to 1 minute on some boards.
DO NOT UNPLUG THE PRINTER. Interrupting the flashing can “brick” your board and if this happens you will need to reflash the bootloader with a programmer before you can flash again.
When the printer boots you may see the TH3D logo on your LCD, printers with low-end CPUs may not show a TH3D logo but all will show a Marlin screen with TH3D Studio showing on the version information.
Reset your EEPROM! #
Make sure to reset your EEPROM on your printer after flashing any firmware. You can do this from your printer LCD by going to Configuration -> Reset EEPROM or by sending an M502 followed by M500 with your favorite Gcode sender application.