Some minor fixes and changes.

This commit is contained in:
Terje Io
2023-12-22 13:35:27 +01:00
parent 1486280b5e
commit 49b43a5fe1
6 changed files with 101 additions and 71 deletions
+1 -1
View File
@@ -13,7 +13,7 @@ It has been written to complement grblHAL and has features such as proper keyboa
---
Latest build date is 20231216, see the [changelog](changelog.md) for details.
Latest build date is 20231222, see the [changelog](changelog.md) for details.
__NOTE:__ A settings reset will be performed on an update of builds earlier than 20230125. Backup and restore of settings is recommended.
---
+20
View File
@@ -1,5 +1,25 @@
## grblHAL changelog
<a name="20231222"/>Build 20231222
Core:
* Some minor fixes and changes.
Drivers:
* STM32F1xx: made timer assignments more flexible. Added support for PWM out on PB9. Ref. [core discussion 62](https://github.com/grblHAL/core/discussions/62).
* STM32F4xx: fixed typos in SPI interface code for SPI3.
Plugins:
* Spindle: updated and verified code for second PWM spindle on top of aux outputs. Requires one PWM capable analog output and at least one digital.
* Embroidery: no longer starts spindle if sync mode is disabled.
---
<a name="20231218"/>Build 20231218
Core:
+1 -1
View File
@@ -42,7 +42,7 @@
#else
#define GRBL_VERSION "1.1f"
#endif
#define GRBL_BUILD 20231218
#define GRBL_BUILD 20231222
#define GRBL_URL "https://github.com/grblHAL"
+1 -1
View File
@@ -35,7 +35,7 @@
#include "machine_limits.h"
#ifndef RT_QUEUE_SIZE
#define RT_QUEUE_SIZE 8 // must be a power of 2
#define RT_QUEUE_SIZE 16 // must be a power of 2
#endif
// Define line flags. Includes comment type tracking and line overflow detection.
+75 -68
View File
@@ -1464,94 +1464,101 @@ static void report_settings_detail (settings_format_t format, const setting_deta
switch(format)
{
case SettingsFormat_HumanReadable:
hal.stream.write(ASCII_EOL "$");
hal.stream.write(uitoa(setting->id + offset));
hal.stream.write(": ");
if(setting->group == Group_Axis0)
hal.stream.write(axis_letter[offset]);
write_name(setting->name, suboffset);
{
bool reboot_newline = false;
switch(setting_datatype_to_external(setting->datatype)) {
hal.stream.write(ASCII_EOL "$");
hal.stream.write(uitoa(setting->id + offset));
hal.stream.write(": ");
if(setting->group == Group_Axis0)
hal.stream.write(axis_letter[offset]);
write_name(setting->name, suboffset);
case Format_AxisMask:
hal.stream.write(" as axismask");
break;
switch(setting_datatype_to_external(setting->datatype)) {
case Format_Bool:
hal.stream.write(" as boolean");
break;
case Format_AxisMask:
hal.stream.write(" as axismask");
break;
case Format_Bitfield:
hal.stream.write(" as bitfield:");
report_bitfield(setting->format, true);
break;
case Format_Bool:
hal.stream.write(" as boolean");
break;
case Format_XBitfield:
hal.stream.write(" as bitfield where setting bit 0 enables the rest:");
report_bitfield(setting->format, true);
break;
case Format_Bitfield:
hal.stream.write(" as bitfield:");
report_bitfield(setting->format, true);
reboot_newline = true;
break;
case Format_RadioButtons:
hal.stream.write(":");
report_bitfield(setting->format, false);
break;
case Format_XBitfield:
hal.stream.write(" as bitfield where setting bit 0 enables the rest:");
report_bitfield(setting->format, true);
reboot_newline = true;
break;
case Format_IPv4:
hal.stream.write(" as IP address");
break;
case Format_RadioButtons:
hal.stream.write(":");
report_bitfield(setting->format, false);
reboot_newline = true;
break;
default:
if(setting->unit) {
hal.stream.write(" in ");
hal.stream.write(setting->unit);
}
break;
}
case Format_IPv4:
hal.stream.write(" as IP address");
break;
if(setting->min_value && setting->max_value) {
hal.stream.write(", range: ");
hal.stream.write(setting->min_value);
hal.stream.write(" - ");
hal.stream.write(setting->max_value);
} else if(!setting_is_list(setting)) {
if(setting->min_value) {
hal.stream.write(", min: ");
default:
if(setting->unit) {
hal.stream.write(" in ");
hal.stream.write(setting->unit);
}
break;
}
if(setting->min_value && setting->max_value) {
hal.stream.write(", range: ");
hal.stream.write(setting->min_value);
}
if(setting->max_value) {
hal.stream.write(", max: ");
hal.stream.write(" - ");
hal.stream.write(setting->max_value);
} else if(!setting_is_list(setting)) {
if(setting->min_value) {
hal.stream.write(", min: ");
hal.stream.write(setting->min_value);
}
if(setting->max_value) {
hal.stream.write(", max: ");
hal.stream.write(setting->max_value);
}
}
}
if(setting->flags.reboot_required)
hal.stream.write(", reboot required");
if(setting->flags.reboot_required)
hal.stream.write(reboot_newline ? ASCII_EOL ASCII_EOL "Reboot required." : ", reboot required");
#ifndef NO_SETTINGS_DESCRIPTIONS
// Add description if driver is capable of outputting it...
if(hal.stream.write_n) {
const char *description = setting_get_description((setting_id_t)(setting->id + offset));
if(description && *description != '\0') {
char *lf;
hal.stream.write(ASCII_EOL);
if((lf = strstr(description, "\\n"))) while(lf) {
// Add description if driver is capable of outputting it...
if(hal.stream.write_n) {
const char *description = setting_get_description((setting_id_t)(setting->id + offset));
if(description && *description != '\0') {
char *lf;
hal.stream.write(ASCII_EOL);
hal.stream.write_n(description, lf - description);
description = lf + 2;
lf = strstr(description, "\\n");
if((lf = strstr(description, "\\n"))) while(lf) {
hal.stream.write(ASCII_EOL);
hal.stream.write_n(description, lf - description);
description = lf + 2;
lf = strstr(description, "\\n");
}
if(*description != '\0') {
hal.stream.write(ASCII_EOL);
hal.stream.write(description);
}
}
if(*description != '\0') {
hal.stream.write(ASCII_EOL);
hal.stream.write(description);
if(setting->flags.reboot_required) {
if(description && *description != '\0')
hal.stream.write(ASCII_EOL ASCII_EOL);
hal.stream.write(SETTINGS_HARD_RESET_REQUIRED + 4);
}
}
if(setting->flags.reboot_required) {
if(description && *description != '\0')
hal.stream.write(ASCII_EOL ASCII_EOL);
hal.stream.write(SETTINGS_HARD_RESET_REQUIRED + 4);
}
}
#endif
}
break;
case SettingsFormat_MachineReadable:
+3
View File
@@ -631,6 +631,7 @@ void spindle_all_off (void)
{
spindle_ptrs_t *spindle;
uint_fast8_t spindle_num = N_SYS_SPINDLE;
do {
if((spindle = spindle_get(--spindle_num))) {
spindle->param->rpm = spindle->param->rpm_overridden = 0.0f;
@@ -642,6 +643,8 @@ void spindle_all_off (void)
#endif
}
} while(spindle_num);
system_add_rt_report(Report_Spindle);
}
/*! \brief Check if any of the enabled spindles is running.