mirror of
https://github.com/bdring/Grbl_Esp32.git
synced 2025-08-31 10:01:48 +02:00
Homing cycle 0 means not homed with home-all, but $HA would work
This commit is contained in:
@@ -392,7 +392,7 @@ void limits_run_homing_cycles(AxisMask axis_mask) {
|
||||
// Run all homing cycles
|
||||
bool someAxisHomed = false;
|
||||
|
||||
for (int cycle = 0; cycle < MAX_N_AXIS; cycle++) {
|
||||
for (int cycle = 1; cycle <= MAX_N_AXIS; cycle++) {
|
||||
// Set axis_mask to the axes that home on this cycle
|
||||
axis_mask = 0;
|
||||
auto n_axis = config->_axes->_numberAxis;
|
||||
|
@@ -25,6 +25,8 @@ namespace Machine {
|
||||
public:
|
||||
Homing() = default;
|
||||
|
||||
// The homing cycles are 1,2,3 etc. 0 means not homed as part of home-all,
|
||||
// but you can still home it manually with e.g. $HA
|
||||
int _cycle = -1; // what homing cycle does this axis home on?
|
||||
bool _square = false;
|
||||
bool _positiveDirection = true;
|
||||
@@ -37,7 +39,7 @@ namespace Machine {
|
||||
float _locate_scaler = 1.0f;
|
||||
|
||||
// Configuration system helpers:
|
||||
void validate() const override { Assert(_cycle >= 1, "Cycle has to be defined as >= 1 for homing sequence."); }
|
||||
void validate() const override { Assert(_cycle >= 0, "Homing cycle must be defined"); }
|
||||
|
||||
void group(Configuration::HandlerBase& handler) override {
|
||||
handler.item("cycle", _cycle);
|
||||
|
Reference in New Issue
Block a user