Browse Source

Merge pull request #8681 from thinkyhead/bf1_pidtempbed_fix

[1.1.x] Change K1 to required option PID_K1
Scott Lahteine 7 years ago
parent
commit
4608e1f590
No account linked to committer's email address
42 changed files with 132 additions and 133 deletions
  1. 3
    3
      Marlin/Configuration.h
  2. 2
    0
      Marlin/SanityCheck.h
  3. 3
    3
      Marlin/example_configurations/AlephObjects/TAZ4/Configuration.h
  4. 3
    3
      Marlin/example_configurations/AliExpress/CL-260/Configuration.h
  5. 3
    3
      Marlin/example_configurations/Anet/A6/Configuration.h
  6. 3
    3
      Marlin/example_configurations/Anet/A8/Configuration.h
  7. 3
    3
      Marlin/example_configurations/BQ/Hephestos/Configuration.h
  8. 3
    3
      Marlin/example_configurations/BQ/Hephestos_2/Configuration.h
  9. 3
    3
      Marlin/example_configurations/BQ/WITBOX/Configuration.h
  10. 3
    3
      Marlin/example_configurations/Cartesio/Configuration.h
  11. 3
    3
      Marlin/example_configurations/Creality/CR-10/Configuration.h
  12. 3
    3
      Marlin/example_configurations/Felix/Configuration.h
  13. 3
    3
      Marlin/example_configurations/Felix/DUAL/Configuration.h
  14. 3
    3
      Marlin/example_configurations/FolgerTech/i3-2020/Configuration.h
  15. 3
    3
      Marlin/example_configurations/Geeetech/GT2560/Configuration.h
  16. 3
    3
      Marlin/example_configurations/Geeetech/I3_Pro_X-GT2560/Configuration.h
  17. 3
    3
      Marlin/example_configurations/Infitary/i3-M508/Configuration.h
  18. 3
    3
      Marlin/example_configurations/Malyan/M150/Configuration.h
  19. 3
    3
      Marlin/example_configurations/Micromake/C1/basic/Configuration.h
  20. 3
    3
      Marlin/example_configurations/Micromake/C1/enhanced/Configuration.h
  21. 3
    3
      Marlin/example_configurations/RepRapWorld/Megatronics/Configuration.h
  22. 3
    3
      Marlin/example_configurations/RigidBot/Configuration.h
  23. 3
    3
      Marlin/example_configurations/SCARA/Configuration.h
  24. 3
    3
      Marlin/example_configurations/Sanguinololu/Configuration.h
  25. 3
    3
      Marlin/example_configurations/TinyBoy2/Configuration.h
  26. 3
    3
      Marlin/example_configurations/Velleman/K8200/Configuration.h
  27. 3
    3
      Marlin/example_configurations/Velleman/K8400/Configuration.h
  28. 3
    3
      Marlin/example_configurations/Velleman/K8400/Dual-head/Configuration.h
  29. 3
    3
      Marlin/example_configurations/Wanhao/Duplicator 6/Configuration.h
  30. 3
    3
      Marlin/example_configurations/adafruit/ST7565/Configuration.h
  31. 3
    3
      Marlin/example_configurations/delta/FLSUN/auto_calibrate/Configuration.h
  32. 3
    3
      Marlin/example_configurations/delta/FLSUN/kossel_mini/Configuration.h
  33. 3
    3
      Marlin/example_configurations/delta/generic/Configuration.h
  34. 3
    3
      Marlin/example_configurations/delta/kossel_mini/Configuration.h
  35. 3
    3
      Marlin/example_configurations/delta/kossel_pro/Configuration.h
  36. 3
    3
      Marlin/example_configurations/delta/kossel_xl/Configuration.h
  37. 3
    3
      Marlin/example_configurations/gCreate/gMax1.5+/Configuration.h
  38. 3
    3
      Marlin/example_configurations/makibox/Configuration.h
  39. 3
    3
      Marlin/example_configurations/tvrrug/Round2/Configuration.h
  40. 3
    3
      Marlin/example_configurations/wt150/Configuration.h
  41. 2
    6
      Marlin/temperature.cpp
  42. 11
    10
      Marlin/temperature.h

+ 3
- 3
Marlin/Configuration.h View File

339
 
339
 
340
 // Comment the following line to disable PID and enable bang-bang.
340
 // Comment the following line to disable PID and enable bang-bang.
341
 #define PIDTEMP
341
 #define PIDTEMP
342
-#define BANG_MAX 255 // limits current to nozzle while in bang-bang mode; 255=full current
343
-#define PID_MAX BANG_MAX // limits current to nozzle while PID is active (see PID_FUNCTIONAL_RANGE below); 255=full current
342
+#define BANG_MAX 255     // Limits current to nozzle while in bang-bang mode; 255=full current
343
+#define PID_MAX BANG_MAX // Limits current to nozzle while PID is active (see PID_FUNCTIONAL_RANGE below); 255=full current
344
+#define PID_K1 0.95      // Smoothing factor within the PID
344
 #if ENABLED(PIDTEMP)
345
 #if ENABLED(PIDTEMP)
345
   //#define PID_AUTOTUNE_MENU // Add PID Autotune to the LCD "Temperature" menu to run M303 and apply the result.
346
   //#define PID_AUTOTUNE_MENU // Add PID Autotune to the LCD "Temperature" menu to run M303 and apply the result.
346
   //#define PID_DEBUG // Sends debug data to the serial port.
347
   //#define PID_DEBUG // Sends debug data to the serial port.
350
                                   // Set/get with gcode: M301 E[extruder number, 0-2]
351
                                   // Set/get with gcode: M301 E[extruder number, 0-2]
351
   #define PID_FUNCTIONAL_RANGE 10 // If the temperature difference between the target temperature and the actual temperature
352
   #define PID_FUNCTIONAL_RANGE 10 // If the temperature difference between the target temperature and the actual temperature
352
                                   // is more than PID_FUNCTIONAL_RANGE then the PID will be shut off and the heater will be set to min/max.
353
                                   // is more than PID_FUNCTIONAL_RANGE then the PID will be shut off and the heater will be set to min/max.
353
-  #define K1 0.95 //smoothing factor within the PID
354
 
354
 
355
   // If you are using a pre-configured hotend then you can use one of the value sets by uncommenting it
355
   // If you are using a pre-configured hotend then you can use one of the value sets by uncommenting it
356
 
356
 

+ 2
- 0
Marlin/SanityCheck.h View File

222
   #error "BABYSTEP_ZPROBE_GFX_REVERSE is now set by OVERLAY_GFX_REVERSE. Please update your configurations."
222
   #error "BABYSTEP_ZPROBE_GFX_REVERSE is now set by OVERLAY_GFX_REVERSE. Please update your configurations."
223
 #elif defined(UBL_GRANULAR_SEGMENTATION_FOR_CARTESIAN)
223
 #elif defined(UBL_GRANULAR_SEGMENTATION_FOR_CARTESIAN)
224
   #error "UBL_GRANULAR_SEGMENTATION_FOR_CARTESIAN is now SEGMENT_LEVELED_MOVES. Please update your configuration."
224
   #error "UBL_GRANULAR_SEGMENTATION_FOR_CARTESIAN is now SEGMENT_LEVELED_MOVES. Please update your configuration."
225
+#elif HAS_PID_HEATING && (defined(K1) || !defined(PID_K1))
226
+  #error "K1 is now PID_K1. Please update your configuration."
225
 #endif
227
 #endif
226
 
228
 
