diff --git a/Marlin/Conditionals_post.h b/Marlin/Conditionals_post.h index 617384bd52..4b4dc4d941 100644 --- a/Marlin/Conditionals_post.h +++ b/Marlin/Conditionals_post.h @@ -698,7 +698,7 @@ #define DELTA_ENDSTOP_ADJ { 0.0, 0.0, 0.0 } #endif #ifndef DELTA_TOWER_ANGLE_TRIM - #define DELTA_TOWER_ANGLE_TRIM {0.0, 0.0} + #define DELTA_TOWER_ANGLE_TRIM {0.0, 0.0, 0.0} #endif #ifndef DELTA_RADIUS_TRIM_TOWER #define DELTA_RADIUS_TRIM_TOWER {0.0, 0.0, 0.0} diff --git a/Marlin/Marlin_main.cpp b/Marlin/Marlin_main.cpp index 18cb090d1f..08b25e2330 100644 --- a/Marlin/Marlin_main.cpp +++ b/Marlin/Marlin_main.cpp @@ -7524,8 +7524,8 @@ inline void gcode_M205() { if (code_seen('X')) delta_tower_angle_trim[A_AXIS] = code_value_linear_units(); if (code_seen('Y')) delta_tower_angle_trim[B_AXIS] = code_value_linear_units(); if (code_seen('Z')) { // rotate all 3 axis for Z = 0 - delta_tower_angle_trim[A_AXIS] += code_value_linear_units(); - delta_tower_angle_trim[B_AXIS] = code_value_linear_units(); + delta_tower_angle_trim[A_AXIS] -= code_value_linear_units(); + delta_tower_angle_trim[B_AXIS] -= code_value_linear_units(); } recalc_delta_settings(delta_radius, delta_diagonal_rod); } diff --git a/Marlin/configuration_store.cpp b/Marlin/configuration_store.cpp index 6a88ef4806..eff32dc8d5 100644 --- a/Marlin/configuration_store.cpp +++ b/Marlin/configuration_store.cpp @@ -1066,13 +1066,14 @@ void MarlinSettings::reset() { #if ENABLED(DELTA) const float adj[ABC] = DELTA_ENDSTOP_ADJ, - dta[2] = DELTA_TOWER_ANGLE_TRIM; + dta[3] = DELTA_TOWER_ANGLE_TRIM; COPY(endstop_adj, adj); delta_radius = DELTA_RADIUS; delta_diagonal_rod = DELTA_DIAGONAL_ROD; delta_segments_per_second = DELTA_SEGMENTS_PER_SECOND; delta_calibration_radius = DELTA_CALIBRATION_RADIUS; - COPY(delta_tower_angle_trim, dta); + delta_tower_angle_trim[A_AXIS] = dta[A_AXIS] - dta[C_AXIS]; + delta_tower_angle_trim[B_AXIS] = dta[B_AXIS] - dta[C_AXIS]; home_offset[Z_AXIS] = 0; #elif ENABLED(Z_DUAL_ENDSTOPS) diff --git a/Marlin/example_configurations/delta/FLSUN/auto_calibrate/Configuration.h b/Marlin/example_configurations/delta/FLSUN/auto_calibrate/Configuration.h index 9b6adff674..bb53080d8e 100644 --- a/Marlin/example_configurations/delta/FLSUN/auto_calibrate/Configuration.h +++ b/Marlin/example_configurations/delta/FLSUN/auto_calibrate/Configuration.h @@ -488,7 +488,7 @@ // Trim adjustments for individual towers // tower angle corrections for X and Y tower / rotate XYZ so Z tower angle = 0 // measured in degrees anticlockwise looking from above the printer - #define DELTA_TOWER_ANGLE_TRIM { -0.00, -0.00 } // get these from auto calibrate + #define DELTA_TOWER_ANGLE_TRIM { 0.00, 0.00, 0.00 } // get these from auto calibrate // delta radius and diaginal rod adjustments measured in mm //#define DELTA_RADIUS_TRIM_TOWER {0.0, 0.0, 0.0} diff --git a/Marlin/example_configurations/delta/FLSUN/kossel_mini/Configuration.h b/Marlin/example_configurations/delta/FLSUN/kossel_mini/Configuration.h index c88d3d1dc0..dbcc9441ed 100644 --- a/Marlin/example_configurations/delta/FLSUN/kossel_mini/Configuration.h +++ b/Marlin/example_configurations/delta/FLSUN/kossel_mini/Configuration.h @@ -489,7 +489,7 @@ // Trim adjustments for individual towers // tower angle corrections for X and Y tower / rotate XYZ so Z tower angle = 0 // measured in degrees anticlockwise looking from above the printer - #define DELTA_TOWER_ANGLE_TRIM { -0.00, -0.00 } // get these from auto calibrate + #define DELTA_TOWER_ANGLE_TRIM { 0.00, 0.00, 0.00 } // get these from auto calibrate // delta radius and diaginal rod adjustments measured in mm //#define DELTA_RADIUS_TRIM_TOWER {0.0, 0.0, 0.0} diff --git a/Marlin/example_configurations/delta/generic/Configuration.h b/Marlin/example_configurations/delta/generic/Configuration.h index 744362c945..3fb5cf748d 100644 --- a/Marlin/example_configurations/delta/generic/Configuration.h +++ b/Marlin/example_configurations/delta/generic/Configuration.h @@ -480,7 +480,7 @@ // Trim adjustments for individual towers // tower angle corrections for X and Y tower / rotate XYZ so Z tower angle = 0 // measured in degrees anticlockwise looking from above the printer - #define DELTA_TOWER_ANGLE_TRIM { -0.00, -0.00 } // get these from auto calibrate + #define DELTA_TOWER_ANGLE_TRIM { 0.00, 0.00, 0.00 } // get these from auto calibrate // delta radius and diaginal rod adjustments measured in mm //#define DELTA_RADIUS_TRIM_TOWER {0.0, 0.0, 0.0} diff --git a/Marlin/example_configurations/delta/kossel_mini/Configuration.h b/Marlin/example_configurations/delta/kossel_mini/Configuration.h index c4a91ee8af..98acaa0de2 100644 --- a/Marlin/example_configurations/delta/kossel_mini/Configuration.h +++ b/Marlin/example_configurations/delta/kossel_mini/Configuration.h @@ -478,7 +478,7 @@ // Trim adjustments for individual towers // tower angle corrections for X and Y tower / rotate XYZ so Z tower angle = 0 // measured in degrees anticlockwise looking from above the printer - #define DELTA_TOWER_ANGLE_TRIM { -0.00, -0.00 } // get these from auto calibrate + #define DELTA_TOWER_ANGLE_TRIM { 0.00, 0.00, 0.00 } // get these from auto calibrate // delta radius and diaginal rod adjustments measured in mm //#define DELTA_RADIUS_TRIM_TOWER {0.0, 0.0, 0.0} diff --git a/Marlin/example_configurations/delta/kossel_pro/Configuration.h b/Marlin/example_configurations/delta/kossel_pro/Configuration.h index 34b6d02150..a086c70a3f 100644 --- a/Marlin/example_configurations/delta/kossel_pro/Configuration.h +++ b/Marlin/example_configurations/delta/kossel_pro/Configuration.h @@ -467,7 +467,7 @@ // Trim adjustments for individual towers // tower angle corrections for X and Y tower / rotate XYZ so Z tower angle = 0 // measured in degrees anticlockwise looking from above the printer - #define DELTA_TOWER_ANGLE_TRIM { -0.00, -0.00 } // get these from auto calibrate + #define DELTA_TOWER_ANGLE_TRIM { 0.00, 0.00, 0.00 } // get these from auto calibrate // delta radius and diaginal rod adjustments measured in mm //#define DELTA_RADIUS_TRIM_TOWER {0.0, 0.0, 0.0} diff --git a/Marlin/example_configurations/delta/kossel_xl/Configuration.h b/Marlin/example_configurations/delta/kossel_xl/Configuration.h index b936203130..c5e56355f1 100644 --- a/Marlin/example_configurations/delta/kossel_xl/Configuration.h +++ b/Marlin/example_configurations/delta/kossel_xl/Configuration.h @@ -483,7 +483,7 @@ // Trim adjustments for individual towers // tower angle corrections for X and Y tower / rotate XYZ so Z tower angle = 0 // measured in degrees anticlockwise looking from above the printer - #define DELTA_TOWER_ANGLE_TRIM { -0.00, -0.00 } // get these from auto calibrate + #define DELTA_TOWER_ANGLE_TRIM { 0.00, 0.00, 0.00 } // get these from auto calibrate // delta radius and diaginal rod adjustments measured in mm //#define DELTA_RADIUS_TRIM_TOWER {0.0, 0.0, 0.0}