mirror of
https://github.com/grblHAL/core.git
synced 2026-02-06 00:52:35 +08:00
Fixed regression mainly affecting WebUI enabled builds. Some internal changes.
This commit is contained in:
18
changelog.md
18
changelog.md
@@ -1,6 +1,22 @@
|
||||
## grblHAL changelog
|
||||
|
||||
<a name="20240125"/>Build 20240125
|
||||
<a name="20240127"/>Build 20240127
|
||||
|
||||
Core:
|
||||
|
||||
* Fixed regression mainly affecting WebUI enabled builds. Some internal changes.
|
||||
|
||||
Drivers:
|
||||
|
||||
* ESP32: reorganized main driver code for readability, minor fixes.
|
||||
|
||||
Plugins:
|
||||
|
||||
* SD card: commented out unused code to avoid compiler warning.
|
||||
|
||||
---
|
||||
|
||||
<a name="20240125"/>Build 20240125
|
||||
|
||||
Core, for developers:
|
||||
|
||||
|
||||
@@ -501,12 +501,18 @@ typedef struct {
|
||||
bool servo_mode;
|
||||
} pwm_config_t;
|
||||
|
||||
typedef union
|
||||
{
|
||||
// pin_mode_t *pin_mode;
|
||||
pwm_config_t *pwm_config;
|
||||
} xbar_cfg_ptr_t __attribute__ ((__transparent_union__));
|
||||
|
||||
struct xbar;
|
||||
|
||||
typedef float (*xbar_get_value_ptr)(struct xbar *pin);
|
||||
typedef void (*xbar_set_value_ptr)(struct xbar *pin, float value);
|
||||
typedef void (*xbar_event_ptr)(bool on);
|
||||
typedef bool (*xbar_config_ptr)(struct xbar *pin, void *cfg_data);
|
||||
typedef bool (*xbar_config_ptr)(struct xbar *pin, xbar_cfg_ptr_t cfg_data);
|
||||
|
||||
typedef enum {
|
||||
AuxCtrl_SafetyDoor = 0,
|
||||
|
||||
@@ -79,6 +79,10 @@
|
||||
#define PROBE_ENABLE 1
|
||||
#endif
|
||||
|
||||
#ifndef NEOPIXELS_ENABLE
|
||||
#define NEOPIXELS_ENABLE 0
|
||||
#endif
|
||||
|
||||
#ifndef USB_SERIAL_CDC
|
||||
#define USB_SERIAL_CDC 0 // for UART comms
|
||||
#endif
|
||||
|
||||
2
grbl.h
2
grbl.h
@@ -42,7 +42,7 @@
|
||||
#else
|
||||
#define GRBL_VERSION "1.1f"
|
||||
#endif
|
||||
#define GRBL_BUILD 20240125
|
||||
#define GRBL_BUILD 20240127
|
||||
|
||||
#define GRBL_URL "https://github.com/grblHAL"
|
||||
|
||||
|
||||
@@ -542,7 +542,7 @@ static void delta_homing_complete (bool success)
|
||||
: machine.home_z - settings.homing.pulloff;
|
||||
|
||||
if(machine.cfg.flags.home_to_cuboid_top)
|
||||
protocol_enqueue_foreground_task(delta_go_home);
|
||||
protocol_enqueue_foreground_task(delta_go_home, NULL);
|
||||
}
|
||||
|
||||
if(on_homing_completed)
|
||||
|
||||
15
vfs.c
15
vfs.c
@@ -200,8 +200,10 @@ vfs_file_t *vfs_open (const char *filename, const char *mode)
|
||||
vfs_file_t *file = NULL;
|
||||
vfs_mount_t *mount = get_mount(filename);
|
||||
|
||||
if(mount && (file = mount->vfs->fopen(get_filename(mount, filename), mode)))
|
||||
if(mount && (file = mount->vfs->fopen(get_filename(mount, filename), mode))) {
|
||||
file->fs = mount->vfs;
|
||||
file->update = !mount->mode.hidden && !!strchr(mode, 'w');
|
||||
}
|
||||
|
||||
return file;
|
||||
}
|
||||
@@ -212,7 +214,8 @@ void vfs_close (vfs_file_t *file)
|
||||
|
||||
((vfs_t *)(file->fs))->fclose(file);
|
||||
|
||||
// TODO: somehow raise vfs.on_fs_changed event when a file openened for writing is closed
|
||||
if(file->update && vfs.on_fs_changed)
|
||||
vfs.on_fs_changed((vfs_t *)file->fs);
|
||||
}
|
||||
|
||||
size_t vfs_read (void *buffer, size_t size, size_t count, vfs_file_t *file)
|
||||
@@ -502,12 +505,12 @@ bool vfs_mount (const char *path, const vfs_t *fs, vfs_st_mode_t mode)
|
||||
mount->mode = mode;
|
||||
mount->next = NULL;
|
||||
|
||||
vfs_mount_t *mount = &root;
|
||||
vfs_mount_t *lmount = &root;
|
||||
|
||||
while(mount->next)
|
||||
mount = mount->next;
|
||||
while(lmount->next)
|
||||
lmount = lmount->next;
|
||||
|
||||
mount->next = mount;
|
||||
lmount->next = mount;
|
||||
}
|
||||
|
||||
if(fs && vfs.on_mount)
|
||||
|
||||
5
vfs.h
5
vfs.h
@@ -80,7 +80,8 @@ typedef struct {
|
||||
typedef struct {
|
||||
const void *fs;
|
||||
size_t size;
|
||||
uint8_t handle; // first byte of file handle structure
|
||||
bool update;
|
||||
uint8_t handle __attribute__ ((aligned (4))); // first byte of file handle structure
|
||||
} vfs_file_t;
|
||||
|
||||
struct vfs_dir;
|
||||
@@ -191,7 +192,7 @@ typedef struct {
|
||||
struct vfs_dir {
|
||||
const void *fs;
|
||||
vfs_mount_ll_entry_t *mounts;
|
||||
uint8_t handle; // must be last!
|
||||
uint8_t handle __attribute__ ((aligned (4))); // must be last!
|
||||
};
|
||||
|
||||
extern int vfs_errno;
|
||||
|
||||
Reference in New Issue
Block a user