mirror of
https://github.com/bdring/Grbl_Esp32.git
synced 2025-08-18 12:21:39 +02:00
Fix race condition in Huanyang.h.
- Initial queue before task.
This commit is contained in:
@@ -108,6 +108,7 @@ void vfd_cmd_task(void* pvParameters) {
|
|||||||
void HuanyangSpindle :: init() {
|
void HuanyangSpindle :: init() {
|
||||||
|
|
||||||
if (! _task_running) { // init can happen many times, we only want to start one task
|
if (! _task_running) { // init can happen many times, we only want to start one task
|
||||||
|
hy_cmd_queue = xQueueCreate(5, sizeof(hy_command_t));
|
||||||
xTaskCreatePinnedToCore(vfd_cmd_task, // task
|
xTaskCreatePinnedToCore(vfd_cmd_task, // task
|
||||||
"vfd_cmdTaskHandle", // name for task
|
"vfd_cmdTaskHandle", // name for task
|
||||||
2048, // size of task stack
|
2048, // size of task stack
|
||||||
@@ -116,7 +117,6 @@ void HuanyangSpindle :: init() {
|
|||||||
&vfd_cmdTaskHandle,
|
&vfd_cmdTaskHandle,
|
||||||
0 // core
|
0 // core
|
||||||
);
|
);
|
||||||
hy_cmd_queue = xQueueCreate(5, sizeof(hy_command_t));
|
|
||||||
_task_running = true;
|
_task_running = true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@@ -22,7 +22,7 @@
|
|||||||
// Grbl versioning system
|
// Grbl versioning system
|
||||||
|
|
||||||
#define GRBL_VERSION "1.2a"
|
#define GRBL_VERSION "1.2a"
|
||||||
#define GRBL_VERSION_BUILD "20200631"
|
#define GRBL_VERSION_BUILD "20200710"
|
||||||
|
|
||||||
//#include <sdkconfig.h>
|
//#include <sdkconfig.h>
|
||||||
#include <Arduino.h>
|
#include <Arduino.h>
|
||||||
|
Reference in New Issue
Block a user