Browse Source

Merge pull request #7992 from thinkyhead/bf2_M106_memorize

[2.0.x] Add EXTRA_FAN_SPEED feature
pull/1/head
Scott Lahteine 7 years ago
committed by GitHub
parent
commit
02f2979760
  1. 9
      Marlin/Configuration_adv.h
  2. 4
      Marlin/src/Marlin.cpp
  3. 4
      Marlin/src/Marlin.h
  4. 9
      Marlin/src/config/default/Configuration_adv.h
  5. 9
      Marlin/src/config/examples/AlephObjects/TAZ4/Configuration_adv.h
  6. 9
      Marlin/src/config/examples/Anet/A6/Configuration_adv.h
  7. 9
      Marlin/src/config/examples/Anet/A8/Configuration_adv.h
  8. 9
      Marlin/src/config/examples/BQ/Hephestos/Configuration_adv.h
  9. 9
      Marlin/src/config/examples/BQ/Hephestos_2/Configuration_adv.h
  10. 9
      Marlin/src/config/examples/BQ/WITBOX/Configuration_adv.h
  11. 9
      Marlin/src/config/examples/Cartesio/Configuration_adv.h
  12. 9
      Marlin/src/config/examples/Creality/CR-10/Configuration_adv.h
  13. 9
      Marlin/src/config/examples/Felix/Configuration_adv.h
  14. 9
      Marlin/src/config/examples/Folger Tech/i3-2020/Configuration_adv.h
  15. 9
      Marlin/src/config/examples/Infitary/i3-M508/Configuration_adv.h
  16. 9
      Marlin/src/config/examples/Malyan/M150/Configuration_adv.h
  17. 9
      Marlin/src/config/examples/Mks/Sbase/Configuration_adv.h
  18. 9
      Marlin/src/config/examples/RigidBot/Configuration_adv.h
  19. 9
      Marlin/src/config/examples/SCARA/Configuration_adv.h
  20. 9
      Marlin/src/config/examples/Sanguinololu/Configuration_adv.h
  21. 9
      Marlin/src/config/examples/TinyBoy2/Configuration_adv.h
  22. 9
      Marlin/src/config/examples/Velleman/K8200/Configuration_adv.h
  23. 9
      Marlin/src/config/examples/Velleman/K8400/Configuration_adv.h
  24. 9
      Marlin/src/config/examples/delta/FLSUN/auto_calibrate/Configuration_adv.h
  25. 9
      Marlin/src/config/examples/delta/FLSUN/kossel_mini/Configuration_adv.h
  26. 9
      Marlin/src/config/examples/delta/generic/Configuration_adv.h
  27. 9
      Marlin/src/config/examples/delta/kossel_mini/Configuration_adv.h
  28. 9
      Marlin/src/config/examples/delta/kossel_pro/Configuration_adv.h
  29. 9
      Marlin/src/config/examples/delta/kossel_xl/Configuration_adv.h
  30. 9
      Marlin/src/config/examples/gCreate/gMax1.5+/Configuration_adv.h
  31. 9
      Marlin/src/config/examples/makibox/Configuration_adv.h
  32. 9
      Marlin/src/config/examples/tvrrug/Round2/Configuration_adv.h
  33. 9
      Marlin/src/config/examples/wt150/Configuration_adv.h
  34. 4
      Marlin/src/gcode/gcode.h
  35. 35
      Marlin/src/gcode/temperature/M106_M107.cpp
  36. 3
      Marlin/src/lcd/language/language_en.h
  37. 37
      Marlin/src/lcd/ultralcd.cpp

9
Marlin/Configuration_adv.h

