|
Post by Bruce on Sept 2, 2018 4:33:15 GMT
On the Protoneer.co.nz webpage it has the following description for GRBL’s PWM functionality – How to control a laser or variable speed spindle. Link: blog.protoneer.co.nz/grbls-pwm-functionality-how-to-control-a-laser-or-variable-speed-spindle/M3 Command : Sets Spindle Pin to the PWM rate as specified by the S command. (Clockwise) Sets Spindle Direction pin High M4 Command : Sets Spindle Pin to the PWM rate as specified by the S command.(Counter Clockwise) Sets Spindle Direction pin Low I'm getting the exact opposite control on the Spindle Direction Pin. M3 sets Spindle Direction Pin Low = 0V and M4 sets Spindle Direction Pin High = 5V Is there a way to reverse this in the GRBL settings? I loaded the file "Carve King Homing and No Homing Laser Spindle.hex"
|
|
|
Post by Bruce on Sept 2, 2018 5:13:55 GMT
I found this in the GRBL Config.h file. Looks like this is enabled in the hex file I'm running.
// Inverts the spindle enable pin from low-disabled/high-enabled to low-enabled/high-disabled. Useful // for some pre-built electronic boards. // NOTE: If VARIABLE_SPINDLE is enabled(default), this option has no effect as the PWM output and // spindle enable are combined to one pin. If you need both this option and spindle speed PWM, // uncomment the config option USE_SPINDLE_DIR_AS_ENABLE_PIN below. // #define INVERT_SPINDLE_ENABLE_PIN // Default disabled. Uncomment to enable.
|
|
|
Post by Bruce on Sept 3, 2018 15:14:01 GMT
I figured this out. I had to make some changes to the Config.h file and recompile. It looks like if you don't specify the GRBL setup parameters in the Config.h file it will use the existing settings with no changes. I'm going to make another post on how to use bCNC with the spindle control interface.
|
|
|
Post by Derek the Admin on Sept 3, 2018 15:43:19 GMT
Thanks for sharing. Let us know how you like the setup once all complete.
|
|
|
Post by Bruce on Sept 3, 2018 15:52:21 GMT
It's pretty slick actually. I can manually start / stop the spindle and set spindle speed in the bCNC control interface with a button and slider.
|
|