My Mill or Their Code?

More
4 years 2 months ago #250182 by Bumbino
Replied by Bumbino on topic My Mill or Their Code?
I either found that grbl answer on autodesk forum or here on this forum.

I built my machine. nema 23's and a chinese special TB6560 controller. Everything is great. It's super tight and does exactly what i want (most times). Just these G28 and G53 commands....

So I have the G28 ironed out, but no matter what I do the G53 still thinks Z0 is down inside of my work table.

I have gone back into the setupwizard and modified my config instead of an axis from 0 to 500mm with switch at 502mm and home at 480mm. I change to -250 to 250, switch at 252 and home 230. I changed all three axis in this way. Restarted linuxcnc and loaded an ngc file... no change. I can see on screen the first move is to drive down into the table.

Using the gcode docs i've managed to figure out programming the G28, but I simply can not figure out the G53 and what's going on here.

Please Log in or Create an account to join the conversation.

More
4 years 2 months ago - 4 years 2 months ago #250186 by JPL
Replied by JPL on topic My Mill or Their Code?
It does not need to work with both G28 and G53. If you found a working solution with G28 (and G28.1) then you should be good to go. You only have to instruct Fusion 360 post processor to use G28 and not G53.

This should be available on the 'post process' setup screen in fusion 360. Find the lines that says 'Safe retract' and select G28 from the drop down box. Fusion 360 will then generate g-code with G28 instead of G53.



 
Last edit: 4 years 2 months ago by JPL.
The following user(s) said Thank You: Bumbino

Please Log in or Create an account to join the conversation.

More
4 years 2 months ago - 4 years 2 months ago #250268 by Todd Zuercher
How do you have the Z0 home position (or Z origin) configured?

If you have the machine configured such that the machine coordinate system's Z0 position is at the bottom of travel. What you are seeing happen would be the expected behavior.

It is the general convention that the machine's Z origin point (Z0) will be at the top of the Z travel, and that this is where the machine homes to.

If for example your machine has 12" of Z travel. You home the machine at the top of that travel, that point will be called Z0. All movement in the machine coordinate system (G53) will be negative.
You then use G54 (or an other work coordinate system) to set Z0 at your work surface, you will then have positive travel above that and that is the number that will be displayed on the DRO. If configured this way commanding a G53Z0 or G91G28Z0 will move the Z axis to the top of travel.

However if you configured the machine coordinate Z origin for any other position (such as the bottom of travel) then those commands will move the Z axis to that position. If you wanted a command to move to the top of the machine's 12" travel you would need to command G53Z12 in this case.

G91G28Z0 is a common Fanuc command. Not every Fanuc control has a G53 command option, but they all do G28. With Fanuc a G28 command will move the machine to the machine origin via an intermediary point (that point defined by the axis commands after the G28). Issuing a G91 before the G28 and a Z0 after, will move the machine zero distance to the intermediary point then to the Z origin (so no intermediary point.) If the G91 were left out and the machine is in G90 mode, the machine would rapid move to the current work coordinate Z0 point then rapid to the Z origin point. Doing that will have disastrous consequences on most machines in many situations.
(Don't ask me why, it's a weird Fanuc quirk that I've never understood either, but everyone has to work with it and why it's seen a lot and why I think it showed up in your post processor.)
Last edit: 4 years 2 months ago by Todd Zuercher.
The following user(s) said Thank You: arvidb, tommylight

Please Log in or Create an account to join the conversation.

More
4 years 2 months ago #250456 by Birdman3131
Replied by Birdman3131 on topic My Mill or Their Code?
Not sure how applicable to LinuxCNC this is but it is worth a watch I think.

Please Log in or Create an account to join the conversation.

More
4 years 2 months ago #250486 by Bumbino
Replied by Bumbino on topic My Mill or Their Code?
OK Guys! First of all - thank you all very much for taking the time.

I have found some happiness with the post process. I'm still using grbl, but did find that I have a choice over G28, G53, or the real gem... "Clearance Height". lol. Amazing!

Next. My G53 was working fine. After reading the docs just about everywhere i could find mention of G53 I was 100% sure that the home position would be the position i tell the machine to move to after homing. Which in my case is very close to the switches. But a G53 G0 X0 Y0 Z0 would move the spindle very far away from these points. It wasn't until I was typing up a question for you all a few days ago that I realized it's doing exactly what it's supposed to do. It is moving to x0 y0 and z0. So in the set up I have on x for example -250mm to 250mm and my switch is at 252mm. So to change my x0 physical position I would change my setup to maybe... -400 to 100.

There's just so much reading to do. I finished the build on this machine about a year ago. Honestly if i had know how complex cad, cam and cnc operation would be i likely never would have built the machine. I'm glad that I didn't know because this is really bad ass. I'm loving it and having a lot of fun. A bit frustrating at times, but there again.... thank you all for the help.

Best,
John
The following user(s) said Thank You: tommylight

Please Log in or Create an account to join the conversation.

More
4 years 2 months ago #250497 by tommylight
Replied by tommylight on topic My Mill or Their Code?

Honestly if i had know how complex cad, cam and cnc operation would be i likely never would have built the machine. I'm glad that I didn't know because this is really bad ass. I'm loving it and having a lot of fun. A bit frustrating at times, but there again.... thank you all for the help.

Best,
John
Welcome to the club! :)

Please Log in or Create an account to join the conversation.

Time to create page: 0.339 seconds
Powered by Kunena Forum