Skip to content

Commit 3aeef25

Browse files
committed
Fix for spindle related crash after core change. Ref. issue #19.
1 parent 18aa72b commit 3aeef25

File tree

1 file changed

+6
-2
lines changed

1 file changed

+6
-2
lines changed

src/driver.c

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
44
Part of grblHAL
55
6-
Copyright (c) 2020-2025 Terje Io
6+
Copyright (c) 2020-2026 Terje Io
77
88
grblHAL is free software: you can redistribute it and/or modify
99
it under the terms of the GNU General Public License as published by
@@ -301,6 +301,10 @@ static bool spindleConfig (spindle_ptrs_t *spindle)
301301
if(spindle == NULL)
302302
return false;
303303

304+
static spindle_pwm_t spindle_pwm;
305+
306+
spindle_precompute_pwm_values(spindle, &spindle_pwm, &settings.pwm_spindle, 1000000);
307+
304308
// spindle_update_caps(spindle, spindle->cap.variable ? &spindle_pwm : NULL);
305309

306310
return true;
@@ -429,7 +433,7 @@ bool driver_init ()
429433
systick_timer.enable = 1;
430434

431435
hal.info = "Simulator";
432-
hal.driver_version = "251002";
436+
hal.driver_version = "260324";
433437
hal.driver_setup = driver_setup;
434438
hal.rx_buffer_size = RX_BUFFER_SIZE;
435439
hal.f_step_timer = F_CPU;

0 commit comments

Comments
 (0)