grblHAL / SAM3X8E

grblHAL driver for Atmel SAM3X8E (Arduino Due)
Other
12 stars 11 forks source link

Spindle is switched off when speed is 0 #28

Open Deltaplc opened 2 days ago

Deltaplc commented 2 days ago

Good morning Sorry for my english....google translator.... I wanted to replace an Arduino Mega (grbl) with an Arduino Due SAM3X8E (grblhal) to control a laser and have more computing power! I noticed that the enable pin doesn't work like in grbl! M3 S0 = enable pin off!! But it remains active even with just M3!! Can its behavior be modified so that it is compatible with the behavior of the old grbl? I'm sorry to bother you but I can't find any documentation about it!! Thank you in advance!

terjeio commented 2 days ago

What is your $9 setting?

$$=9 outputs:

    0 - Enable (1)
    1 - RPM controls spindle enable signal (2)
    2 - Disable laser mode capability (4)
Enable controls PWM output availability.
When `RPM controls spindle enable signal` is checked and M3 or M4 is active S0 switches it off and S > 0 switches it on.

And is $32=1 (laser mode)?

Deltaplc commented 2 days ago

HI Thanks for the reply! The current position of $9=0! I tried changing to $9=1....but it doesn't change the behavior!! $32=1 ok!

Deltaplc commented 2 days ago

I read somewhere that the $7 command also exists!! What is this for? It doesn't appear in my $$ list! Could you tell me where I can find updated documentation on grblhal's $ commands?

Deltaplc commented 2 days ago

If I enter $9=2... and then do $$, $9 goes back to $9=0!!! Why??

Deltaplc commented 2 days ago

This is in my config.h file....

// Spindle settings (Group_Spindle)

/! @name $9 - Setting_SpindlePWMOptions / ///@{

if !defined DEFAULT_SPINDLE_ENABLE_OFF_WITH_ZERO_SPEED || defined DOXYGEN

define DEFAULT_SPINDLE_ENABLE_OFF_WITH_ZERO_SPEED Off

endif

///@}

Deltaplc commented 2 days ago

I tried other settings... $9 = 3 It seems that the enable pin works like in the old grbl! I also set $16=1 Now it seems to work like with Arduino Mega grbl Is there an updated and more detailed list of GrblHal $codes? Thanks for your help!