227
 /**
229
 /**

+ 3
- 3
Marlin/example_configurations/AlephObjects/TAZ4/Configuration.h View File

339
 
339
 
340
 // Comment the following line to disable PID and enable bang-bang.
340
 // Comment the following line to disable PID and enable bang-bang.
341
 #define PIDTEMP
341
 #define PIDTEMP
342
-#define BANG_MAX 70 // limits current to nozzle while in bang-bang mode; 255=full current
343
-#define PID_MAX 74 // limits current to nozzle while PID is active (see PID_FUNCTIONAL_RANGE below); 255=full current
342
+#define BANG_MAX 70      // Limits current to nozzle while in bang-bang mode; 255=full current
343
+#define PID_MAX  74      // Limits current to nozzle while PID is active (see PID_FUNCTIONAL_RANGE below); 255=full current
344
+#define PID_K1 0.95      // Smoothing factor within the PID
344
 #if ENABLED(PIDTEMP)
345
 #if ENABLED(PIDTEMP)
345
   //#define PID_AUTOTUNE_MENU // Add PID Autotune to the LCD "Temperature" menu to run M303 and apply the result.
346
   //#define PID_AUTOTUNE_MENU // Add PID Autotune to the LCD "Temperature" menu to run M303 and apply the result.
346
   //#define PID_DEBUG // Sends debug data to the serial port.
347
   //#define PID_DEBUG // Sends debug data to the serial port.
350
                                   // Set/get with gcode: M301 E[extruder number, 0-2]
351
                                   // Set/get with gcode: M301 E[extruder number, 0-2]
351
   #define PID_FUNCTIONAL_RANGE 16 // If the temperature difference between the target temperature and the actual temperature
352
   #define PID_FUNCTIONAL_RANGE 16 // If the temperature difference between the target temperature and the actual temperature
352
                                   // is more than PID_FUNCTIONAL_RANGE then the PID will be shut off and the heater will be set to min/max.
353
                                   // is more than PID_FUNCTIONAL_RANGE then the PID will be shut off and the heater will be set to min/max.
353
-  #define K1 0.95 //smoothing factor within the PID
354
 
354
 
355
   // If you are using a pre-configured hotend then you can use one of the value sets by uncommenting it
355
   // If you are using a pre-configured hotend then you can use one of the value sets by uncommenting it
356
   // Buda 2.0 on 24V
356
   // Buda 2.0 on 24V

+ 3
- 3
Marlin/example_configurations/AliExpress/CL-260/Configuration.h View File

339
 
339
 
340
 // Comment the following line to disable PID and enable bang-bang.
340
 // Comment the following line to disable PID and enable bang-bang.
341
 #define PIDTEMP
341
 #define PIDTEMP
342
-#define BANG_MAX 255 // limits current to nozzle while in bang-bang mode; 255=full current
343
-#define PID_MAX BANG_MAX // limits current to nozzle while PID is active (see PID_FUNCTIONAL_RANGE below); 255=full current
342
+#define BANG_MAX 255     // Limits current to nozzle while in bang-bang mode; 255=full current
343
+#define PID_MAX BANG_MAX // Limits current to nozzle while PID is active (see PID_FUNCTIONAL_RANGE below); 255=full current
344
+#define PID_K1 0.95      // Smoothing factor within the PID
344
 #if ENABLED(PIDTEMP)
345
 #if ENABLED(PIDTEMP)
345
   //#define PID_AUTOTUNE_MENU // Add PID Autotune to the LCD "Temperature" menu to run M303 and apply the result.
346
   //#define PID_AUTOTUNE_MENU // Add PID Autotune to the LCD "Temperature" menu to run M303 and apply the result.
346
   //#define PID_DEBUG // Sends debug data to the serial port.
347
   //#define PID_DEBUG // Sends debug data to the serial port.
350
                                   // Set/get with gcode: M301 E[extruder number, 0-2]
351
                                   // Set/get with gcode: M301 E[extruder number, 0-2]
351
   #define PID_FUNCTIONAL_RANGE 10 // If the temperature difference between the target temperature and the actual temperature
352
   #define PID_FUNCTIONAL_RANGE 10 // If the temperature difference between the target temperature and the actual temperature
352
                                   // is more than PID_FUNCTIONAL_RANGE then the PID will be shut off and the heater will be set to min/max.
353
                                   // is more than PID_FUNCTIONAL_RANGE then the PID will be shut off and the heater will be set to min/max.
353
-  #define K1 0.95 //smoothing factor within the PID
354
 
354
 
355
   // If you are using a pre-configured hotend then you can use one of the value sets by uncommenting it
355
   // If you are using a pre-configured hotend then you can use one of the value sets by uncommenting it
356
 
356
 

+ 3
- 3
Marlin/example_configurations/Anet/A6/Configuration.h View File

339
 
339
 
340
 // Comment the following line to disable PID and enable bang-bang.
340
 // Comment the following line to disable PID and enable bang-bang.
341
 #define PIDTEMP
341
 #define PIDTEMP
342
-#define BANG_MAX 255 // limits current to nozzle while in bang-bang mode; 255=full current
343
-#define PID_MAX BANG_MAX // limits current to nozzle while PID is active (see PID_FUNCTIONAL_RANGE below); 255=full current
342
+#define BANG_MAX 255     // Limits current to nozzle while in bang-bang mode; 255=full current
343
+#define PID_MAX BANG_MAX // Limits current to nozzle while PID is active (see PID_FUNCTIONAL_RANGE below); 255=full current
344
+#define PID_K1 0.95      // Smoothing factor within the PID
344
 #if ENABLED(PIDTEMP)
345
 #if ENABLED(PIDTEMP)
345
   //#define PID_AUTOTUNE_MENU // Add PID Autotune to the LCD "Temperature" menu to run M303 and apply the result.
346
   //#define PID_AUTOTUNE_MENU // Add PID Autotune to the LCD "Temperature" menu to run M303 and apply the result.
346
   //#define PID_DEBUG // Sends debug data to the serial port.
347
   //#define PID_DEBUG // Sends debug data to the serial port.
350
                                   // Set/get with gcode: M301 E[extruder number, 0-2]
351
                                   // Set/get with gcode: M301 E[extruder number, 0-2]
351
   #define PID_FUNCTIONAL_RANGE 10 // If the temperature difference between the target temperature and the actual temperature
352
   #define PID_FUNCTIONAL_RANGE 10 // If the temperature difference between the target temperature and the actual temperature
352
                                   // is more than PID_FUNCTIONAL_RANGE then the PID will be shut off and the heater will be set to min/max.
353
                                   // is more than PID_FUNCTIONAL_RANGE then the PID will be shut off and the heater will be set to min/max.
353
-  #define K1 0.95 //smoothing factor within the PID
354
 
354
 
355
   // If you are using a pre-configured hotend then you can use one of the value sets by uncommenting it
355
   // If you are using a pre-configured hotend then you can use one of the value sets by uncommenting it
356
 
356
 

+ 3
- 3
Marlin/example_configurations/Anet/A8/Configuration.h View File

340
 
340
 
341
 // Comment the following line to disable PID and enable bang-bang.
341
 // Comment the following line to disable PID and enable bang-bang.
342
 #define PIDTEMP
342
 #define PIDTEMP
343
-#define BANG_MAX 255 // limits current to nozzle while in bang-bang mode; 255=full current
344
-#define PID_MAX BANG_MAX // limits current to nozzle while PID is active (see PID_FUNCTIONAL_RANGE below); 255=full current
343
+#define BANG_MAX 255     // Limits current to nozzle while in bang-bang mode; 255=full current
344
+#define PID_MAX BANG_MAX // Limits current to nozzle while PID is active (see PID_FUNCTIONAL_RANGE below); 255=full current
345
+#define PID_K1 0.95      // Smoothing factor within the PID
345
 #if ENABLED(PIDTEMP)
346
 #if ENABLED(PIDTEMP)
346
   //#define PID_AUTOTUNE_MENU // Add PID Autotune to the LCD "Temperature" menu to run M303 and apply the result.
347
   //#define PID_AUTOTUNE_MENU // Add PID Autotune to the LCD "Temperature" menu to run M303 and apply the result.
347
   //#define PID_DEBUG // Sends debug data to the serial port.
348
   //#define PID_DEBUG // Sends debug data to the serial port.
351
                                   // Set/get with gcode: M301 E[extruder number, 0-2]
352
                                   // Set/get with gcode: M301 E[extruder number, 0-2]
352
   #define PID_FUNCTIONAL_RANGE 15 // If the temperature difference between the target temperature and the actual temperature
353
   #define PID_FUNCTIONAL_RANGE 15 // If the temperature difference between the target temperature and the actual temperature
353
                                   // is more than PID_FUNCTIONAL_RANGE then the PID will be shut off and the heater will be set to min/max.
354
                                   // is more than PID_FUNCTIONAL_RANGE then the PID will be shut off and the heater will be set to min/max.
354
-  #define K1 0.95 //smoothing factor within the PID
355
 
355
 
356
   // If you are using a pre-configured hotend then you can use one of the value sets by uncommenting it
356
   // If you are using a pre-configured hotend then you can use one of the value sets by uncommenting it
357
 
357
 

+ 3
- 3
Marlin/example_configurations/BQ/Hephestos/Configuration.h View File

342
 
342
 
343
 // Comment the following line to disable PID and enable bang-bang.
343
 // Comment the following line to disable PID and enable bang-bang.
344
 #define PIDTEMP
344
 #define PIDTEMP
345
-#define BANG_MAX 255 // limits current to nozzle while in bang-bang mode; 255=full current
346
-#define PID_MAX BANG_MAX // limits current to nozzle while PID is active (see PID_FUNCTIONAL_RANGE below); 255=full current
345
+#define BANG_MAX 255     // Limits current to nozzle while in bang-bang mode; 255=full current
346
+#define PID_MAX BANG_MAX // Limits current to nozzle while PID is active (see PID_FUNCTIONAL_RANGE below); 255=full current
347
+#define PID_K1 0.95      // Smoothing factor within the PID
347
 #if ENABLED(PIDTEMP)
348
 #if ENABLED(PIDTEMP)
348
   //#define PID_AUTOTUNE_MENU // Add PID Autotune to the LCD "Temperature" menu to run M303 and apply the result.
349
   //#define PID_AUTOTUNE_MENU // Add PID Autotune to the LCD "Temperature" menu to run M303 and apply the result.
349
   //#define PID_DEBUG // Sends debug data to the serial port.
350
   //#define PID_DEBUG // Sends debug data to the serial port.
353
                                   // Set/get with gcode: M301 E[extruder number, 0-2]
354
                                   // Set/get with gcode: M301 E[extruder number, 0-2]
354
   #define PID_FUNCTIONAL_RANGE 10 // If the temperature difference between the target temperature and the actual temperature
355
   #define PID_FUNCTIONAL_RANGE 10 // If the temperature difference between the target temperature and the actual temperature
355
                                   // is more than PID_FUNCTIONAL_RANGE then the PID will be shut off and the heater will be set to min/max.
356
                                   // is more than PID_FUNCTIONAL_RANGE then the PID will be shut off and the heater will be set to min/max.
356
-  #define K1 0.95 //smoothing factor within the PID
357
 
357
 
358
   // Hephestos i3
358
   // Hephestos i3
359
   #define  DEFAULT_Kp 23.05
359
   #define  DEFAULT_Kp 23.05

+ 3
- 3
Marlin/example_configurations/BQ/Hephestos_2/Configuration.h View File

344
 
344
 
345
 // Comment the following line to disable PID and enable bang-bang.
345
 // Comment the following line to disable PID and enable bang-bang.
346
 #define PIDTEMP
346
 #define PIDTEMP
347
-#define BANG_MAX 255 // limits current to nozzle while in bang-bang mode; 255=full current
348
-#define PID_MAX BANG_MAX // limits current to nozzle while PID is active (see PID_FUNCTIONAL_RANGE below); 255=full current
347
+#define BANG_MAX 255     // Limits current to nozzle while in bang-bang mode; 255=full current
348
+#define PID_MAX BANG_MAX // Limits current to nozzle while PID is active (see PID_FUNCTIONAL_RANGE below); 255=full current
349
+#define PID_K1 0.95      // Smoothing factor within the PID
349
 #if ENABLED(PIDTEMP)
350
 #if ENABLED(PIDTEMP)
350
   //#define PID_AUTOTUNE_MENU // Add PID Autotune to the LCD "Temperature" menu to run M303 and apply the result.
351
   //#define PID_AUTOTUNE_MENU // Add PID Autotune to the LCD "Temperature" menu to run M303 and apply the result.
351
   //#define PID_DEBUG // Sends debug data to the serial port.
352
   //#define PID_DEBUG // Sends debug data to the serial port.
355
                                   // Set/get with gcode: M301 E[extruder number, 0-2]
356
                                   // Set/get with gcode: M301 E[extruder number, 0-2]
356
   #define PID_FUNCTIONAL_RANGE 50 // If the temperature difference between the target temperature and the actual temperature
357
   #define PID_FUNCTIONAL_RANGE 50 // If the temperature difference between the target temperature and the actual temperature
357
                                     // is more than PID_FUNCTIONAL_RANGE then the PID will be shut off and the heater will be set to min/max.
358
                                     // is more than PID_FUNCTIONAL_RANGE then the PID will be shut off and the heater will be set to min/max.
358
-  #define K1 0.95 //smoothing factor within the PID
359
 
359
 
360
   // Tuned PID values using M303
360
   // Tuned PID values using M303
361
   #define  DEFAULT_Kp 19.18
361
   #define  DEFAULT_Kp 19.18

+ 3
- 3
Marlin/example_configurations/BQ/WITBOX/Configuration.h View File

342
 
342
 
343
 // Comment the following line to disable PID and enable bang-bang.
343
 // Comment the following line to disable PID and enable bang-bang.
344
 #define PIDTEMP
344
 #define PIDTEMP
345
-#define BANG_MAX 255 // limits current to nozzle while in bang-bang mode; 255=full current
346
-#define PID_MAX BANG_MAX // limits current to nozzle while PID is active (see PID_FUNCTIONAL_RANGE below); 255=full current
345
+#define BANG_MAX 255     // Limits current to nozzle while in bang-bang mode; 255=full current
346
+#define PID_MAX BANG_MAX // Limits current to nozzle while PID is active (see PID_FUNCTIONAL_RANGE below); 255=full current
347
+#define PID_K1 0.95      // Smoothing factor within the PID
347
 #if ENABLED(PIDTEMP)
348
 #if ENABLED(PIDTEMP)
348
   //#define PID_AUTOTUNE_MENU // Add PID Autotune to the LCD "Temperature" menu to run M303 and apply the result.
349
   //#define PID_AUTOTUNE_MENU // Add PID Autotune to the LCD "Temperature" menu to run M303 and apply the result.
349
   //#define PID_DEBUG // Sends debug data to the serial port.
350
   //#define PID_DEBUG // Sends debug data to the serial port.
353
                                   // Set/get with gcode: M301 E[extruder number, 0-2]
354
                                   // Set/get with gcode: M301 E[extruder number, 0-2]
354
   #define PID_FUNCTIONAL_RANGE 10 // If the temperature difference between the target temperature and the actual temperature
355
   #define PID_FUNCTIONAL_RANGE 10 // If the temperature difference between the target temperature and the actual temperature
355
                                   // is more than PID_FUNCTIONAL_RANGE then the PID will be shut off and the heater will be set to min/max.
356
                                   // is more than PID_FUNCTIONAL_RANGE then the PID will be shut off and the heater will be set to min/max.
356
-  #define K1 0.95 //smoothing factor within the PID
357
 
357
 
358
   // Witbox
358
   // Witbox
359
   #define  DEFAULT_Kp 22.2
359
   #define  DEFAULT_Kp 22.2

+ 3
- 3
Marlin/example_configurations/Cartesio/Configuration.h View File

340
 
340
 
341
 // Comment the following line to disable PID and enable bang-bang.
341
 // Comment the following line to disable PID and enable bang-bang.
342
 #define PIDTEMP
342
 #define PIDTEMP
343
-#define BANG_MAX 255 // limits current to nozzle while in bang-bang mode; 255=full current
344
-#define PID_MAX BANG_MAX // limits current to nozzle while PID is active (see PID_FUNCTIONAL_RANGE below); 255=full current
343
+#define BANG_MAX 255     // Limits current to nozzle while in bang-bang mode; 255=full current
344
+#define PID_MAX BANG_MAX // Limits current to nozzle while PID is active (see PID_FUNCTIONAL_RANGE below); 255=full current
345
+#define PID_K1 0.95      // Smoothing factor within the PID
345
 #if ENABLED(PIDTEMP)
346
 #if ENABLED(PIDTEMP)
346
   //#define PID_AUTOTUNE_MENU // Add PID Autotune to the LCD "Temperature" menu to run M303 and apply the result.
347
   //#define PID_AUTOTUNE_MENU // Add PID Autotune to the LCD "Temperature" menu to run M303 and apply the result.
347
   //#define PID_DEBUG // Sends debug data to the serial port.
348
   //#define PID_DEBUG // Sends debug data to the serial port.
351
                                   // Set/get with gcode: M301 E[extruder number, 0-2]
352
                                   // Set/get with gcode: M301 E[extruder number, 0-2]
352
   #define PID_FUNCTIONAL_RANGE 10 // If the temperature difference between the target temperature and the actual temperature
353
   #define PID_FUNCTIONAL_RANGE 10 // If the temperature difference between the target temperature and the actual temperature
353
                                   // is more than PID_FUNCTIONAL_RANGE then the PID will be shut off and the heater will be set to min/max.
354
                                   // is more than PID_FUNCTIONAL_RANGE then the PID will be shut off and the heater will be set to min/max.
354
-  #define K1 0.95 //smoothing factor within the PID
355
 
355
 
356
   // If you are using a pre-configured hotend then you can use one of the value sets by uncommenting it
356
   // If you are using a pre-configured hotend then you can use one of the value sets by uncommenting it
357
 
357
 

+ 3
- 3
Marlin/example_configurations/Creality/CR-10/Configuration.h View File

339
 
339
 
340
 // Comment the following line to disable PID and enable bang-bang.
340
 // Comment the following line to disable PID and enable bang-bang.
341
 #define PIDTEMP
341
 #define PIDTEMP
342
-#define BANG_MAX 255 // limits current to nozzle while in bang-bang mode; 255=full current
343
-#define PID_MAX BANG_MAX // limits current to nozzle while PID is active (see PID_FUNCTIONAL_RANGE below); 255=full current
342
+#define BANG_MAX 255     // Limits current to nozzle while in bang-bang mode; 255=full current
343
+#define PID_MAX BANG_MAX // Limits current to nozzle while PID is active (see PID_FUNCTIONAL_RANGE below); 255=full current
344
+#define PID_K1 0.95      // Smoothing factor within the PID
344
 #if ENABLED(PIDTEMP)
345
 #if ENABLED(PIDTEMP)
345
   //#define PID_AUTOTUNE_MENU // Add PID Autotune to the LCD "Temperature" menu to run M303 and apply the result.
346
   //#define PID_AUTOTUNE_MENU // Add PID Autotune to the LCD "Temperature" menu to run M303 and apply the result.
346
   //#define PID_DEBUG // Sends debug data to the serial port.
347
   //#define PID_DEBUG // Sends debug data to the serial port.
350
                                   // Set/get with gcode: M301 E[extruder number, 0-2]
351
                                   // Set/get with gcode: M301 E[extruder number, 0-2]
351
   #define PID_FUNCTIONAL_RANGE 10 // If the temperature difference between the target temperature and the actual temperature
352
   #define PID_FUNCTIONAL_RANGE 10 // If the temperature difference between the target temperature and the actual temperature
352
                                   // is more than PID_FUNCTIONAL_RANGE then the PID will be shut off and the heater will be set to min/max.
353
                                   // is more than PID_FUNCTIONAL_RANGE then the PID will be shut off and the heater will be set to min/max.
353
-  #define K1 0.95 //smoothing factor within the PID
354
 
354
 
355
   // If you are using a pre-configured hotend then you can use one of the value sets by uncommenting it
355
   // If you are using a pre-configured hotend then you can use one of the value sets by uncommenting it
356
 
356
 

+ 3
- 3
Marlin/example_configurations/Felix/Configuration.h View File

339
 
339
 
340
 // Comment the following line to disable PID and enable bang-bang.
340
 // Comment the following line to disable PID and enable bang-bang.
341
 #define PIDTEMP
341
 #define PIDTEMP
342
-#define BANG_MAX 255 // limits current to nozzle while in bang-bang mode; 255=full current
343
-#define PID_MAX BANG_MAX // limits current to nozzle while PID is active (see PID_FUNCTIONAL_RANGE below); 255=full current
342
+#define BANG_MAX 255     // Limits current to nozzle while in bang-bang mode; 255=full current
343
+#define PID_MAX BANG_MAX // Limits current to nozzle while PID is active (see PID_FUNCTIONAL_RANGE below); 255=full current
344
+#define PID_K1 0.95      // Smoothing factor within the PID
344
 #if ENABLED(PIDTEMP)
345
 #if ENABLED(PIDTEMP)
345
   //#define PID_AUTOTUNE_MENU // Add PID Autotune to the LCD "Temperature" menu to run M303 and apply the result.
346
   //#define PID_AUTOTUNE_MENU // Add PID Autotune to the LCD "Temperature" menu to run M303 and apply the result.
346
   //#define PID_DEBUG // Sends debug data to the serial port.
347
   //#define PID_DEBUG // Sends debug data to the serial port.
350
                                   // Set/get with gcode: M301 E[extruder number, 0-2]
351
                                   // Set/get with gcode: M301 E[extruder number, 0-2]
351
   #define PID_FUNCTIONAL_RANGE 10 // If the temperature difference between the target temperature and the actual temperature
352
   #define PID_FUNCTIONAL_RANGE 10 // If the temperature difference between the target temperature and the actual temperature
352
                                   // is more than PID_FUNCTIONAL_RANGE then the PID will be shut off and the heater will be set to min/max.
353
                                   // is more than PID_FUNCTIONAL_RANGE then the PID will be shut off and the heater will be set to min/max.
353
-  #define K1 0.95 //smoothing factor within the PID
354
 
354
 
355
   // Felix 2.0+ electronics with v4 Hotend
355
   // Felix 2.0+ electronics with v4 Hotend
356
   #define DEFAULT_Kp 12
356
   #define DEFAULT_Kp 12

+ 3
- 3
Marlin/example_configurations/Felix/DUAL/Configuration.h View File

339
 
339
 
340
 // Comment the following line to disable PID and enable bang-bang.
340
 // Comment the following line to disable PID and enable bang-bang.
341
 #define PIDTEMP
341
 #define PIDTEMP
342
-#define BANG_MAX 255 // limits current to nozzle while in bang-bang mode; 255=full current
343
-#define PID_MAX BANG_MAX // limits current to nozzle while PID is active (see PID_FUNCTIONAL_RANGE below); 255=full current
342
+#define BANG_MAX 255     // Limits current to nozzle while in bang-bang mode; 255=full current
343
+#define PID_MAX BANG_MAX // Limits current to nozzle while PID is active (see PID_FUNCTIONAL_RANGE below); 255=full current
344
+#define PID_K1 0.95      // Smoothing factor within the PID
344
 #if ENABLED(PIDTEMP)
345
 #if ENABLED(PIDTEMP)
345
   //#define PID_AUTOTUNE_MENU // Add PID Autotune to the LCD "Temperature" menu to run M303 and apply the result.
346
   //#define PID_AUTOTUNE_MENU // Add PID Autotune to the LCD "Temperature" menu to run M303 and apply the result.
346
   //#define PID_DEBUG // Sends debug data to the serial port.
347
   //#define PID_DEBUG // Sends debug data to the serial port.
350
                                   // Set/get with gcode: M301 E[extruder number, 0-2]
351
                                   // Set/get with gcode: M301 E[extruder number, 0-2]
351
   #define PID_FUNCTIONAL_RANGE 10 // If the temperature difference between the target temperature and the actual temperature
352
   #define PID_FUNCTIONAL_RANGE 10 // If the temperature difference between the target temperature and the actual temperature
352
                                   // is more than PID_FUNCTIONAL_RANGE then the PID will be shut off and the heater will be set to min/max.
353
                                   // is more than PID_FUNCTIONAL_RANGE then the PID will be shut off and the heater will be set to min/max.
353
-  #define K1 0.95 //smoothing factor within the PID
354
 
354
 
355
   // Felix 2.0+ electronics with v4 Hotend
355
   // Felix 2.0+ electronics with v4 Hotend
356
   #define DEFAULT_Kp 12
356
   #define DEFAULT_Kp 12

+ 3
- 3
Marlin/example_configurations/FolgerTech/i3-2020/Configuration.h View File

339
 
339
 
340
 // Comment the following line to disable PID and enable bang-bang.
340
 // Comment the following line to disable PID and enable bang-bang.
341
 #define PIDTEMP
341
 #define PIDTEMP
342
-#define BANG_MAX 255 // limits current to nozzle while in bang-bang mode; 255=full current
343
-#define PID_MAX BANG_MAX // limits current to nozzle while PID is active (see PID_FUNCTIONAL_RANGE below); 255=full current
342
+#define BANG_MAX 255     // Limits current to nozzle while in bang-bang mode; 255=full current
343
+#define PID_MAX BANG_MAX // Limits current to nozzle while PID is active (see PID_FUNCTIONAL_RANGE below); 255=full current
344
+#define PID_K1 0.95      // Smoothing factor within the PID
344
 #if ENABLED(PIDTEMP)
345
 #if ENABLED(PIDTEMP)
345
   //#define PID_AUTOTUNE_MENU // Add PID Autotune to the LCD "Temperature" menu to run M303 and apply the result.
346
   //#define PID_AUTOTUNE_MENU // Add PID Autotune to the LCD "Temperature" menu to run M303 and apply the result.
346
   //#define PID_DEBUG // Sends debug data to the serial port.
347
   //#define PID_DEBUG // Sends debug data to the serial port.
350
                                   // Set/get with gcode: M301 E[extruder number, 0-2]
351
                                   // Set/get with gcode: M301 E[extruder number, 0-2]
351
   #define PID_FUNCTIONAL_RANGE 10 // If the temperature difference between the target temperature and the actual temperature
352
   #define PID_FUNCTIONAL_RANGE 10 // If the temperature difference between the target temperature and the actual temperature
352
                                   // is more than PID_FUNCTIONAL_RANGE then the PID will be shut off and the heater will be set to min/max.
353
                                   // is more than PID_FUNCTIONAL_RANGE then the PID will be shut off and the heater will be set to min/max.
353
-  #define K1 0.95 //smoothing factor within the PID
354
 
354
 
355
   // If you are using a pre-configured hotend then you can use one of the value sets by uncommenting it
355
   // If you are using a pre-configured hotend then you can use one of the value sets by uncommenting it
356
 
356
 

+ 3
- 3
Marlin/example_configurations/Geeetech/GT2560/Configuration.h View File

339
 
339
 
340
 // Comment the following line to disable PID and enable bang-bang.
340
 // Comment the following line to disable PID and enable bang-bang.
341
 #define PIDTEMP
341
 #define PIDTEMP
342
-#define BANG_MAX 255 // limits current to nozzle while in bang-bang mode; 255=full current
343
-#define PID_MAX BANG_MAX // limits current to nozzle while PID is active (see PID_FUNCTIONAL_RANGE below); 255=full current
342
+#define BANG_MAX 255     // Limits current to nozzle while in bang-bang mode; 255=full current
343
+#define PID_MAX BANG_MAX // Limits current to nozzle while PID is active (see PID_FUNCTIONAL_RANGE below); 255=full current
344
+#define PID_K1 0.95      // Smoothing factor within the PID
344
 #if ENABLED(PIDTEMP)
345
 #if ENABLED(PIDTEMP)
345
   //#define PID_AUTOTUNE_MENU // Add PID Autotune to the LCD "Temperature" menu to run M303 and apply the result.
346
   //#define PID_AUTOTUNE_MENU // Add PID Autotune to the LCD "Temperature" menu to run M303 and apply the result.
346
   //#define PID_DEBUG // Sends debug data to the serial port.
347
   //#define PID_DEBUG // Sends debug data to the serial port.
350
                                   // Set/get with gcode: M301 E[extruder number, 0-2]
351
                                   // Set/get with gcode: M301 E[extruder number, 0-2]
351
   #define PID_FUNCTIONAL_RANGE 10 // If the temperature difference between the target temperature and the actual temperature
352
   #define PID_FUNCTIONAL_RANGE 10 // If the temperature difference between the target temperature and the actual temperature
352
                                   // is more than PID_FUNCTIONAL_RANGE then the PID will be shut off and the heater will be set to min/max.
353
                                   // is more than PID_FUNCTIONAL_RANGE then the PID will be shut off and the heater will be set to min/max.
353
-  #define K1 0.95 //smoothing factor within the PID
354
 
354
 
355
   // Geeetech MK8 Extruder
355
   // Geeetech MK8 Extruder
356
   #define  DEFAULT_Kp 12.33
356
   #define  DEFAULT_Kp 12.33

+ 3
- 3
Marlin/example_configurations/Geeetech/I3_Pro_X-GT2560/Configuration.h View File

339
 
339
 
340
 // Comment the following line to disable PID and enable bang-bang.
340
 // Comment the following line to disable PID and enable bang-bang.
341
 #define PIDTEMP
341
 #define PIDTEMP
342
-#define BANG_MAX 255 // limits current to nozzle while in bang-bang mode; 255=full current
343
-#define PID_MAX BANG_MAX // limits current to nozzle while PID is active (see PID_FUNCTIONAL_RANGE below); 255=full current
342
+#define BANG_MAX 255     // Limits current to nozzle while in bang-bang mode; 255=full current
343
+#define PID_MAX BANG_MAX // Limits current to nozzle while PID is active (see PID_FUNCTIONAL_RANGE below); 255=full current
344
+#define PID_K1 0.95      // Smoothing factor within the PID
344
 #if ENABLED(PIDTEMP)
345
 #if ENABLED(PIDTEMP)
345
   //#define PID_AUTOTUNE_MENU // Add PID Autotune to the LCD "Temperature" menu to run M303 and apply the result.
346
   //#define PID_AUTOTUNE_MENU // Add PID Autotune to the LCD "Temperature" menu to run M303 and apply the result.
346
   //#define PID_DEBUG // Sends debug data to the serial port.
347
   //#define PID_DEBUG // Sends debug data to the serial port.
350
                                   // Set/get with gcode: M301 E[extruder number, 0-2]
351
                                   // Set/get with gcode: M301 E[extruder number, 0-2]
351
   #define PID_FUNCTIONAL_RANGE 10 // If the temperature difference between the target temperature and the actual temperature
352
   #define PID_FUNCTIONAL_RANGE 10 // If the temperature difference between the target temperature and the actual temperature
352
                                   // is more than PID_FUNCTIONAL_RANGE then the PID will be shut off and the heater will be set to min/max.
353
                                   // is more than PID_FUNCTIONAL_RANGE then the PID will be shut off and the heater will be set to min/max.
353
-  #define K1 0.95 //smoothing factor within the PID
354
 
354
 
355
   // If you are using a pre-configured hotend then you can use one of the value sets by uncommenting it
355
   // If you are using a pre-configured hotend then you can use one of the value sets by uncommenting it
356
 
356
 

+ 3
- 3
Marlin/example_configurations/Infitary/i3-M508/Configuration.h View File

339
 
339
 
340
 // Comment the following line to disable PID and enable bang-bang.
340
 // Comment the following line to disable PID and enable bang-bang.
341
 #define PIDTEMP
341
 #define PIDTEMP
342
-#define BANG_MAX 255 // limits current to nozzle while in bang-bang mode; 255=full current
343
-#define PID_MAX BANG_MAX // limits current to nozzle while PID is active (see PID_FUNCTIONAL_RANGE below); 255=full current
342
+#define BANG_MAX 255     // Limits current to nozzle while in bang-bang mode; 255=full current
343
+#define PID_MAX BANG_MAX // Limits current to nozzle while PID is active (see PID_FUNCTIONAL_RANGE below); 255=full current
344
+#define PID_K1 0.95      // Smoothing factor within the PID
344
 #if ENABLED(PIDTEMP)
345
 #if ENABLED(PIDTEMP)
345
   //#define PID_AUTOTUNE_MENU // Add PID Autotune to the LCD "Temperature" menu to run M303 and apply the result.
346
   //#define PID_AUTOTUNE_MENU // Add PID Autotune to the LCD "Temperature" menu to run M303 and apply the result.
346
   //#define PID_DEBUG // Sends debug data to the serial port.
347
   //#define PID_DEBUG // Sends debug data to the serial port.
350
                                   // Set/get with gcode: M301 E[extruder number, 0-2]
351
                                   // Set/get with gcode: M301 E[extruder number, 0-2]
351
   #define PID_FUNCTIONAL_RANGE 10 // If the temperature difference between the target temperature and the actual temperature
352
   #define PID_FUNCTIONAL_RANGE 10 // If the temperature difference between the target temperature and the actual temperature
352
                                   // is more than PID_FUNCTIONAL_RANGE then the PID will be shut off and the heater will be set to min/max.
353
                                   // is more than PID_FUNCTIONAL_RANGE then the PID will be shut off and the heater will be set to min/max.
353
-  #define K1 0.95 //smoothing factor within the PID
354
 
354
 
355
   // If you are using a pre-configured hotend then you can use one of the value sets by uncommenting it
355
   // If you are using a pre-configured hotend then you can use one of the value sets by uncommenting it
356
 
356
 

+ 3
- 3
Marlin/example_configurations/Malyan/M150/Configuration.h View File

347
 
347
 
348
 // Comment the following line to disable PID and enable bang-bang.
348
 // Comment the following line to disable PID and enable bang-bang.
349
 #define PIDTEMP
349
 #define PIDTEMP
350
-#define BANG_MAX 255 // limits current to nozzle while in bang-bang mode; 255=full current
351
-#define PID_MAX BANG_MAX // limits current to nozzle while PID is active (see PID_FUNCTIONAL_RANGE below); 255=full current
350
+#define BANG_MAX 255     // Limits current to nozzle while in bang-bang mode; 255=full current
351
+#define PID_MAX BANG_MAX // Limits current to nozzle while PID is active (see PID_FUNCTIONAL_RANGE below); 255=full current
352
+#define PID_K1 0.95      // Smoothing factor within the PID
352
 #if ENABLED(PIDTEMP)
353
 #if ENABLED(PIDTEMP)
353
   //#define PID_AUTOTUNE_MENU // Add PID Autotune to the LCD "Temperature" menu to run M303 and apply the result.
354
   //#define PID_AUTOTUNE_MENU // Add PID Autotune to the LCD "Temperature" menu to run M303 and apply the result.
354
   //#define PID_DEBUG // Sends debug data to the serial port.
355
   //#define PID_DEBUG // Sends debug data to the serial port.
358
                                   // Set/get with gcode: M301 E[extruder number, 0-2]
359
                                   // Set/get with gcode: M301 E[extruder number, 0-2]
359
   #define PID_FUNCTIONAL_RANGE 10 // If the temperature difference between the target temperature and the actual temperature
360
   #define PID_FUNCTIONAL_RANGE 10 // If the temperature difference between the target temperature and the actual temperature
360
                                   // is more than PID_FUNCTIONAL_RANGE then the PID will be shut off and the heater will be set to min/max.
361
                                   // is more than PID_FUNCTIONAL_RANGE then the PID will be shut off and the heater will be set to min/max.
361
-  #define K1 0.95 //smoothing factor within the PID
362
 
362
 
363
   // If you are using a pre-configured hotend then you can use one of the value sets by uncommenting it
363
   // If you are using a pre-configured hotend then you can use one of the value sets by uncommenting it
364
 
364
 

+ 3
- 3
Marlin/example_configurations/Micromake/C1/basic/Configuration.h View File

339
 
339
 
340
 // Comment the following line to disable PID and enable bang-bang.
340
 // Comment the following line to disable PID and enable bang-bang.
341
 #define PIDTEMP
341
 #define PIDTEMP
342
-#define BANG_MAX 255 // limits current to nozzle while in bang-bang mode; 255=full current
343
-#define PID_MAX BANG_MAX // limits current to nozzle while PID is active (see PID_FUNCTIONAL_RANGE below); 255=full current
342
+#define BANG_MAX 255     // Limits current to nozzle while in bang-bang mode; 255=full current
343
+#define PID_MAX BANG_MAX // Limits current to nozzle while PID is active (see PID_FUNCTIONAL_RANGE below); 255=full current
344
+#define PID_K1 0.95      // Smoothing factor within the PID
344
 #if ENABLED(PIDTEMP)
345
 #if ENABLED(PIDTEMP)
345
   //#define PID_AUTOTUNE_MENU // Add PID Autotune to the LCD "Temperature" menu to run M303 and apply the result.
346
   //#define PID_AUTOTUNE_MENU // Add PID Autotune to the LCD "Temperature" menu to run M303 and apply the result.
346
   //#define PID_DEBUG // Sends debug data to the serial port.
347
   //#define PID_DEBUG // Sends debug data to the serial port.
350
                                   // Set/get with gcode: M301 E[extruder number, 0-2]
351
                                   // Set/get with gcode: M301 E[extruder number, 0-2]
351
   #define PID_FUNCTIONAL_RANGE 10 // If the temperature difference between the target temperature and the actual temperature
352
   #define PID_FUNCTIONAL_RANGE 10 // If the temperature difference between the target temperature and the actual temperature
352
                                   // is more than PID_FUNCTIONAL_RANGE then the PID will be shut off and the heater will be set to min/max.
353
                                   // is more than PID_FUNCTIONAL_RANGE then the PID will be shut off and the heater will be set to min/max.
353
-  #define K1 0.95 //smoothing factor within the PID
354
 
354
 
355
   // If you are using a pre-configured hotend then you can use one of the value sets by uncommenting it
355
   // If you are using a pre-configured hotend then you can use one of the value sets by uncommenting it
356
 
356
 

+ 3
- 3
Marlin/example_configurations/Micromake/C1/enhanced/Configuration.h View File

339
 
339
 
340
 // Comment the following line to disable PID and enable bang-bang.
340
 // Comment the following line to disable PID and enable bang-bang.
341
 #define PIDTEMP
341
 #define PIDTEMP
342
-#define BANG_MAX 255 // limits current to nozzle while in bang-bang mode; 255=full current
343
-#define PID_MAX BANG_MAX // limits current to nozzle while PID is active (see PID_FUNCTIONAL_RANGE below); 255=full current
342
+#define BANG_MAX 255     // Limits current to nozzle while in bang-bang mode; 255=full current
343
+#define PID_MAX BANG_MAX // Limits current to nozzle while PID is active (see PID_FUNCTIONAL_RANGE below); 255=full current
344
+#define PID_K1 0.95      // Smoothing factor within the PID
344
 #if ENABLED(PIDTEMP)
345
 #if ENABLED(PIDTEMP)
345
   //#define PID_AUTOTUNE_MENU // Add PID Autotune to the LCD "Temperature" menu to run M303 and apply the result.
346
   //#define PID_AUTOTUNE_MENU // Add PID Autotune to the LCD "Temperature" menu to run M303 and apply the result.
346
   //#define PID_DEBUG // Sends debug data to the serial port.
347
   //#define PID_DEBUG // Sends debug data to the serial port.
350
                                   // Set/get with gcode: M301 E[extruder number, 0-2]
351
                                   // Set/get with gcode: M301 E[extruder number, 0-2]
351
   #define PID_FUNCTIONAL_RANGE 10 // If the temperature difference between the target temperature and the actual temperature
352
   #define PID_FUNCTIONAL_RANGE 10 // If the temperature difference between the target temperature and the actual temperature
352
                                   // is more than PID_FUNCTIONAL_RANGE then the PID will be shut off and the heater will be set to min/max.
353
                                   // is more than PID_FUNCTIONAL_RANGE then the PID will be shut off and the heater will be set to min/max.
353
-  #define K1 0.95 //smoothing factor within the PID
354
 
354
 
355
   // If you are using a pre-configured hotend then you can use one of the value sets by uncommenting it
355
   // If you are using a pre-configured hotend then you can use one of the value sets by uncommenting it
356
 
356
 

+ 3
- 3
Marlin/example_configurations/RepRapWorld/Megatronics/Configuration.h View File

339
 
339
 
340
 // Comment the following line to disable PID and enable bang-bang.
340
 // Comment the following line to disable PID and enable bang-bang.
341
 #define PIDTEMP
341
 #define PIDTEMP
342
-#define BANG_MAX 255 // limits current to nozzle while in bang-bang mode; 255=full current
343
-#define PID_MAX BANG_MAX // limits current to nozzle while PID is active (see PID_FUNCTIONAL_RANGE below); 255=full current
342
+#define BANG_MAX 255     // Limits current to nozzle while in bang-bang mode; 255=full current
343
+#define PID_MAX BANG_MAX // Limits current to nozzle while PID is active (see PID_FUNCTIONAL_RANGE below); 255=full current
344
+#define PID_K1 0.95      // Smoothing factor within the PID
344
 #if ENABLED(PIDTEMP)
345
 #if ENABLED(PIDTEMP)
345
   //#define PID_AUTOTUNE_MENU // Add PID Autotune to the LCD "Temperature" menu to run M303 and apply the result.
346
   //#define PID_AUTOTUNE_MENU // Add PID Autotune to the LCD "Temperature" menu to run M303 and apply the result.
346
   //#define PID_DEBUG // Sends debug data to the serial port.
347
   //#define PID_DEBUG // Sends debug data to the serial port.
350
                                   // Set/get with gcode: M301 E[extruder number, 0-2]
351
                                   // Set/get with gcode: M301 E[extruder number, 0-2]
351
   #define PID_FUNCTIONAL_RANGE 10 // If the temperature difference between the target temperature and the actual temperature
352
   #define PID_FUNCTIONAL_RANGE 10 // If the temperature difference between the target temperature and the actual temperature
352
                                   // is more than PID_FUNCTIONAL_RANGE then the PID will be shut off and the heater will be set to min/max.
353
                                   // is more than PID_FUNCTIONAL_RANGE then the PID will be shut off and the heater will be set to min/max.
353
-  #define K1 0.95 //smoothing factor within the PID
354
 
354
 
355
   // If you are using a pre-configured hotend then you can use one of the value sets by uncommenting it
355
   // If you are using a pre-configured hotend then you can use one of the value sets by uncommenting it
356
 
356
 

+ 3
- 3
Marlin/example_configurations/RigidBot/Configuration.h View File

342
 
342
 
343
 // Comment the following line to disable PID and enable bang-bang.
343
 // Comment the following line to disable PID and enable bang-bang.
344
 #define PIDTEMP
344
 #define PIDTEMP
345
-#define BANG_MAX 255 // limits current to nozzle while in bang-bang mode; 255=full current
346
-#define PID_MAX BANG_MAX // limits current to nozzle while PID is active (see PID_FUNCTIONAL_RANGE below); 255=full current
345
+#define BANG_MAX 255     // Limits current to nozzle while in bang-bang mode; 255=full current
346
+#define PID_MAX BANG_MAX // Limits current to nozzle while PID is active (see PID_FUNCTIONAL_RANGE below); 255=full current
347
+#define PID_K1 0.95      // Smoothing factor within the PID
347
 #if ENABLED(PIDTEMP)
348
 #if ENABLED(PIDTEMP)
348
   //#define PID_AUTOTUNE_MENU // Add PID Autotune to the LCD "Temperature" menu to run M303 and apply the result.
349
   //#define PID_AUTOTUNE_MENU // Add PID Autotune to the LCD "Temperature" menu to run M303 and apply the result.
349
   //#define PID_DEBUG // Sends debug data to the serial port.
350
   //#define PID_DEBUG // Sends debug data to the serial port.
353
                                   // Set/get with gcode: M301 E[extruder number, 0-2]
354
                                   // Set/get with gcode: M301 E[extruder number, 0-2]
354
   #define PID_FUNCTIONAL_RANGE 10 // If the temperature difference between the target temperature and the actual temperature
355
   #define PID_FUNCTIONAL_RANGE 10 // If the temperature difference between the target temperature and the actual temperature
355
                                   // is more than PID_FUNCTIONAL_RANGE then the PID will be shut off and the heater will be set to min/max.
356
                                   // is more than PID_FUNCTIONAL_RANGE then the PID will be shut off and the heater will be set to min/max.
356
-  #define K1 0.95 //smoothing factor within the PID
357
 
357
 
358
   // If you are using a pre-configured hotend then you can use one of the value sets by uncommenting it
358
   // If you are using a pre-configured hotend then you can use one of the value sets by uncommenting it
359
 
359
 

+ 3
- 3
Marlin/example_configurations/SCARA/Configuration.h View File

369
 
369
 
370
 // Comment the following line to disable PID and enable bang-bang.
370
 // Comment the following line to disable PID and enable bang-bang.
371
 #define PIDTEMP
371
 #define PIDTEMP
372
-#define BANG_MAX 255 // limits current to nozzle while in bang-bang mode; 255=full current
373
-#define PID_MAX BANG_MAX // limits current to nozzle while PID is active (see PID_FUNCTIONAL_RANGE below); 255=full current
372
+#define BANG_MAX 255     // Limits current to nozzle while in bang-bang mode; 255=full current
373
+#define PID_MAX BANG_MAX // Limits current to nozzle while PID is active (see PID_FUNCTIONAL_RANGE below); 255=full current
374
+#define PID_K1 0.95      // Smoothing factor within the PID
374
 #if ENABLED(PIDTEMP)
375
 #if ENABLED(PIDTEMP)
375
   //#define PID_AUTOTUNE_MENU // Add PID Autotune to the LCD "Temperature" menu to run M303 and apply the result.
376
   //#define PID_AUTOTUNE_MENU // Add PID Autotune to the LCD "Temperature" menu to run M303 and apply the result.
376
   //#define PID_DEBUG // Sends debug data to the serial port.
377
   //#define PID_DEBUG // Sends debug data to the serial port.
380
                                   // Set/get with gcode: M301 E[extruder number, 0-2]
381
                                   // Set/get with gcode: M301 E[extruder number, 0-2]
381
   #define PID_FUNCTIONAL_RANGE 20 // If the temperature difference between the target temperature and the actual temperature
382
   #define PID_FUNCTIONAL_RANGE 20 // If the temperature difference between the target temperature and the actual temperature
382
                                   // is more than PID_FUNCTIONAL_RANGE then the PID will be shut off and the heater will be set to min/max.
383
                                   // is more than PID_FUNCTIONAL_RANGE then the PID will be shut off and the heater will be set to min/max.
383
-  #define K1 0.95 //smoothing factor within the PID
384
 
384
 
385
   // Merlin Hotend: From Autotune
385
   // Merlin Hotend: From Autotune
386
   #define  DEFAULT_Kp 24.5
386
   #define  DEFAULT_Kp 24.5

+ 3
- 3
Marlin/example_configurations/Sanguinololu/Configuration.h View File

339
 
339
 
340
 // Comment the following line to disable PID and enable bang-bang.
340
 // Comment the following line to disable PID and enable bang-bang.
341
 #define PIDTEMP
341
 #define PIDTEMP
342
-#define BANG_MAX 255 // limits current to nozzle while in bang-bang mode; 255=full current
343
-#define PID_MAX BANG_MAX // limits current to nozzle while PID is active (see PID_FUNCTIONAL_RANGE below); 255=full current
342
+#define BANG_MAX 255     // Limits current to nozzle while in bang-bang mode; 255=full current
343
+#define PID_MAX BANG_MAX // Limits current to nozzle while PID is active (see PID_FUNCTIONAL_RANGE below); 255=full current
344
+#define PID_K1 0.95      // Smoothing factor within the PID
344
 #if ENABLED(PIDTEMP)
345
 #if ENABLED(PIDTEMP)
345
   //#define PID_AUTOTUNE_MENU // Add PID Autotune to the LCD "Temperature" menu to run M303 and apply the result.
346
   //#define PID_AUTOTUNE_MENU // Add PID Autotune to the LCD "Temperature" menu to run M303 and apply the result.
346
   //#define PID_DEBUG // Sends debug data to the serial port.
347
   //#define PID_DEBUG // Sends debug data to the serial port.
350
                                   // Set/get with gcode: M301 E[extruder number, 0-2]
351
                                   // Set/get with gcode: M301 E[extruder number, 0-2]
351
   #define PID_FUNCTIONAL_RANGE 10 // If the temperature difference between the target temperature and the actual temperature
352
   #define PID_FUNCTIONAL_RANGE 10 // If the temperature difference between the target temperature and the actual temperature
352
                                   // is more than PID_FUNCTIONAL_RANGE then the PID will be shut off and the heater will be set to min/max.
353
                                   // is more than PID_FUNCTIONAL_RANGE then the PID will be shut off and the heater will be set to min/max.
353
-  #define K1 0.95 //smoothing factor within the PID
354
 
354
 
355
   // If you are using a pre-configured hotend then you can use one of the value sets by uncommenting it
355
   // If you are using a pre-configured hotend then you can use one of the value sets by uncommenting it
356
 
356
 

+ 3
- 3
Marlin/example_configurations/TinyBoy2/Configuration.h View File

366
 
366
 
367
 // Comment the following line to disable PID and enable bang-bang.
367
 // Comment the following line to disable PID and enable bang-bang.
368
 #define PIDTEMP
368
 #define PIDTEMP
369
-#define BANG_MAX 255 // limits current to nozzle while in bang-bang mode; 255=full current
370
-#define PID_MAX BANG_MAX // limits current to nozzle while PID is active (see PID_FUNCTIONAL_RANGE below); 255=full current
369
+#define BANG_MAX 255     // Limits current to nozzle while in bang-bang mode; 255=full current
370
+#define PID_MAX BANG_MAX // Limits current to nozzle while PID is active (see PID_FUNCTIONAL_RANGE below); 255=full current
371
+#define PID_K1 0.95      // Smoothing factor within the PID
371
 #if ENABLED(PIDTEMP)
372
 #if ENABLED(PIDTEMP)
372
   //#define PID_AUTOTUNE_MENU // Add PID Autotune to the LCD "Temperature" menu to run M303 and apply the result.
373
   //#define PID_AUTOTUNE_MENU // Add PID Autotune to the LCD "Temperature" menu to run M303 and apply the result.
373
   //#define PID_DEBUG // Sends debug data to the serial port.
374
   //#define PID_DEBUG // Sends debug data to the serial port.
377
                                   // Set/get with gcode: M301 E[extruder number, 0-2]
378
                                   // Set/get with gcode: M301 E[extruder number, 0-2]
378
   #define PID_FUNCTIONAL_RANGE 10 // If the temperature difference between the target temperature and the actual temperature
379
   #define PID_FUNCTIONAL_RANGE 10 // If the temperature difference between the target temperature and the actual temperature
379
                                   // is more than PID_FUNCTIONAL_RANGE then the PID will be shut off and the heater will be set to min/max.
380
                                   // is more than PID_FUNCTIONAL_RANGE then the PID will be shut off and the heater will be set to min/max.
380
-  #define K1 0.95 //smoothing factor within the PID
381
 
381
 
382
   // If you are using a pre-configured hotend then you can use one of the value sets by uncommenting it
382
   // If you are using a pre-configured hotend then you can use one of the value sets by uncommenting it
383
 
383
 

+ 3
- 3
Marlin/example_configurations/Velleman/K8200/Configuration.h View File

359
 
359
 
360
 // Comment the following line to disable PID and enable bang-bang.
360
 // Comment the following line to disable PID and enable bang-bang.
361
 #define PIDTEMP
361
 #define PIDTEMP
362
-#define BANG_MAX 255 // limits current to nozzle while in bang-bang mode; 255=full current
363
-#define PID_MAX BANG_MAX // limits current to nozzle while PID is active (see PID_FUNCTIONAL_RANGE below); 255=full current
362
+#define BANG_MAX 255     // Limits current to nozzle while in bang-bang mode; 255=full current
363
+#define PID_MAX BANG_MAX // Limits current to nozzle while PID is active (see PID_FUNCTIONAL_RANGE below); 255=full current
364
+#define PID_K1 0.95      // Smoothing factor within the PID
364
 #if ENABLED(PIDTEMP)
365
 #if ENABLED(PIDTEMP)
365
   //#define PID_AUTOTUNE_MENU // Add PID Autotune to the LCD "Temperature" menu to run M303 and apply the result.
366
   //#define PID_AUTOTUNE_MENU // Add PID Autotune to the LCD "Temperature" menu to run M303 and apply the result.
366
   //#define PID_DEBUG // Sends debug data to the serial port.
367
   //#define PID_DEBUG // Sends debug data to the serial port.
370
                                   // Set/get with gcode: M301 E[extruder number, 0-2]
371
                                   // Set/get with gcode: M301 E[extruder number, 0-2]
371
   #define PID_FUNCTIONAL_RANGE 10 // If the temperature difference between the target temperature and the actual temperature
372
   #define PID_FUNCTIONAL_RANGE 10 // If the temperature difference between the target temperature and the actual temperature
372
                                   // is more than PID_FUNCTIONAL_RANGE then the PID will be shut off and the heater will be set to min/max.
373
                                   // is more than PID_FUNCTIONAL_RANGE then the PID will be shut off and the heater will be set to min/max.
373
-  #define K1 0.95 //smoothing factor within the PID
374
 
374
 
375
   // If you are using a pre-configured hotend then you can use one of the value sets by uncommenting it
375
   // If you are using a pre-configured hotend then you can use one of the value sets by uncommenting it
376
 
376
 

+ 3
- 3
Marlin/example_configurations/Velleman/K8400/Configuration.h View File

339
 
339
 
340
 // Comment the following line to disable PID and enable bang-bang.
340
 // Comment the following line to disable PID and enable bang-bang.
341
 #define PIDTEMP
341
 #define PIDTEMP
342
-#define BANG_MAX 255 // limits current to nozzle while in bang-bang mode; 255=full current
343
-#define PID_MAX BANG_MAX // limits current to nozzle while PID is active (see PID_FUNCTIONAL_RANGE below); 255=full current
342
+#define BANG_MAX 255     // Limits current to nozzle while in bang-bang mode; 255=full current
343
+#define PID_MAX BANG_MAX // Limits current to nozzle while PID is active (see PID_FUNCTIONAL_RANGE below); 255=full current
344
+#define PID_K1 0.95      // Smoothing factor within the PID
344
 #if ENABLED(PIDTEMP)
345
 #if ENABLED(PIDTEMP)
345
   //#define PID_AUTOTUNE_MENU // Add PID Autotune to the LCD "Temperature" menu to run M303 and apply the result.
346
   //#define PID_AUTOTUNE_MENU // Add PID Autotune to the LCD "Temperature" menu to run M303 and apply the result.
346
   //#define PID_DEBUG // Sends debug data to the serial port.
347
   //#define PID_DEBUG // Sends debug data to the serial port.
350
                                   // Set/get with gcode: M301 E[extruder number, 0-2]
351
                                   // Set/get with gcode: M301 E[extruder number, 0-2]
351
   #define PID_FUNCTIONAL_RANGE 10 // If the temperature difference between the target temperature and the actual temperature
352
   #define PID_FUNCTIONAL_RANGE 10 // If the temperature difference between the target temperature and the actual temperature
352
                                   // is more than PID_FUNCTIONAL_RANGE then the PID will be shut off and the heater will be set to min/max.
353
                                   // is more than PID_FUNCTIONAL_RANGE then the PID will be shut off and the heater will be set to min/max.
353
-  #define K1 0.95 //smoothing factor within the PID
354
 
354
 
355
   // If you are using a pre-configured hotend then you can use one of the value sets by uncommenting it
355
   // If you are using a pre-configured hotend then you can use one of the value sets by uncommenting it
356
 
356
 

+ 3
- 3
Marlin/example_configurations/Velleman/K8400/Dual-head/Configuration.h View File

339
 
339
 
340
 // Comment the following line to disable PID and enable bang-bang.
340
 // Comment the following line to disable PID and enable bang-bang.
341
 #define PIDTEMP
341
 #define PIDTEMP
342
-#define BANG_MAX 255 // limits current to nozzle while in bang-bang mode; 255=full current
343
-#define PID_MAX BANG_MAX // limits current to nozzle while PID is active (see PID_FUNCTIONAL_RANGE below); 255=full current
342
+#define BANG_MAX 255     // Limits current to nozzle while in bang-bang mode; 255=full current
343
+#define PID_MAX BANG_MAX // Limits current to nozzle while PID is active (see PID_FUNCTIONAL_RANGE below); 255=full current
344
+#define PID_K1 0.95      // Smoothing factor within the PID
344
 #if ENABLED(PIDTEMP)
345
 #if ENABLED(PIDTEMP)
345
   //#define PID_AUTOTUNE_MENU // Add PID Autotune to the LCD "Temperature" menu to run M303 and apply the result.
346
   //#define PID_AUTOTUNE_MENU // Add PID Autotune to the LCD "Temperature" menu to run M303 and apply the result.
346
   //#define PID_DEBUG // Sends debug data to the serial port.
347
   //#define PID_DEBUG // Sends debug data to the serial port.
350
                                   // Set/get with gcode: M301 E[extruder number, 0-2]
351
                                   // Set/get with gcode: M301 E[extruder number, 0-2]
351
   #define PID_FUNCTIONAL_RANGE 10 // If the temperature difference between the target temperature and the actual temperature
352
   #define PID_FUNCTIONAL_RANGE 10 // If the temperature difference between the target temperature and the actual temperature
352
                                   // is more than PID_FUNCTIONAL_RANGE then the PID will be shut off and the heater will be set to min/max.
353
                                   // is more than PID_FUNCTIONAL_RANGE then the PID will be shut off and the heater will be set to min/max.
353
-  #define K1 0.95 //smoothing factor within the PID
354
 
354
 
355
   // If you are using a pre-configured hotend then you can use one of the value sets by uncommenting it
355
   // If you are using a pre-configured hotend then you can use one of the value sets by uncommenting it
356
 
356
 

+ 3
- 3
Marlin/example_configurations/Wanhao/Duplicator 6/Configuration.h View File

339
 
339
 
340
 // Comment the following line to disable PID and enable bang-bang.
340
 // Comment the following line to disable PID and enable bang-bang.
341
 #define PIDTEMP
341
 #define PIDTEMP
342
-#define BANG_MAX 255 // limits current to nozzle while in bang-bang mode; 255=full current
343
-#define PID_MAX BANG_MAX // limits current to nozzle while PID is active (see PID_FUNCTIONAL_RANGE below); 255=full current
342
+#define BANG_MAX 255     // Limits current to nozzle while in bang-bang mode; 255=full current
343
+#define PID_MAX BANG_MAX // Limits current to nozzle while PID is active (see PID_FUNCTIONAL_RANGE below); 255=full current
344
+#define PID_K1 0.95      // Smoothing factor within the PID
344
 #if ENABLED(PIDTEMP)
345
 #if ENABLED(PIDTEMP)
345
   #define PID_AUTOTUNE_MENU // Add PID Autotune to the LCD "Temperature" menu to run M303 and apply the result.
346
   #define PID_AUTOTUNE_MENU // Add PID Autotune to the LCD "Temperature" menu to run M303 and apply the result.
346
   //#define PID_DEBUG // Sends debug data to the serial port.
347
   //#define PID_DEBUG // Sends debug data to the serial port.
350
                                   // Set/get with gcode: M301 E[extruder number, 0-2]
351
                                   // Set/get with gcode: M301 E[extruder number, 0-2]
351
   #define PID_FUNCTIONAL_RANGE 10 // If the temperature difference between the target temperature and the actual temperature
352
   #define PID_FUNCTIONAL_RANGE 10 // If the temperature difference between the target temperature and the actual temperature
352
                                   // is more than PID_FUNCTIONAL_RANGE then the PID will be shut off and the heater will be set to min/max.
353
                                   // is more than PID_FUNCTIONAL_RANGE then the PID will be shut off and the heater will be set to min/max.
353
-  #define K1 0.95 //smoothing factor within the PID
354
 
354
 
355
   // If you are using a pre-configured hotend then you can use one of the value sets by uncommenting it
355
   // If you are using a pre-configured hotend then you can use one of the value sets by uncommenting it
356
 
356
 

+ 3
- 3
Marlin/example_configurations/adafruit/ST7565/Configuration.h View File

339
 
339
 
340
 // Comment the following line to disable PID and enable bang-bang.
340
 // Comment the following line to disable PID and enable bang-bang.
341
 #define PIDTEMP
341
 #define PIDTEMP
342
-#define BANG_MAX 255 // limits current to nozzle while in bang-bang mode; 255=full current
343
-#define PID_MAX BANG_MAX // limits current to nozzle while PID is active (see PID_FUNCTIONAL_RANGE below); 255=full current
342
+#define BANG_MAX 255     // Limits current to nozzle while in bang-bang mode; 255=full current
343
+#define PID_MAX BANG_MAX // Limits current to nozzle while PID is active (see PID_FUNCTIONAL_RANGE below); 255=full current
344
+#define PID_K1 0.95      // Smoothing factor within the PID
344
 #if ENABLED(PIDTEMP)
345
 #if ENABLED(PIDTEMP)
345
   //#define PID_AUTOTUNE_MENU // Add PID Autotune to the LCD "Temperature" menu to run M303 and apply the result.
346
   //#define PID_AUTOTUNE_MENU // Add PID Autotune to the LCD "Temperature" menu to run M303 and apply the result.
346
   //#define PID_DEBUG // Sends debug data to the serial port.
347
   //#define PID_DEBUG // Sends debug data to the serial port.
350
                                   // Set/get with gcode: M301 E[extruder number, 0-2]
351
                                   // Set/get with gcode: M301 E[extruder number, 0-2]
351
   #define PID_FUNCTIONAL_RANGE 10 // If the temperature difference between the target temperature and the actual temperature
352
   #define PID_FUNCTIONAL_RANGE 10 // If the temperature difference between the target temperature and the actual temperature
352
                                   // is more than PID_FUNCTIONAL_RANGE then the PID will be shut off and the heater will be set to min/max.
353
                                   // is more than PID_FUNCTIONAL_RANGE then the PID will be shut off and the heater will be set to min/max.
353
-  #define K1 0.95 //smoothing factor within the PID
354
 
354
 
355
   // If you are using a pre-configured hotend then you can use one of the value sets by uncommenting it
355
   // If you are using a pre-configured hotend then you can use one of the value sets by uncommenting it
356
 
356
 

+ 3
- 3
Marlin/example_configurations/delta/FLSUN/auto_calibrate/Configuration.h View File

339
 
339
 
340
 // Comment the following line to disable PID and enable bang-bang.
340
 // Comment the following line to disable PID and enable bang-bang.
341
 #define PIDTEMP
341
 #define PIDTEMP
342
-#define BANG_MAX 255 // limits current to nozzle while in bang-bang mode; 255=full current
343
-#define PID_MAX BANG_MAX // limits current to nozzle while PID is active (see PID_FUNCTIONAL_RANGE below); 255=full current
342
+#define BANG_MAX 255     // Limits current to nozzle while in bang-bang mode; 255=full current
343
+#define PID_MAX BANG_MAX // Limits current to nozzle while PID is active (see PID_FUNCTIONAL_RANGE below); 255=full current
344
+#define PID_K1 0.95      // Smoothing factor within the PID
344
 #if ENABLED(PIDTEMP)
345
 #if ENABLED(PIDTEMP)
345
   #define PID_AUTOTUNE_MENU // Add PID Autotune to the LCD "Temperature" menu to run M303 and apply the result.
346
   #define PID_AUTOTUNE_MENU // Add PID Autotune to the LCD "Temperature" menu to run M303 and apply the result.
346
   //#define PID_DEBUG // Sends debug data to the serial port.
347
   //#define PID_DEBUG // Sends debug data to the serial port.
350
                                   // Set/get with gcode: M301 E[extruder number, 0-2]
351
                                   // Set/get with gcode: M301 E[extruder number, 0-2]
351
   #define PID_FUNCTIONAL_RANGE 10 // If the temperature difference between the target temperature and the actual temperature
352
   #define PID_FUNCTIONAL_RANGE 10 // If the temperature difference between the target temperature and the actual temperature
352
                                   // is more than PID_FUNCTIONAL_RANGE then the PID will be shut off and the heater will be set to min/max.
353
                                   // is more than PID_FUNCTIONAL_RANGE then the PID will be shut off and the heater will be set to min/max.
353
-  #define K1 0.95 //smoothing factor within the PID
354
 
354
 
355
   // If you are using a pre-configured hotend then you can use one of the value sets by uncommenting it
355
   // If you are using a pre-configured hotend then you can use one of the value sets by uncommenting it
356
 
356
 

+ 3
- 3
Marlin/example_configurations/delta/FLSUN/kossel_mini/Configuration.h View File

339
 
339
 
340
 // Comment the following line to disable PID and enable bang-bang.
340
 // Comment the following line to disable PID and enable bang-bang.
341
 #define PIDTEMP
341
 #define PIDTEMP
342
-#define BANG_MAX 255 // limits current to nozzle while in bang-bang mode; 255=full current
343
-#define PID_MAX BANG_MAX // limits current to nozzle while PID is active (see PID_FUNCTIONAL_RANGE below); 255=full current
342
+#define BANG_MAX 255     // Limits current to nozzle while in bang-bang mode; 255=full current
343
+#define PID_MAX BANG_MAX // Limits current to nozzle while PID is active (see PID_FUNCTIONAL_RANGE below); 255=full current
344
+#define PID_K1 0.95      // Smoothing factor within the PID
344
 #if ENABLED(PIDTEMP)
345
 #if ENABLED(PIDTEMP)
345
   #define PID_AUTOTUNE_MENU // Add PID Autotune to the LCD "Temperature" menu to run M303 and apply the result.
346
   #define PID_AUTOTUNE_MENU // Add PID Autotune to the LCD "Temperature" menu to run M303 and apply the result.
346
   //#define PID_DEBUG // Sends debug data to the serial port.
347
   //#define PID_DEBUG // Sends debug data to the serial port.
350
                                   // Set/get with gcode: M301 E[extruder number, 0-2]
351
                                   // Set/get with gcode: M301 E[extruder number, 0-2]
351
   #define PID_FUNCTIONAL_RANGE 10 // If the temperature difference between the target temperature and the actual temperature
352
   #define PID_FUNCTIONAL_RANGE 10 // If the temperature difference between the target temperature and the actual temperature
352
                                   // is more than PID_FUNCTIONAL_RANGE then the PID will be shut off and the heater will be set to min/max.
353
                                   // is more than PID_FUNCTIONAL_RANGE then the PID will be shut off and the heater will be set to min/max.
353
-  #define K1 0.95 //smoothing factor within the PID
354
 
354
 
355
   // If you are using a pre-configured hotend then you can use one of the value sets by uncommenting it
355
   // If you are using a pre-configured hotend then you can use one of the value sets by uncommenting it
356
 
356
 

+ 3
- 3
Marlin/example_configurations/delta/generic/Configuration.h View File

339
 
339
 
340
 // Comment the following line to disable PID and enable bang-bang.
340
 // Comment the following line to disable PID and enable bang-bang.
341
 #define PIDTEMP
341
 #define PIDTEMP
342
-#define BANG_MAX 255 // limits current to nozzle while in bang-bang mode; 255=full current
343
-#define PID_MAX BANG_MAX // limits current to nozzle while PID is active (see PID_FUNCTIONAL_RANGE below); 255=full current
342
+#define BANG_MAX 255     // Limits current to nozzle while in bang-bang mode; 255=full current
343
+#define PID_MAX BANG_MAX // Limits current to nozzle while PID is active (see PID_FUNCTIONAL_RANGE below); 255=full current
344
+#define PID_K1 0.95      // Smoothing factor within the PID
344
 #if ENABLED(PIDTEMP)
345
 #if ENABLED(PIDTEMP)
345
   //#define PID_AUTOTUNE_MENU // Add PID Autotune to the LCD "Temperature" menu to run M303 and apply the result.
346
   //#define PID_AUTOTUNE_MENU // Add PID Autotune to the LCD "Temperature" menu to run M303 and apply the result.
346
   //#define PID_DEBUG // Sends debug data to the serial port.
347
   //#define PID_DEBUG // Sends debug data to the serial port.
350
                                   // Set/get with gcode: M301 E[extruder number, 0-2]
351
                                   // Set/get with gcode: M301 E[extruder number, 0-2]
351
   #define PID_FUNCTIONAL_RANGE 10 // If the temperature difference between the target temperature and the actual temperature
352
   #define PID_FUNCTIONAL_RANGE 10 // If the temperature difference between the target temperature and the actual temperature
352
                                   // is more than PID_FUNCTIONAL_RANGE then the PID will be shut off and the heater will be set to min/max.
353
                                   // is more than PID_FUNCTIONAL_RANGE then the PID will be shut off and the heater will be set to min/max.
353
-  #define K1 0.95 //smoothing factor within the PID
354
 
354
 
355
   // If you are using a pre-configured hotend then you can use one of the value sets by uncommenting it
355
   // If you are using a pre-configured hotend then you can use one of the value sets by uncommenting it
356
 
356
 

+ 3
- 3
Marlin/example_configurations/delta/kossel_mini/Configuration.h View File

339
 
339
 
340
 // Comment the following line to disable PID and enable bang-bang.
340
 // Comment the following line to disable PID and enable bang-bang.
341
 #define PIDTEMP
341
 #define PIDTEMP
342
-#define BANG_MAX 255 // limits current to nozzle while in bang-bang mode; 255=full current
343
-#define PID_MAX BANG_MAX // limits current to nozzle while PID is active (see PID_FUNCTIONAL_RANGE below); 255=full current
342
+#define BANG_MAX 255     // Limits current to nozzle while in bang-bang mode; 255=full current
343
+#define PID_MAX BANG_MAX // Limits current to nozzle while PID is active (see PID_FUNCTIONAL_RANGE below); 255=full current
344
+#define PID_K1 0.95      // Smoothing factor within the PID
344
 #if ENABLED(PIDTEMP)
345
 #if ENABLED(PIDTEMP)
345
   //#define PID_AUTOTUNE_MENU // Add PID Autotune to the LCD "Temperature" menu to run M303 and apply the result.
346
   //#define PID_AUTOTUNE_MENU // Add PID Autotune to the LCD "Temperature" menu to run M303 and apply the result.
346
   //#define PID_DEBUG // Sends debug data to the serial port.
347
   //#define PID_DEBUG // Sends debug data to the serial port.
350
                                   // Set/get with gcode: M301 E[extruder number, 0-2]
351
                                   // Set/get with gcode: M301 E[extruder number, 0-2]
351
   #define PID_FUNCTIONAL_RANGE 10 // If the temperature difference between the target temperature and the actual temperature
352
   #define PID_FUNCTIONAL_RANGE 10 // If the temperature difference between the target temperature and the actual temperature
352
                                   // is more than PID_FUNCTIONAL_RANGE then the PID will be shut off and the heater will be set to min/max.
353
                                   // is more than PID_FUNCTIONAL_RANGE then the PID will be shut off and the heater will be set to min/max.
353
-  #define K1 0.95 //smoothing factor within the PID
354
 
354
 
355
   // If you are using a pre-configured hotend then you can use one of the value sets by uncommenting it
355
   // If you are using a pre-configured hotend then you can use one of the value sets by uncommenting it
356
 
356
 

+ 3
- 3
Marlin/example_configurations/delta/kossel_pro/Configuration.h View File

343
 
343
 
344
 // Comment the following line to disable PID and enable bang-bang.
344
 // Comment the following line to disable PID and enable bang-bang.
345
 #define PIDTEMP
345
 #define PIDTEMP
346
-#define BANG_MAX 255 // limits current to nozzle while in bang-bang mode; 255=full current
347
-#define PID_MAX  125 // limits current to nozzle while PID is active (see PID_FUNCTIONAL_RANGE below); 255=full current
346
+#define BANG_MAX 255     // Limits current to nozzle while in bang-bang mode; 255=full current
347
+#define PID_MAX  125     // Limits current to nozzle while PID is active (see PID_FUNCTIONAL_RANGE below); 255=full current
348
+#define PID_K1 0.95      // Smoothing factor within the PID
348
 #if ENABLED(PIDTEMP)
349
 #if ENABLED(PIDTEMP)
349
   //#define PID_AUTOTUNE_MENU // Add PID Autotune to the LCD "Temperature" menu to run M303 and apply the result.
350
   //#define PID_AUTOTUNE_MENU // Add PID Autotune to the LCD "Temperature" menu to run M303 and apply the result.
350
   //#define PID_DEBUG // Sends debug data to the serial port.
351
   //#define PID_DEBUG // Sends debug data to the serial port.
354
                                   // Set/get with gcode: M301 E[extruder number, 0-2]
355
                                   // Set/get with gcode: M301 E[extruder number, 0-2]
355
   #define PID_FUNCTIONAL_RANGE 50 // If the temperature difference between the target temperature and the actual temperature
356
   #define PID_FUNCTIONAL_RANGE 50 // If the temperature difference between the target temperature and the actual temperature
356
                                   // is more than PID_FUNCTIONAL_RANGE then the PID will be shut off and the heater will be set to min/max.
357
                                   // is more than PID_FUNCTIONAL_RANGE then the PID will be shut off and the heater will be set to min/max.
357
-  #define K1 0.95 //smoothing factor within the PID
358
 
358
 
359
   // Kossel Pro
359
   // Kossel Pro
360
   #define  DEFAULT_Kp 19.30
360
   #define  DEFAULT_Kp 19.30

+ 3
- 3
Marlin/example_configurations/delta/kossel_xl/Configuration.h View File

339
 
339
 
340
 // Comment the following line to disable PID and enable bang-bang.
340
 // Comment the following line to disable PID and enable bang-bang.
341
 #define PIDTEMP
341
 #define PIDTEMP
342
-#define BANG_MAX 255 // limits current to nozzle while in bang-bang mode; 255=full current
343
-#define PID_MAX BANG_MAX // limits current to nozzle while PID is active (see PID_FUNCTIONAL_RANGE below); 255=full current
342
+#define BANG_MAX 255     // Limits current to nozzle while in bang-bang mode; 255=full current
343
+#define PID_MAX BANG_MAX // Limits current to nozzle while PID is active (see PID_FUNCTIONAL_RANGE below); 255=full current
344
+#define PID_K1 0.95      // Smoothing factor within the PID
344
 #if ENABLED(PIDTEMP)
345
 #if ENABLED(PIDTEMP)
345
   //#define PID_AUTOTUNE_MENU // Add PID Autotune to the LCD "Temperature" menu to run M303 and apply the result.
346
   //#define PID_AUTOTUNE_MENU // Add PID Autotune to the LCD "Temperature" menu to run M303 and apply the result.
346
   //#define PID_DEBUG // Sends debug data to the serial port.
347
   //#define PID_DEBUG // Sends debug data to the serial port.
350
                                   // Set/get with gcode: M301 E[extruder number, 0-2]
351
                                   // Set/get with gcode: M301 E[extruder number, 0-2]
351
   #define PID_FUNCTIONAL_RANGE 10 // If the temperature difference between the target temperature and the actual temperature
352
   #define PID_FUNCTIONAL_RANGE 10 // If the temperature difference between the target temperature and the actual temperature
352
                                   // is more than PID_FUNCTIONAL_RANGE then the PID will be shut off and the heater will be set to min/max.
353
                                   // is more than PID_FUNCTIONAL_RANGE then the PID will be shut off and the heater will be set to min/max.
353
-  #define K1 0.95 //smoothing factor within the PID
354
 
354
 
355
   // If you are using a pre-configured hotend then you can use one of the value sets by uncommenting it
355
   // If you are using a pre-configured hotend then you can use one of the value sets by uncommenting it
356
   // oXis Kossel k800 XL
356
   // oXis Kossel k800 XL

+ 3
- 3
Marlin/example_configurations/gCreate/gMax1.5+/Configuration.h View File

347
 
347
 
348
 // Comment the following line to disable PID and enable bang-bang.
348
 // Comment the following line to disable PID and enable bang-bang.
349
 #define PIDTEMP
349
 #define PIDTEMP
350
-#define BANG_MAX 255 // limits current to nozzle while in bang-bang mode; 255=full current
351
-#define PID_MAX BANG_MAX // limits current to nozzle while PID is active (see PID_FUNCTIONAL_RANGE below); 255=full current
350
+#define BANG_MAX 255     // Limits current to nozzle while in bang-bang mode; 255=full current
351
+#define PID_MAX BANG_MAX // Limits current to nozzle while PID is active (see PID_FUNCTIONAL_RANGE below); 255=full current
352
+#define PID_K1 0.95      // Smoothing factor within the PID
352
 #if ENABLED(PIDTEMP)
353
 #if ENABLED(PIDTEMP)
353
   //#define PID_AUTOTUNE_MENU // Add PID Autotune to the LCD "Temperature" menu to run M303 and apply the result.
354
   //#define PID_AUTOTUNE_MENU // Add PID Autotune to the LCD "Temperature" menu to run M303 and apply the result.
354
   //#define PID_DEBUG // Sends debug data to the serial port.
355
   //#define PID_DEBUG // Sends debug data to the serial port.
358
                                   // Set/get with gcode: M301 E[extruder number, 0-2]
359
                                   // Set/get with gcode: M301 E[extruder number, 0-2]
359
   #define PID_FUNCTIONAL_RANGE 10 // If the temperature difference between the target temperature and the actual temperature
360
   #define PID_FUNCTIONAL_RANGE 10 // If the temperature difference between the target temperature and the actual temperature
360
                                   // is more than PID_FUNCTIONAL_RANGE then the PID will be shut off and the heater will be set to min/max.
361
                                   // is more than PID_FUNCTIONAL_RANGE then the PID will be shut off and the heater will be set to min/max.
361
-  #define K1 0.95 //smoothing factor within the PID
362
 
362
 
363
   // If you are using a pre-configured hotend then you can use one of the value sets by uncommenting it
363
   // If you are using a pre-configured hotend then you can use one of the value sets by uncommenting it
364
 
364
 

+ 3
- 3
Marlin/example_configurations/makibox/Configuration.h View File

339
 
339
 
340
 // Comment the following line to disable PID and enable bang-bang.
340
 // Comment the following line to disable PID and enable bang-bang.
341
 #define PIDTEMP
341
 #define PIDTEMP
342
-#define BANG_MAX 255 // limits current to nozzle while in bang-bang mode; 255=full current
343
-#define PID_MAX BANG_MAX // limits current to nozzle while PID is active (see PID_FUNCTIONAL_RANGE below); 255=full current
342
+#define BANG_MAX 255     // Limits current to nozzle while in bang-bang mode; 255=full current
343
+#define PID_MAX BANG_MAX // Limits current to nozzle while PID is active (see PID_FUNCTIONAL_RANGE below); 255=full current
344
+#define PID_K1 0.95      // Smoothing factor within the PID
344
 #if ENABLED(PIDTEMP)
345
 #if ENABLED(PIDTEMP)
345
   //#define PID_AUTOTUNE_MENU // Add PID Autotune to the LCD "Temperature" menu to run M303 and apply the result.
346
   //#define PID_AUTOTUNE_MENU // Add PID Autotune to the LCD "Temperature" menu to run M303 and apply the result.
346
   //#define PID_DEBUG // Sends debug data to the serial port.
347
   //#define PID_DEBUG // Sends debug data to the serial port.
350
                                   // Set/get with gcode: M301 E[extruder number, 0-2]
351
                                   // Set/get with gcode: M301 E[extruder number, 0-2]
351
   #define PID_FUNCTIONAL_RANGE 10 // If the temperature difference between the target temperature and the actual temperature
352
   #define PID_FUNCTIONAL_RANGE 10 // If the temperature difference between the target temperature and the actual temperature
352
                                   // is more than PID_FUNCTIONAL_RANGE then the PID will be shut off and the heater will be set to min/max.
353
                                   // is more than PID_FUNCTIONAL_RANGE then the PID will be shut off and the heater will be set to min/max.
353
-  #define K1 0.95 //smoothing factor within the PID
354
 
354
 
355
   // If you are using a pre-configured hotend then you can use one of the value sets by uncommenting it
355
   // If you are using a pre-configured hotend then you can use one of the value sets by uncommenting it
356
 
356
 

+ 3
- 3
Marlin/example_configurations/tvrrug/Round2/Configuration.h View File

339
 
339
 
340
 // Comment the following line to disable PID and enable bang-bang.
340
 // Comment the following line to disable PID and enable bang-bang.
341
 #define PIDTEMP
341
 #define PIDTEMP
342
-#define BANG_MAX 255 // limits current to nozzle while in bang-bang mode; 255=full current
343
-#define PID_MAX BANG_MAX // limits current to nozzle while PID is active (see PID_FUNCTIONAL_RANGE below); 255=full current
342
+#define BANG_MAX 255     // Limits current to nozzle while in bang-bang mode; 255=full current
343
+#define PID_MAX BANG_MAX // Limits current to nozzle while PID is active (see PID_FUNCTIONAL_RANGE below); 255=full current
344
+#define PID_K1 0.95      // Smoothing factor within the PID
344
 #if ENABLED(PIDTEMP)
345
 #if ENABLED(PIDTEMP)
345
   //#define PID_AUTOTUNE_MENU // Add PID Autotune to the LCD "Temperature" menu to run M303 and apply the result.
346
   //#define PID_AUTOTUNE_MENU // Add PID Autotune to the LCD "Temperature" menu to run M303 and apply the result.
346
   //#define PID_DEBUG // Sends debug data to the serial port.
347
   //#define PID_DEBUG // Sends debug data to the serial port.
350
                                   // Set/get with gcode: M301 E[extruder number, 0-2]
351
                                   // Set/get with gcode: M301 E[extruder number, 0-2]
351
   #define PID_FUNCTIONAL_RANGE 10 // If the temperature difference between the target temperature and the actual temperature
352
   #define PID_FUNCTIONAL_RANGE 10 // If the temperature difference between the target temperature and the actual temperature
352
                                   // is more than PID_FUNCTIONAL_RANGE then the PID will be shut off and the heater will be set to min/max.
353
                                   // is more than PID_FUNCTIONAL_RANGE then the PID will be shut off and the heater will be set to min/max.
353
-  #define K1 0.95 //smoothing factor within the PID
354
 
354
 
355
   // If you are using a pre-configured hotend then you can use one of the value sets by uncommenting it
355
   // If you are using a pre-configured hotend then you can use one of the value sets by uncommenting it
356
   // J-Head Mk V-B
356
   // J-Head Mk V-B

+ 3
- 3
Marlin/example_configurations/wt150/Configuration.h View File

339
 
339
 
340
 // Comment the following line to disable PID and enable bang-bang.
340
 // Comment the following line to disable PID and enable bang-bang.
341
 #define PIDTEMP
341
 #define PIDTEMP
342
-#define BANG_MAX 255 // limits current to nozzle while in bang-bang mode; 255=full current
343
-#define PID_MAX BANG_MAX // limits current to nozzle while PID is active (see PID_FUNCTIONAL_RANGE below); 255=full current
342
+#define BANG_MAX 255     // Limits current to nozzle while in bang-bang mode; 255=full current
343
+#define PID_MAX BANG_MAX // Limits current to nozzle while PID is active (see PID_FUNCTIONAL_RANGE below); 255=full current
344
+#define PID_K1 0.95      // Smoothing factor within the PID
344
 #if ENABLED(PIDTEMP)
345
 #if ENABLED(PIDTEMP)
345
   //#define PID_AUTOTUNE_MENU // Add PID Autotune to the LCD "Temperature" menu to run M303 and apply the result.
346
   //#define PID_AUTOTUNE_MENU // Add PID Autotune to the LCD "Temperature" menu to run M303 and apply the result.
346
   //#define PID_DEBUG // Sends debug data to the serial port.
347
   //#define PID_DEBUG // Sends debug data to the serial port.
350
                                   // Set/get with gcode: M301 E[extruder number, 0-2]
351
                                   // Set/get with gcode: M301 E[extruder number, 0-2]
351
   #define PID_FUNCTIONAL_RANGE 10 // If the temperature difference between the target temperature and the actual temperature
352
   #define PID_FUNCTIONAL_RANGE 10 // If the temperature difference between the target temperature and the actual temperature
352
                                   // is more than PID_FUNCTIONAL_RANGE then the PID will be shut off and the heater will be set to min/max.
353
                                   // is more than PID_FUNCTIONAL_RANGE then the PID will be shut off and the heater will be set to min/max.
353
-  #define K1 0.95 //smoothing factor within the PID
354
 
354
 
355
   // If you are using a pre-configured hotend then you can use one of the value sets by uncommenting it
355
   // If you are using a pre-configured hotend then you can use one of the value sets by uncommenting it
356
 
356
 

+ 2
- 6
Marlin/temperature.cpp View File

47
   #include "watchdog.h"
47
   #include "watchdog.h"
48
 #endif
48
 #endif
49
 
49
 
50
-#ifdef K1 // Defined in Configuration.h in the PID settings
51
-  #define K2 (1.0-K1)
52
-#endif
53
-
54
 #if ENABLED(TEMP_SENSOR_1_AS_REDUNDANT)
50
 #if ENABLED(TEMP_SENSOR_1_AS_REDUNDANT)
55
   static void* heater_ttbl_map[2] = { (void*)HEATER_0_TEMPTABLE, (void*)HEATER_1_TEMPTABLE };
51
   static void* heater_ttbl_map[2] = { (void*)HEATER_0_TEMPTABLE, (void*)HEATER_1_TEMPTABLE };
56
   static uint8_t heater_ttbllen_map[2] = { HEATER_0_TEMPTABLE_LEN, HEATER_1_TEMPTABLE_LEN };
52
   static uint8_t heater_ttbllen_map[2] = { HEATER_0_TEMPTABLE_LEN, HEATER_1_TEMPTABLE_LEN };
599
   #if ENABLED(PIDTEMP)
595
   #if ENABLED(PIDTEMP)
600
     #if DISABLED(PID_OPENLOOP)
596
     #if DISABLED(PID_OPENLOOP)
601
       pid_error[HOTEND_INDEX] = target_temperature[HOTEND_INDEX] - current_temperature[HOTEND_INDEX];
597
       pid_error[HOTEND_INDEX] = target_temperature[HOTEND_INDEX] - current_temperature[HOTEND_INDEX];
602
-      dTerm[HOTEND_INDEX] = K2 * PID_PARAM(Kd, HOTEND_INDEX) * (current_temperature[HOTEND_INDEX] - temp_dState[HOTEND_INDEX]) + K1 * dTerm[HOTEND_INDEX];
598
+      dTerm[HOTEND_INDEX] = PID_K2 * PID_PARAM(Kd, HOTEND_INDEX) * (current_temperature[HOTEND_INDEX] - temp_dState[HOTEND_INDEX]) + PID_K1 * dTerm[HOTEND_INDEX];
603
       temp_dState[HOTEND_INDEX] = current_temperature[HOTEND_INDEX];
599
       temp_dState[HOTEND_INDEX] = current_temperature[HOTEND_INDEX];
604
       #if HEATER_IDLE_HANDLER
600
       #if HEATER_IDLE_HANDLER
605
         if (heater_idle_timeout_exceeded[HOTEND_INDEX]) {
601
         if (heater_idle_timeout_exceeded[HOTEND_INDEX]) {
696
       temp_iState_bed += pid_error_bed;
692
       temp_iState_bed += pid_error_bed;
697
       iTerm_bed = bedKi * temp_iState_bed;
693
       iTerm_bed = bedKi * temp_iState_bed;
698
 
694
 
699
-      dTerm_bed = K2 * bedKd * (current_temperature_bed - temp_dState_bed) + K1 * dTerm_bed;
695
+      dTerm_bed = PID_K2 * bedKd * (current_temperature_bed - temp_dState_bed) + PID_K1 * dTerm_bed;
700
       temp_dState_bed = current_temperature_bed;
696
       temp_dState_bed = current_temperature_bed;
701
 
697
 
702
       pid_output = pTerm_bed + iTerm_bed - dTerm_bed;
698
       pid_output = pTerm_bed + iTerm_bed - dTerm_bed;

+ 11
- 10
Marlin/temperature.h View File

96
 
96
 
97
 #define ACTUAL_ADC_SAMPLES max(int(MIN_ADC_ISR_LOOPS), int(SensorsReady))
97
 #define ACTUAL_ADC_SAMPLES max(int(MIN_ADC_ISR_LOOPS), int(SensorsReady))
98
 
98
 
99
+#if HAS_PID_HEATING
100
+  #define PID_K2 (1.0-PID_K1)
101
+  #define PID_dT ((OVERSAMPLENR * float(ACTUAL_ADC_SAMPLES)) / (F_CPU / 64.0 / 256.0))
102
+
103
+  // Apply the scale factors to the PID values
104
+  #define scalePID_i(i)   ( (i) * PID_dT )
105
+  #define unscalePID_i(i) ( (i) / PID_dT )
106
+  #define scalePID_d(d)   ( (d) / PID_dT )
107
+  #define unscalePID_d(d) ( (d) * PID_dT )
108
+#endif
109
+
99
 #if !HAS_HEATER_BED
110
 #if !HAS_HEATER_BED
100
   constexpr int16_t target_temperature_bed = 0;
111
   constexpr int16_t target_temperature_bed = 0;
101
 #endif
112
 #endif
124
                      soft_pwm_count_fan[FAN_COUNT];
135
                      soft_pwm_count_fan[FAN_COUNT];
125
     #endif
136
     #endif
126
 
137
 
127
-    #if ENABLED(PIDTEMP) || ENABLED(PIDTEMPBED)
128
-      #define PID_dT ((OVERSAMPLENR * float(ACTUAL_ADC_SAMPLES)) / (F_CPU / 64.0 / 256.0))
129
-    #endif
130
-
131
     #if ENABLED(PIDTEMP)
138
     #if ENABLED(PIDTEMP)
132
 
139
 
133
       #if ENABLED(PID_PARAMS_PER_HOTEND) && HOTENDS > 1
140
       #if ENABLED(PID_PARAMS_PER_HOTEND) && HOTENDS > 1
148
 
155
 
149
       #endif // PID_PARAMS_PER_HOTEND
156
       #endif // PID_PARAMS_PER_HOTEND
150
 
157
 
151
-      // Apply the scale factors to the PID values
152
-      #define scalePID_i(i)   ( (i) * PID_dT )
153
-      #define unscalePID_i(i) ( (i) / PID_dT )
154
-      #define scalePID_d(d)   ( (d) / PID_dT )
155
-      #define unscalePID_d(d) ( (d) * PID_dT )
156
-
157
     #endif
158
     #endif
158
 
159
 
159
     #if ENABLED(PIDTEMPBED)
160
     #if ENABLED(PIDTEMPBED)

Loading…
Cancel
Save