mirror of
https://github.com/bdring/Grbl_Esp32.git
synced 2025-09-01 02:21:46 +02:00
Fixed startup issue with spindle
The spindle object was not getting created unitl after the wifi starts. If a n open serial port starts requesting status of the spindle, it is trying to talk to a null object. The solution was to start the spindle before the wifi
This commit is contained in:
@@ -91,6 +91,7 @@ void setup() {
|
||||
#ifdef HOMING_INIT_LOCK
|
||||
if (bit_istrue(settings.flags, BITFLAG_HOMING_ENABLE)) sys.state = STATE_ALARM;
|
||||
#endif
|
||||
spindle_select(SPINDLE_TYPE);
|
||||
#ifdef ENABLE_WIFI
|
||||
wifi_config.begin();
|
||||
#endif
|
||||
@@ -117,7 +118,7 @@ void loop() {
|
||||
// Reset Grbl primary systems.
|
||||
serial_reset_read_buffer(CLIENT_ALL); // Clear serial read buffer
|
||||
gc_init(); // Set g-code parser to default state
|
||||
spindle_select(SPINDLE_TYPE);
|
||||
//spindle_select(SPINDLE_TYPE);
|
||||
coolant_init();
|
||||
limits_init();
|
||||
probe_init();
|
||||
|
Reference in New Issue
Block a user