mirror of
https://github.com/grblHAL/core.git
synced 2026-02-06 09:02:33 +08:00
Fixed issue where VFD spindle alarm during homing failed to stop movement.
Changed homing init to only stop spindle and coolant if already on.
This commit is contained in:
@@ -11,7 +11,7 @@ It has been written to complement grblHAL and has features such as proper keyboa
|
||||
|
||||
---
|
||||
|
||||
Latest build date is 20211213, see the [changelog](changelog.md) for details.
|
||||
Latest build date is 20211218, see the [changelog](changelog.md) for details.
|
||||
__NOTE:__ A settings reset will be performed on an update for versions earlier than 20211122. Backup and restore of settings is recommended.
|
||||
__IMPORTANT!__ A new setting has been introduced for ganged axes motors in version 20211121.
|
||||
I have only bench tested this for a couple of drivers, correct function should be verified after updating by those who have more than three motors configured.
|
||||
@@ -83,4 +83,4 @@ List of Supported G-Codes:
|
||||
Some [plugins](https://github.com/grblHAL/plugins) implements additional M-codes.
|
||||
|
||||
---
|
||||
2021-12-13
|
||||
2021-12-18
|
||||
|
||||
27
changelog.md
27
changelog.md
@@ -1,5 +1,31 @@
|
||||
## grblHAL changelog
|
||||
|
||||
Build 20211218:
|
||||
|
||||
Core:
|
||||
|
||||
* Fixed issue where VFD spindle alarm during homing failed to stop movement. Changed homing init to only stop spindle and coolant if already on.
|
||||
|
||||
Plugins:
|
||||
|
||||
* Trinamic: Bug fixes and improvements for ganged axes handling.
|
||||
|
||||
Drivers:
|
||||
|
||||
* All STM32 drivers, LPC176x, MSP432E401Y and TM4C1294:
|
||||
Made folder references relative in Eclipse _.cproject_ file to allow renaming of project.
|
||||
|
||||
* STM32F4xx:
|
||||
Added alternative startup code for F407 and F446 to allow use of additional peripherals in user code.
|
||||
__NOTE:__ This may break PlatformIO compilation. A possible workaround is to delete the startup folders not matching the MCU variant.
|
||||
Added support for Bigtreetech SKR 1.2 boards \(as a synonomym for SKR 1.1\), switched soft UART pins for Trinamic drivers to direct connection.
|
||||
|
||||
* ESP32: Bug fixes for ganged axes and output pins with pin number > 31.
|
||||
|
||||
* SAM3X8E and SAMD21: Simplified USB polling.
|
||||
|
||||
---
|
||||
|
||||
Build 20211213:
|
||||
|
||||
Core:
|
||||
@@ -21,6 +47,7 @@ Plugins:
|
||||
* Networking, Bluetooth: updated for core stream switcher.
|
||||
|
||||
---
|
||||
|
||||
Core:
|
||||
|
||||
* Renamed unused function.
|
||||
|
||||
2
grbl.h
2
grbl.h
@@ -34,7 +34,7 @@
|
||||
#else
|
||||
#define GRBL_VERSION "1.1f"
|
||||
#endif
|
||||
#define GRBL_BUILD 20211209
|
||||
#define GRBL_BUILD 20211218
|
||||
|
||||
// The following symbols are set here if not already set by the compiler or in config.h
|
||||
// Do NOT change here!
|
||||
|
||||
@@ -781,18 +781,22 @@ status_code_t mc_homing_cycle (axes_signals_t cycle)
|
||||
|
||||
state_set(STATE_HOMING); // Set homing system state.
|
||||
#if COMPATIBILITY_LEVEL == 0
|
||||
protocol_enqueue_realtime_command(CMD_STATUS_REPORT); // Force a status report and
|
||||
protocol_enqueue_realtime_command(CMD_STATUS_REPORT); // Force a status report and
|
||||
delay_sec(0.1f, DelayMode_Dwell); // delay a bit to get it sent (or perhaps wait a bit for a request?)
|
||||
#endif
|
||||
hal.limits.enable(false, true); // Disable hard limits pin change register for cycle duration
|
||||
|
||||
// Turn off spindle and coolant (and update parser state)
|
||||
gc_state.spindle.rpm = 0.0f;
|
||||
gc_state.modal.spindle.on = gc_state.modal.spindle.ccw = Off;
|
||||
spindle_set_state(gc_state.modal.spindle, 0.0f);
|
||||
if(hal.spindle.get_state().on) {
|
||||
gc_state.spindle.rpm = 0.0f;
|
||||
gc_state.modal.spindle.on = gc_state.modal.spindle.ccw = Off;
|
||||
spindle_set_state(gc_state.modal.spindle, 0.0f);
|
||||
}
|
||||
|
||||
gc_state.modal.coolant.mask = 0;
|
||||
coolant_set_state(gc_state.modal.coolant);
|
||||
if(hal.coolant.get_state().mask) {
|
||||
gc_state.modal.coolant.mask = 0;
|
||||
coolant_set_state(gc_state.modal.coolant);
|
||||
}
|
||||
|
||||
// ---------------------------------------------------------------------------
|
||||
// Perform homing routine. NOTE: Special motion case. Only system reset works.
|
||||
|
||||
2
report.c
2
report.c
@@ -285,7 +285,7 @@ status_code_t report_status_message (status_code_t status_code)
|
||||
alarm_code_t report_alarm_message (alarm_code_t alarm_code)
|
||||
{
|
||||
hal.stream.write_all(appendbuf(3, "ALARM:", uitoa((uint32_t)alarm_code), ASCII_EOL));
|
||||
hal.delay_ms(500, NULL); // Force delay to ensure message clears output stream buffer.
|
||||
hal.delay_ms(100, NULL); // Force delay to ensure message clears output stream buffer.
|
||||
|
||||
return alarm_code;
|
||||
}
|
||||
|
||||
4
system.c
4
system.c
@@ -980,7 +980,9 @@ void system_apply_jog_limits (float *target)
|
||||
|
||||
void system_raise_alarm (alarm_code_t alarm)
|
||||
{
|
||||
if(sys.alarm != alarm) {
|
||||
if(state_get() == STATE_HOMING && !(sys.rt_exec_state & EXEC_RESET))
|
||||
system_set_exec_alarm(alarm);
|
||||
else if(sys.alarm != alarm) {
|
||||
sys.alarm = alarm;
|
||||
state_set(alarm == Alarm_EStop ? STATE_ESTOP : STATE_ALARM);
|
||||
if(sys.driver_started || sys.alarm == Alarm_SelftestFailed)
|
||||
|
||||
Reference in New Issue
Block a user