commit96c1807b76Merge:4b9fce2e85e0f75d4f06Author: Sergey <sergey@terentiev.me> Date: Mon Jan 10 12:18:37 2022 +0300 Merge branch '2.0.x' into vanilla_fb_2.0.x commite0f75d4f06Author: David Ross Smith <5095074+DragRedSim@users.noreply.github.com> Date: Fri Jan 7 22:44:44 2022 +1100 🚑️ Fix preheat target bug Fixes Jyers/Marlin#1651 commit42449b8683Author: Scott Lahteine <github@thinkyhead.com> Date: Sun Jan 9 04:39:15 2022 -0600 🌐 Update auto home axis strings commite23c696566Author: Roman Moravčík <roman.moravcik@gmail.com> Date: Sun Jan 9 10:51:16 2022 +0100 🌐 Update Slovak language (#23475) commit035f9b8e13Author: Scott Lahteine <github@thinkyhead.com> Date: Sun Jan 9 03:48:17 2022 -0600 🔨 Rename (not copy) with board_build.rename commit49f8171f7aAuthor: Miguel Risco-Castillo <mriscoc@users.noreply.github.com> Date: Sun Jan 9 03:37:09 2022 -0500 🚸 BLTouch HS menu item for DWIN Enhanced UI (#23480) commit75d0e94d5bAuthor: ClockeNessMnstr <locke.dftc@gmail.com> Date: Sat Jan 8 15:09:25 2022 -0500 🚸 Do G34 "Z Backoff" at full current commit915f610782Author: jdegenstein <jdegenstein@users.noreply.github.com> Date: Thu Jan 6 19:03:02 2022 -0600 📌 LCD_FOR_MELZI for BTT E3 RRF (#23453) commit2231e00b2cAuthor: Lefteris Garyfalakis <46350667+lefterisgar@users.noreply.github.com> Date: Thu Jan 6 13:30:41 2022 +0200 🌐 Localize E3V2 Enhanced UI (#23424) commit63f2b15396Author: Anson Liu <ansonl@users.noreply.github.com> Date: Thu Jan 6 06:26:12 2022 -0500 📺 Tune ULTI_CONTROLLER encoder, enable PCA9632 (#23461) commitf503722c45Author: Kyle Hu <kyle.hu.gz@gmail.com> Date: Thu Jan 6 15:54:04 2022 +0800 🐛 Fix Artillery Ruby (startup code, build flags) (#23446) commit4fd1de7fb7Author: Mike La Spina <mike.laspina@shaw.ca> Date: Wed Jan 5 06:14:40 2022 -0600 🐛 Define required endstop enums (#23425) commit93126c0d02Author: Scott Lahteine <thinkyhead@users.noreply.github.com> Date: Wed Jan 5 01:48:18 2022 -0600 🔨 Strip CR in mftest > awk commit80f77ea807Author: Scott Lahteine <thinkyhead@users.noreply.github.com> Date: Wed Jan 5 01:52:02 2022 -0600 🐛 Fix strlen_P parameter error Fixes #23447 commit9ff8220b8aAuthor: Scott Lahteine <thinkyhead@users.noreply.github.com> Date: Mon Jan 3 09:18:10 2022 -0600 🩹 Fix RADDS+RRD encoder button commit7754860289Author: hwmland <12407423+hwmland@users.noreply.github.com> Date: Mon Jan 3 06:54:12 2022 +0100 🩹 RAMPS FET order overridable, E + Laser (#23428) commit4efe4788afAuthor: Jason Smith <jason.inet@gmail.com> Date: Sun Jan 2 21:27:22 2022 -0800 ⬆️ Assert newer GCC in PIO via atmelavr@~3.4 (#23432) commit2faf4e2a99Author: Jason Smith <jason.inet@gmail.com> Date: Sun Jan 2 19:17:19 2022 -0800 💚 Fix Teensy CI test (#23433) commit9956e62674Author: Scott Lahteine <thinkyhead@users.noreply.github.com> Date: Sun Jan 2 09:22:36 2022 -0600 🧑💻 Apply axis conditionals commita732427329Author: Scott Lahteine <thinkyhead@users.noreply.github.com> Date: Sun Jan 2 09:22:06 2022 -0600 🚨 Fix M906 warning commit974883d2f6Author: Mike La Spina <mike.laspina@shaw.ca> Date: Sun Jan 2 02:23:55 2022 -0600 🔧 Normal FET layout with Spindle/Laser (#23409) commit1170ed995eAuthor: Jason Smith <jason.inet@gmail.com> Date: Sun Jan 2 00:19:10 2022 -0800 🔧 Update deprecated auto_build.py (#23427) commit24f9c3a777Author: Johannes Hörmann <johannes.hoermann@t-online.de> Date: Sun Jan 2 06:46:55 2022 +0100 🔨 Upload to Optiboot at 115200 (#23403) commit5ec384f40cAuthor: Scott Lahteine <thinkyhead@users.noreply.github.com> Date: Sat Jan 1 22:54:27 2022 -0600 ✨ M919 : Chopper Timing (#23400) commit6d7ffa6addAuthor: Jason Smith <jason.inet@gmail.com> Date: Fri Dec 31 12:32:28 2021 -0800 🔧 Only warn about enabled CONFIGURATION_EMBEDDING (#23408) commitdadd7516b5Author: Scott Lahteine <github@thinkyhead.com> Date: Fri Dec 31 07:42:07 2021 -0600 🚑️ Fix thermal conditionals, structure commitf99732ba75Author: Robby Candra <robbycandra.mail@gmail.com> Date: Fri Dec 31 15:22:49 2021 +0700 🔧 DWIN_MARLINUI sanity checks (#23399) commit5a9635aa58Author: Scott Lahteine <thinkyhead@users.noreply.github.com> Date: Wed Dec 29 04:17:41 2021 -0600 🩺 Assert FAN_SOFT_PWM where required (#23383, #23477) commit1552c6d2a5Author: Lefteris Garyfalakis <46350667+lefterisgar@users.noreply.github.com> Date: Wed Dec 29 05:22:01 2021 +0200 🎨 E3V2 corner leveling => tramming (#23375) commit06c2ed3c99Author: Miguel Risco-Castillo <mriscoc@users.noreply.github.com> Date: Tue Dec 28 00:23:50 2021 -0500 🚸 DWIN Enhanced improve, fix, and extend (#23240) - Offset icon change to show mesh leveling status - Reset extruder position when enter to Move menu - New live end-stop diagnostic page - Editable firmware retracts settings for Tune and filament settings menu - Print Statistics page accessible from the Advanced Settings menu - Reset printer draws the boot image - Adds individual axes homing menu - Adds probe deploy/stow to Probe Settings menu - Updates lock screen - Rebuilds main buttons to support text caption in other languages - Increases probe offset limits to 60 mm - Fix M303 PID variable update - Fix Resume/Pause button update - Fix redraw of print done - Fix very large file name bug - Fix bug in bed manual leveling commit430c5da54cAuthor: Scott Lahteine <thinkyhead@users.noreply.github.com> Date: Tue Dec 28 18:29:05 2021 -0600 🚚 Rename L6470 G-code file commit5b9f3bd4b1Author: Scott Lahteine <thinkyhead@users.noreply.github.com> Date: Tue Dec 28 02:57:24 2021 -0600 🧑💻 Remove extraneous 'inline' hints commitccc66a8528Author: Scott Lahteine <thinkyhead@users.noreply.github.com> Date: Tue Dec 21 22:15:48 2021 -0600 🎨 Misc. cleanup commit8abe314b18Author: Scott Lahteine <github@thinkyhead.com> Date: Sun Jan 9 01:06:19 2022 -0600 🔨 Get FIRMWARE_BIN from env commitdc470eb10fAuthor: Miguel Risco-Castillo <mriscoc@users.noreply.github.com> Date: Sun Jan 9 02:29:36 2022 -0500 🐛 Fix EEPROM_INIT_NOW build hash test (#23479) commit4c5e57ae89Author: Miguel Risco-Castillo <mriscoc@users.noreply.github.com> Date: Sun Jan 9 02:24:56 2022 -0500 🩹 Reset DWIN CrealityUI print progress on start (#23481) commit5d7328df46Author: Scott Lahteine <thinkyhead@users.noreply.github.com> Date: Tue Dec 28 05:02:40 2021 -0600 🧑💻 Add AXIS_COLLISION to catch broken parameters \ commit99c237e05eAuthor: Scott Lahteine <thinkyhead@users.noreply.github.com> Date: Tue Dec 28 05:43:10 2021 -0600 🚸 Refine stepper-driver-related G-codes (#23372) commit56adbc3ebfAuthor: Scott Lahteine <thinkyhead@users.noreply.github.com> Date: Mon Dec 27 20:52:43 2021 -0600 📝 Consistent pin header orientation commit4cfe812c18Author: Scott Lahteine <thinkyhead@users.noreply.github.com> Date: Mon Dec 27 17:40:53 2021 -0600 📌 Define MKS Monster8 pins for MKS_MINI_12864 Fixes #23324 commit27d2471ea3Author: Scott Lahteine <thinkyhead@users.noreply.github.com> Date: Mon Dec 27 14:28:59 2021 -0600 🐛 Fix mffp usage commit61b9248c35Author: Scott Lahteine <thinkyhead@users.noreply.github.com> Date: Sun Dec 26 03:20:29 2021 -0600 🎨 Pins and SDIO cleanup commitc9561a8826Author: EvilGremlin <22657714+EvilGremlin@users.noreply.github.com> Date: Sun Dec 26 09:46:13 2021 +0300 🔧 Check Chiron LCD requirements (#23353) Co-Authored-By: EvilGremlin <22657714+EvilGremlin@users.noreply.github.com> commit58c84f17baAuthor: Scott Lahteine <github@thinkyhead.com> Date: Wed Dec 29 03:41:28 2021 -0600 🎨 Simplify some debug echos commit73b8320e9cAuthor: Scott Lahteine <github@thinkyhead.com> Date: Sat Jan 1 20:01:24 2022 -0600 🔨 Add .vscode/extensions.json commit1c3f2498b1Author: ellensp <530024+ellensp@users.noreply.github.com> Date: Thu Dec 30 20:35:22 2021 +1300 🐛 Fix RRW Keypad & Zonestar buttons (#23388) commit4202baa409Author: GHGiampy <83699429+GHGiampy@users.noreply.github.com> Date: Thu Dec 30 05:37:07 2021 +0100 🩹 Fix Enhanced UI max E speed (#23387) commitf471eab1a2Author: Scott Lahteine <thinkyhead@users.noreply.github.com> Date: Sat Dec 25 22:13:20 2021 -0600 🔖 Marlin 2.0.9.3 commit4b9fce2e85Merge:ecb08b15bee17d710c5cAuthor: Sergey <sergey@terentiev.me> Date: Mon Dec 27 16:47:22 2021 +0300 Merge branch '2.0.x' into vanilla_fb_2.0.x commit9b13ae2399Author: Keith Bennett <13375512+thisiskeithb@users.noreply.github.com> Date: Sat Dec 25 19:41:01 2021 -0800 🐛 Fix MKS Robin E3 NeoPixel pin default (#23350) commite17d710c5cAuthor: Scott Lahteine <thinkyhead@users.noreply.github.com> Date: Sat Dec 25 22:13:20 2021 -0600 🔖 Marlin 2.0.9.3 commit06f36dc746Author: kaidegit <60053077+kaidegit@users.noreply.github.com> Date: Sun Dec 26 10:12:20 2021 +0800 🐛 Fix open for bin rename (#23351) commit98eca9cb23Author: Scott Lahteine <thinkyhead@users.noreply.github.com> Date: Sat Dec 25 03:27:45 2021 -0600 🔧 Move MOTHERBOARD closer to top commit6268795003Author: fflosi <34758322+fflosi@users.noreply.github.com> Date: Sat Dec 25 05:57:07 2021 -0300 ✨ Per-axis TMC hold multiplier (#23345) commitb4f0922a7cAuthor: Sola <42537573+solawc@users.noreply.github.com> Date: Fri Dec 24 14:03:32 2021 +0800 ✨ MKS TinyBee board support (#23340) Co-Authored-By: Sola <42537573+solawc@users.noreply.github.com> commitaef613acd3Author: Robby Candra <robbycandra.mail@gmail.com> Date: Thu Dec 23 15:19:39 2021 +0700 🔧 Group FAST_PWM_FAN.options (#23331) Co-authored-by: Scott Lahteine <thinkyhead@users.noreply.github.com> commit9ecfa1d252Author: InsanityAutomation <38436470+InsanityAutomation@users.noreply.github.com> Date: Tue Dec 21 23:09:55 2021 -0500 ✨ BLTouch High Speed mode runtime configuration (#22916, #23337) Co-Authored-By: Scott Lahteine <thinkyhead@users.noreply.github.com> commite0bed1e344Author: ellensp <530024+ellensp@users.noreply.github.com> Date: Wed Dec 22 15:44:04 2021 +1300 ✨ Option to reset EEPROM on first run (#23276) Co-authored-by: Scott Lahteine <thinkyhead@users.noreply.github.com> commitd21fa25ab8Author: Spencer Owen <owenspencer@gmail.com> Date: Sat Dec 18 18:58:46 2021 -0700 ✨ Creality3D V4.2.3 / Ender-2 Pro board (#23307) commit0dc1a58b24Author: X-Ryl669 <boite.pour.spam@gmail.com> Date: Tue Dec 14 07:22:06 2021 +0100 ✨ Configurations embed and retrieve (#21321, #23303) commitf2ca70e232Author: John Lagonikas <39417467+zeleps@users.noreply.github.com> Date: Wed Dec 8 20:55:09 2021 +0200 🐛 Fix and improve MAX31865 (#23215) Co-authored-by: Scott Lahteine <thinkyhead@users.noreply.github.com> commita6bed22839Author: BigTreeTech <38851044+bigtreetech@users.noreply.github.com> Date: Sat Dec 11 03:38:03 2021 +0800 ✨ BigTreeTech SKR mini E3 V3.0 (STM32G0B1RET6) (#23283) commitefd67cf80dAuthor: Giuseppe499 <giuseppe499@live.it> Date: Tue Dec 7 02:53:51 2021 +0100 ✨ X Twist Compensation & Calibration (#23238) commit15204470a8Author: ladismrkolj <ladismrkolj@gmail.com> Date: Sun Dec 5 22:41:39 2021 +0100 🔧 Chamber Fan index option (#23262) commit48358d6a5cAuthor: Mike La Spina <mike.laspina@shaw.ca> Date: Fri Dec 3 12:48:48 2021 -0600 🏗️ Fix Maple HAL/STM32F1 PWM (#23211) commitd7abb891cdAuthor: Tanguy Pruvot <tpruvot@users.noreply.github.com> Date: Fri Dec 3 19:31:48 2021 +0100 🏗️ Rework STM32 timer frequency protection (#23187) commit52a44eb200Author: Scott Lahteine <thinkyhead@users.noreply.github.com> Date: Tue Nov 30 15:04:05 2021 -0600 🐛 Fix STM32 FastPWM commit9b1c0a75e1Author: Scott Lahteine <github@thinkyhead.com> Date: Sat Nov 27 18:33:32 2021 -0600 🎨 Rename HAL timer elements commitd75e7784e5Author: schmttc <89831403+schmttc@users.noreply.github.com> Date: Wed Nov 24 08:52:18 2021 +1100 ✨ EasyThreeD ET4000+ board and UI (#23080) Co-authored-by: Scott Lahteine <thinkyhead@users.noreply.github.com> commit0e60c8b7e0Author: John Robertson <john@cirtech.co.uk> Date: Tue Nov 23 21:24:24 2021 +0000 ✨ MarkForged YX kinematics (#23163) commit018c7b1cf4Author: Keith Bennett <13375512+thisiskeithb@users.noreply.github.com> Date: Sun Nov 21 11:25:06 2021 -0800 ✨ BigTreeTech Mini 12864 V1.0 (#23130) Co-authored-by: Scott Lahteine <thinkyhead@users.noreply.github.com> commitaf1d603374Author: Giuliano Zaro <3684609+GMagician@users.noreply.github.com> Date: Tue Nov 23 21:01:53 2021 +0100 ✨ Fan tachometer support (#23086, #23180, #23199) Co-Authored-By: Scott Lahteine <github@thinkyhead.com> commit884308f964Author: Scott Lahteine <github@thinkyhead.com> Date: Tue Nov 16 08:54:30 2021 -0600 🔧 SOUND_MENU_ITEM for E3V2 commit7269990413Author: Miguel Risco-Castillo <mriscoc@users.noreply.github.com> Date: Wed Nov 10 11:31:35 2021 -0500 🚸 Expose sub-options for E3V2 Enhanced (#23099) commit2a90d93b17Author: Keith Bennett <13375512+thisiskeithb@users.noreply.github.com> Date: Wed Nov 17 09:33:42 2021 -0800 📌 Overridable probe-related pins (#23107) commit6e284f8823Author: BigTreeTech <38851044+bigtreetech@users.noreply.github.com> Date: Wed Nov 10 23:56:10 2021 +0800 ✨ Support for BIQU B1-SE-Plus strain gauge probe (#23101) Co-authored-by: Scott Lahteine <thinkyhead@users.noreply.github.com> commita2349fc411Author: Scott Lahteine <thinkyhead@users.noreply.github.com> Date: Fri Dec 24 23:47:52 2021 -0600 🔨 Configurable firmware bin filename Configuration.h > FIRMWARE_BIN commita3964b2b40Author: Scott Lahteine <thinkyhead@users.noreply.github.com> Date: Fri Dec 24 20:59:28 2021 -0600 🔨 Ignore more generated files commit226ee7c1f3Author: Scott Lahteine <thinkyhead@users.noreply.github.com> Date: Fri Dec 24 01:46:51 2021 -0600 🔧 Sanity check MMU2_MENUS commit2c12171f46Author: Attila BODY <attila.body@gmail.com> Date: Fri Dec 24 06:57:20 2021 +0100 🐛 Fix Robin Nano v3 filament runout pins (#23344) Co-authored-by: Scott Lahteine <thinkyhead@users.noreply.github.com> commitd034a9c295Author: MrAlvin <umo-testing@3iii.dk> Date: Thu Dec 23 10:47:52 2021 +0100 🚸 Show mm'ss during first hour (#23335) Co-authored-by: Scott Lahteine <thinkyhead@users.noreply.github.com> commitd2c7104bb3Author: Robby Candra <robbycandra.mail@gmail.com> Date: Wed Dec 15 07:51:19 2021 +0700 🚸 Change "SD" to "Media" or "SD/FD" (#23297) commit570c7e8638Author: ellensp <530024+ellensp@users.noreply.github.com> Date: Wed Dec 22 13:48:38 2021 +1300 🐛 Fix Chitu Z_STOP_PIN (#23330) commitcc4578a3d3Author: Tanguy Pruvot <tpruvot@users.noreply.github.com> Date: Thu Dec 23 07:49:15 2021 +0100 🩹 Fix settings G21 report (#23338) commit1db84be66aAuthor: Mike La Spina <mike.laspina@shaw.ca> Date: Tue Dec 21 01:26:31 2021 -0600 🚑️ FAST_PWM_FAN default 1KHz base freq. (#23326) Co-authored-by: Scott Lahteine <thinkyhead@users.noreply.github.com> commit77c9668fe2Author: ellensp <530024+ellensp@users.noreply.github.com> Date: Tue Dec 14 19:25:28 2021 +1300 🐛 Fix LCD_BED_LEVELING compile (#23298) commit22cf9b444eAuthor: GHGiampy <83699429+GHGiampy@users.noreply.github.com> Date: Mon Dec 20 09:44:43 2021 +0100 🧑💻 Option allowing > 127 Neopixels (#23322) commit97798d1e47Author: Scott Lahteine <thinkyhead@users.noreply.github.com> Date: Thu Jul 8 01:33:49 2021 -0500 🎨 Update SKR V2 pins commitf4b808456aAuthor: Giuliano Zaro <3684609+GMagician@users.noreply.github.com> Date: Tue Dec 14 01:47:57 2021 +0100 🚸 Use M600 for disabled MMU (#21865) commit6264736968Author: Tanguy Pruvot <tpruvot@users.noreply.github.com> Date: Tue Dec 14 01:41:21 2021 +0100 🐛 Fix TFT_COLOR_UI Release Media issue (#23123) commit7a5f103bcfAuthor: John Lagonikas <39417467+zeleps@users.noreply.github.com> Date: Sat Dec 18 01:31:10 2021 +0200 🔧 Warning for IGNORE_THERMOCOUPLE_ERRORS (#23312) commit1a8307b196Author: Scott Lahteine <thinkyhead@users.noreply.github.com> Date: Sat Dec 18 17:38:29 2021 -0600 📝 Fix a config comment commit13a1c86ae8Author: ellensp <530024+ellensp@users.noreply.github.com> Date: Tue Dec 14 13:18:24 2021 +1300 ✨ M115 flag EXTENDED_M20 (#22941) commit15656201d2Author: ellensp <530024+ellensp@users.noreply.github.com> Date: Tue Dec 14 13:13:34 2021 +1300 ✏️ Clean up duplicate defs (#23182) commitf3e372cb4cAuthor: Robby Candra <robbycandra.mail@gmail.com> Date: Tue Dec 14 07:11:52 2021 +0700 🩹 Init fan speed at boot (#23181) Co-authored-by: Scott Lahteine <thinkyhead@users.noreply.github.com> commitc781ecc437Author: Scott Lahteine <thinkyhead@users.noreply.github.com> Date: Mon Dec 13 16:15:46 2021 -0600 🔧 Fix unknown board test commitdaa8fff6c6Author: Scott Lahteine <thinkyhead@users.noreply.github.com> Date: Sun Dec 12 16:16:40 2021 -0600 🩹 SD abort requires open file See #22566 commitd481bba327Author: ellensp <530024+ellensp@users.noreply.github.com> Date: Sun Dec 12 11:06:45 2021 +1300 🐛 Fix MARLIN_F103Rx variant SCK / MOSI pins (#23282) commit32b08ae04cAuthor: Scott Alfter <scott@alfter.us> Date: Wed Dec 8 23:18:04 2021 -0800 Fix Endstops::report_states (#23280) Fix regression 4d45fdf0eb commitf00a0356c7Author: Scott Lahteine <github@thinkyhead.com> Date: Wed Dec 8 18:36:08 2021 -0600 🎨 Misc. probe / endstop cleanup commit9871800874Author: Sola <42537573+solawc@users.noreply.github.com> Date: Thu Dec 9 03:37:45 2021 +0800 🐛 Fix MKS LVGL UI retraction (#23267) commit39c2c038beAuthor: Robby Candra <robbycandra.mail@gmail.com> Date: Thu Dec 9 02:15:31 2021 +0700 🩹 Coerce pin_t in set_pwm_duty macros (#23273) commit285d6488a3Author: Jason Smith <jason.inet@gmail.com> Date: Wed Dec 8 11:10:37 2021 -0800 🐛 Fix ACTION_ITEM with nullptr (#23195) Co-authored-by: Scott Lahteine <thinkyhead@users.noreply.github.com> commiteecbd09a46Author: Robby Candra <robbycandra.mail@gmail.com> Date: Thu Dec 9 01:57:50 2021 +0700 🚸 Onboard SD for SKR 2.0 / SKR PRO (#23274) commit8d4e4ac115Author: Scott Lahteine <thinkyhead@users.noreply.github.com> Date: Wed Dec 8 12:40:23 2021 -0600 🎨 Rename MAX31865 elements commitb77a5d4c8dAuthor: Scott Lahteine <thinkyhead@users.noreply.github.com> Date: Mon Dec 6 20:18:50 2021 -0600 ✏️ MAX31856 => MAX31865 commitc3b8b3e7e6Author: Mike La Spina <mike.laspina@shaw.ca> Date: Mon Dec 6 15:52:18 2021 -0600 🩹 Fix non-PWM cutter compile (#23169) commit7123b15801Author: Stuart Pittaway <1201909+stuartpittaway@users.noreply.github.com> Date: Mon Dec 6 21:40:18 2021 +0000 🐛 Fix TWIBus Wire.begin call (#23183) commit8a2f13d657Author: Chris Pepper <p3p@p3psoft.co.uk> Date: Sun Dec 5 22:18:02 2021 +0000 🐛 HAL_reboot for native HAL (#23246) commit251d9fc1d7Author: tommywienert <53783769+tommywienert@users.noreply.github.com> Date: Sun Dec 5 23:16:23 2021 +0100 🐛 Fix env:chitu_f103 (#23225) commit5eeb9650b5Author: ellensp <530024+ellensp@users.noreply.github.com> Date: Mon Dec 6 10:42:56 2021 +1300 📌 More Longer3D LKx Pro serial tests (#23260) commitc0addd1d33Author: Stuart Pittaway <1201909+stuartpittaway@users.noreply.github.com> Date: Sat Dec 4 23:44:10 2021 +0000 ✨ M3426 to read i2c MCP3426 ADC (#23184) commit05b57278d4Author: Scott Lahteine <github@thinkyhead.com> Date: Sat Dec 4 17:17:10 2021 -0600 🔧 Cutter pins for SKR 2.0 commitaa3ec2fbfdAuthor: Robby Candra <robbycandra.mail@gmail.com> Date: Sun Dec 5 05:14:19 2021 +0700 🚸 Park nozzle on "loud kill" (#23172) commit4468516aa2Author: ellensp <530024+ellensp@users.noreply.github.com> Date: Sun Dec 5 11:10:29 2021 +1300 ✨ BigTree SKR 2 with F429 (#23177) commit95d006b406Author: ellensp <530024+ellensp@users.noreply.github.com> Date: Sat Dec 4 09:48:54 2021 +1300 🐛 Fix TIMER_TONE for ZM3E4 (#23212) commit5b057b4bcfAuthor: Jiri Jirus <jiri.jirus@cloudaper.com> Date: Tue Nov 30 21:46:48 2021 +0100 🩹 Assume 4K EEPROM for RUMBA32 BTT (#23205) commit77af48e547Author: Scott Lahteine <github@thinkyhead.com> Date: Tue Nov 30 13:03:31 2021 -0600 🐛 Fix STM32 FastPWM commit0f7f709aadAuthor: Keith Bennett <13375512+thisiskeithb@users.noreply.github.com> Date: Sat Nov 27 14:59:32 2021 -0800 ✏️ Fix Unicode (#23186) commita8c0e11cb1Author: Jason Smith <jason.inet@gmail.com> Date: Sat Nov 27 13:54:39 2021 -0800 🩹 Handle nullptr in CardReader::printLongPath (#23197) commit0556da85b0Author: Anson Liu <ansonl@users.noreply.github.com> Date: Sat Nov 27 17:58:05 2021 -0500 🩹 UM2 extruder cooling fan on PJ6 (#23194) commit93652e5c6fAuthor: George Fu <nailao_5918@163.com> Date: Sun Nov 28 03:26:53 2021 +0800 ✨ FYSETC Spider v2.2 (#23208) commitf3fc1d15a3Author: Giuliano Zaro <3684609+GMagician@users.noreply.github.com> Date: Tue Nov 23 22:33:33 2021 +0100 🩹 Fix include path (#23150) commit3148060550Author: Keith Bennett <13375512+thisiskeithb@users.noreply.github.com> Date: Tue Nov 23 13:54:31 2021 -0800 📌 Biqu BX temporary framework workaround (#23131) commit5f08864d1fAuthor: Mike La Spina <mike.laspina@shaw.ca> Date: Tue Nov 23 14:05:50 2021 -0600 🐛 Fix STM32 set_pwm_duty (#23125) commit184fc36a08Author: Tanguy Pruvot <tpruvot@users.noreply.github.com> Date: Sun Nov 21 20:13:01 2021 +0100 🐛 Fix TFT backlight sleep/wake (#23153) commit281ed99868Author: Tanguy Pruvot <tpruvot@users.noreply.github.com> Date: Sat Nov 20 02:44:53 2021 +0100 ⚡️ Reduce calls to set fan PWM (#23149) commit2cc4a1b326Author: Scott Lahteine <thinkyhead@users.noreply.github.com> Date: Wed Nov 17 13:01:44 2021 -0600 🎨 Misc formatting commitc5bd08755cAuthor: BigTreeTech <38851044+bigtreetech@users.noreply.github.com> Date: Thu Nov 18 01:35:28 2021 +0800 🐛 Init PROBE_ENABLE_PIN (#23133) commit99f58f63f2Author: luzpaz <luzpaz@users.noreply.github.com> Date: Wed Nov 17 12:09:01 2021 -0500 🎨 Fix misspelling (#23137) commitc2a674d2c1Author: espr14 <espr14@gmail.com> Date: Wed Nov 17 18:07:11 2021 +0100 🏗️ Planner::busy() (#23145) commitfeffc19867Author: Scott Lahteine <thinkyhead@users.noreply.github.com> Date: Tue Nov 16 14:06:36 2021 -0600 🐛 Fix fast PWM WGM code Followup to #23102 commitf637e1c501Author: Scott Lahteine <thinkyhead@users.noreply.github.com> Date: Tue Nov 16 12:49:25 2021 -0600 🔨 Bring Makefile up to date commit78240a279bAuthor: EvilGremlin <22657714+EvilGremlin@users.noreply.github.com> Date: Tue Nov 16 19:32:43 2021 +0300 🔨 Ignore sim flashdrive file (#23129) commit656034d2d9Author: Luc Van Daele <lvd@sound-silence.com> Date: Tue Nov 16 16:24:53 2021 +0100 🐛 Fix G33, Delta radii, reachable (#22795) commit39a81d167eAuthor: Mikhail Basov <github@basov.net> Date: Mon Nov 15 07:46:34 2021 +0300 🚸 LCD_SHOW_E_TOTAL for TFT_COLOR_UI (#23127) commitcb1570d162Author: Scott Lahteine <github@thinkyhead.com> Date: Sun Nov 14 17:19:57 2021 -0600 🐛 Fix SENSORLESS_HOMING for 6-axis commit8cb646cc20Author: EvilGremlin <22657714+EvilGremlin@users.noreply.github.com> Date: Mon Nov 15 00:15:07 2021 +0300 🚸 Simplify touchscreen calibration for SimUI (#23124) commit3cccb21dc9Author: Miguel Risco-Castillo <mriscoc@users.noreply.github.com> Date: Wed Nov 10 11:55:20 2021 -0500 🚸 Fix up E3V2 Enhanced (#23100) commit7f4a49cc44Author: Scott Lahteine <github@thinkyhead.com> Date: Fri Oct 22 13:21:26 2021 -0500 🎨 Misc. issue review patches commite0c439fe91Author: Mike La Spina <mike.laspina@shaw.ca> Date: Sun Nov 14 05:55:31 2021 -0600 ⚡️ Controller Fan software PWM (etc.) (#23102) Co-authored-by: Scott Lahteine <thinkyhead@users.noreply.github.com> commit49e233e06fAuthor: Tanguy Pruvot <tpruvot@users.noreply.github.com> Date: Fri Nov 12 21:26:19 2021 +0100 🎨 MPX ARM Mini pins cleanup (#23113) commitb662dd1f92Author: Mike La Spina <mike.laspina@shaw.ca> Date: Fri Nov 12 12:14:28 2021 -0600 🐛 [LCP1768] Init PWM in set_pwm_duty (#23110) commit700cae43abAuthor: Skruppy <skruppy@onmars.eu> Date: Fri Nov 12 15:57:24 2021 +0100 🩹 Fix RGB case light compile (#23108) commit1c74c6e7acAuthor: George Fu <nailao_5918@163.com> Date: Wed Nov 10 23:58:20 2021 +0800 🐛 Fix FYSETC Cheetah 2.0 pins for production (#23104) commit757a9477dbAuthor: Minims <github@minims.fr> Date: Sun Oct 10 01:10:21 2021 +0200 🩹 Adjust GTR 1.0 ST7920 display delay (#22904) commit59d43408f6Author: Scott Lahteine <thinkyhead@users.noreply.github.com> Date: Sat Dec 25 00:57:30 2021 -0600 fix breaks in F() resolution commit1d8941d008Author: Scott Lahteine <github@thinkyhead.com> Date: Tue Oct 5 21:35:31 2021 -0500 🔨 Port libsdl2_net required for macOS simulator commit17f853d99cAuthor: Keith Bennett <13375512+thisiskeithb@users.noreply.github.com> Date: Tue Nov 9 08:30:02 2021 -0800 ⚡️ BTT002 (STM32F407VET6) variant, MK3_FAN_PINS flag (#23093) commit6f9f25dbb2Author: Scott Lahteine <github@thinkyhead.com> Date: Sun Nov 7 01:11:51 2021 -0600 🎨 Misc. code cleanup commit0273a68587Author: VragVideo <91742261+VragVideo@users.noreply.github.com> Date: Sun Oct 3 06:12:51 2021 +0300 ✨ WYH L12864 LCD (Alfawise Ex8) (#22863) commit58a26fcaacAuthor: Keith Bennett <13375512+thisiskeithb@users.noreply.github.com> Date: Sat Nov 6 23:09:15 2021 -0700 🚸 Indicate Preheating for probe / leveling (#23088) commit489aca03ffAuthor: Evgeniy Zhabotinskiy <evg-zhabotinsky@users.noreply.github.com> Date: Sun Nov 7 07:16:18 2021 +0300 🩹 Fix M503 report (#23084) commitf32e19e1c6Author: Jin <3448324+jinhong-@users.noreply.github.com> Date: Sun Nov 7 11:53:36 2021 +0800 🍻 Preliminary fix for Max31865 SPI (#22682) Co-authored-by: Scott Lahteine <thinkyhead@users.noreply.github.com> commit57bd04b6ceAuthor: dwzg <50058606+dwzg@users.noreply.github.com> Date: Sun Nov 7 04:48:00 2021 +0100 🐛 Fix JyersUI scrolling filename, etc. (#23082) Co-authored-by: Scott Lahteine <github@thinkyhead.com> commit396df93220Author: ellensp <530024+ellensp@users.noreply.github.com> Date: Sun Nov 7 15:27:53 2021 +1300 🐛 Fix DGUS Reloaded status message (#23090) commit9b76b58b79Author: Scott Lahteine <github@thinkyhead.com> Date: Thu Nov 4 12:18:23 2021 -0500 🍻 Get/clear reset source earlier Followup to #23075 commit9fffed7160Author: Skruppy <skruppy@onmars.eu> Date: Thu Nov 4 18:11:57 2021 +0100 🐛 Prevent AVR watchdogpile (#23075) commitfd136d5501Author: Tanguy Pruvot <tpruvot@users.noreply.github.com> Date: Thu Nov 4 18:04:04 2021 +0100 🐛 Fix TFT backlight [STM32] (#23062) commit89ec1c71f0Author: BigTreeTech <38851044+bigtreetech@users.noreply.github.com> Date: Thu Nov 4 18:54:38 2021 +0800 🐛 Fix Octopus-Pro Max31865 / SPI (#23072) commitfc2020c6ecAuthor: Robby Candra <robbycandra.mail@gmail.com> Date: Thu Nov 4 17:28:42 2021 +0700 🔨 Fix IntelliSense / PIO conflicts (#23058) Co-authored-by: Scott Lahteine <github@thinkyhead.com> commitf97635de36Author: ellensp <530024+ellensp@users.noreply.github.com> Date: Thu Nov 4 14:04:06 2021 +1300 📌 'STOP' auto-assign, some Chitu V9 pins (#22889) Co-authored-by: Scott Lahteine <github@thinkyhead.com> commita0a57406a2Author: Scott Lahteine <github@thinkyhead.com> Date: Wed Nov 3 07:06:31 2021 -0500 🔨 Script 'mfprep' finds pending commits commit5efef86cfaAuthor: Scott Lahteine <github@thinkyhead.com> Date: Wed Nov 3 07:02:21 2021 -0500 🔨 Update git helper scripts commit20c747753dAuthor: Scott Lahteine <github@thinkyhead.com> Date: Tue Nov 2 01:28:00 2021 -0500 🔨 Support ABM in mf scripts commit08a9c61587Author: Keith Bennett <13375512+thisiskeithb@users.noreply.github.com> Date: Mon Nov 1 23:15:29 2021 -0700 📌 Default NeoPixel pin for MKS Robin E3/E3D (#23060) commit0d91b07797Author: Andrei M <22990561+andrei-moraru@users.noreply.github.com> Date: Tue Nov 2 01:47:16 2021 -0400 ⚗️ Use pwm_set_duty over analogWrite to set PWM (#23048) Co-authored-by: Scott Lahteine <thinkyhead@users.noreply.github.com> commitb033da1782Author: Keith Bennett <13375512+thisiskeithb@users.noreply.github.com> Date: Mon Nov 1 22:43:40 2021 -0700 🔧 Endstop / DIAG homing conflict warning (#23050) commit4dcd872be5Author: Keith Bennett <13375512+thisiskeithb@users.noreply.github.com> Date: Mon Nov 1 21:23:54 2021 -0700 ✨ Allow Low EJERK with LA, optional (#23054) commit7e9e2a7435Author: Keith Bennett <13375512+thisiskeithb@users.noreply.github.com> Date: Mon Nov 1 20:23:24 2021 -0700 ✨ Artillery Ruby (STM32F401RCT6) (#23029) commit0b84194127Author: tombrazier <68918209+tombrazier@users.noreply.github.com> Date: Mon Nov 1 23:03:50 2021 +0000 🚸 More flexible Probe Temperature Compensation (#23033) commitefd9329c81Author: Scott Lahteine <thinkyhead@users.noreply.github.com> Date: Thu Jul 8 01:17:16 2021 -0500 📝 Tweak EXP comments commit5cbb820e29Author: Scott Lahteine <github@thinkyhead.com> Date: Sat Oct 30 23:43:19 2021 -0500 🔨 Help for GDB remote debugging commit5a0166489eAuthor: Scott Lahteine <github@thinkyhead.com> Date: Sat Oct 30 22:43:02 2021 -0500 🩹 Fix linker error (transfer_port_index) commit692c9a6312Author: Scott Lahteine <github@thinkyhead.com> Date: Sat Oct 30 04:16:37 2021 -0500 💚 Update Ender-3 V2 config path MarlinFirmware/Configurations#600 commit545d14f9a5Author: Scott Lahteine <github@thinkyhead.com> Date: Sat Oct 30 01:39:33 2021 -0500 🎨 Adjust Ender-3 V2 DWIN options commit7b9e01eb2bAuthor: aalku <aalku7@gmail.com> Date: Sat Oct 30 07:17:20 2021 +0200 ✨ Shutdown Host Action (#22908) Co-authored-by: Scott Lahteine <thinkyhead@users.noreply.github.com> commit8562f0ec44Author: Scott Lahteine <thinkyhead@users.noreply.github.com> Date: Fri Oct 29 20:46:55 2021 -0500 ✨ "Rutilea" ESP32 board (#22880) commit6f59d8171fAuthor: Scott Lahteine <github@thinkyhead.com> Date: Fri Oct 29 20:42:52 2021 -0500 🔧 Configuration version 02000903 commitd29a9014f2Author: Scott Lahteine <github@thinkyhead.com> Date: Wed Oct 27 21:36:06 2021 -0500 🎨 Standard 'cooldown' method commit205d867e4bAuthor: Scott Lahteine <github@thinkyhead.com> Date: Wed Oct 27 20:01:44 2021 -0500 🎨 Standard material presets behavior commit84f9490149Author: Scott Lahteine <github@thinkyhead.com> Date: Wed Oct 27 21:15:58 2021 -0500 🎨 Define HAS_PREHEAT conditional commit1fd4258423Author: tome9111991 <57866234+tome9111991@users.noreply.github.com> Date: Sat Oct 30 00:49:12 2021 +0200 🐛 Fix E3V2 (CrealityUI) Tune/Prepare > Zoffset (#23040) commite8a55972a7Author: Scott Lahteine <github@thinkyhead.com> Date: Thu Oct 28 19:22:35 2021 -0500 🐛 Fix EZBoard V2 board name commitaef413202eAuthor: Keith Bennett <13375512+thisiskeithb@users.noreply.github.com> Date: Thu Oct 28 03:26:05 2021 -0700 🐛 Fix MKS Robin E3/E3D Z Stop/Probe pins (#23034) commitcbc7dadf42Author: Scott Lahteine <github@thinkyhead.com> Date: Tue Oct 26 21:54:43 2021 -0500 🎨 Apply HAS_MULTI_HOTEND conditional commitc508ecc414Author: Zlopi <zlopi.ru@gmail.com> Date: Wed Oct 27 23:10:46 2021 +0300 🚸 Scroll long filename on MKS TFT (#23031) commit384a31765fAuthor: ellensp <530024+ellensp@users.noreply.github.com> Date: Thu Oct 28 09:06:06 2021 +1300 🩹 Retain LCD pins with motor expansion (#23024) commit0f2c4fc40bAuthor: somehibs <hibs@circuitco.de> Date: Wed Oct 27 21:00:02 2021 +0100 🐛 Fix serial PORT_RESTORE (and BUFFER_MONITORING) (#23022) commit66a274452cAuthor: tome9111991 <57866234+tome9111991@users.noreply.github.com> Date: Wed Oct 27 21:58:32 2021 +0200 🐛 Fix E3V2 (CrealityUI) position display (#23023) Followup to #23005, #22778 commit12f8168d1eAuthor: Scott Lahteine <github@thinkyhead.com> Date: Tue Oct 26 19:36:16 2021 -0500 🚸 Tweaks to UBL G29 Q commit2142e1dae4Author: woisy00 <spam@bergermeier.info> Date: Wed Oct 27 01:05:34 2021 +0200 🐛 Fix AUTOTEMP bug (thermal runaway) (#23025) Regression from9823a37commit8d21ea55a2Author: tombrazier <68918209+tombrazier@users.noreply.github.com> Date: Mon Oct 25 06:33:40 2021 +0100 🐛 Add USE_TEMP_EXT_COMPENSATION options (#23007) commita0da7e8a1fAuthor: Scott Lahteine <thinkyhead@users.noreply.github.com> Date: Sun Oct 24 23:33:27 2021 -0500 🔧 Fewer alerts about Z_SAFE_HOMING commite2452d6c57Author: tome9111991 <57866234+tome9111991@users.noreply.github.com> Date: Fri Oct 22 18:16:07 2021 +0200 🐛 Fix SHOW_REMAINING_TIME option for JyersUI (#22999) commit5173a3140dAuthor: Keith Bennett <13375512+thisiskeithb@users.noreply.github.com> Date: Fri Oct 22 08:52:31 2021 -0700 ✨ BigTreeTech TFT35 SPI V1.0 (#22986) commite44f2b7d2dAuthor: Mike La Spina <mike.laspina@shaw.ca> Date: Tue Oct 19 06:05:23 2021 -0500 🩹 Fix pragma ignored for older GCC (#22978) commited78f7f4e6Author: Scott Lahteine <thinkyhead@users.noreply.github.com> Date: Tue Oct 19 05:59:48 2021 -0500 🎨 Refactor MOSFET pins layout (#22983) commitaa198e41ddAuthor: Scott Lahteine <github@thinkyhead.com> Date: Tue Oct 19 05:52:41 2021 -0500 🎨 Pragma GCC cleanup commit18b38fb58aAuthor: Jason Smith <jason.inet@gmail.com> Date: Mon Oct 18 01:11:16 2021 -0700 🐛 Fix max chamber fan speed (#22977) commit5d79d8fad6Author: Keith Bennett <13375512+thisiskeithb@users.noreply.github.com> Date: Mon Oct 18 00:57:54 2021 -0700 🐛 Fix I2C EEPROM SDA/SCL aliases with SKR Mini E3 V2 (#22955) commite7a746966dAuthor: ellensp <530024+ellensp@users.noreply.github.com> Date: Mon Oct 18 20:54:20 2021 +1300 🐛 Fix MMU1 compile (#22965) commit555f35d46fAuthor: Mike La Spina <mike.laspina@shaw.ca> Date: Mon Oct 18 02:40:47 2021 -0500 🎨 Suppress type warning (#22976) commitde77dfcbbdAuthor: Scott Lahteine <github@thinkyhead.com> Date: Sun Oct 17 22:10:08 2021 -0500 🎨 Add MKS UI goto_previous_ui commitaf08f16efcAuthor: Scott Lahteine <github@thinkyhead.com> Date: Sun Oct 17 20:24:41 2021 -0500 🚸 Tweak MKS UI G-code console commit01a0f3a8cfAuthor: Scott Lahteine <github@thinkyhead.com> Date: Sun Oct 17 18:11:16 2021 -0500 🎨 Fix up MKS UI defines commitf80bcdcc5cAuthor: Scott Lahteine <github@thinkyhead.com> Date: Fri Oct 15 00:24:08 2021 -0500 🎨 Refactor Host Actions as singleton commit1ead7ce681Author: ellensp <530024+ellensp@users.noreply.github.com> Date: Fri Oct 15 14:38:03 2021 +1300 🔧 Add, update TFT sanity checks (#22928) commitdffa56463eAuthor: InsanityAutomation <38436470+InsanityAutomation@users.noreply.github.com> Date: Tue Oct 12 23:19:05 2021 -0400 ⚡️ Formbot ST7920 delays, intentional X2 pins (#22915) Co-authored-by: Scott Lahteine <thinkyhead@users.noreply.github.com> commitae98d2e5eaAuthor: Dmytro <svetotled@gmail.com> Date: Wed Oct 13 05:45:00 2021 +0300 🎨 Update MKS UI for no bed, extruder (#22938) Co-authored-by: Scott Lahteine <thinkyhead@users.noreply.github.com> commit5b1ef638eeAuthor: InsanityAutomation <38436470+InsanityAutomation@users.noreply.github.com> Date: Tue Oct 12 19:40:56 2021 -0400 🐛 Fix IDEX + DISABLE_INACTIVE_EXTRUDER (#22925) commitf3be03da20Author: Stuart Pittaway <1201909+stuartpittaway@users.noreply.github.com> Date: Mon Oct 11 23:42:29 2021 +0100 ✨ M261 S I2C output format (#22890) Co-authored-by: Scott Lahteine <github@thinkyhead.com> commit64128a5bcbAuthor: Tanguy Pruvot <tpruvot@users.noreply.github.com> Date: Sun Oct 10 01:05:24 2021 +0200 🐛 Queue string followup (#22900) commit0018c94a79Author: Pyro-Fox <36782094+Pyro-Fox@users.noreply.github.com> Date: Sat Oct 9 15:09:50 2021 -0700 🐛 LCD string followup (#22892) commitd48cb11537Author: Scott Lahteine <github@thinkyhead.com> Date: Tue Oct 5 21:19:28 2021 -0500 🐛 Followup to F() in config_line Followup to 1dafd1887e commitd9f7de7a24Author: Scott Lahteine <github@thinkyhead.com> Date: Mon Oct 4 19:50:14 2021 -0500 🐛 ExtUI F() followups Followup to 12b5d997a2 commit3d102a77caAuthor: Scott Lahteine <thinkyhead@users.noreply.github.com> Date: Tue Sep 28 20:15:52 2021 -0500 🎨 Apply F() to kill / sendinfoscreen commit492d70424dAuthor: Scott Lahteine <thinkyhead@users.noreply.github.com> Date: Tue Sep 28 19:28:29 2021 -0500 🎨 Apply F() to MKS UI errors, assets commit24dbeceb45Author: Scott Lahteine <thinkyhead@users.noreply.github.com> Date: Mon Sep 27 13:46:42 2021 -0500 🎨 Apply F() to various reports commitcabd538fddAuthor: Scott Lahteine <thinkyhead@users.noreply.github.com> Date: Mon Sep 27 13:40:01 2021 -0500 🎨 Apply F() to G-code report header commit9cf1c3cf05Author: Scott Lahteine <thinkyhead@users.noreply.github.com> Date: Sat Sep 25 23:52:41 2021 -0500 🎨 Apply F() to UTF-8/MMU2 string put commitc3ae221a10Author: Scott Lahteine <thinkyhead@users.noreply.github.com> Date: Sat Sep 25 22:11:48 2021 -0500 🎨 Apply F() to some ExtUI functions commit7626d859a6Author: Scott Lahteine <thinkyhead@users.noreply.github.com> Date: Mon Sep 27 11:55:08 2021 -0500 🎨 Apply F() to Host Actions strings commit360311f232Author: Scott Lahteine <github@thinkyhead.com> Date: Sat Sep 25 17:05:11 2021 -0500 🎨 Apply F() to status message commit433eedd50fAuthor: Scott Lahteine <thinkyhead@users.noreply.github.com> Date: Mon Sep 27 11:03:07 2021 -0500 🎨 Apply F() to serial macros commit46c53f6730Author: Scott Lahteine <github@thinkyhead.com> Date: Sat Sep 25 21:11:31 2021 -0500 🎨 Apply F() to G-code suite and queue commit2b9ae0cc33Author: Scott Lahteine <github@thinkyhead.com> Date: Sat Sep 25 18:43:52 2021 -0500 🎨 Apply F() to G-code subcommands commit433a27e475Author: Scott Lahteine <github@thinkyhead.com> Date: Sat Sep 25 18:22:37 2021 -0500 🎨 Update F string declarations commit1de265ea5dAuthor: Scott Lahteine <thinkyhead@users.noreply.github.com> Date: Mon Oct 4 00:24:41 2021 -0500 🎨 Axis name string interpolation, with examples (#22879) commitecb08b15beMerge:798d12c2af854ce63358Author: Sergey <sergey@terentiev.me> Date: Wed Dec 22 11:58:28 2021 +0300 Merge branch '2.0.x' into vanilla_fb_2.0.x commit854ce63358Author: Robby Candra <robbycandra.mail@gmail.com> Date: Sun Dec 19 05:33:21 2021 +0700 🐛 Fix loud_kill heater disable (#23314) commit170f77fadaAuthor: lukrow80 <64228214+lukrow80@users.noreply.github.com> Date: Tue Nov 23 22:30:13 2021 +0100 🐛 Fix homing current for extra axes (#23152) Followup to #19112 commit72b99bf1baAuthor: InsanityAutomation <38436470+InsanityAutomation@users.noreply.github.com> Date: Sat Oct 9 19:13:19 2021 -0400 🐛 Fix IDEX Duplication Mode Positioning (#22914) Fixing #22538 commit1a8583f4fcAuthor: Robby Candra <robbycandra.mail@gmail.com> Date: Wed Nov 24 04:19:32 2021 +0700 🐛 Fix serial_data_available (#23160)
1288 lines
44 KiB
Python
1288 lines
44 KiB
Python
#!/usr/bin/env python
|
|
#######################################
|
|
#
|
|
# Marlin 3D Printer Firmware
|
|
# Copyright (c) 2020 MarlinFirmware [https://github.com/MarlinFirmware/Marlin]
|
|
#
|
|
# Based on Sprinter and grbl.
|
|
# Copyright (c) 2011 Camiel Gubbels / Erik van der Zalm
|
|
#
|
|
# This program is free software: you can redistribute it and/or modify
|
|
# it under the terms of the GNU General Public License as published by
|
|
# the Free Software Foundation, either version 3 of the License, or
|
|
# (at your option) any later version.
|
|
#
|
|
# This program is distributed in the hope that it will be useful,
|
|
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
# GNU General Public License for more details.
|
|
#
|
|
# You should have received a copy of the GNU General Public License
|
|
# along with this program. If not, see <https://www.gnu.org/licenses/>.
|
|
#
|
|
#######################################
|
|
|
|
#######################################
|
|
#
|
|
# Revision: 2.1.0
|
|
#
|
|
# Description: script to automate PlatformIO builds
|
|
# CLI: python auto_build.py build_option
|
|
# build_option (required)
|
|
# build executes -> platformio run -e target_env
|
|
# clean executes -> platformio run --target clean -e target_env
|
|
# upload executes -> platformio run --target upload -e target_env
|
|
# traceback executes -> platformio run --target upload -e target_env
|
|
# program executes -> platformio run --target program -e target_env
|
|
# test executes -> platformio test upload -e target_env
|
|
# remote executes -> platformio remote run --target upload -e target_env
|
|
# debug executes -> platformio debug -e target_env
|
|
#
|
|
# 'traceback' just uses the debug variant of the target environment if one exists
|
|
#
|
|
#######################################
|
|
|
|
#######################################
|
|
#
|
|
# General program flow
|
|
#
|
|
# 1. Scans Configuration.h for the motherboard name and Marlin version.
|
|
# 2. Scans pins.h for the motherboard.
|
|
# returns the CPU(s) and platformio environment(s) used by the motherboard
|
|
# 3. If further info is needed then a popup gets it from the user.
|
|
# 4. The OUTPUT_WINDOW class creates a window to display the output of the PlatformIO program.
|
|
# 5. A thread is created by the OUTPUT_WINDOW class in order to execute the RUN_PIO function.
|
|
# 6. The RUN_PIO function uses a subprocess to run the CLI version of PlatformIO.
|
|
# 7. The "iter(pio_subprocess.stdout.readline, '')" function is used to stream the output of
|
|
# PlatformIO back to the RUN_PIO function.
|
|
# 8. Each line returned from PlatformIO is formatted to match the color coding seen in the
|
|
# PlatformIO GUI.
|
|
# 9. If there is a color change within a line then the line is broken at each color change
|
|
# and sent separately.
|
|
# 10. Each formatted segment (could be a full line or a split line) is put into the queue
|
|
# IO_queue as it arrives from the platformio subprocess.
|
|
# 11. The OUTPUT_WINDOW class periodically samples IO_queue. If data is available then it
|
|
# is written to the window.
|
|
# 12. The window stays open until the user closes it.
|
|
# 13. The OUTPUT_WINDOW class continues to execute as long as the window is open. This allows
|
|
# copying, saving, scrolling of the window. A right click popup is available.
|
|
#
|
|
#######################################
|
|
|
|
from __future__ import print_function
|
|
from __future__ import division
|
|
|
|
import sys,os,re
|
|
|
|
pwd = os.getcwd() # make sure we're executing from the correct directory level
|
|
pwd = pwd.replace('\\', '/')
|
|
if 0 <= pwd.find('buildroot/share/vscode'):
|
|
pwd = pwd[:pwd.find('buildroot/share/vscode')]
|
|
os.chdir(pwd)
|
|
print('pwd: ', pwd)
|
|
|
|
num_args = len(sys.argv)
|
|
if num_args > 1:
|
|
build_type = str(sys.argv[1])
|
|
else:
|
|
print('Please specify build type')
|
|
exit()
|
|
|
|
print('build_type: ', build_type)
|
|
|
|
print('\nWorking\n')
|
|
|
|
python_ver = sys.version_info[0] # major version - 2 or 3
|
|
|
|
print("python version " + str(sys.version_info[0]) + "." + str(sys.version_info[1]) + "." + str(sys.version_info[2]))
|
|
|
|
import platform
|
|
current_OS = platform.system()
|
|
|
|
#globals
|
|
target_env = ''
|
|
board_name = ''
|
|
|
|
from datetime import datetime, date, time
|
|
|
|
#########
|
|
# Python 2 error messages:
|
|
# Can't find a usable init.tcl in the following directories ...
|
|
# error "invalid command name "tcl_findLibrary""
|
|
#
|
|
# Fix for the above errors on my Win10 system:
|
|
# search all init.tcl files for the line "package require -exact Tcl" that has the highest 8.5.x number
|
|
# copy it into the first directory listed in the error messages
|
|
# set the environmental variables TCLLIBPATH and TCL_LIBRARY to the directory where you found the init.tcl file
|
|
# reboot
|
|
#########
|
|
|
|
##########################################################################################
|
|
#
|
|
# popup to get input from user
|
|
#
|
|
##########################################################################################
|
|
|
|
def get_answer(board_name, question_txt, options, default_value=1):
|
|
|
|
if python_ver == 2:
|
|
import Tkinter as tk
|
|
else:
|
|
import tkinter as tk
|
|
|
|
def CPU_exit_3(): # forward declare functions
|
|
CPU_exit_3_()
|
|
|
|
def got_answer():
|
|
got_answer_()
|
|
|
|
def kill_session():
|
|
kill_session_()
|
|
|
|
root_get_answer = tk.Tk()
|
|
root_get_answer.title('')
|
|
#root_get_answer.withdraw()
|
|
#root_get_answer.deiconify()
|
|
root_get_answer.attributes("-topmost", True)
|
|
|
|
def disable_event():
|
|
pass
|
|
|
|
root_get_answer.protocol("WM_DELETE_WINDOW", disable_event)
|
|
root_get_answer.resizable(False, False)
|
|
|
|
root_get_answer.radio_state = default_value # declare variables used by TK and enable
|
|
|
|
global get_answer_val
|
|
get_answer_val = default_value # return get_answer_val, set default to match radio_state default
|
|
|
|
radio_state = tk.IntVar()
|
|
radio_state.set(get_answer_val)
|
|
|
|
l1 = tk.Label(text=board_name, fg="light green", bg="dark green",
|
|
font="default 14 bold").grid(row=0, columnspan=2, sticky='EW', ipadx=2, ipady=2)
|
|
|
|
l2 = tk.Label(text=question_txt).grid(row=1, pady=4, columnspan=2, sticky='EW')
|
|
|
|
buttons = []
|
|
|
|
for index, val in enumerate(options):
|
|
buttons.append(
|
|
tk.Radiobutton(
|
|
text=val,
|
|
fg="black",
|
|
bg="lightgray",
|
|
relief=tk.SUNKEN,
|
|
selectcolor="green",
|
|
variable=radio_state,
|
|
value=index + 1,
|
|
indicatoron=0,
|
|
command=CPU_exit_3
|
|
).grid(row=index + 2, pady=1, ipady=2, ipadx=10, columnspan=2))
|
|
|
|
b6 = tk.Button(text="Cancel", fg="red", command=kill_session).grid(row=(2 + len(options)), column=0, padx=4, pady=4, ipadx=2, ipady=2)
|
|
|
|
b7 = tk.Button(text="Continue", fg="green", command=got_answer).grid(row=(2 + len(options)), column=1, padx=4, pady=4, ipadx=2, ipady=2)
|
|
|
|
def got_answer_():
|
|
root_get_answer.destroy()
|
|
|
|
def CPU_exit_3_():
|
|
global get_answer_val
|
|
get_answer_val = radio_state.get()
|
|
|
|
def kill_session_():
|
|
raise SystemExit(0) # kill everything
|
|
|
|
root_get_answer.mainloop()
|
|
|
|
# end - get answer
|
|
|
|
|
|
#
|
|
# move custom board definitions from project folder to PlatformIO
|
|
#
|
|
def resolve_path(path):
|
|
import os
|
|
|
|
# turn the selection into a partial path
|
|
|
|
if 0 <= path.find('"'):
|
|
path = path[path.find('"'):]
|
|
if 0 <= path.find(', line '):
|
|
path = path.replace(', line ', ':')
|
|
path = path.replace('"', '')
|
|
|
|
# get line and column numbers
|
|
line_num = 1
|
|
column_num = 1
|
|
line_start = path.find(':', 2) # use 2 here so don't eat Windows full path
|
|
column_start = path.find(':', line_start + 1)
|
|
if column_start == -1:
|
|
column_start = len(path)
|
|
column_end = path.find(':', column_start + 1)
|
|
if column_end == -1:
|
|
column_end = len(path)
|
|
if 0 <= line_start:
|
|
line_num = path[line_start + 1:column_start]
|
|
if line_num == '':
|
|
line_num = 1
|
|
if column_start != column_end:
|
|
column_num = path[column_start + 1:column_end]
|
|
if column_num == '':
|
|
column_num = 0
|
|
|
|
index_end = path.find(',')
|
|
if 0 <= index_end:
|
|
path = path[:index_end] # delete comma and anything after
|
|
index_end = path.find(':', 2)
|
|
if 0 <= index_end:
|
|
path = path[:path.find(':', 2)] # delete the line number and anything after
|
|
|
|
path = path.replace('\\', '/')
|
|
|
|
if 1 == path.find(':') and current_OS == 'Windows':
|
|
return path, line_num, column_num # found a full path - no need for further processing
|
|
elif 0 == path.find('/') and (current_OS == 'Linux' or current_OS == 'Darwin'):
|
|
return path, line_num, column_num # found a full path - no need for further processing
|
|
|
|
else:
|
|
|
|
# resolve as many '../' as we can
|
|
while 0 <= path.find('../'):
|
|
end = path.find('../') - 1
|
|
start = path.find('/')
|
|
while 0 <= path.find('/', start) and end > path.find('/', start):
|
|
start = path.find('/', start) + 1
|
|
path = path[0:start] + path[end + 4:]
|
|
|
|
# this is an alternative to the above - it just deletes the '../' section
|
|
# start_temp = path.find('../')
|
|
# while 0 <= path.find('../',start_temp):
|
|
# start = path.find('../',start_temp)
|
|
# start_temp = start + 1
|
|
# if 0 <= start:
|
|
# path = path[start + 2 : ]
|
|
|
|
start = path.find('/')
|
|
if start != 0: # make sure path starts with '/'
|
|
while 0 == path.find(' '): # eat any spaces at the beginning
|
|
path = path[1:]
|
|
path = '/' + path
|
|
|
|
if current_OS == 'Windows':
|
|
search_path = path.replace('/', '\\') # os.walk uses '\' in Windows
|
|
else:
|
|
search_path = path
|
|
|
|
start_path = os.path.abspath('')
|
|
|
|
# search project directory for the selection
|
|
found = False
|
|
full_path = ''
|
|
for root, directories, filenames in os.walk(start_path):
|
|
for filename in filenames:
|
|
if 0 <= root.find('.git'): # don't bother looking in this directory
|
|
break
|
|
full_path = os.path.join(root, filename)
|
|
if 0 <= full_path.find(search_path):
|
|
found = True
|
|
break
|
|
if found:
|
|
break
|
|
|
|
return full_path, line_num, column_num
|
|
|
|
# end - resolve_path
|
|
|
|
|
|
#
|
|
# Open the file in the preferred editor at the line & column number
|
|
# If the preferred editor isn't already running then it tries the next.
|
|
# If none are open then the system default is used.
|
|
#
|
|
# Editor order:
|
|
# 1. Notepad++ (Windows only)
|
|
# 2. Sublime Text
|
|
# 3. Atom
|
|
# 4. System default (opens at line 1, column 1 only)
|
|
#
|
|
def open_file(path):
|
|
import subprocess
|
|
file_path, line_num, column_num = resolve_path(path)
|
|
|
|
if file_path == '':
|
|
return
|
|
|
|
if current_OS == 'Windows':
|
|
|
|
editor_note = subprocess.check_output('wmic process where "name=' + "'notepad++.exe'" + '" get ExecutablePath')
|
|
editor_sublime = subprocess.check_output('wmic process where "name=' + "'sublime_text.exe'" + '" get ExecutablePath')
|
|
editor_atom = subprocess.check_output('wmic process where "name=' + "'atom.exe'" + '" get ExecutablePath')
|
|
|
|
if 0 <= editor_note.find('notepad++.exe'):
|
|
start = editor_note.find('\n') + 1
|
|
end = editor_note.find('\n', start + 5) - 4
|
|
editor_note = editor_note[start:end]
|
|
command = file_path, ' -n' + str(line_num), ' -c' + str(column_num)
|
|
subprocess.Popen([editor_note, command])
|
|
|
|
elif 0 <= editor_sublime.find('sublime_text.exe'):
|
|
start = editor_sublime.find('\n') + 1
|
|
end = editor_sublime.find('\n', start + 5) - 4
|
|
editor_sublime = editor_sublime[start:end]
|
|
command = file_path + ':' + line_num + ':' + column_num
|
|
subprocess.Popen([editor_sublime, command])
|
|
|
|
elif 0 <= editor_atom.find('atom.exe'):
|
|
start = editor_atom.find('\n') + 1
|
|
end = editor_atom.find('\n', start + 5) - 4
|
|
editor_atom = editor_atom[start:end]
|
|
command = file_path + ':' + str(line_num) + ':' + str(column_num)
|
|
subprocess.Popen([editor_atom, command])
|
|
|
|
else:
|
|
os.startfile(resolve_path(path)) # open file with default app
|
|
|
|
elif current_OS == 'Linux':
|
|
|
|
command = file_path + ':' + str(line_num) + ':' + str(column_num)
|
|
index_end = command.find(',')
|
|
if 0 <= index_end:
|
|
command = command[:index_end] # sometimes a comma magically appears, don't want it
|
|
running_apps = subprocess.Popen('ps ax -o cmd', stdout=subprocess.PIPE, shell=True)
|
|
(output, err) = running_apps.communicate()
|
|
temp = output.split('\n')
|
|
|
|
def find_editor_linux(name, search_obj):
|
|
for line in search_obj:
|
|
if 0 <= line.find(name):
|
|
path = line
|
|
return True, path
|
|
return False, ''
|
|
|
|
(success_sublime, editor_path_sublime) = find_editor_linux('sublime_text', temp)
|
|
(success_atom, editor_path_atom) = find_editor_linux('atom', temp)
|
|
|
|
if success_sublime:
|
|
subprocess.Popen([editor_path_sublime, command])
|
|
|
|
elif success_atom:
|
|
subprocess.Popen([editor_path_atom, command])
|
|
|
|
else:
|
|
os.system('xdg-open ' + file_path)
|
|
|
|
elif current_OS == 'Darwin': # MAC
|
|
|
|
command = file_path + ':' + str(line_num) + ':' + str(column_num)
|
|
index_end = command.find(',')
|
|
if 0 <= index_end:
|
|
command = command[:index_end] # sometimes a comma magically appears, don't want it
|
|
running_apps = subprocess.Popen('ps axwww -o command', stdout=subprocess.PIPE, shell=True)
|
|
(output, err) = running_apps.communicate()
|
|
temp = output.split('\n')
|
|
|
|
def find_editor_mac(name, search_obj):
|
|
for line in search_obj:
|
|
if 0 <= line.find(name):
|
|
path = line
|
|
if 0 <= path.find('-psn'):
|
|
path = path[:path.find('-psn') - 1]
|
|
return True, path
|
|
return False, ''
|
|
|
|
(success_sublime, editor_path_sublime) = find_editor_mac('Sublime', temp)
|
|
(success_atom, editor_path_atom) = find_editor_mac('Atom', temp)
|
|
|
|
if success_sublime:
|
|
subprocess.Popen([editor_path_sublime, command])
|
|
|
|
elif success_atom:
|
|
subprocess.Popen([editor_path_atom, command])
|
|
|
|
else:
|
|
os.system('open ' + file_path)
|
|
|
|
# end - open_file
|
|
|
|
|
|
# Get the last build environment
|
|
def get_build_last():
|
|
env_last = ''
|
|
DIR_PWD = os.listdir('.')
|
|
if '.pio' in DIR_PWD:
|
|
date_last = 0.0
|
|
DIR__pioenvs = os.listdir('.pio')
|
|
for name in DIR__pioenvs:
|
|
if 0 <= name.find('.') or 0 <= name.find('-'): # skip files in listing
|
|
continue
|
|
DIR_temp = os.listdir('.pio/build/' + name)
|
|
for names_temp in DIR_temp:
|
|
|
|
if 0 == names_temp.find('firmware.'):
|
|
date_temp = os.path.getmtime('.pio/build/' + name + '/' + names_temp)
|
|
if date_temp > date_last:
|
|
date_last = date_temp
|
|
env_last = name
|
|
return env_last
|
|
|
|
|
|
# Get the board being built from the Configuration.h file
|
|
# return: board name, major version of Marlin being used (1 or 2)
|
|
def get_board_name():
|
|
board_name = ''
|
|
# get board name
|
|
|
|
with open('Marlin/Configuration.h', 'r') as myfile:
|
|
Configuration_h = myfile.read()
|
|
|
|
Configuration_h = Configuration_h.split('\n')
|
|
Marlin_ver = 0 # set version to invalid number
|
|
for lines in Configuration_h:
|
|
if 0 == lines.find('#define CONFIGURATION_H_VERSION 01'):
|
|
Marlin_ver = 1
|
|
if 0 == lines.find('#define CONFIGURATION_H_VERSION 02'):
|
|
Marlin_ver = 2
|
|
board = lines.find(' BOARD_') + 1
|
|
motherboard = lines.find(' MOTHERBOARD ') + 1
|
|
define = lines.find('#define ')
|
|
comment = lines.find('//')
|
|
if (comment == -1 or comment > board) and \
|
|
board > motherboard and \
|
|
motherboard > define and \
|
|
define >= 0 :
|
|
spaces = lines.find(' ', board) # find the end of the board substring
|
|
if spaces == -1:
|
|
board_name = lines[board:]
|
|
else:
|
|
board_name = lines[board:spaces]
|
|
break
|
|
|
|
return board_name, Marlin_ver
|
|
|
|
|
|
# extract first environment name found after the start position
|
|
# return: environment name and position to start the next search from
|
|
def get_env_from_line(line, start_position):
|
|
env = ''
|
|
next_position = -1
|
|
env_position = line.find('env:', start_position)
|
|
if 0 < env_position:
|
|
next_position = line.find(' ', env_position + 4)
|
|
if 0 < next_position:
|
|
env = line[env_position + 4:next_position]
|
|
else:
|
|
env = line[env_position + 4:] # at the end of the line
|
|
return env, next_position
|
|
|
|
|
|
def invalid_board():
|
|
print('ERROR - invalid board')
|
|
print(board_name)
|
|
raise SystemExit(0) # quit if unable to find board
|
|
|
|
# scan pins.h for board name and return the environment(s) found
|
|
def get_starting_env(board_name_full, version):
|
|
# get environment starting point
|
|
|
|
if version == 1:
|
|
path = 'Marlin/pins.h'
|
|
if version == 2:
|
|
path = 'Marlin/src/pins/pins.h'
|
|
with open(path, 'r') as myfile:
|
|
pins_h = myfile.read()
|
|
|
|
board_name = board_name_full[6:] # only use the part after "BOARD_" since we're searching the pins.h file
|
|
pins_h = pins_h.split('\n')
|
|
list_start_found = False
|
|
possible_envs = None
|
|
for i, line in enumerate(pins_h):
|
|
if 0 < line.find("Unknown MOTHERBOARD value set in Configuration.h"):
|
|
invalid_board();
|
|
if list_start_found == False and 0 < line.find('1280'):
|
|
list_start_found = True
|
|
elif list_start_found == False: # skip lines until find start of CPU list
|
|
continue
|
|
|
|
# Use a regex to find the board. Make sure it is surrounded by separators so the full boardname
|
|
# will be matched, even if multiple exist in a single MB macro. This avoids problems with boards
|
|
# such as MALYAN_M200 and MALYAN_M200_V2 where one board is a substring of the other.
|
|
if re.search(r'MB.*[\(, ]' + board_name + r'[, \)]', line):
|
|
# need to look at the next line for environment info
|
|
possible_envs = re.findall(r'env:([^ ]+)', pins_h[i + 1])
|
|
break
|
|
return possible_envs
|
|
|
|
|
|
# get environment to be used for the build
|
|
# return: environment
|
|
def get_env(board_name, ver_Marlin):
|
|
|
|
def no_environment():
|
|
print('ERROR - no environment for this board')
|
|
print(board_name)
|
|
raise SystemExit(0) # no environment so quit
|
|
|
|
possible_envs = get_starting_env(board_name, ver_Marlin)
|
|
|
|
if not possible_envs:
|
|
no_environment()
|
|
|
|
# Proceed to ask questions based on the available environments to filter down to a smaller list.
|
|
# If more then one remains after this filtering the user will be prompted to choose between
|
|
# all remaining options.
|
|
|
|
# Filter selection based on CPU choice
|
|
CPU_questions = [
|
|
{'options':['1280', '2560'], 'text':'1280 or 2560 CPU?', 'default':2},
|
|
{'options':['644', '1284'], 'text':'644 or 1284 CPU?', 'default':2},
|
|
{'options':['STM32F103RC', 'STM32F103RE'], 'text':'MCU Type?', 'default':1}]
|
|
|
|
for question in CPU_questions:
|
|
if any(question['options'][0] in env for env in possible_envs) and any(question['options'][1] in env for env in possible_envs):
|
|
get_answer(board_name, question['text'], [question['options'][0], question['options'][1]], question['default'])
|
|
possible_envs = [env for env in possible_envs if question['options'][get_answer_val - 1] in env]
|
|
|
|
# Choose which STM32 framework to use, if both are available
|
|
if [env for env in possible_envs if '_maple' in env] and [env for env in possible_envs if '_maple' not in env]:
|
|
get_answer(board_name, 'Which STM32 Framework should be used?', ['ST STM32 (Preferred)', 'Maple (Deprecated)'])
|
|
if 1 == get_answer_val:
|
|
possible_envs = [env for env in possible_envs if '_maple' not in env]
|
|
else:
|
|
possible_envs = [env for env in possible_envs if '_maple' in env]
|
|
|
|
# Both USB and non-USB STM32 options exist, filter based on these
|
|
if any('STM32F103R' in env for env in possible_envs) and any('_USB' in env for env in possible_envs) and any('_USB' not in env for env in possible_envs):
|
|
get_answer(board_name, 'USB Support?', ['USB', 'No USB'])
|
|
if 1 == get_answer_val:
|
|
possible_envs = [env for env in possible_envs if '_USB' in env]
|
|
else:
|
|
possible_envs = [env for env in possible_envs if '_USB' not in env]
|
|
|
|
if not possible_envs:
|
|
no_environment()
|
|
if len(possible_envs) == 1:
|
|
return possible_envs[0] # only one environment so finished
|
|
|
|
target_env = None
|
|
|
|
# A few environments require special behavior
|
|
if 'LPC1768' in possible_envs:
|
|
if build_type == 'traceback' or (build_type == 'clean' and get_build_last() == 'LPC1768_debug_and_upload'):
|
|
target_env = 'LPC1768_debug_and_upload'
|
|
else:
|
|
target_env = 'LPC1768'
|
|
elif 'DUE' in possible_envs:
|
|
target_env = 'DUE'
|
|
if build_type == 'traceback' or (build_type == 'clean' and get_build_last() == 'DUE_debug'):
|
|
target_env = 'DUE_debug'
|
|
elif 'DUE_USB' in possible_envs:
|
|
get_answer(board_name, 'DUE Download Port?', ['(Native) USB port', 'Programming port'])
|
|
if 1 == get_answer_val:
|
|
target_env = 'DUE_USB'
|
|
else:
|
|
target_env = 'DUE'
|
|
else:
|
|
options = possible_envs
|
|
# Perform some substitutions for environment names which follow a consistent
|
|
# naming pattern and are very commonly used. This is fragile code, and replacements
|
|
# should only be made here for stable environments unlikely to change often.
|
|
for i, option in enumerate(options):
|
|
if 'melzi' in option:
|
|
options[i] = 'Melzi'
|
|
elif 'sanguino1284p' in option:
|
|
options[i] = 'sanguino1284p'
|
|
if 'optiboot' in option:
|
|
options[i] = options[i] + ' (Optiboot Bootloader)'
|
|
if 'optimized' in option:
|
|
options[i] = options[i] + ' (Optimized for Size)'
|
|
get_answer(board_name, 'Which environment?', options)
|
|
target_env = possible_envs[get_answer_val - 1]
|
|
|
|
if build_type == 'traceback' and target_env != 'LPC1768_debug_and_upload' and target_env != 'DUE_debug' and Marlin_ver == 2:
|
|
print("ERROR - this board isn't setup for traceback")
|
|
print('board_name: ', board_name)
|
|
print('target_env: ', target_env)
|
|
raise SystemExit(0)
|
|
|
|
return target_env
|
|
|
|
# end - get_env
|
|
|
|
|
|
# puts screen text into queue so that the parent thread can fetch the data from this thread
|
|
if python_ver == 2:
|
|
import Queue as queue
|
|
else:
|
|
import queue as queue
|
|
IO_queue = queue.Queue()
|
|
|
|
|
|
#PIO_queue = queue.Queue() not used!
|
|
def write_to_screen_queue(text, format_tag='normal'):
|
|
double_in = [text, format_tag]
|
|
IO_queue.put(double_in, block=False)
|
|
|
|
|
|
#
|
|
# send one line to the terminal screen with syntax highlighting
|
|
#
|
|
# input: unformatted text, flags from previous run
|
|
# return: formatted text ready to go to the terminal, flags from this run
|
|
#
|
|
# This routine remembers the status from call to call because previous
|
|
# lines can affect how the current line is highlighted
|
|
#
|
|
|
|
# 'static' variables - init here and then keep updating them from within print_line
|
|
warning = False
|
|
warning_FROM = False
|
|
error = False
|
|
standard = True
|
|
prev_line_COM = False
|
|
next_line_warning = False
|
|
warning_continue = False
|
|
line_counter = 0
|
|
|
|
|
|
def line_print(line_input):
|
|
|
|
global warning
|
|
global warning_FROM
|
|
global error
|
|
global standard
|
|
global prev_line_COM
|
|
global next_line_warning
|
|
global warning_continue
|
|
global line_counter
|
|
|
|
# all '0' elements must precede all '1' elements or they'll be skipped
|
|
platformio_highlights = [
|
|
['Environment', 0, 'highlight_blue'], ['[SKIP]', 1, 'warning'], ['[IGNORED]', 1, 'warning'], ['[ERROR]', 1, 'error'],
|
|
['[FAILED]', 1, 'error'], ['[SUCCESS]', 1, 'highlight_green']
|
|
]
|
|
|
|
def write_to_screen_with_replace(text, highlights): # search for highlights & split line accordingly
|
|
did_something = False
|
|
for highlight in highlights:
|
|
found = text.find(highlight[0])
|
|
if did_something == True:
|
|
break
|
|
if found >= 0:
|
|
did_something = True
|
|
if 0 == highlight[1]:
|
|
found_1 = text.find(' ')
|
|
found_tab = text.find('\t')
|
|
if found_1 < 0 or found_1 > found_tab:
|
|
found_1 = found_tab
|
|
write_to_screen_queue(text[:found_1 + 1])
|
|
for highlight_2 in highlights:
|
|
if highlight[0] == highlight_2[0]:
|
|
continue
|
|
found = text.find(highlight_2[0])
|
|
if found >= 0:
|
|
found_space = text.find(' ', found_1 + 1)
|
|
found_tab = text.find('\t', found_1 + 1)
|
|
if found_space < 0 or found_space > found_tab:
|
|
found_space = found_tab
|
|
found_right = text.find(']', found + 1)
|
|
write_to_screen_queue(text[found_1 + 1:found_space + 1], highlight[2])
|
|
write_to_screen_queue(text[found_space + 1:found + 1])
|
|
write_to_screen_queue(text[found + 1:found_right], highlight_2[2])
|
|
write_to_screen_queue(text[found_right:] + '\n')
|
|
break
|
|
break
|
|
if 1 == highlight[1]:
|
|
found_right = text.find(']', found + 1)
|
|
write_to_screen_queue(text[:found + 1])
|
|
write_to_screen_queue(text[found + 1:found_right], highlight[2])
|
|
write_to_screen_queue(text[found_right:] + '\n' + '\n')
|
|
break
|
|
if did_something == False:
|
|
r_loc = text.find('\r') + 1
|
|
if r_loc > 0 and r_loc < len(text): # need to split this line
|
|
text = text.split('\r')
|
|
for line in text:
|
|
if line != '':
|
|
write_to_screen_queue(line + '\n')
|
|
else:
|
|
write_to_screen_queue(text + '\n')
|
|
|
|
# end - write_to_screen_with_replace
|
|
|
|
# scan the line
|
|
line_counter = line_counter + 1
|
|
max_search = len(line_input)
|
|
if max_search > 3:
|
|
max_search = 3
|
|
beginning = line_input[:max_search]
|
|
|
|
# set flags
|
|
if 0 < line_input.find(': warning: '): # start of warning block
|
|
warning = True
|
|
warning_FROM = False
|
|
error = False
|
|
standard = False
|
|
prev_line_COM = False
|
|
prev_line_COM = False
|
|
warning_continue = True
|
|
if 0 < line_input.find('Thank you') or 0 < line_input.find('SUMMARY'):
|
|
warning = False #standard line found
|
|
warning_FROM = False
|
|
error = False
|
|
standard = True
|
|
prev_line_COM = False
|
|
warning_continue = False
|
|
elif beginning == 'War' or \
|
|
beginning == '#er' or \
|
|
beginning == 'In ' or \
|
|
(beginning != 'Com' and prev_line_COM == True and not(beginning == 'Arc' or beginning == 'Lin' or beginning == 'Ind') or \
|
|
next_line_warning == True):
|
|
warning = True #warning found
|
|
warning_FROM = False
|
|
error = False
|
|
standard = False
|
|
prev_line_COM = False
|
|
elif beginning == 'Com' or \
|
|
beginning == 'Ver' or \
|
|
beginning == ' [E' or \
|
|
beginning == 'Rem' or \
|
|
beginning == 'Bui' or \
|
|
beginning == 'Ind' or \
|
|
beginning == 'PLA':
|
|
warning = False #standard line found
|
|
warning_FROM = False
|
|
error = False
|
|
standard = True
|
|
prev_line_COM = False
|
|
warning_continue = False
|
|
elif beginning == '***':
|
|
warning = False # error found
|
|
warning_FROM = False
|
|
error = True
|
|
standard = False
|
|
prev_line_COM = False
|
|
elif 0 < line_input.find(': error:') or \
|
|
0 < line_input.find(': fatal error:'): # start of warning /error block
|
|
warning = False # error found
|
|
warning_FROM = False
|
|
error = True
|
|
standard = False
|
|
prev_line_COM = False
|
|
warning_continue = True
|
|
elif beginning == 'fro' and warning == True or \
|
|
beginning == '.pi' : # start of warning /error block
|
|
warning_FROM = True
|
|
prev_line_COM = False
|
|
warning_continue = True
|
|
elif warning_continue == True:
|
|
warning = True
|
|
warning_FROM = False # keep the warning status going until find a standard line or an error
|
|
error = False
|
|
standard = False
|
|
prev_line_COM = False
|
|
warning_continue = True
|
|
|
|
else:
|
|
warning = False # unknown so assume standard line
|
|
warning_FROM = False
|
|
error = False
|
|
standard = True
|
|
prev_line_COM = False
|
|
warning_continue = False
|
|
|
|
if beginning == 'Com':
|
|
prev_line_COM = True
|
|
|
|
# print based on flags
|
|
if standard == True:
|
|
write_to_screen_with_replace(line_input, platformio_highlights) #print white on black with substitutions
|
|
if warning == True:
|
|
write_to_screen_queue(line_input + '\n', 'warning')
|
|
if error == True:
|
|
write_to_screen_queue(line_input + '\n', 'error')
|
|
|
|
# end - line_print
|
|
|
|
|
|
##########################################################################
|
|
# #
|
|
# run Platformio #
|
|
# #
|
|
##########################################################################
|
|
|
|
# build platformio run -e target_env
|
|
# clean platformio run --target clean -e target_env
|
|
# upload platformio run --target upload -e target_env
|
|
# traceback platformio run --target upload -e target_env
|
|
# program platformio run --target program -e target_env
|
|
# test platformio test upload -e target_env
|
|
# remote platformio remote run --target upload -e target_env
|
|
# debug platformio debug -e target_env
|
|
|
|
|
|
def sys_PIO():
|
|
|
|
##########################################################################
|
|
# #
|
|
# run Platformio inside the same shell as this Python script #
|
|
# #
|
|
##########################################################################
|
|
|
|
global build_type
|
|
global target_env
|
|
|
|
import os
|
|
|
|
print('build_type: ', build_type)
|
|
print('starting platformio')
|
|
|
|
if build_type == 'build':
|
|
# pio_result = os.system("echo -en '\033c'")
|
|
pio_result = os.system('platformio run -e ' + target_env)
|
|
elif build_type == 'clean':
|
|
pio_result = os.system('platformio run --target clean -e ' + target_env)
|
|
elif build_type == 'upload':
|
|
pio_result = os.system('platformio run --target upload -e ' + target_env)
|
|
elif build_type == 'traceback':
|
|
pio_result = os.system('platformio run --target upload -e ' + target_env)
|
|
elif build_type == 'program':
|
|
pio_result = os.system('platformio run --target program -e ' + target_env)
|
|
elif build_type == 'test':
|
|
pio_result = os.system('platformio test upload -e ' + target_env)
|
|
elif build_type == 'remote':
|
|
pio_result = os.system('platformio remote run --target program -e ' + target_env)
|
|
elif build_type == 'debug':
|
|
pio_result = os.system('platformio debug -e ' + target_env)
|
|
else:
|
|
print('ERROR - unknown build type: ', build_type)
|
|
raise SystemExit(0) # kill everything
|
|
|
|
# stream output from subprocess and split it into lines
|
|
#for line in iter(pio_subprocess.stdout.readline, ''):
|
|
# line_print(line.replace('\n', ''))
|
|
|
|
# append info used to run PlatformIO
|
|
# write_to_screen_queue('\nBoard name: ' + board_name + '\n') # put build info at the bottom of the screen
|
|
# write_to_screen_queue('Build type: ' + build_type + '\n')
|
|
# write_to_screen_queue('Environment used: ' + target_env + '\n')
|
|
# write_to_screen_queue(str(datetime.now()) + '\n')
|
|
|
|
# end - sys_PIO
|
|
|
|
|
|
def run_PIO(dummy):
|
|
|
|
global build_type
|
|
global target_env
|
|
global board_name
|
|
print('build_type: ', build_type)
|
|
|
|
import subprocess
|
|
import sys
|
|
|
|
print('starting platformio')
|
|
|
|
if build_type == 'build':
|
|
# platformio run -e target_env
|
|
# combine stdout & stderr so all compile messages are included
|
|
pio_subprocess = subprocess.Popen(
|
|
['platformio', 'run', '-e', target_env], stdout=subprocess.PIPE, stderr=subprocess.STDOUT
|
|
)
|
|
|
|
elif build_type == 'clean':
|
|
# platformio run --target clean -e target_env
|
|
# combine stdout & stderr so all compile messages are included
|
|
pio_subprocess = subprocess.Popen(
|
|
['platformio', 'run', '--target', 'clean', '-e', target_env], stdout=subprocess.PIPE, stderr=subprocess.STDOUT
|
|
)
|
|
|
|
elif build_type == 'upload':
|
|
# platformio run --target upload -e target_env
|
|
# combine stdout & stderr so all compile messages are included
|
|
pio_subprocess = subprocess.Popen(
|
|
['platformio', 'run', '--target', 'upload', '-e', target_env], stdout=subprocess.PIPE, stderr=subprocess.STDOUT
|
|
)
|
|
|
|
elif build_type == 'traceback':
|
|
# platformio run --target upload -e target_env - select the debug environment if there is one
|
|
# combine stdout & stderr so all compile messages are included
|
|
pio_subprocess = subprocess.Popen(
|
|
['platformio', 'run', '--target', 'upload', '-e', target_env], stdout=subprocess.PIPE, stderr=subprocess.STDOUT
|
|
)
|
|
|
|
elif build_type == 'program':
|
|
# platformio run --target program -e target_env
|
|
# combine stdout & stderr so all compile messages are included
|
|
pio_subprocess = subprocess.Popen(
|
|
['platformio', 'run', '--target', 'program', '-e', target_env], stdout=subprocess.PIPE, stderr=subprocess.STDOUT
|
|
)
|
|
|
|
elif build_type == 'test':
|
|
#platformio test upload -e target_env
|
|
# combine stdout & stderr so all compile messages are included
|
|
pio_subprocess = subprocess.Popen(
|
|
['platformio', 'test', 'upload', '-e', target_env], stdout=subprocess.PIPE, stderr=subprocess.STDOUT
|
|
)
|
|
|
|
elif build_type == 'remote':
|
|
# platformio remote run --target upload -e target_env
|
|
# combine stdout & stderr so all compile messages are included
|
|
pio_subprocess = subprocess.Popen(
|
|
['platformio', 'remote', 'run', '--target', 'program', '-e', target_env],
|
|
stdout=subprocess.PIPE,
|
|
stderr=subprocess.STDOUT
|
|
)
|
|
|
|
elif build_type == 'debug':
|
|
# platformio debug -e target_env
|
|
# combine stdout & stderr so all compile messages are included
|
|
pio_subprocess = subprocess.Popen(
|
|
['platformio', 'debug', '-e', target_env], stdout=subprocess.PIPE, stderr=subprocess.STDOUT
|
|
)
|
|
|
|
else:
|
|
print('ERROR - unknown build type: ', build_type)
|
|
raise SystemExit(0) # kill everything
|
|
|
|
# stream output from subprocess and split it into lines
|
|
if python_ver == 2:
|
|
for line in iter(pio_subprocess.stdout.readline, ''):
|
|
line_print(line.replace('\n', ''))
|
|
else:
|
|
for line in iter(pio_subprocess.stdout.readline, b''):
|
|
line = line.decode('utf-8')
|
|
line_print(line.replace('\n', ''))
|
|
|
|
# append info used to run PlatformIO
|
|
write_to_screen_queue('\nBoard name: ' + board_name + '\n') # put build info at the bottom of the screen
|
|
write_to_screen_queue('Build type: ' + build_type + '\n')
|
|
write_to_screen_queue('Environment used: ' + target_env + '\n')
|
|
write_to_screen_queue(str(datetime.now()) + '\n')
|
|
|
|
# end - run_PIO
|
|
|
|
########################################################################
|
|
|
|
import time
|
|
import threading
|
|
if python_ver == 2:
|
|
import Tkinter as tk
|
|
import Queue as queue
|
|
import ttk
|
|
from Tkinter import Tk, Frame, Text, Scrollbar, Menu
|
|
#from tkMessageBox import askokcancel this is not used: removed
|
|
import tkFileDialog as fileDialog
|
|
else:
|
|
import tkinter as tk
|
|
import queue as queue
|
|
from tkinter import ttk, Tk, Frame, Text, Menu
|
|
import subprocess
|
|
import sys
|
|
que = queue.Queue()
|
|
#IO_queue = queue.Queue()
|
|
|
|
|
|
class output_window(Text):
|
|
# based on Super Text
|
|
global continue_updates
|
|
continue_updates = True
|
|
|
|
global search_position
|
|
search_position = '' # start with invalid search position
|
|
|
|
global error_found
|
|
error_found = False # are there any errors?
|
|
|
|
def __init__(self):
|
|
|
|
self.root = tk.Tk()
|
|
self.root.attributes("-topmost", True)
|
|
self.frame = tk.Frame(self.root)
|
|
self.frame.pack(fill='both', expand=True)
|
|
|
|
# text widget
|
|
#self.text = tk.Text(self.frame, borderwidth=3, relief="sunken")
|
|
Text.__init__(self, self.frame, borderwidth=3, relief="sunken")
|
|
self.config(tabs=(400, )) # configure Text widget tab stops
|
|
self.config(background='black', foreground='white', font=("consolas", 12), wrap='word', undo='True')
|
|
#self.config(background = 'black', foreground = 'white', font= ("consolas", 12), wrap = 'none', undo = 'True')
|
|
self.config(height=24, width=100)
|
|
self.config(insertbackground='pale green') # keyboard insertion point
|
|
self.pack(side='left', fill='both', expand=True)
|
|
|
|
self.tag_config('normal', foreground='white')
|
|
self.tag_config('warning', foreground='yellow')
|
|
self.tag_config('error', foreground='red')
|
|
self.tag_config('highlight_green', foreground='green')
|
|
self.tag_config('highlight_blue', foreground='cyan')
|
|
self.tag_config('error_highlight_inactive', background='dim gray')
|
|
self.tag_config('error_highlight_active', background='light grey')
|
|
|
|
self.bind_class("Text", "<Control-a>", self.select_all) # required in windows, works in others
|
|
self.bind_all("<Control-Shift-E>", self.scroll_errors)
|
|
self.bind_class("<Control-Shift-R>", self.rebuild)
|
|
|
|
# scrollbar
|
|
|
|
scrb = tk.Scrollbar(self.frame, orient='vertical', command=self.yview)
|
|
self.config(yscrollcommand=scrb.set)
|
|
scrb.pack(side='right', fill='y')
|
|
|
|
#self.scrb_Y = tk.Scrollbar(self.frame, orient='vertical', command=self.yview)
|
|
#self.scrb_Y.config(yscrollcommand=self.scrb_Y.set)
|
|
#self.scrb_Y.pack(side='right', fill='y')
|
|
|
|
#self.scrb_X = tk.Scrollbar(self.frame, orient='horizontal', command=self.xview)
|
|
#self.scrb_X.config(xscrollcommand=self.scrb_X.set)
|
|
#self.scrb_X.pack(side='bottom', fill='x')
|
|
|
|
#scrb_X = tk.Scrollbar(self, orient=tk.HORIZONTAL, command=self.xview) # tk.HORIZONTAL now have a horizsontal scroll bar BUT... shrinks it to a postage stamp and hides far right behind the vertical scroll bar
|
|
#self.config(xscrollcommand=scrb_X.set)
|
|
#scrb_X.pack(side='bottom', fill='x')
|
|
|
|
#scrb= tk.Scrollbar(self, orient='vertical', command=self.yview)
|
|
#self.config(yscrollcommand=scrb.set)
|
|
#scrb.pack(side='right', fill='y')
|
|
|
|
#self.config(height = 240, width = 1000) # didn't get the size baCK TO NORMAL
|
|
#self.pack(side='left', fill='both', expand=True) # didn't get the size baCK TO NORMAL
|
|
|
|
# pop-up menu
|
|
self.popup = tk.Menu(self, tearoff=0)
|
|
|
|
self.popup.add_command(label='Copy', command=self._copy)
|
|
self.popup.add_command(label='Paste', command=self._paste)
|
|
self.popup.add_separator()
|
|
self.popup.add_command(label='Cut', command=self._cut)
|
|
self.popup.add_separator()
|
|
self.popup.add_command(label='Select All', command=self._select_all)
|
|
self.popup.add_command(label='Clear All', command=self._clear_all)
|
|
self.popup.add_separator()
|
|
self.popup.add_command(label='Save As', command=self._file_save_as)
|
|
self.popup.add_separator()
|
|
#self.popup.add_command(label='Repeat Build(CTL-shift-r)', command=self._rebuild)
|
|
self.popup.add_command(label='Repeat Build', command=self._rebuild)
|
|
self.popup.add_separator()
|
|
self.popup.add_command(label='Scroll Errors (CTL-shift-e)', command=self._scroll_errors)
|
|
self.popup.add_separator()
|
|
self.popup.add_command(label='Open File at Cursor', command=self._open_selected_file)
|
|
|
|
if current_OS == 'Darwin': # MAC
|
|
self.bind('<Button-2>', self._show_popup) # macOS only
|
|
else:
|
|
self.bind('<Button-3>', self._show_popup) # Windows & Linux
|
|
|
|
# threading & subprocess section
|
|
|
|
def start_thread(self, ):
|
|
global continue_updates
|
|
# create then start a secondary thread to run an arbitrary function
|
|
# must have at least one argument
|
|
self.secondary_thread = threading.Thread(target=lambda q, arg1: q.put(run_PIO(arg1)), args=(que, ''))
|
|
self.secondary_thread.start()
|
|
continue_updates = True
|
|
# check the Queue in 50ms
|
|
self.root.after(50, self.check_thread)
|
|
self.root.after(50, self.update)
|
|
|
|
def check_thread(self): # wait for user to kill the window
|
|
global continue_updates
|
|
if continue_updates == True:
|
|
self.root.after(10, self.check_thread)
|
|
|
|
def update(self):
|
|
global continue_updates
|
|
if continue_updates == True:
|
|
self.root.after(10, self.update) #method is called every 50ms
|
|
temp_text = ['0', '0']
|
|
if IO_queue.empty():
|
|
if not (self.secondary_thread.is_alive()):
|
|
continue_updates = False # queue is exhausted and thread is dead so no need for further updates
|
|
else:
|
|
try:
|
|
temp_text = IO_queue.get(block=False)
|
|
except Queue.Empty:
|
|
continue_updates = False # queue is exhausted so no need for further updates
|
|
else:
|
|
self.insert('end', temp_text[0], temp_text[1])
|
|
self.see("end") # make the last line visible (scroll text off the top)
|
|
|
|
# text editing section
|
|
|
|
def _scroll_errors(self):
|
|
global search_position
|
|
global error_found
|
|
if search_position == '': # first time so highlight all errors
|
|
countVar = tk.IntVar()
|
|
search_position = '1.0'
|
|
search_count = 0
|
|
while search_position != '' and search_count < 100:
|
|
search_position = self.search("error", search_position, stopindex="end", count=countVar, nocase=1)
|
|
search_count = search_count + 1
|
|
if search_position != '':
|
|
error_found = True
|
|
end_pos = '{}+{}c'.format(search_position, 5)
|
|
self.tag_add("error_highlight_inactive", search_position, end_pos)
|
|
search_position = '{}+{}c'.format(search_position, 1) # point to the next character for new search
|
|
else:
|
|
break
|
|
|
|
if error_found:
|
|
if search_position == '':
|
|
search_position = self.search("error", '1.0', stopindex="end", nocase=1) # new search
|
|
else: # remove active highlight
|
|
end_pos = '{}+{}c'.format(search_position, 5)
|
|
start_pos = '{}+{}c'.format(search_position, -1)
|
|
self.tag_remove("error_highlight_active", start_pos, end_pos)
|
|
search_position = self.search(
|
|
"error", search_position, stopindex="end", nocase=1
|
|
) # finds first occurrence AGAIN on the first time through
|
|
if search_position == "": # wrap around
|
|
search_position = self.search("error", '1.0', stopindex="end", nocase=1)
|
|
end_pos = '{}+{}c'.format(search_position, 5)
|
|
self.tag_add("error_highlight_active", search_position, end_pos) # add active highlight
|
|
self.see(search_position)
|
|
search_position = '{}+{}c'.format(search_position, 1) # point to the next character for new search
|
|
|
|
def scroll_errors(self, event):
|
|
self._scroll_errors()
|
|
|
|
def _rebuild(self):
|
|
#global board_name
|
|
#global Marlin_ver
|
|
#global target_env
|
|
#board_name, Marlin_ver = get_board_name()
|
|
#target_env = get_env(board_name, Marlin_ver)
|
|
self.start_thread()
|
|
|
|
def rebuild(self, event):
|
|
print("event happened")
|
|
self._rebuild()
|
|
|
|
def _open_selected_file(self):
|
|
current_line = self.index('insert')
|
|
line_start = current_line[:current_line.find('.')] + '.0'
|
|
line_end = current_line[:current_line.find('.')] + '.200'
|
|
self.mark_set("path_start", line_start)
|
|
self.mark_set("path_end", line_end)
|
|
path = self.get("path_start", "path_end")
|
|
from_loc = path.find('from ')
|
|
colon_loc = path.find(': ')
|
|
if 0 <= from_loc and ((colon_loc == -1) or (from_loc < colon_loc)):
|
|
path = path[from_loc + 5:]
|
|
if 0 <= colon_loc:
|
|
path = path[:colon_loc]
|
|
if 0 <= path.find('\\') or 0 <= path.find('/'): # make sure it really contains a path
|
|
open_file(path)
|
|
|
|
def _file_save_as(self):
|
|
self.filename = fileDialog.asksaveasfilename(defaultextension='.txt')
|
|
f = open(self.filename, 'w')
|
|
f.write(self.get('1.0', 'end'))
|
|
f.close()
|
|
|
|
def copy(self, event):
|
|
try:
|
|
selection = self.get(*self.tag_ranges('sel'))
|
|
self.clipboard_clear()
|
|
self.clipboard_append(selection)
|
|
except TypeError:
|
|
pass
|
|
|
|
def cut(self, event):
|
|
try:
|
|
selection = self.get(*self.tag_ranges('sel'))
|
|
self.clipboard_clear()
|
|
self.clipboard_append(selection)
|
|
self.delete(*self.tag_ranges('sel'))
|
|
except TypeError:
|
|
pass
|
|
|
|
def _show_popup(self, event):
|
|
'''right-click popup menu'''
|
|
|
|
if self.root.focus_get() != self:
|
|
self.root.focus_set()
|
|
|
|
try:
|
|
self.popup.tk_popup(event.x_root, event.y_root, 0)
|
|
finally:
|
|
self.popup.grab_release()
|
|
|
|
def _cut(self):
|
|
try:
|
|
selection = self.get(*self.tag_ranges('sel'))
|
|
self.clipboard_clear()
|
|
self.clipboard_append(selection)
|
|
self.delete(*self.tag_ranges('sel'))
|
|
except TypeError:
|
|
pass
|
|
|
|
def cut(self, event):
|
|
self._cut()
|
|
|
|
def _copy(self):
|
|
|
|
try:
|
|
selection = self.get(*self.tag_ranges('sel'))
|
|
self.clipboard_clear()
|
|
self.clipboard_append(selection)
|
|
except TypeError:
|
|
pass
|
|
|
|
def copy(self, event):
|
|
self._copy()
|
|
|
|
def _paste(self):
|
|
self.insert('insert', self.selection_get(selection='CLIPBOARD'))
|
|
|
|
def _select_all(self):
|
|
self.tag_add('sel', '1.0', 'end')
|
|
|
|
def select_all(self, event):
|
|
self.tag_add('sel', '1.0', 'end')
|
|
|
|
def _clear_all(self):
|
|
#'''erases all text'''
|
|
#
|
|
#isok = askokcancel('Clear All', 'Erase all text?', frame=self,
|
|
# default='ok')
|
|
#if isok:
|
|
# self.delete('1.0', 'end')
|
|
self.delete('1.0', 'end')
|
|
|
|
# end - output_window
|
|
|
|
|
|
def main():
|
|
|
|
##########################################################################
|
|
# #
|
|
# main program #
|
|
# #
|
|
##########################################################################
|
|
|
|
global build_type
|
|
global target_env
|
|
global board_name
|
|
|
|
board_name, Marlin_ver = get_board_name()
|
|
|
|
target_env = get_env(board_name, Marlin_ver)
|
|
|
|
# Re-use the VSCode terminal, if possible
|
|
if os.environ.get('PLATFORMIO_CALLER', '') == 'vscode':
|
|
sys_PIO()
|
|
else:
|
|
auto_build = output_window()
|
|
auto_build.start_thread() # executes the "run_PIO" function
|
|
|
|
auto_build.root.mainloop()
|
|
|
|
|
|
if __name__ == '__main__':
|
|
|
|
main()
|