diff --git a/Grbl_Esp32/src/Grbl.h b/Grbl_Esp32/src/Grbl.h index 2172f344..1d3e57e3 100644 --- a/Grbl_Esp32/src/Grbl.h +++ b/Grbl_Esp32/src/Grbl.h @@ -22,7 +22,7 @@ // Grbl versioning system const char* const GRBL_VERSION = "1.3a"; -const char* const GRBL_VERSION_BUILD = "20210304"; +const char* const GRBL_VERSION_BUILD = "20210305"; //#include #include diff --git a/Grbl_Esp32/src/Motors/StandardStepper.cpp b/Grbl_Esp32/src/Motors/StandardStepper.cpp index 68803a46..3f5a91da 100644 --- a/Grbl_Esp32/src/Motors/StandardStepper.cpp +++ b/Grbl_Esp32/src/Motors/StandardStepper.cpp @@ -40,7 +40,11 @@ namespace Motors { } StandardStepper::StandardStepper(uint8_t axis_index, uint8_t step_pin, uint8_t dir_pin, uint8_t disable_pin) : - Motor(axis_index), _step_pin(step_pin), _dir_pin(dir_pin), _disable_pin(disable_pin) {} + Motor(axis_index), _step_pin(step_pin), _dir_pin(dir_pin), _disable_pin(disable_pin) { +#ifdef USE_RMT_STEPS + _rmt_chan_num = get_next_RMT_chan_num(); +#endif + } void StandardStepper::init() { read_settings(); @@ -72,7 +76,6 @@ namespace Motors { rmtItem[1].duration0 = 0; rmtItem[1].duration1 = 0; - _rmt_chan_num = get_next_RMT_chan_num(); if (_rmt_chan_num == RMT_CHANNEL_MAX) { return; }