Init XYZ to configured home position
This commit is contained in:
parent
4fbbce9a35
commit
a2e3226597
@ -921,9 +921,7 @@ void setup() {
|
|||||||
|
|
||||||
#if HAS_M206_COMMAND
|
#if HAS_M206_COMMAND
|
||||||
// Initialize current position based on home_offset
|
// Initialize current position based on home_offset
|
||||||
COPY(current_position, home_offset);
|
LOOP_XYZ(a) current_position[a] += home_offset[a];
|
||||||
#else
|
|
||||||
ZERO(current_position);
|
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
// Vital to init stepper/planner equivalent for current_position
|
// Vital to init stepper/planner equivalent for current_position
|
||||||
|
@ -88,7 +88,7 @@ bool relative_mode; // = false;
|
|||||||
* Used by 'buffer_line_to_current_position' to do a move after changing it.
|
* Used by 'buffer_line_to_current_position' to do a move after changing it.
|
||||||
* Used by 'sync_plan_position' to update 'planner.position'.
|
* Used by 'sync_plan_position' to update 'planner.position'.
|
||||||
*/
|
*/
|
||||||
float current_position[XYZE] = { 0 };
|
float current_position[XYZE] = { X_HOME_POS, Y_HOME_POS, Z_HOME_POS };
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Cartesian Destination
|
* Cartesian Destination
|
||||||
@ -96,7 +96,7 @@ float current_position[XYZE] = { 0 };
|
|||||||
* and expected by functions like 'prepare_move_to_destination'.
|
* and expected by functions like 'prepare_move_to_destination'.
|
||||||
* Set with 'get_destination_from_command' or 'set_destination_from_current'.
|
* Set with 'get_destination_from_command' or 'set_destination_from_current'.
|
||||||
*/
|
*/
|
||||||
float destination[XYZE] = { 0 };
|
float destination[XYZE]; // = { 0 }
|
||||||
|
|
||||||
// The active extruder (tool). Set with T<extruder> command.
|
// The active extruder (tool). Set with T<extruder> command.
|
||||||
#if EXTRUDERS > 1
|
#if EXTRUDERS > 1
|
||||||
|
Loading…
Reference in New Issue
Block a user