Artillery Genius Pro / Sidewinder X2 - Marlin post-2.0.9.3 bugfix 9-02-2022 + TFT Firmware 9-02-2022

Artillery Genius Pro / Sidewinder X2 - Marlin post-2.0.9.3 bugfix 9-02-2022 + TFT Firmware 9-02-2022

thingiverse

<h1>Artillery Genius Pro / Sidewinder X2 Custom Marlin 2.0.9.3 + TFT Firmware </h1> <b>(different themes available)<br> Build/Source date: 9-02-2022, <br> v3 Version bugfix based on Marlin post-2.0.9.3 bugfix branch dated 9-02-2022 with even more adjusted parameters.</b> <br><br> <h2><b>Users which have troubles with flashing the TFT Firmware - It seems that Artillery is shipping new printers with a new TFT controller (If you open the case the chipset on TFT will read "GD32F305") </h2></b> <br><b>Seems like this TFT doesn't come from BTT and/or cannot be flashed correctly and is currently not supported! I will try to at lease work around it and create a firmware for the mainboard without touching the TFT side to bring back leveling etc. but it will require some time. For now I recommend to refrain from flashing.. this is most unfortunate and pity, that artillery is switching between manufacturers in the middle of product lifecycle... </b><br><br> <b>CREDITS:</b> <br> Firmware for Artillery Sidewinder X2 (SWX2) and Genius Pro compiled from latest Marlin 2.9.0.3 sources. Including also optimized TFT Firmware. Both sources dated 9-02-2022. <br> Both optimized and added special sauce and tweaks to it too.<br> Courtesy of Marlin (GPL-3.0 License)<br> https://marlinfw.org<br> (Mainboard firmware for the Artillery_Ruby Mainboard)<br> Artillery (adjustments and commits for Ruby Mainboard)<br> and Bigtreetech <br> https://bigtree-tech.com<br> (TFT Firmware).<br> <br> STM32Cube Programmer -- Copyright STMicroelectronics All rights reserved.<br> https://www.st.com/content/st_com/en/about/st_company_information/who-we-are.html <br><br> Pronterface/Printrun -- Copyright (C) 2011-2020 Kliment Yanev, Guillaume Seguin<br> https://github.com/kliment/Printrun<br> <br> Compiled from sources found here:<br> https://github.com/MarlinFirmware/Marlin/<br> https://github.com/bigtreetech/BIGTREETECH-TouchScreenFirmware<br> <br> Initial settings taken tweaked and ported from the SWX2 Firmware blob, posted by Artillery:<br> https://github.com/artillery3d/sidewinder-x2-firmware<br> <br> Special thanks and credits for flashing guide in STM32Cube Programmer goes to "mjrama" and "MasterBPM".<br> Credits go to "digant" for beeing a "spark" that ignited my interest to start developing firmware’s, investigating the SWX2 issues etc. Also for his big contribution in the TFT Firmware development. For link to his page incl. donation page please scroll to the bottom. <br><br> <h2><b>FIRMWARE INFORMATION:</b></h2> Special tweaks -- besides the ones that are required by the new TFT firmware to be fully functional (it is A LOT and some really important ones --- but since these are "standard" for the new TFT firmware to fully function --- will be listed at the end instead of at the beginning). All changes to default (or parameters which I thought are viable) have been commented with //SoniC (my nickname Since 2005 or so, PrEzi was before that). <br><br> Special Tweaks besides the "TFT Tweaks" : <br> -EEPROM Storage enabled incl. EEPROM autoinit on first boot after flash.<br> -Homing feedrate tweaks<br> -Z Safehoming enabled<br> -Unified bed leveling enabled with finer 7x7 grid<br> if you want to switch to a different method -- switch between mesh bl and ubl in config.h Lines 1554-1558 <br> -Detailed logging of G28, G29 and other leveling features -- as the new Mainboard has now more mem and more powah - why not<br> -Restore Leveling after G28<br> -Repeatability test for BLTouch clone enabled<br> -Increased probing to 3 with extra probing step 1 - means more accurate bed leveling and discards one result from 3 that is way above the rest -- further increasing accuracy<br> -S_Curve acceleration enabled, experimental S_curve acceleration also enabled<br> -Linear advance enabled and set to K=0.13 (seems it is more or less accurate value for stock, if you replaced the nozzle or heatbreaker you might want to tweak it – for me it is 0.05 after the changes to heatbreak and nozzle)<br> -Tuned the acceleration values taken from Artillery<br> -Since I tweaked the heatbreaker I have also risen the max safe temp to 300 (if you have all stock you can either revert it back or just stay below 260 degrees Celsius. Config.h line 558)<br> -LED Test enabled at the start<br> <br> Tweaks required for the TFT to be functional + additional tweaks for extended features : General options which MUST be activated:<br> -EEPROM_SETTINGS (in Configuration.h)<br> -BABYSTEPPING (in Configuration_adv.h)<br> -AUTO_REPORT_TEMPERATURES (in Configuration_adv.h)<br> -AUTO_REPORT_POSITION (in Configuration_adv.h)<br> -M115_GEOMETRY_REPORT (in Configuration_adv.h)<br> -M114_DETAIL (in Configuration_adv.h)<br> -REPORT_FAN_CHANGE (in Configuration_adv.h)<br> <br> Options to support printing from onboard SD:<br> -SDSUPPORT (in Configuration.h)<br> -LONG_FILENAME_HOST_SUPPORT (in Configuration_adv.h)<br> -AUTO_REPORT_SD_STATUS (in Configuration_adv.h)<br> -SDCARD_CONNECTION ONBOARD (in Configuration_adv.h)<br> <br> Options to support dialog with host:<br> -EMERGENCY_PARSER (in Configuration_adv.h)<br> -SERIAL_FLOAT_PRECISION 4 (in Configuration_adv.h)<br> -HOST_ACTION_COMMANDS (in Configuration_adv.h)<br> -HOST_PROMPT_SUPPORT (in Configuration_adv.h)<br> <br> Options to support M600 with host & (Un)Load menu: (Options to support dialog with host as pre requisite)<br> -NOZZLE_PARK_FEATURE (in Configuration.h)<br> -ADVANCED_PAUSE_FEATURE (in Configuration_adv.h)<br> -PARK_HEAD_ON_PAUSE (in Configuration_adv.h)<br> -FILAMENT_LOAD_UNLOAD_GCODES (in Configuration_adv.h)<br> <br> Options to fully support Bed Leveling menu:<br> -Z_MIN_PROBE_REPEATABILITY_TEST (in Configuration.h)<br> -G26_MESH_VALIDATION (in Configuration.h) (in Configuration.h)<br> -Z_STEPPER_AUTO_ALIGN (in Configuration_adv.h)<br> <br><br> <h2><b>Additional new parameters introduced in the build 9-02-2022: </h2></b> -FILAMENT_RUNOUT_SCRIPT "M600" -- separate definition of the M600 runout script (it is disabled if the Filament sensor is not connected to mainboard and M600 never will be defined in a clean way). Since SWX2/GP have the runout sensor connected to TFT instead of mainboard – this might improve the filament runout handling when printing e.g. from Octo, Pronterface etc.<br> -UBL_HILBERT_CURVE - this one should optimize the movement paths when doing multi-point UBL<br> -SHOW_REMAINING_TIME in conjunction with LCD_SET_PROGRESS_MANUALLY it should allow the display of remaining time provided from external sources (e.g. Octo)<br> -LONG_FILENAME_WRITE_SUPPORT -- ability to write to SD – pre-requisite for e.g. embedding the configuration into firmware, writing and deleting files via M28 and M30 and Binary Transfer (starting to experiment with firmware flashing via USB also for the Mainboard! Yay ! But it will take time. A LOT of time for me to experiment with this. Also not fully enabled yet as I will want to test the binary transfer internally first.<br> -SCROLL_LONG_FILENAMES // Scroll long filenames in the SD card menu <br> <br> <h2><b>Bugfixes to TFT since the last firmware 4-01-2022 to 9-02-2022: </h2></b> -Updated languages – Hungarian, Czech, Portuguese, PT-BR<br> -Add a pop-up message for no SD card/USB disk detected to differentiate between detection errors and read errors<br> -fixed buggy console & infinite loop after G29<br> -fix duplicate serial data pushed to debug serial port<br> -Fixed a bug with M0, M1 when printing from TFT (SD or USB). In case of M0 or M1 present in the gcode file, upon resume it would dive the nozzle into the bed - and make a nice tattoo there<br> -Fix randomly M21/M1 Errors<br> -Fixes a bug in the file list when selecting files from onboard SD<br> -Added long folder name when printing from onboard SD<br> -Fixed a bug in "printAbort()" function, a loop avoidance was implemented there but it was inactive<br> -Fix Fan menu odd behavior<br> <br> <br> <h2><b>Major bugfixes to Marlin since 2.0.9.3:</h2></b> -Fix M81 delay feature<br> -Fix EEPROM_INIT_NOW hash test result<br> -Preheat mode incorrect<br> -M105 output formatting breaks Pronterface and Cura<br> -Long filename file create/write<br> -Fix conditional M81 suicide issue<br> -Simplify Fast PWM timer macros<br> -Fix M852 reporting as M851<br> -Eliminate unwanted Z movement when parking head<br> -Fix init of delta safe height (for G29, G33, etc.)<br> -Fix, Improve Power-Loss Recovery<br> -Sanitize HOST_PROMPT_SUPPORT notifications<br> <br><br> <h2><b>CHANGELOG:</b></h2> <b>- 9-02-2022 post-2.0.9.3 bugfix for both SWX and GP: </b><br> -TEMP_BED_RESIDENCY_TIME 15 Allows more time for the bed to heat up evenly (upped from 10 seconds)<br> -DEFAULT_MAX_FEEDRATE { 300, 300, 30, 40 } – lowever Z and E0 feedrates a little<br> -DEFAULT_ACCELERATION 800 back to artillery stock. You can change it in your own slicer profiles.<br> -JUNCTION_DEVIATION_MM 0.016 - was 0,013 but with accel set in Slicer profile as 1250 and Jerk 7 it is roughly 0,016<br> -(yet again) adjusted the NOZZLE_TO_PROBE_OFFSET (M851) - the artillery value for Z= -2 was deemed too much for some, which resulted in nozzle crashing into bed. Now it is set as -1 per default. <br> -(yet again) tuned the E-Stepper steps per mm - based on the feedback most of you have a value close to 445) (M92) <br> - (ONLY For PWMFAN Version) FAN_MIN_PWM 30<br> - (ONLY For PWMFAN Version) FAST_PWM_FAN <br> - (ONLY For PWMFAN Version) FAST_PWM_FAN_FREQUENCY 76 <br> - all the bugfixes listed under TFT and Marlin<br><br> <b>- 9-01-2022 2.0.9.3 v2 (both SWX2 and GP):</b><br> -adjusted the NOZZLE_TO_PROBE_OFFSET (M851) - the artillery value for Z -2 was deemed too much for some, which resulted in nozzle crashing into bed. -tuned the E-Stepper steps per mm (from 445 to 415) (M92) - according to my own tuning... A calibration run with PID, P Offset, Steps per MM and fine adjusting the first layer via Babystepping is still recommended.<br> -corrected the FILAMENT_RUNOUT_DISTANCE_MM - desired was 25 but actual was 200 which resulted in longer delay between runout event trigger in octoprint and actual stop.<br> <br> -7-01-2022 2.0.9.3 v1:<br> -initial release for Genius Pro + TFT firmware<br> <br> -4-01-2022 2.0.9.3 v1:<br> -Initial release for SWX2 + TFT firmware <br> <br> <h2><b>COMPILING AND FLASHING:</b></h2> Since I haven't found a possibility to cleanly compile & flash the firmware via Visual Studio Code + Platformio in ST-Link mode (compiling alone is fine, compiling&flashing - even with hardcoded paths to st-files fails) there is a need to compile in VS Studio Code as usual and use the STM32 Programmer since the DFU mode in VSCode + Platformio doesn't seem to work too... <br><br> If you mess things up - no worries -- the bootloader on Ruby should be still accessible - get access to the mainboard and place a jumper on the Pins described as "3.3V and BOOT". Then attach the USB cable and the Bootloader should be accessible for you to reflash the DFU-Version of the Firmware (reverting to stock via this mode is also possible -- compiled firmware on the Artillery website). No need to turn the external power on - the board will be powered from the USB Port. <br> <br> Further instructions and flashing guide - I have included a pre-compiled version of the Firmware -- ready to be flashed in STM32 Programmer as “Firmware_SWX2_GP_Stock_PWMFan_Combo.7z” Package. The TFT Combo is under the filename “TFT_SWX2_GP_SFS_Combo_9-02-2022.7z” Sources are listed under “SWX2_GP_FANPWM_Marlin-post2093bugfx_Sources_only.7z “ <br> <br> <b>Flash instruction:</b> Obviously if you want to flash the "combo" (TFT + Mainboard) then start with the TFT (download the TFT package). <br> <h3><b>TFT:</b></h3> In order to upgrade the TFT Firmware to the newest Bigtreetech version from 9-02-2022 you need to have a MicroSD card (max 8GB) formatted as FAT32. If you have a bigger card just create a smaller FAT32 partition.<br> -Download “TFT_SWX2_GP_SFS_Combo_9-02-2022.7z”<br> For different flavors I have prepared different config files and also bin-files (in case you have a different TFT version and after flashing TFT becomes unresponsive) In order to flash the stock SWX2 just follow the instruction.<br> In order to flash the Genius Pro version replace config.ini with configGenius.ini<br> In order to flash the SWX2 BTTSFS Version replace config.ini with configBTTSFS.ini<br> In order to flash the GP BTTSFS Version replace config.ini with configGPBTTSFS.ini<br> <br><br> Then put on the ROOT of the SD card the MKS directory, config.ini and MKSTFT28.bin Choose whichever THEME you want and copy both bmp and font directories from the respective Theme into the MKS dir. <br><br> If you want to switch from the default language (eng) copy one of the language files in Language Packs directory also to the ROOT of the SD card. <br><br> Then turn off the printer, put the SD card into the slot and turn on the printer.<br> You will see booting, upgrading fonts then upgrading images (various images of the respective theme flashing on the screen). <br> Once the TFT firmware is upgraded there should be a sound and a normal graphical Marlin Menu should appear.<br> In order to connect TFT to your printer you might want to go into Menu - connection settings and modify the connection speed (try 115200 and 250000). <br> Once the TFT connects there should be a sound.<br><br> Please note that after upgrading the Mainboard Firmware the speed is set to 115200 and you need to redo this again.<br><br><br> <h3><b>If your TFT is unresponsive after the flashing: </h3></b> Always try with the "stock" MKSTFT28.bin. <br> If you have problems after flashing with the stock MKSTFT28.bin and TFT is not responding after flashing - I have included three different bin files. <br> The MKSTFT28.bin is the "stock v4". <br> The "NEW_GENIUS" is the "v5 installed mainly in Genius and also newest SWX2 "gen2" Printers. <br> v3 is the older one.<br> First try to replace the v4 (MKSTFT28.bin) with the v5 version (delete MKSTFT28.bin and rename MKS_TFT28_NEW_GENIUS.bin to MKSTFT28.bin) and flash as described below. If it still doesn't work try the v3 version. <br><br><br> If you also want to upgrade the mainboard firmware (with power coming only via the USB cable) to the newest Marlin you should always go into the TFT Menu then under Connections click on Disconnect ---- this disconnects physically the TFT from the mainboard (not sure about Genius Pro/SWX2 but in Genius/SWX1 TFT and Mainboard shared the same connection and there were problems with flashing the mainboard firmware when TFT was still connected --- like I've said - not checked if this is also the case with Genius Pro/SWX2 but it doesn't hurt, right?). Of course if you apply the "combo" (TFT + Mainboard) then start from TFT first. <br> If you want to replace the Genius Pro/Sidewinder X2 logo during boot with the "old" Bigtreetech one then go to the bmp folder, delete the "logo.bmp" and rename "logo_BTT.bmp" into "logo.bmp".<br> In the root there is logo.bmp (for SWX2) and logo_Genius.bmp (for Genius Pro) – just replace the file in the theme of your choice).<br> <br><br><br> <h3><b>MAINBOARD:</b></h3> --Download “Firmware_SWX2_GP_Stock_PWMFan_Combo.7z”<br> --Download and install STM32CubeProgrammer (includes drivers) from <br> https://www.st.com/en/development-tools/stm32cubeprog.html<br> (you can register for free)<br> --Install and allow the drivers to be installed too.<br> --Turn the printer off (no need for external power source as we get it via USB)<br> --Connect your printer via USB<br> --Download and open Pronterface (Printrun) which can be downloaded e.g. from here :<br> https://github.com/kliment/Printrun/releases/tag/printrun-2.0.0rc8<br> --Check under which port the Serial device was installed (COM Port might vary)<br> --Connect with Pronterface and the specific port with baud speed 115200.<br> --Type M997 in the console and send the command to the printer. <br> --Ignore the error messages and disconnect pronterface from the printer. DO NOT disconnect USB, we aren't done yet.<br> --Look again in the device manager and look for "STM32 BOOTLOADER" this time.<br> --If you don't see it --- you have an older version and you need to do the jumper trick to force the mainboard into the Bootloader/DFU mode. Read further on what to do.<br> --If you see the bootloader in device manages / usb-devices then start the STM32 Cube Programmer, switch from "ST-Link" to "USB" (which is actually DFU mode) and click on connect.<br> --If everything went fine you will see some hex/ascii code read and displayed left --- this is your current firmware. If you want to save/backup it - click on "Read" and "save as" - save your backup somewhere.<br> --Then switch from "device memory" to "open file" and point to the "Firmware<insertprinterhere>.bin" from the downloaded "Firmware_SWX2_GP_Stock_PWMFan_Combo.7z" (or point to your firmware compiled from the sources). <br> --Click on "Download" to trigger the flashing of your mainboard with the new firmware.<br> --After a while you should get a popup "File download complete" --- click on "OK", click on "disconnect" and remove the USB Cable.<br> --IF you needed a jumper -- this before powering the printer back on - remove the jumper.<br> --If you flashed it without the necessity to use the jumper - you are done and can proceed with configuring the Firmware --- first perform an EEPROM reset --- if you already have custom TFT Firmware -- either by going into menu/commands -- EEPROM defaults, then EEPROM Save - or by issuing the M502 command ( restore EEPROM defaults) followed by M500 (Save to EEPROM). <br> --Proceed with PID Tuning, Bed Leveling and other calibration steps.<br> <br><br> <b>JUMPER Method </b>to force the Mainboard into DFU/Bootloader mode (or after a broken flash): --Open the bottom and place a jumper on the two pins described as "BOOT" and "3.3V".<br> --Connect the printer via USB only to your PC, if the correct STM32 drivers are installed (included in STM32 Cube Programmer) the STM32 Bootloader device should be visible in the device manager.<br> --Proceed to flashing using STM32 Cube Programmer described above.<br> <br><br><br> <h3><b>CALIBRATION after the Flash</h3></b> -ALWAYS put a thin sheet of paper to prevent the nozzle from crashing into the bed. The values have been increased and deemed as “safe” but I won’t take any responsibility for any damages caused by these files. I have tested it several times + have a beta-tester that is helping me, but it is better to be safe than sorry.<br> -After the flash start with Homing all axes – homes fine and doesn’t crash into the bed ? Move on.<br> -do the PID Tuning<br> -preheat nozzle and bed to the target temp of your liking<br> -Go into Movement – Leveling – and set the “P offset” – I do this till the nozzle is just before slightly scratching the surface of the paper. Please keep in mind that I put the paper only under the nozzle – not under the BLtouch sensor.<br> -do the rest of the calibration steps --- e.g. steps per mm, UBL.<br> -after doing UBL make sure you turn BL on (in the same menu as UBL -- BL : on is displayed)<br> -make sure you save everything to EEProm<br> -start printing and be ready to fine-tune your first layer with the “Babystepping” – do it in small increments. Do not forget to save afterwards.<br> -Done! Enjoy your prints! <br> Oh... you may also want to tweak Linear advance. Current k value is 0.13 but if you switched the nozzle or heatbreaker you may be nearer to 0.05 rather than 0.13 :-) <br> <br> Last but not least ---- support will be available and I will check the comments daily and I will "try" to help you out, but I need to repeat it clearly --- you are doing it on your own responsibility and I won't accept any blame if something goes wrong. For me it works perfectly.<br> You need a little bit of knowledge in any case -- flashing --- a little, <br> --if you want to modify the source -- a lot more,<br> --You NEED to use Visual Studio Code with PlatformIO Extension to compile. Forget about ArduinoIDE, PERIOD. If you don't know how to use MS VSC + Platformio and how to set it up - before starting to ask questions here - LEARN from various YT tutorials. I am not here to school you through VSC.<br> <br> <br> <b>Enjoy und viel Spaß meine lieben! Pozdrawiam serdecznie!<br> Oh! and if you remix and or modify my files in any way and post them -- please also give credits where due !!! <br> //SoniC vel PrEzi </b> <br><br> P.S.2 If you were too fast with flashing the mainboard firmware even though you couldn't flash the TFT firmware because of the new GD32 microcontroller User lvpvsinfabvla has posted a stock firmware for Genius Pro. Revert back and wait for the GD32 microcontrollers to be supported.<br> Here is how :<br> https://drive.google.com/file/d/1382tuxYnfamRnw8TrK182olgUWo5nGtV/view?usp=sharing<br> Here the link for the firmware.hex, you can flash it on printer with STM32 after placing a jumper between 3.3V and BOOT printer is accessible again for PC in DFU mode. For me it work and now printer functionality are back!

Download Model from thingiverse

With this file you will be able to print Artillery Genius Pro / Sidewinder X2 - Marlin post-2.0.9.3 bugfix 9-02-2022 + TFT Firmware 9-02-2022 with your 3D printer. Click on the button and save the file on your computer to work, edit or customize your design. You can also find more 3D designs for printers on Artillery Genius Pro / Sidewinder X2 - Marlin post-2.0.9.3 bugfix 9-02-2022 + TFT Firmware 9-02-2022.