From 9263f3a912658a7474e7f866ee87bd41fe778e1c Mon Sep 17 00:00:00 2001 From: Bassam Husain Date: Wed, 8 Mar 2023 03:05:33 -0500 Subject: [PATCH] Implemented TEMPERATURE_WAIT in macros. NOTE: users should pull these changes. --- README.md | 9 +++++---- cfgs/macros.cfg | 22 ++++++++++++++++++++++ 2 files changed, 27 insertions(+), 4 deletions(-) diff --git a/README.md b/README.md index 5851b0a..70a8bc6 100644 --- a/README.md +++ b/README.md @@ -1,6 +1,6 @@ # 🚨 *One-Stop-Shop* Sovol SV06 Klipper Configuration -This repository contains the Klipper configuration and firmware for the Sovol SV06 3D printer. +This repository contains the Klipper configuration and firmware for the Sovol SV06 3D printer with completely *stock hardware*. I am creating these files for my personal use and cannot be held responsible for what it might do to your printer. @@ -19,14 +19,15 @@ I am creating these files for my personal use and cannot be held responsible for - Load/unload filament macros. - Purge line macro. -To do: +## To do: -- [ ] Replace M109/M190 with `TEMPERATURE_WAIT`. +- [x] Replace M109/M190 with `TEMPERATURE_WAIT`. - [ ] Get the Ellis `TEST_SPEED` macro working. - [x] Add information about directory structure. - [ ] Create FAQ section. +- [x] Get filament sensor working with hotend PCB. - [ ] Finalize filament sensor config and merge into `master`. -- [ ] Create topic in Discussion section detailing how users should keep track of their own Klipper config using `git`. +- [ ] Create topic in Discussion section detailing how users should keep this repository in sync with their own Klipper config using `git`. ## Stay Up-to-Date diff --git a/cfgs/macros.cfg b/cfgs/macros.cfg index 7962d60..f762c09 100644 --- a/cfgs/macros.cfg +++ b/cfgs/macros.cfg @@ -13,6 +13,28 @@ gcode: {action_raise_error('Pre purge prime length not found')} {% endif %} +[gcode_macro M109] +rename_existing: M99109 +gcode: + #Parameters + {% set s = params.S|float %} + + M104 {% for p in params %}{'%s%s' % (p, params[p])}{% endfor %} ; Set hotend temp + {% if s != 0 %} + TEMPERATURE_WAIT SENSOR=extruder MINIMUM={s} MAXIMUM={s+1} ; Wait for hotend temp (within 1 degree) + {% endif %} + +[gcode_macro M190] +rename_existing: M99190 +gcode: + #Parameters + {% set s = params.S|float %} + + M140 {% for p in params %}{'%s%s' % (p, params[p])}{% endfor %} ; Set bed temp + {% if s != 0 %} + TEMPERATURE_WAIT SENSOR=heater_bed MINIMUM={s} MAXIMUM={s+1} ; Wait for bed temp (within 1 degree) + {% endif %} + [gcode_macro PURGE_LINE] # https://github.com/JoeCat1207/V0.1-Purge-line-SuperSlicer/blob/main/Purgeline.txt # https://github.com/VoronDesign/Voron-Switchwire/blob/200cdae033c59ef81f67c4235469da7ca66d53a1/Firmware/skr_mini_e3_v2_config.cfg