460#define BANG_MAX 255 // Limits current to nozzle while in bang-bang mode; 255=full current
461#define PID_MAX BANG_MAX // Limits current to nozzle while PID is active (see PID_FUNCTIONAL_RANGE below); 255=full current
462#define PID_K1 0.95 // Smoothing factor within any PID loop
463#if ENABLED(PIDTEMP)
464//#define PID_EDIT_MENU // Add PID editing to the "Advanced Settings" menu. (~700 bytes of PROGMEM)
465//#define PID_AUTOTUNE_MENU // Add PID auto-tuning to the "Advanced Settings" menu. (~250 bytes of PROGMEM)
466//#define PID_DEBUG // Sends debug data to the serial port.
467//#define PID_OPENLOOP 1 // Puts PID in open loop. M104/M140 sets the output power from 0 to PID_MAX
468//#define SLOW_PWM_HEATERS // PWM with very low frequency (roughly 0.125Hz=8s) and minimum state time of approximately 1s useful for heaters driven by a relay
469//#define PID_PARAMS_PER_HOTEND // Uses separate PID parameters for each extruder (useful for mismatched extruders)
470// Set/get with gcode: M301 E[extruder number, 0-2]
471 #define PID_FUNCTIONAL_RANGE 10 // If the temperature difference between the target temperature and the actual temperature
472// is more than PID_FUNCTIONAL_RANGE then the PID will be shut off and the heater will be set to min/max.
473
474// If you are using a pre-configured hotend then you can use one of the value sets by uncommenting it
820 * Define this pin if the probe is not connected to Z_MIN_PIN.
821 * If not defined the default pin for the selected MOTHERBOARD
822 * will be used. Most of the time the default is what you want.
823 *
824 * - The simplest option is to use a free endstop connector.
825 * - Use 5V for powered (usually inductive) sensors.
826 *
827 * - RAMPS 1.3/1.4 boards may use the 5V, GND, and Aux4->D32 pin:
828 * - For simple switches connect...
829 * - normally-closed switches to GND and D32.
830 * - normally-open switches to 5V and D32.
831 *
832 */
833//#define Z_MIN_PROBE_PIN 32 // Pin 32 is the RAMPS default
834
835/**
836 * Probe Type
837 *
838 * Allen Key Probes, Servo Probes, Z-Sled Probes, FIX_MOUNTED_PROBE, etc.
839 * Activate one of these to use Auto Bed Leveling below.
840 */
841
842/**
843 * The "Manual Probe" provides a means to do "Auto" Bed Leveling without a probe.
844 * Use G29 repeatedly, adjusting the Z height at each point with movement commands
845 * or (with LCD_BED_LEVELING) the LCD controller.
846 */
847//#define PROBE_MANUALLY
848//#define MANUAL_PROBE_START_Z 0.2
849
850/**
851 * A Fix-Mounted Probe either doesn't deploy or needs manual deployment.
852 * (e.g., an inductive probe or a nozzle-based probe-switch.)
853 */
854//#define FIX_MOUNTED_PROBE
855
856/**
857 * Z Servo Probe, such as an endstop switch on a rotating arm.
858 */
859//#define Z_PROBE_SERVO_NR 0 // Defaults to SERVO 0 connector.
860//#define Z_SERVO_ANGLES { 70, 0 } // Z Servo Deploy and Stow angles
861
862/**
863 * The BLTouch probe uses a Hall effect sensor and emulates a servo.
864 */
865//#define BLTOUCH
866
867/**
868 * Touch-MI Probe by hotends.fr
869 *
870 * This probe is deployed and activated by moving the X-axis to a magnet at the edge of the bed.
871 * By default, the magnet is assumed to be on the left and activated by a home. If the magnet is
872 * on the right, enable and set TOUCH_MI_DEPLOY_XPOS to the deploy position.
873 *
874 * Also requires: BABYSTEPPING, BABYSTEP_ZPROBE_OFFSET, Z_SAFE_HOMING,
875 * and a minimum Z_HOMING_HEIGHT of 10.
876 */
877//#define TOUCH_MI_PROBE
878#if ENABLED(TOUCH_MI_PROBE)
879 #define TOUCH_MI_RETRACT_Z 0.5 // Height at which the probe retracts
880//#define TOUCH_MI_DEPLOY_XPOS (X_MAX_BED + 2) // For a magnet on the right side of the bed
881//#define TOUCH_MI_MANUAL_DEPLOY // For manual deploy (LCD menu)
882#endif
883
884// A probe that is deployed and stowed with a solenoid pin (SOL1_PIN)
885//#define SOLENOID_PROBE
886
887// A sled-mounted probe like those designed by Charles Bell.
888//#define Z_PROBE_SLED
889//#define SLED_DOCKING_OFFSET 5 // The extra distance the X axis must travel to pickup the sled. 0 should be fine but you can push it further if you'd like.
890
891// A probe deployed by moving the x-axis, such as the Wilson II's rack-and-pinion probe designed by Marty Rice.
892//#define RACK_AND_PINION_PROBE
893#if ENABLED(RACK_AND_PINION_PROBE)
894 #define Z_PROBE_DEPLOY_X X_MIN_POS
895 #define Z_PROBE_RETRACT_X X_MAX_POS
896#endif
897
898//
899// For Z_PROBE_ALLEN_KEY see the Delta example configurations.
900//
901
902/**
903 * Z Probe to nozzle (X,Y) offset, relative to (0, 0).
904 *
905 * In the following example the X and Y offsets are both positive: