vlachoudis / bCNC

GRBL CNC command sender, autoleveler and g-code editor
GNU General Public License v2.0
1.54k stars 528 forks source link

bCNC say's not connected, but I can jog. Solved by $10=1, but now I cannot zero #1687

Open GatzeTech opened 2 years ago

GatzeTech commented 2 years ago

bCNC say after connecting to a STM32F401 with Grblhal that it is not connected, but I can jog around. I saw a solution in these \ https://github.com/vlachoudis/bCNC/issues/1133 https://github.com/vlachoudis/bCNC/issues/544 https://github.com/vlachoudis/bCNC/issues/1017 https://github.com/vlachoudis/bCNC/issues/1644

After changing $10=1 I could get the state idle again and have readings of xyz. But now I cannot zero anymore, probably because I get now only the machine position back (and not work position). Everything is still working fine in UGS.

How to get work position back and how to zero ?

And the most strange thing is: yesterday everything was working fine with $10=0, how could this strange behaviour could be explained ?

Btw I really like the program especially the cam feature to have a fast posibility to flatten or drill, keep up the good work.

GatzeTech commented 2 years ago

It was very hard to find information about the $10 command. First I read this: https://github.com/terjeio/grblHAL/blob/master/doc/markdown/settings.md

But still no luck. Then I found this pdf and that brought me the idea hat the bits are used as mask value's: https://www.google.com/url?sa=t&rct=j&q=&esrc=s&source=web&cd=&cad=rja&uact=8&ved=2ahUKEwjfzdPzxaX2AhUUPuwKHW8iBWoQFnoECAkQAQ&url=https%3A%2F%2Fwww.routerforums.com%2Fattachments%2Fgrbl-instructions-pdf.370799%2F&usg=AOvVaw12BJ1KW7xTbhR3IqsMW4Ff

Summary: Report Type Value Machine Position 1 Work Position 2 Planner Buffer 4 RX Buffer 8 Limit Pins 16

So I tried 1+2+16 = 19, but still no luck. Also with $10=31 no luck. Because I got the idea of the mask pins I just used $10=255 for activating everything and everything is working again. So I don't know the exact value needed.

Probably somehow $10 lost value, but the other value's are still there. I also noticed that my limit pins also weren't shown in UGS, this was the reason. Anyway, solved.

Edit: Looks like 32 (bit 6) has also a function, needed to get it work, I have now used 49, it is not needed to get the buffer values and stuff like that. Checked it with ? in Putty.