Commit 687dc9a 1 parent 755c196 commit 687dc9a Copy full SHA for 687dc9a
File tree 2 files changed +6
-4
lines changed
2 files changed +6
-4
lines changed Original file line number Diff line number Diff line change 24
24
#if ENABLED(X_AXIS_TWIST_COMPENSATION)
25
25
26
26
#include " x_twist.h"
27
+ #include " ../module/probe.h"
27
28
28
29
XATC xatc;
29
30
30
- bool XATC::enabled = true ;
31
+ bool XATC::enabled;
31
32
float XATC::spacing, XATC::start;
32
33
xatc_array_t XATC::z_offset; // Initialized by settings.load()
33
34
34
35
void XATC::reset () {
35
36
constexpr float xzo[] = XATC_Z_OFFSETS;
36
37
static_assert (COUNT (xzo) == XATC_MAX_POINTS, " XATC_Z_OFFSETS is the wrong size." );
37
- enabled = false ;
38
38
COPY (z_offset, xzo);
39
+ xatc.spacing = (probe.max_x () - probe.min_x ()) / (XATC_MAX_POINTS - 1 );
40
+ xatc.start = probe.min_x ();
41
+ enabled = true ;
39
42
}
40
43
41
44
void XATC::print_points () {
Original file line number Diff line number Diff line change @@ -189,8 +189,7 @@ void xatc_wizard_homing_done() {
189
189
}
190
190
191
191
if (ui.use_click ()) {
192
- xatc.spacing = (probe.max_x () - probe.min_x ()) / (XATC_MAX_POINTS - 1 );
193
- xatc.start = probe.min_x ();
192
+ xatc.reset ();
194
193
195
194
SET_SOFT_ENDSTOP_LOOSE (true ); // Disable soft endstops for free Z movement
196
195
You can’t perform that action at this time.
0 commit comments