Merge pull request #4517 from thinkyhead/rc_min_probe_pin
Define Z_MIN_PROBE_PIN always, allowing override
This commit is contained in:
commit
bd7a96ed42
7 changed files with 44 additions and 53 deletions
|
@ -270,11 +270,17 @@
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Z_MIN_PIN and Z_MIN_PROBE_PIN can't co-exist when Z_MIN_PROBE_USES_Z_MIN_ENDSTOP_PIN
|
* Require a Z min pin
|
||||||
*/
|
*/
|
||||||
#if HAS_Z_MIN && HAS_Z_MIN_PROBE_PIN && ENABLED(Z_MIN_PROBE_USES_Z_MIN_ENDSTOP_PIN)
|
#if HAS_Z_MIN
|
||||||
|
// Z_MIN_PIN and Z_MIN_PROBE_PIN can't co-exist when Z_MIN_PROBE_USES_Z_MIN_ENDSTOP_PIN
|
||||||
|
#if HAS_Z_MIN_PROBE_PIN && ENABLED(Z_MIN_PROBE_USES_Z_MIN_ENDSTOP_PIN)
|
||||||
#error "A probe cannot have more than one pin! Use Z_MIN_PROBE_USES_Z_MIN_ENDSTOP_PIN or Z_MIN_PROBE_PIN."
|
#error "A probe cannot have more than one pin! Use Z_MIN_PROBE_USES_Z_MIN_ENDSTOP_PIN or Z_MIN_PROBE_PIN."
|
||||||
#endif
|
#endif
|
||||||
|
#elif !HAS_Z_MIN_PROBE_PIN || (DISABLED(Z_MIN_PROBE_ENDSTOP) || ENABLED(DISABLE_Z_MIN_PROBE_ENDSTOP))
|
||||||
|
// A pin was set for the Z probe, but not enabled.
|
||||||
|
#error "A probe requires a Z_MIN or Z_PROBE pin. Z_MIN_PIN or Z_MIN_PROBE_PIN must point to a valid hardware pin."
|
||||||
|
#endif
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Make sure the plug is enabled if it's used
|
* Make sure the plug is enabled if it's used
|
||||||
|
@ -384,15 +390,6 @@
|
||||||
#error "You must use AUTO_BED_LEVELING_GRID for DELTA bed leveling."
|
#error "You must use AUTO_BED_LEVELING_GRID for DELTA bed leveling."
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
/**
|
|
||||||
* Require a Z min pin
|
|
||||||
*/
|
|
||||||
#if !PIN_EXISTS(Z_MIN)
|
|
||||||
#if !PIN_EXISTS(Z_MIN_PROBE) || (DISABLED(Z_MIN_PROBE_ENDSTOP) || ENABLED(DISABLE_Z_MIN_PROBE_ENDSTOP)) // It's possible for someone to set a pin for the Z probe, but not enable it.
|
|
||||||
#error "AUTO_BED_LEVELING_FEATURE requires a Z_MIN or Z_PROBE endstop. Z_MIN_PIN or Z_MIN_PROBE_PIN must point to a valid hardware pin."
|
|
||||||
#endif
|
|
||||||
#endif
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Check if Probe_Offset * Grid Points is greater than Probing Range
|
* Check if Probe_Offset * Grid Points is greater than Probing Range
|
||||||
*/
|
*/
|
||||||
|
|
|
@ -60,14 +60,10 @@
|
||||||
#define Z_MAX_PIN 18
|
#define Z_MAX_PIN 18
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
#ifndef Z_MIN_PROBE_PIN
|
||||||
#if ENABLED(Z_MIN_PROBE_ENDSTOP)
|
|
||||||
//#undef Z_MIN_PIN
|
|
||||||
//#define Z_MIN_PIN 15
|
|
||||||
// Define a pin to use as the signal pin on Arduino for the Z probe endstop.
|
|
||||||
#define Z_MIN_PROBE_PIN 19
|
#define Z_MIN_PROBE_PIN 19
|
||||||
#endif
|
#endif
|
||||||
//
|
|
||||||
#define E2_STEP_PIN 23
|
#define E2_STEP_PIN 23
|
||||||
#define E2_DIR_PIN 25
|
#define E2_DIR_PIN 25
|
||||||
#define E2_ENABLE_PIN 40
|
#define E2_ENABLE_PIN 40
|
||||||
|
|
|
@ -41,21 +41,24 @@
|
||||||
|
|
||||||
#define LARGE_FLASH true
|
#define LARGE_FLASH true
|
||||||
|
|
||||||
|
#define X_STOP_PIN 47
|
||||||
|
#define Y_STOP_PIN 18
|
||||||
|
#define Z_MAX_PIN 36
|
||||||
|
#ifndef Z_MIN_PROBE_PIN
|
||||||
|
#define Z_MIN_PROBE_PIN 17
|
||||||
|
#endif
|
||||||
|
|
||||||
#define X_STEP_PIN 33
|
#define X_STEP_PIN 33
|
||||||
#define X_DIR_PIN 32
|
#define X_DIR_PIN 32
|
||||||
#define X_ENABLE_PIN 11
|
#define X_ENABLE_PIN 11
|
||||||
#define X_STOP_PIN 47
|
|
||||||
|
|
||||||
#define Y_STEP_PIN 31
|
#define Y_STEP_PIN 31
|
||||||
#define Y_DIR_PIN 30
|
#define Y_DIR_PIN 30
|
||||||
#define Y_ENABLE_PIN 8
|
#define Y_ENABLE_PIN 8
|
||||||
#define Y_STOP_PIN 18
|
|
||||||
|
|
||||||
#define Z_STEP_PIN 29
|
#define Z_STEP_PIN 29
|
||||||
#define Z_DIR_PIN 28
|
#define Z_DIR_PIN 28
|
||||||
#define Z_ENABLE_PIN 37
|
#define Z_ENABLE_PIN 37
|
||||||
#define Z_MAX_PIN 36
|
|
||||||
#define Z_MIN_PROBE_PIN 17 // Bed Z probe
|
|
||||||
|
|
||||||
#define E0_STEP_PIN 35
|
#define E0_STEP_PIN 35
|
||||||
#define E0_DIR_PIN 34
|
#define E0_DIR_PIN 34
|
||||||
|
|
|
@ -42,26 +42,30 @@
|
||||||
#define SLED_PIN -1
|
#define SLED_PIN -1
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#define X_STEP_PIN 37
|
|
||||||
#define X_DIR_PIN 48
|
|
||||||
#define X_MIN_PIN 12
|
#define X_MIN_PIN 12
|
||||||
#define X_MAX_PIN 24
|
#define X_MAX_PIN 24
|
||||||
|
#define Y_MIN_PIN 11
|
||||||
|
#define Y_MAX_PIN 23
|
||||||
|
#define Z_MIN_PIN 10
|
||||||
|
#define Z_MAX_PIN 30
|
||||||
|
#ifndef Z_MIN_PROBE_PIN
|
||||||
|
#define Z_MIN_PROBE_PIN 10
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#define X_STEP_PIN 37
|
||||||
|
#define X_DIR_PIN 48
|
||||||
#define X_ENABLE_PIN 29
|
#define X_ENABLE_PIN 29
|
||||||
#define X_MS1_PIN 40
|
#define X_MS1_PIN 40
|
||||||
#define X_MS2_PIN 41
|
#define X_MS2_PIN 41
|
||||||
|
|
||||||
#define Y_STEP_PIN 36
|
#define Y_STEP_PIN 36
|
||||||
#define Y_DIR_PIN 49
|
#define Y_DIR_PIN 49
|
||||||
#define Y_MIN_PIN 11
|
|
||||||
#define Y_MAX_PIN 23
|
|
||||||
#define Y_ENABLE_PIN 28
|
#define Y_ENABLE_PIN 28
|
||||||
#define Y_MS1_PIN 69
|
#define Y_MS1_PIN 69
|
||||||
#define Y_MS2_PIN 39
|
#define Y_MS2_PIN 39
|
||||||
|
|
||||||
#define Z_STEP_PIN 35
|
#define Z_STEP_PIN 35
|
||||||
#define Z_DIR_PIN 47
|
#define Z_DIR_PIN 47
|
||||||
#define Z_MIN_PIN 10
|
|
||||||
#define Z_MAX_PIN 30
|
|
||||||
#define Z_ENABLE_PIN 27
|
#define Z_ENABLE_PIN 27
|
||||||
#define Z_MS1_PIN 68
|
#define Z_MS1_PIN 68
|
||||||
#define Z_MS2_PIN 67
|
#define Z_MS2_PIN 67
|
||||||
|
|
|
@ -63,25 +63,29 @@
|
||||||
#define SERVO2_PIN 5
|
#define SERVO2_PIN 5
|
||||||
#define SERVO3_PIN 4
|
#define SERVO3_PIN 4
|
||||||
|
|
||||||
#define X_STEP_PIN 54
|
|
||||||
#define X_DIR_PIN 55
|
|
||||||
#define X_ENABLE_PIN 38
|
|
||||||
#define X_MIN_PIN 3
|
#define X_MIN_PIN 3
|
||||||
#ifndef X_MAX_PIN
|
#ifndef X_MAX_PIN
|
||||||
#define X_MAX_PIN 2
|
#define X_MAX_PIN 2
|
||||||
#endif
|
#endif
|
||||||
|
#define Y_MIN_PIN 14
|
||||||
|
#define Y_MAX_PIN 15
|
||||||
|
#define Z_MIN_PIN 18
|
||||||
|
#define Z_MAX_PIN 19
|
||||||
|
#ifndef Z_MIN_PROBE_PIN
|
||||||
|
#define Z_MIN_PROBE_PIN 32
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#define X_STEP_PIN 54
|
||||||
|
#define X_DIR_PIN 55
|
||||||
|
#define X_ENABLE_PIN 38
|
||||||
|
|
||||||
#define Y_STEP_PIN 60
|
#define Y_STEP_PIN 60
|
||||||
#define Y_DIR_PIN 61
|
#define Y_DIR_PIN 61
|
||||||
#define Y_ENABLE_PIN 56
|
#define Y_ENABLE_PIN 56
|
||||||
#define Y_MIN_PIN 14
|
|
||||||
#define Y_MAX_PIN 15
|
|
||||||
|
|
||||||
#define Z_STEP_PIN 46
|
#define Z_STEP_PIN 46
|
||||||
#define Z_DIR_PIN 48
|
#define Z_DIR_PIN 48
|
||||||
#define Z_ENABLE_PIN 62
|
#define Z_ENABLE_PIN 62
|
||||||
#define Z_MIN_PIN 18
|
|
||||||
#define Z_MAX_PIN 19
|
|
||||||
|
|
||||||
#define E0_STEP_PIN 26
|
#define E0_STEP_PIN 26
|
||||||
#define E0_DIR_PIN 28
|
#define E0_DIR_PIN 28
|
||||||
|
@ -97,11 +101,6 @@
|
||||||
// Use the RAMPS 1.4 Analog input 5 on the AUX2 connector
|
// Use the RAMPS 1.4 Analog input 5 on the AUX2 connector
|
||||||
#define FILWIDTH_PIN 5 // ANALOG NUMBERING
|
#define FILWIDTH_PIN 5 // ANALOG NUMBERING
|
||||||
|
|
||||||
#if ENABLED(Z_MIN_PROBE_ENDSTOP)
|
|
||||||
// Define a pin to use as the signal pin on Arduino for the Z_PROBE endstop.
|
|
||||||
#define Z_MIN_PROBE_PIN 32
|
|
||||||
#endif
|
|
||||||
|
|
||||||
// define digital pin 4 for the filament runout sensor. Use the RAMPS 1.4 digital input 4 on the servos connector
|
// define digital pin 4 for the filament runout sensor. Use the RAMPS 1.4 digital input 4 on the servos connector
|
||||||
#define FIL_RUNOUT_PIN 4
|
#define FIL_RUNOUT_PIN 4
|
||||||
|
|
||||||
|
|
|
@ -24,22 +24,15 @@
|
||||||
* RIGIDBOARD Arduino Mega with RAMPS v1.4 pin assignments
|
* RIGIDBOARD Arduino Mega with RAMPS v1.4 pin assignments
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#include "pins_RAMPS.h"
|
|
||||||
|
|
||||||
#undef BOARD_NAME
|
|
||||||
#define BOARD_NAME "RigidBoard"
|
#define BOARD_NAME "RigidBoard"
|
||||||
|
|
||||||
#if ENABLED(Z_MIN_PROBE_ENDSTOP)
|
#define RAMPS_D10_PIN 9 // EXTRUDER 1
|
||||||
#undef Z_MAX_PIN
|
#define MOSFET_D_PIN 12 // EXTRUDER 2 or FAN
|
||||||
#define Z_MAX_PIN -1
|
#ifndef Z_MIN_PROBE_PIN
|
||||||
#undef Z_MIN_PROBE_PIN
|
|
||||||
#define Z_MIN_PROBE_PIN 19 // Z-MAX pin J14 End Stops
|
#define Z_MIN_PROBE_PIN 19 // Z-MAX pin J14 End Stops
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#undef HEATER_0_PIN
|
#include "pins_RAMPS.h"
|
||||||
#undef HEATER_1_PIN
|
|
||||||
#define HEATER_0_PIN 9 // EXTRUDER 1
|
|
||||||
#define HEATER_1_PIN 12 // EXTRUDER 2 (FAN On Sprinter)
|
|
||||||
|
|
||||||
#undef TEMP_0_PIN
|
#undef TEMP_0_PIN
|
||||||
#undef TEMP_1_PIN
|
#undef TEMP_1_PIN
|
||||||
|
|
|
@ -53,8 +53,7 @@
|
||||||
#define Z_MIN_PIN 33
|
#define Z_MIN_PIN 33
|
||||||
#define Z_MAX_PIN 32
|
#define Z_MAX_PIN 32
|
||||||
|
|
||||||
#if ENABLED(Z_MIN_PROBE_ENDSTOP)
|
#ifndef Z_MIN_PROBE_PIN
|
||||||
// Define a pin to use as the signal pin on Arduino for the Z probe endstop.
|
|
||||||
#define Z_MIN_PROBE_PIN 33
|
#define Z_MIN_PROBE_PIN 33
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
|
Reference in a new issue