gcobos / grblesp

GRBL ported to ESP8266, using up to 8 axis. No arduino involved
53 stars 24 forks source link

Enable interrupts after the task switch flag was cleared #3

Closed apollo2030 closed 4 years ago

apollo2030 commented 4 years ago

Grbl uses flags to switch tasks and to set them it disables the interrupts with cli(), sets the flag then calls restore_SREG() which is defined as #define restore_SREG(state) xt_wsr_ps(state); sei(); // restore the state (uint32_t). It seems that the macro definition is wrong because after adding an additional call to sei(); in the flag clearing functions - the nodemcu doesn't software reset.

apollo2030 commented 4 years ago

Fixes #4