Up to 9 linear/rotary axes

MarlinFirmware/Marlin#23112
This commit is contained in:
Scott Lahteine 2022-03-31 20:37:35 -05:00
parent 733e4ce987
commit ff0dd3188c
586 changed files with 64190 additions and 9472 deletions

View file

@ -163,9 +163,9 @@
//#define MACHINE_UUID "00000000-0000-0000-0000-000000000000"
/**
* Define the number of coordinated linear axes.
* Define the number of coordinated axes.
* See https://github.com/DerAndere1/Marlin/wiki
* Each linear axis gets its own stepper control and endstop:
* Each axis gets its own stepper control and endstop:
*
* Steppers: *_STEP_PIN, *_ENABLE_PIN, *_DIR_PIN, *_ENABLE_ON
* Endstops: *_STOP_PIN, USE_*MIN_PLUG, USE_*MAX_PLUG
@ -174,9 +174,9 @@
* DEFAULT_MAX_ACCELERATION, AXIS_RELATIVE_MODES,
* MICROSTEP_MODES, MANUAL_FEEDRATE
*
* :[3, 4, 5, 6]
* :[3, 4, 5, 6, 7, 8, 9]
*/
//#define LINEAR_AXES 3
//#define NUM_AXES 3
/**
* Axis codes for additional axes:
@ -191,14 +191,29 @@
* Regardless of the settings, firmware-internal axis IDs are
* I (AXIS4), J (AXIS5), K (AXIS6).
*/
#if LINEAR_AXES >= 4
#if NUM_AXES >= 4
#define AXIS4_NAME 'A' // :['A', 'B', 'C', 'U', 'V', 'W']
#define AXIS4_ROTATES
#endif
#if LINEAR_AXES >= 5
#define AXIS5_NAME 'B' // :['A', 'B', 'C', 'U', 'V', 'W']
#if NUM_AXES >= 5
#define AXIS5_NAME 'B' // :['B', 'C', 'U', 'V', 'W']
#define AXIS5_ROTATES
#endif
#if LINEAR_AXES >= 6
#define AXIS6_NAME 'C' // :['A', 'B', 'C', 'U', 'V', 'W']
#if NUM_AXES >= 6
#define AXIS6_NAME 'C' // :['C', 'U', 'V', 'W']
#define AXIS6_ROTATES
#endif
#if NUM_AXES >= 7
#define AXIS7_NAME 'U' // :['U', 'V', 'W']
//#define AXIS7_ROTATES
#endif
#if NUM_AXES >= 8
#define AXIS8_NAME 'V' // :['V', 'W']
//#define AXIS8_ROTATES
#endif
#if NUM_AXES >= 9
#define AXIS9_NAME 'W' // :['W']
//#define AXIS9_ROTATES
#endif
// @section extruder
@ -807,12 +822,18 @@
//#define USE_IMIN_PLUG
//#define USE_JMIN_PLUG
//#define USE_KMIN_PLUG
//#define USE_UMIN_PLUG
//#define USE_VMIN_PLUG
//#define USE_WMIN_PLUG
#define USE_XMAX_PLUG
#define USE_YMAX_PLUG
#define USE_ZMAX_PLUG
//#define USE_IMAX_PLUG
//#define USE_JMAX_PLUG
//#define USE_KMAX_PLUG
//#define USE_UMAX_PLUG
//#define USE_VMAX_PLUG
//#define USE_WMAX_PLUG
// Enable pullup for all endstops to prevent a floating state
#define ENDSTOPPULLUPS
@ -824,12 +845,18 @@
//#define ENDSTOPPULLUP_IMIN
//#define ENDSTOPPULLUP_JMIN
//#define ENDSTOPPULLUP_KMIN
//#define ENDSTOPPULLUP_UMIN
//#define ENDSTOPPULLUP_VMIN
//#define ENDSTOPPULLUP_WMIN
#define ENDSTOPPULLUP_XMAX
#define ENDSTOPPULLUP_YMAX
#define ENDSTOPPULLUP_ZMAX
//#define ENDSTOPPULLUP_IMAX
//#define ENDSTOPPULLUP_JMAX
//#define ENDSTOPPULLUP_KMAX
//#define ENDSTOPPULLUP_UMAX
//#define ENDSTOPPULLUP_VMAX
//#define ENDSTOPPULLUP_WMAX
#define ENDSTOPPULLUP_ZMIN_PROBE
#endif
@ -843,12 +870,18 @@
//#define ENDSTOPPULLDOWN_IMIN
//#define ENDSTOPPULLDOWN_JMIN
//#define ENDSTOPPULLDOWN_KMIN
//#define ENDSTOPPULLDOWN_UMIN
//#define ENDSTOPPULLDOWN_VMIN
//#define ENDSTOPPULLDOWN_WMIN
//#define ENDSTOPPULLDOWN_XMAX
//#define ENDSTOPPULLDOWN_YMAX
//#define ENDSTOPPULLDOWN_ZMAX
//#define ENDSTOPPULLDOWN_IMAX
//#define ENDSTOPPULLDOWN_JMAX
//#define ENDSTOPPULLDOWN_KMAX
//#define ENDSTOPPULLDOWN_UMAX
//#define ENDSTOPPULLDOWN_VMAX
//#define ENDSTOPPULLDOWN_WMAX
//#define ENDSTOPPULLDOWN_ZMIN_PROBE
#endif
@ -859,12 +892,18 @@
#define I_MIN_ENDSTOP_INVERTING false // Set to true to invert the logic of the endstop.
#define J_MIN_ENDSTOP_INVERTING false // Set to true to invert the logic of the endstop.
#define K_MIN_ENDSTOP_INVERTING false // Set to true to invert the logic of the endstop.
#define U_MIN_ENDSTOP_INVERTING false // Set to true to invert the logic of the endstop.
#define V_MIN_ENDSTOP_INVERTING false // Set to true to invert the logic of the endstop.
#define W_MIN_ENDSTOP_INVERTING false // Set to true to invert the logic of the endstop.
#define X_MAX_ENDSTOP_INVERTING true // Set to true to invert the logic of the endstop.
#define Y_MAX_ENDSTOP_INVERTING true // Set to true to invert the logic of the endstop.
#define Z_MAX_ENDSTOP_INVERTING true // Set to true to invert the logic of the endstop.
#define I_MAX_ENDSTOP_INVERTING false // Set to true to invert the logic of the endstop.
#define J_MAX_ENDSTOP_INVERTING false // Set to true to invert the logic of the endstop.
#define K_MAX_ENDSTOP_INVERTING false // Set to true to invert the logic of the endstop.
#define U_MAX_ENDSTOP_INVERTING false // Set to true to invert the logic of the endstop.
#define V_MAX_ENDSTOP_INVERTING false // Set to true to invert the logic of the endstop.
#define W_MAX_ENDSTOP_INVERTING false // Set to true to invert the logic of the endstop.
#define Z_MIN_PROBE_ENDSTOP_INVERTING true // Set to true to invert the logic of the probe.
/**
@ -896,6 +935,9 @@
//#define I_DRIVER_TYPE A4988
//#define J_DRIVER_TYPE A4988
//#define K_DRIVER_TYPE A4988
//#define U_DRIVER_TYPE A4988
//#define V_DRIVER_TYPE A4988
//#define W_DRIVER_TYPE A4988
#define E0_DRIVER_TYPE A4988
//#define E1_DRIVER_TYPE A4988
//#define E2_DRIVER_TYPE A4988
@ -947,16 +989,16 @@
//#define DISTINCT_E_FACTORS
/**
* Default Axis Steps Per Unit (steps/mm)
* Default Axis Steps Per Unit (linear=steps/mm, rotational=steps/°)
* Override with M92
* X, Y, Z [, I [, J [, K]]], E0 [, E1[, E2...]]
* X, Y, Z [, I [, J [, K...]]], E0 [, E1[, E2...]]
*/
#define DEFAULT_AXIS_STEPS_PER_UNIT { 85.48,85.48,533.33,104.7 }
/**
* Default Max Feed Rate (mm/s)
* Default Max Feed Rate (linear=mm/s, rotational=°/s)
* Override with M203
* X, Y, Z [, I [, J [, K]]], E0 [, E1[, E2...]]
* X, Y, Z [, I [, J [, K...]]], E0 [, E1[, E2...]]
*/
#define DEFAULT_MAX_FEEDRATE { 150, 150, 15, 20 }
@ -966,10 +1008,10 @@
#endif
/**
* Default Max Acceleration (change/s) change = mm/s
* Default Max Acceleration (speed change with time) (linear=mm/(s^2), rotational=°/(s^2))
* (Maximum start speed for accelerated moves)
* Override with M201
* X, Y, Z [, I [, J [, K]]], E0 [, E1[, E2...]]
* X, Y, Z [, I [, J [, K...]]], E0 [, E1[, E2...]]
*/
#define DEFAULT_MAX_ACCELERATION { 10000, 10000, 50, 500 }
@ -979,7 +1021,7 @@
#endif
/**
* Default Acceleration (change/s) change = mm/s
* Default Acceleration (speed change with time) (linear=mm/(s^2), rotational=°/(s^2))
* Override with M204
*
* M204 P Acceleration
@ -992,7 +1034,7 @@
/**
* Default Jerk limits (mm/s)
* Override with M205 X Y Z E
* Override with M205 X Y Z . . . E
*
* "Jerk" specifies the minimum speed change that requires acceleration.
* When changing speed and direction, if the difference is less than the
@ -1006,6 +1048,9 @@
//#define DEFAULT_IJERK 0.3
//#define DEFAULT_JJERK 0.3
//#define DEFAULT_KJERK 0.3
//#define DEFAULT_UJERK 0.3
//#define DEFAULT_VJERK 0.3
//#define DEFAULT_WJERK 0.3
//#define TRAVEL_EXTRA_XYJERK 0.0 // Additional jerk allowance for all travel moves
@ -1344,6 +1389,9 @@
//#define I_ENABLE_ON 0
//#define J_ENABLE_ON 0
//#define K_ENABLE_ON 0
//#define U_ENABLE_ON 0
//#define V_ENABLE_ON 0
//#define W_ENABLE_ON 0
// Disable axis steppers immediately when they're not being stepped.
// WARNING: When motors turn off there is a chance of losing position accuracy!
@ -1353,6 +1401,9 @@
//#define DISABLE_I false
//#define DISABLE_J false
//#define DISABLE_K false
//#define DISABLE_U false
//#define DISABLE_V false
//#define DISABLE_W false
// Turn off the display blinking that warns about possible accuracy reduction
//#define DISABLE_REDUCED_ACCURACY_WARNING
@ -1371,6 +1422,9 @@
//#define INVERT_I_DIR false
//#define INVERT_J_DIR false
//#define INVERT_K_DIR false
//#define INVERT_U_DIR false
//#define INVERT_V_DIR false
//#define INVERT_W_DIR false
// @section extruder
@ -1409,6 +1463,9 @@
//#define I_HOME_DIR -1
//#define J_HOME_DIR -1
//#define K_HOME_DIR -1
//#define U_HOME_DIR -1
//#define V_HOME_DIR -1
//#define W_HOME_DIR -1
// @section machine
@ -1416,7 +1473,7 @@
#define X_BED_SIZE 261
#define Y_BED_SIZE 193
// Travel limits (mm) after homing, corresponding to endstop positions.
// Travel limits (linear=mm, rotational=°) after homing, corresponding to endstop positions.
#define X_MIN_POS 0
#define Y_MIN_POS 0
#define Z_MIN_POS 0
@ -1429,6 +1486,12 @@
//#define J_MAX_POS 50
//#define K_MIN_POS 0
//#define K_MAX_POS 50
//#define U_MIN_POS 0
//#define U_MAX_POS 50
//#define V_MIN_POS 0
//#define V_MAX_POS 50
//#define W_MIN_POS 0
//#define W_MAX_POS 50
/**
* Software Endstops
@ -1448,6 +1511,9 @@
#define MIN_SOFTWARE_ENDSTOP_I
#define MIN_SOFTWARE_ENDSTOP_J
#define MIN_SOFTWARE_ENDSTOP_K
#define MIN_SOFTWARE_ENDSTOP_U
#define MIN_SOFTWARE_ENDSTOP_V
#define MIN_SOFTWARE_ENDSTOP_W
#endif
// Max software endstops constrain movement within maximum coordinate bounds
@ -1459,6 +1525,9 @@
#define MAX_SOFTWARE_ENDSTOP_I
#define MAX_SOFTWARE_ENDSTOP_J
#define MAX_SOFTWARE_ENDSTOP_K
#define MAX_SOFTWARE_ENDSTOP_U
#define MAX_SOFTWARE_ENDSTOP_V
#define MAX_SOFTWARE_ENDSTOP_W
#endif
#if EITHER(MIN_SOFTWARE_ENDSTOPS, MAX_SOFTWARE_ENDSTOPS)
@ -1773,6 +1842,9 @@
//#define MANUAL_I_HOME_POS 0
//#define MANUAL_J_HOME_POS 0
//#define MANUAL_K_HOME_POS 0
//#define MANUAL_U_HOME_POS 0
//#define MANUAL_V_HOME_POS 0
//#define MANUAL_W_HOME_POS 0
/**
* Use "Z Safe Homing" to avoid homing with a Z probe outside the bed area.
@ -1788,7 +1860,7 @@
#define Z_SAFE_HOMING_Y_POINT Y_CENTER // Y point for Z homing
#endif
// Homing speeds (mm/min)
// Homing speeds (linear=mm/min, rotational=°/min)
#define HOMING_FEEDRATE_MM_M { (50*60), (50*60), (8*60) }
// Validate that endstops are triggered on homing moves