From b2e5ec85d7f707494b8a281e0d13b3502e75adb0 Mon Sep 17 00:00:00 2001 From: Scott Lahteine Date: Tue, 30 Aug 2016 14:15:41 -0500 Subject: [PATCH] Add [XYZ]_CENTER conditionals --- Marlin/Conditionals_post.h | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/Marlin/Conditionals_post.h b/Marlin/Conditionals_post.h index d0a7c67a8..6eab11dac 100644 --- a/Marlin/Conditionals_post.h +++ b/Marlin/Conditionals_post.h @@ -35,11 +35,14 @@ #endif /** - * Axis lengths + * Axis lengths and center */ #define X_MAX_LENGTH (X_MAX_POS - (X_MIN_POS)) #define Y_MAX_LENGTH (Y_MAX_POS - (Y_MIN_POS)) #define Z_MAX_LENGTH (Z_MAX_POS - (Z_MIN_POS)) + #define X_CENTER float((X_MIN_POS + X_MAX_POS) * 0.5) + #define Y_CENTER float((Y_MIN_POS + Y_MAX_POS) * 0.5) + #define Z_CENTER float((Z_MIN_POS + Z_MAX_POS) * 0.5) /** * CoreXY and CoreXZ