@ -825,6 +825,15 @@
#define RETRACT_RECOVER_FEEDRATE_SWAP 8 // Default feedrate for recovering from swap retraction (mm/s)
#endif
/**
* Extra Fan Speed
* Adds a secondary fan speed for each print-cooling fan.
* 'M106 P<fan> T3-255' : Set a secondary speed for <fan>
* 'M106 P<fan> T2' : Use the set secondary speed
* 'M106 P<fan> T1' : Restore the previous fan speed
*/
//#define EXTRA_FAN_SPEED
/**
* Advanced Pause
* Experimental feature for filament change support and for parking the nozzle when paused.

4
Marlin/src/Marlin.cpp

@ -165,6 +165,10 @@ bool axis_homed[XYZ] = { false }, axis_known_position[XYZ] = { false };
#if FAN_COUNT > 0
int16_t fanSpeeds[FAN_COUNT] = { 0 };
#if ENABLED(EXTRA_FAN_SPEEDS)
int16_t old_fanSpeeds[FAN_COUNT],
new_fanSpeeds[FAN_COUNT];
#endif
#if ENABLED(PROBING_FANS_OFF)
bool fans_paused = false;
int16_t paused_fanSpeeds[FAN_COUNT] = { 0 };

4
Marlin/src/Marlin.h

@ -198,6 +198,10 @@ extern millis_t max_inactive_time, stepper_inactive_time;
#if FAN_COUNT > 0
extern int16_t fanSpeeds[FAN_COUNT];
#if ENABLED(EXTRA_FAN_SPEEDS)
extern int16_t old_fanSpeeds[FAN_COUNT],
new_fanSpeeds[FAN_COUNT];
#endif
#if ENABLED(PROBING_FANS_OFF)
extern bool fans_paused;
extern int16_t paused_fanSpeeds[FAN_COUNT];

9
Marlin/src/config/default/Configuration_adv.h

@ -825,6 +825,15 @@
#define RETRACT_RECOVER_FEEDRATE_SWAP 8 // Default feedrate for recovering from swap retraction (mm/s)
#endif
/**
* Extra Fan Speed
* Adds a secondary fan speed for each print-cooling fan.
* 'M106 P<fan> T3-255' : Set a secondary speed for <fan>
* 'M106 P<fan> T2' : Use the set secondary speed
* 'M106 P<fan> T1' : Restore the previous fan speed
*/
//#define EXTRA_FAN_SPEED
/**
* Advanced Pause
* Experimental feature for filament change support and for parking the nozzle when paused.

9
Marlin/src/config/examples/AlephObjects/TAZ4/Configuration_adv.h

@ -824,6 +824,15 @@
#define RETRACT_RECOVER_FEEDRATE_SWAP 8 // Default feedrate for recovering from swap retraction (mm/s)
#endif
/**
* Extra Fan Speed
* Adds a secondary fan speed for each print-cooling fan.
* 'M106 P<fan> T3-255' : Set a secondary speed for <fan>
* 'M106 P<fan> T2' : Use the set secondary speed
* 'M106 P<fan> T1' : Restore the previous fan speed
*/
//#define EXTRA_FAN_SPEED
/**
* Advanced Pause
* Experimental feature for filament change support and for parking the nozzle when paused.

9
Marlin/src/config/examples/Anet/A6/Configuration_adv.h

@ -824,6 +824,15 @@
#define RETRACT_RECOVER_FEEDRATE_SWAP 8 // Default feedrate for recovering from swap retraction (mm/s)
#endif
/**
* Extra Fan Speed
* Adds a secondary fan speed for each print-cooling fan.
* 'M106 P<fan> T3-255' : Set a secondary speed for <fan>
* 'M106 P<fan> T2' : Use the set secondary speed
* 'M106 P<fan> T1' : Restore the previous fan speed
*/
//#define EXTRA_FAN_SPEED
/**
* Advanced Pause
* Experimental feature for filament change support and for parking the nozzle when paused.

9
Marlin/src/config/examples/Anet/A8/Configuration_adv.h

@ -824,6 +824,15 @@
#define RETRACT_RECOVER_FEEDRATE_SWAP 8 // Default feedrate for recovering from swap retraction (mm/s)
#endif
/**
* Extra Fan Speed
* Adds a secondary fan speed for each print-cooling fan.
* 'M106 P<fan> T3-255' : Set a secondary speed for <fan>
* 'M106 P<fan> T2' : Use the set secondary speed
* 'M106 P<fan> T1' : Restore the previous fan speed
*/
//#define EXTRA_FAN_SPEED
/**
* Advanced Pause
* Experimental feature for filament change support and for parking the nozzle when paused.

9
Marlin/src/config/examples/BQ/Hephestos/Configuration_adv.h

@ -824,6 +824,15 @@
#define RETRACT_RECOVER_FEEDRATE_SWAP 8 // Default feedrate for recovering from swap retraction (mm/s)
#endif
/**
* Extra Fan Speed
* Adds a secondary fan speed for each print-cooling fan.
* 'M106 P<fan> T3-255' : Set a secondary speed for <fan>
* 'M106 P<fan> T2' : Use the set secondary speed
* 'M106 P<fan> T1' : Restore the previous fan speed
*/
//#define EXTRA_FAN_SPEED
/**
* Advanced Pause
* Experimental feature for filament change support and for parking the nozzle when paused.

9
Marlin/src/config/examples/BQ/Hephestos_2/Configuration_adv.h

@ -821,6 +821,15 @@
#define RETRACT_RECOVER_FEEDRATE_SWAP 8 // Default feedrate for recovering from swap retraction (mm/s)
#endif
/**
* Extra Fan Speed
* Adds a secondary fan speed for each print-cooling fan.
* 'M106 P<fan> T3-255' : Set a secondary speed for <fan>
* 'M106 P<fan> T2' : Use the set secondary speed
* 'M106 P<fan> T1' : Restore the previous fan speed
*/
//#define EXTRA_FAN_SPEED
/**
* Advanced Pause
* Experimental feature for filament change support and for parking the nozzle when paused.

9
Marlin/src/config/examples/BQ/WITBOX/Configuration_adv.h

@ -824,6 +824,15 @@
#define RETRACT_RECOVER_FEEDRATE_SWAP 8 // Default feedrate for recovering from swap retraction (mm/s)
#endif
/**
* Extra Fan Speed
* Adds a secondary fan speed for each print-cooling fan.
* 'M106 P<fan> T3-255' : Set a secondary speed for <fan>
* 'M106 P<fan> T2' : Use the set secondary speed
* 'M106 P<fan> T1' : Restore the previous fan speed
*/
//#define EXTRA_FAN_SPEED
/**
* Advanced Pause
* Experimental feature for filament change support and for parking the nozzle when paused.

9
Marlin/src/config/examples/Cartesio/Configuration_adv.h

@ -824,6 +824,15 @@
#define RETRACT_RECOVER_FEEDRATE_SWAP 8 // Default feedrate for recovering from swap retraction (mm/s)
#endif
/**
* Extra Fan Speed
* Adds a secondary fan speed for each print-cooling fan.
* 'M106 P<fan> T3-255' : Set a secondary speed for <fan>
* 'M106 P<fan> T2' : Use the set secondary speed
* 'M106 P<fan> T1' : Restore the previous fan speed
*/
//#define EXTRA_FAN_SPEED
/**
* Advanced Pause
* Experimental feature for filament change support and for parking the nozzle when paused.

9
Marlin/src/config/examples/Creality/CR-10/Configuration_adv.h

@ -824,6 +824,15 @@
#define RETRACT_RECOVER_FEEDRATE_SWAP 8 // Default feedrate for recovering from swap retraction (mm/s)
#endif
/**
* Extra Fan Speed
* Adds a secondary fan speed for each print-cooling fan.
* 'M106 P<fan> T3-255' : Set a secondary speed for <fan>
* 'M106 P<fan> T2' : Use the set secondary speed
* 'M106 P<fan> T1' : Restore the previous fan speed
*/
//#define EXTRA_FAN_SPEED
/**
* Advanced Pause
* Experimental feature for filament change support and for parking the nozzle when paused.

9
Marlin/src/config/examples/Felix/Configuration_adv.h

@ -824,6 +824,15 @@
#define RETRACT_RECOVER_FEEDRATE_SWAP 8 // Default feedrate for recovering from swap retraction (mm/s)
#endif
/**
* Extra Fan Speed
* Adds a secondary fan speed for each print-cooling fan.
* 'M106 P<fan> T3-255' : Set a secondary speed for <fan>
* 'M106 P<fan> T2' : Use the set secondary speed
* 'M106 P<fan> T1' : Restore the previous fan speed
*/
//#define EXTRA_FAN_SPEED
/**
* Advanced Pause
* Experimental feature for filament change support and for parking the nozzle when paused.

9
Marlin/src/config/examples/Folger Tech/i3-2020/Configuration_adv.h

@ -824,6 +824,15 @@
#define RETRACT_RECOVER_FEEDRATE_SWAP 8 // Default feedrate for recovering from swap retraction (mm/s)
#endif
/**
* Extra Fan Speed
* Adds a secondary fan speed for each print-cooling fan.
* 'M106 P<fan> T3-255' : Set a secondary speed for <fan>
* 'M106 P<fan> T2' : Use the set secondary speed
* 'M106 P<fan> T1' : Restore the previous fan speed
*/
//#define EXTRA_FAN_SPEED
/**
* Advanced Pause
* Experimental feature for filament change support and for parking the nozzle when paused.

9
Marlin/src/config/examples/Infitary/i3-M508/Configuration_adv.h

@ -824,6 +824,15 @@
#define RETRACT_RECOVER_FEEDRATE_SWAP 8 // Default feedrate for recovering from swap retraction (mm/s)
#endif
/**
* Extra Fan Speed
* Adds a secondary fan speed for each print-cooling fan.
* 'M106 P<fan> T3-255' : Set a secondary speed for <fan>
* 'M106 P<fan> T2' : Use the set secondary speed
* 'M106 P<fan> T1' : Restore the previous fan speed
*/
//#define EXTRA_FAN_SPEED
/**
* Advanced Pause
* Experimental feature for filament change support and for parking the nozzle when paused.

9
Marlin/src/config/examples/Malyan/M150/Configuration_adv.h

@ -821,6 +821,15 @@
#define RETRACT_RECOVER_FEEDRATE_SWAP 8 // Default feedrate for recovering from swap retraction (mm/s)
#endif
/**
* Extra Fan Speed
* Adds a secondary fan speed for each print-cooling fan.
* 'M106 P<fan> T3-255' : Set a secondary speed for <fan>
* 'M106 P<fan> T2' : Use the set secondary speed
* 'M106 P<fan> T1' : Restore the previous fan speed
*/
//#define EXTRA_FAN_SPEED
/**
* Advanced Pause
* Experimental feature for filament change support and for parking the nozzle when paused.

9
Marlin/src/config/examples/Mks/Sbase/Configuration_adv.h

@ -845,6 +845,15 @@
#define RETRACT_RECOVER_FEEDRATE_SWAP 8 // Default feedrate for recovering from swap retraction (mm/s)
#endif
/**
* Extra Fan Speed
* Adds a secondary fan speed for each print-cooling fan.
* 'M106 P<fan> T3-255' : Set a secondary speed for <fan>
* 'M106 P<fan> T2' : Use the set secondary speed
* 'M106 P<fan> T1' : Restore the previous fan speed
*/
//#define EXTRA_FAN_SPEED
/**
* Advanced Pause
* Experimental feature for filament change support and for parking the nozzle when paused.

9
Marlin/src/config/examples/RigidBot/Configuration_adv.h

@ -824,6 +824,15 @@
#define RETRACT_RECOVER_FEEDRATE_SWAP 8 // Default feedrate for recovering from swap retraction (mm/s)
#endif
/**
* Extra Fan Speed
* Adds a secondary fan speed for each print-cooling fan.
* 'M106 P<fan> T3-255' : Set a secondary speed for <fan>
* 'M106 P<fan> T2' : Use the set secondary speed
* 'M106 P<fan> T1' : Restore the previous fan speed
*/
//#define EXTRA_FAN_SPEED
/**
* Advanced Pause
* Experimental feature for filament change support and for parking the nozzle when paused.

9
Marlin/src/config/examples/SCARA/Configuration_adv.h

@ -824,6 +824,15 @@
#define RETRACT_RECOVER_FEEDRATE_SWAP 8 // Default feedrate for recovering from swap retraction (mm/s)
#endif
/**
* Extra Fan Speed
* Adds a secondary fan speed for each print-cooling fan.
* 'M106 P<fan> T3-255' : Set a secondary speed for <fan>
* 'M106 P<fan> T2' : Use the set secondary speed
* 'M106 P<fan> T1' : Restore the previous fan speed
*/
//#define EXTRA_FAN_SPEED
/**
* Advanced Pause
* Experimental feature for filament change support and for parking the nozzle when paused.

9
Marlin/src/config/examples/Sanguinololu/Configuration_adv.h

@ -813,6 +813,15 @@
#define RETRACT_RECOVER_FEEDRATE_SWAP 8 // Default feedrate for recovering from swap retraction (mm/s)
#endif
/**
* Extra Fan Speed
* Adds a secondary fan speed for each print-cooling fan.
* 'M106 P<fan> T3-255' : Set a secondary speed for <fan>
* 'M106 P<fan> T2' : Use the set secondary speed
* 'M106 P<fan> T1' : Restore the previous fan speed
*/
//#define EXTRA_FAN_SPEED
/**
* Advanced Pause
* Experimental feature for filament change support and for parking the nozzle when paused.

9
Marlin/src/config/examples/TinyBoy2/Configuration_adv.h

@ -824,6 +824,15 @@
#define RETRACT_RECOVER_FEEDRATE_SWAP 8 // Default feedrate for recovering from swap retraction (mm/s)
#endif
/**
* Extra Fan Speed
* Adds a secondary fan speed for each print-cooling fan.
* 'M106 P<fan> T3-255' : Set a secondary speed for <fan>
* 'M106 P<fan> T2' : Use the set secondary speed
* 'M106 P<fan> T1' : Restore the previous fan speed
*/
//#define EXTRA_FAN_SPEED
/**
* Advanced Pause
* Experimental feature for filament change support and for parking the nozzle when paused.

9
Marlin/src/config/examples/Velleman/K8200/Configuration_adv.h

@ -834,6 +834,15 @@
#define RETRACT_RECOVER_FEEDRATE_SWAP 8 // Default feedrate for recovering from swap retraction (mm/s)
#endif
/**
* Extra Fan Speed
* Adds a secondary fan speed for each print-cooling fan.
* 'M106 P<fan> T3-255' : Set a secondary speed for <fan>
* 'M106 P<fan> T2' : Use the set secondary speed
* 'M106 P<fan> T1' : Restore the previous fan speed
*/
//#define EXTRA_FAN_SPEED
/**
* Advanced Pause
* Experimental feature for filament change support and for parking the nozzle when paused.

9
Marlin/src/config/examples/Velleman/K8400/Configuration_adv.h

@ -824,6 +824,15 @@
#define RETRACT_RECOVER_FEEDRATE_SWAP 8 // Default feedrate for recovering from swap retraction (mm/s)
#endif
/**
* Extra Fan Speed
* Adds a secondary fan speed for each print-cooling fan.
* 'M106 P<fan> T3-255' : Set a secondary speed for <fan>
* 'M106 P<fan> T2' : Use the set secondary speed
* 'M106 P<fan> T1' : Restore the previous fan speed
*/
//#define EXTRA_FAN_SPEED
/**
* Advanced Pause
* Experimental feature for filament change support and for parking the nozzle when paused.

9
Marlin/src/config/examples/delta/FLSUN/auto_calibrate/Configuration_adv.h

@ -826,6 +826,15 @@
#define RETRACT_RECOVER_FEEDRATE_SWAP 8 // Default feedrate for recovering from swap retraction (mm/s)
#endif
/**
* Extra Fan Speed
* Adds a secondary fan speed for each print-cooling fan.
* 'M106 P<fan> T3-255' : Set a secondary speed for <fan>
* 'M106 P<fan> T2' : Use the set secondary speed
* 'M106 P<fan> T1' : Restore the previous fan speed
*/
//#define EXTRA_FAN_SPEED
/**
* Advanced Pause
* Experimental feature for filament change support and for parking the nozzle when paused.

9
Marlin/src/config/examples/delta/FLSUN/kossel_mini/Configuration_adv.h

@ -826,6 +826,15 @@
#define RETRACT_RECOVER_FEEDRATE_SWAP 8 // Default feedrate for recovering from swap retraction (mm/s)
#endif
/**
* Extra Fan Speed
* Adds a secondary fan speed for each print-cooling fan.
* 'M106 P<fan> T3-255' : Set a secondary speed for <fan>
* 'M106 P<fan> T2' : Use the set secondary speed
* 'M106 P<fan> T1' : Restore the previous fan speed
*/
//#define EXTRA_FAN_SPEED
/**
* Advanced Pause
* Experimental feature for filament change support and for parking the nozzle when paused.

9
Marlin/src/config/examples/delta/generic/Configuration_adv.h

@ -826,6 +826,15 @@
#define RETRACT_RECOVER_FEEDRATE_SWAP 8 // Default feedrate for recovering from swap retraction (mm/s)
#endif
/**
* Extra Fan Speed
* Adds a secondary fan speed for each print-cooling fan.
* 'M106 P<fan> T3-255' : Set a secondary speed for <fan>
* 'M106 P<fan> T2' : Use the set secondary speed
* 'M106 P<fan> T1' : Restore the previous fan speed
*/
//#define EXTRA_FAN_SPEED
/**
* Advanced Pause
* Experimental feature for filament change support and for parking the nozzle when paused.

9
Marlin/src/config/examples/delta/kossel_mini/Configuration_adv.h

@ -826,6 +826,15 @@
#define RETRACT_RECOVER_FEEDRATE_SWAP 8 // Default feedrate for recovering from swap retraction (mm/s)
#endif
/**
* Extra Fan Speed
* Adds a secondary fan speed for each print-cooling fan.
* 'M106 P<fan> T3-255' : Set a secondary speed for <fan>
* 'M106 P<fan> T2' : Use the set secondary speed
* 'M106 P<fan> T1' : Restore the previous fan speed
*/
//#define EXTRA_FAN_SPEED
/**
* Advanced Pause
* Experimental feature for filament change support and for parking the nozzle when paused.

9
Marlin/src/config/examples/delta/kossel_pro/Configuration_adv.h

@ -831,6 +831,15 @@
#define RETRACT_RECOVER_FEEDRATE_SWAP 8 // Default feedrate for recovering from swap retraction (mm/s)
#endif
/**
* Extra Fan Speed
* Adds a secondary fan speed for each print-cooling fan.
* 'M106 P<fan> T3-255' : Set a secondary speed for <fan>
* 'M106 P<fan> T2' : Use the set secondary speed
* 'M106 P<fan> T1' : Restore the previous fan speed
*/
//#define EXTRA_FAN_SPEED
/**
* Advanced Pause
* Experimental feature for filament change support and for parking the nozzle when paused.

9
Marlin/src/config/examples/delta/kossel_xl/Configuration_adv.h

@ -826,6 +826,15 @@
#define RETRACT_RECOVER_FEEDRATE_SWAP 8 // Default feedrate for recovering from swap retraction (mm/s)
#endif
/**
* Extra Fan Speed
* Adds a secondary fan speed for each print-cooling fan.
* 'M106 P<fan> T3-255' : Set a secondary speed for <fan>
* 'M106 P<fan> T2' : Use the set secondary speed
* 'M106 P<fan> T1' : Restore the previous fan speed
*/
//#define EXTRA_FAN_SPEED
/**
* Advanced Pause
* Experimental feature for filament change support and for parking the nozzle when paused.

9
Marlin/src/config/examples/gCreate/gMax1.5+/Configuration_adv.h

@ -824,6 +824,15 @@
#define RETRACT_RECOVER_FEEDRATE_SWAP 8 // Default feedrate for recovering from swap retraction (mm/s)
#endif
/**
* Extra Fan Speed
* Adds a secondary fan speed for each print-cooling fan.
* 'M106 P<fan> T3-255' : Set a secondary speed for <fan>
* 'M106 P<fan> T2' : Use the set secondary speed
* 'M106 P<fan> T1' : Restore the previous fan speed
*/
//#define EXTRA_FAN_SPEED
/**
* Advanced Pause
* Experimental feature for filament change support and for parking the nozzle when paused.

9
Marlin/src/config/examples/makibox/Configuration_adv.h

@ -824,6 +824,15 @@
#define RETRACT_RECOVER_FEEDRATE_SWAP 8 // Default feedrate for recovering from swap retraction (mm/s)
#endif
/**
* Extra Fan Speed
* Adds a secondary fan speed for each print-cooling fan.
* 'M106 P<fan> T3-255' : Set a secondary speed for <fan>
* 'M106 P<fan> T2' : Use the set secondary speed
* 'M106 P<fan> T1' : Restore the previous fan speed
*/
//#define EXTRA_FAN_SPEED
/**
* Advanced Pause
* Experimental feature for filament change support and for parking the nozzle when paused.

9
Marlin/src/config/examples/tvrrug/Round2/Configuration_adv.h

@ -824,6 +824,15 @@
#define RETRACT_RECOVER_FEEDRATE_SWAP 8 // Default feedrate for recovering from swap retraction (mm/s)
#endif
/**
* Extra Fan Speed
* Adds a secondary fan speed for each print-cooling fan.
* 'M106 P<fan> T3-255' : Set a secondary speed for <fan>
* 'M106 P<fan> T2' : Use the set secondary speed
* 'M106 P<fan> T1' : Restore the previous fan speed
*/
//#define EXTRA_FAN_SPEED
/**
* Advanced Pause
* Experimental feature for filament change support and for parking the nozzle when paused.

9
Marlin/src/config/examples/wt150/Configuration_adv.h

@ -824,6 +824,15 @@
#define RETRACT_RECOVER_FEEDRATE_SWAP 8 // Default feedrate for recovering from swap retraction (mm/s)
#endif
/**
* Extra Fan Speed
* Adds a secondary fan speed for each print-cooling fan.
* 'M106 P<fan> T3-255' : Set a secondary speed for <fan>
* 'M106 P<fan> T2' : Use the set secondary speed
* 'M106 P<fan> T1' : Restore the previous fan speed
*/
//#define EXTRA_FAN_SPEED
/**
* Advanced Pause
* Experimental feature for filament change support and for parking the nozzle when paused.

4
Marlin/src/gcode/gcode.h

@ -113,8 +113,8 @@
* M100 - Watch Free Memory (for debugging) (Requires M100_FREE_MEMORY_WATCHER)
* M104 - Set extruder target temp.
* M105 - Report current temperatures.
* M106 - Fan on.
* M107 - Fan off.
* M106 - Set print fan speed.
* M107 - Print fan off.
* M108 - Break out of heating loops (M109, M190, M303). With no controller, breaks out of M0/M1. (Requires EMERGENCY_PARSER)
* M109 - Sxxx Wait for extruder current temp to reach target temp. Waits only when heating
* Rxxx Wait for extruder current temp to reach target temp. Waits when heating and cooling

35
Marlin/src/gcode/temperature/M106_M107.cpp

@ -32,12 +32,39 @@
*
* S<int> Speed between 0-255
* P<index> Fan index, if more than one fan
*
* With EXTRA_FAN_SPEED enabled:
*
* T<int> Restore/Use/Set Temporary Speed:
* 1 = Restore previous speed after T2
* 2 = Use temporary speed set with T3-255
* 3-255 = Set the speed for use with T2
*/
void GcodeSuite::M106() {
uint16_t s = parser.ushortval('S', 255);
NOMORE(s, 255);
const uint8_t p = parser.byteval('P', 0);
if (p < FAN_COUNT) fanSpeeds[p] = s;
const uint8_t p = parser.byteval('P');
if (p < FAN_COUNT) {
#if ENABLED(EXTRA_FAN_SPEED)
const int16_t t = parser.intval('T');
NOMORE(t, 255);
if (t > 0) {
switch (t) {
case 1:
fanSpeeds[p] = old_fanSpeeds[p];
break;
case 2:
old_fanSpeeds[p] = fanSpeeds[p];
fanSpeeds[p] = new_fanSpeeds[p];
break;
default:
new_fanSpeeds[p] = t;
break;
}
return;
}
#endif // EXTRA_FAN_SPEED
const uint16_t s = parser.ushortval('S', 255);
fanSpeeds[p] = min(s, 255);
}
}
/**

3
Marlin/src/lcd/language/language_en.h

@ -398,6 +398,9 @@
#ifndef MSG_FAN_SPEED
#define MSG_FAN_SPEED _UxGT("Fan speed")
#endif
#ifndef MSG_EXTRA_FAN_SPEED
#define MSG_EXTRA_FAN_SPEED _UxGT("Extra fan speed")
#endif
#ifndef MSG_FLOW
#define MSG_FLOW _UxGT("Flow")
#endif

37
Marlin/src/lcd/ultralcd.cpp

@ -1238,6 +1238,15 @@ void kill_screen(const char* lcd_msg) {
#endif // ADVANCED_PAUSE_FEATURE
// First Fan Speed title in "Tune" and "Control>Temperature" menus
#if FAN_COUNT > 0 && HAS_FAN0
#if FAN_COUNT > 1
#define FAN_SPEED_1_SUFFIX " 1"
#else
#define FAN_SPEED_1_SUFFIX ""
#endif
#endif
/**
*
* "Tune" submenu
@ -1293,18 +1302,22 @@ void kill_screen(const char* lcd_msg) {
//
#if FAN_COUNT > 0
#if HAS_FAN0
#if FAN_COUNT > 1
#define MSG_1ST_FAN_SPEED MSG_FAN_SPEED " 1"
#else
#define MSG_1ST_FAN_SPEED MSG_FAN_SPEED
MENU_MULTIPLIER_ITEM_EDIT(int3, MSG_FAN_SPEED FAN_SPEED_1_SUFFIX, &fanSpeeds[0], 0, 255);
#if ENABLED(EXTRA_FAN_SPEED)
MENU_MULTIPLIER_ITEM_EDIT(int3, MSG_EXTRA_FAN_SPEED FAN_SPEED_1_SUFFIX, &new_fanSpeeds[0], 3, 255);
#endif
MENU_MULTIPLIER_ITEM_EDIT(int3, MSG_1ST_FAN_SPEED, &fanSpeeds[0], 0, 255);
#endif
#if HAS_FAN1
MENU_MULTIPLIER_ITEM_EDIT(int3, MSG_FAN_SPEED " 2", &fanSpeeds[1], 0, 255);
#if ENABLED(EXTRA_FAN_SPEED)
MENU_MULTIPLIER_ITEM_EDIT(int3, MSG_EXTRA_FAN_SPEED " 2", &new_fanSpeeds[1], 3, 255);
#endif
#endif
#if HAS_FAN2
MENU_MULTIPLIER_ITEM_EDIT(int3, MSG_FAN_SPEED " 3", &fanSpeeds[2], 0, 255);
#if ENABLED(EXTRA_FAN_SPEED)
MENU_MULTIPLIER_ITEM_EDIT(int3, MSG_EXTRA_FAN_SPEED " 3", &new_fanSpeeds[2], 3, 255);
#endif
#endif
#endif // FAN_COUNT > 0
@ -3305,18 +3318,22 @@ void kill_screen(const char* lcd_msg) {
//
#if FAN_COUNT > 0
#if HAS_FAN0
#if FAN_COUNT > 1
#define MSG_1ST_FAN_SPEED MSG_FAN_SPEED " 1"
#else
#define MSG_1ST_FAN_SPEED MSG_FAN_SPEED
MENU_MULTIPLIER_ITEM_EDIT(int3, MSG_FAN_SPEED FAN_SPEED_1_SUFFIX, &fanSpeeds[0], 0, 255);
#if ENABLED(EXTRA_FAN_SPEED)
MENU_MULTIPLIER_ITEM_EDIT(int3, MSG_EXTRA_FAN_SPEED FAN_SPEED_1_SUFFIX, &new_fanSpeeds[0], 3, 255);
#endif
MENU_MULTIPLIER_ITEM_EDIT(int3, MSG_1ST_FAN_SPEED, &fanSpeeds[0], 0, 255);
#endif
#if HAS_FAN1
MENU_MULTIPLIER_ITEM_EDIT(int3, MSG_FAN_SPEED " 2", &fanSpeeds[1], 0, 255);
#if ENABLED(EXTRA_FAN_SPEED)
MENU_MULTIPLIER_ITEM_EDIT(int3, MSG_EXTRA_FAN_SPEED " 2", &new_fanSpeeds[1], 3, 255);
#endif
#endif
#if HAS_FAN2
MENU_MULTIPLIER_ITEM_EDIT(int3, MSG_FAN_SPEED " 3", &fanSpeeds[2], 0, 255);
#if ENABLED(EXTRA_FAN_SPEED)
MENU_MULTIPLIER_ITEM_EDIT(int3, MSG_EXTRA_FAN_SPEED " 3", &new_fanSpeeds[2], 3, 255);
#endif
#endif
#endif // FAN_COUNT > 0

Loading…
Cancel
Save