Machine home zeroing with no motion from G code.
Is there a way to set the machine home position to zero, with no motion, from within a G code program?
Sherline lathe
Gecko drivers
Standard XYZA (Y unused) stepper setup wizard settings.
No HAL tweaking done.
I'm working in G91 mode, and manually writing the G code.
You should see the nice lead-ins and lead-outs on these threads -- perfect! I could bore and thread a hole, and fill it perfectly with a threaded rod. ("perfect" meaning "theoretically/mathematically/geometrically perfect, with so-so execution")
Thanks.
Please Log in or Create an account to join the conversation.
linuxcnc.org/docs/html/gcode_main.html#sub:G92,-G92.1,-G92.2,
Also look at G10
Rick G
Please Log in or Create an account to join the conversation.
Is there a way to set the machine home position to zero, with no motion, from within a G code program?
No, that is not possible.
Are you trying to thread without any position feedback from the spindle?
John
Please Log in or Create an account to join the conversation.
You could set the machine limit very high indeed, that might work. I doubt that any of us will live long enough to see 10^38 spindle revs.I'm using a stepper spindle on my lathe for threading, and it works great, but I have to unwind the spindle back to the home position or the machine limit will eventually be reached. Setting A to zero with G54 does no good because the machine limit is unchanged.
Are you using an encoder and index, or using G-code with coordinated Z,A moves?
Please Log in or Create an account to join the conversation.
Please Log in or Create an account to join the conversation.
Everything is coordinated.
This is a hobby where the process is just as important to me as the product.
If I were vanilla threading I'd use a spindle encoder and canned cycles, but I'm particular about my threads, and I will also be making worms, ornamental turning, and who knows what else. I'm using the spindle more like a fast rotary table.
If the machine limit parameter is astronomical I'll just zero with G54, but my object oriented sensitivities will suffer. I'd like my subs to leave the machine as they found it.
You guys do a lot of work, and I appreciate your attention. Thank you.
--Justin
Please Log in or Create an account to join the conversation.
Whoa, just lost my reply when I hit "submit". It said "Code not correct". I'll have to recompose my reply ...
Yeah, this site is all a bit flaky, but outside our control.
It's a good insurance to select-all / copy your reply before hitting the button.
Please Log in or Create an account to join the conversation.
Please Log in or Create an account to join the conversation.
If the machine limit parameter is astronomical I'll just zero with G54, but my object oriented sensitivities will suffer.
The internal representation of the pulse counter is a long long, or signed-64.
At 200 steps per rev, and 8x microstepping it will wrap at 5.7 quadrillion revolutions (5764607523034234 to be exact)
You will find that your floating point representation of position gets a bit granular rather sooner, though. That is a double, so has 16 decimal digits of precision, meaning you will not be able to read the angle to less than 0.01 degrees after only about 30 billion revs.
I have looked at the code, and there is no way to zero the stepgen accumulator (which is what you would need to do) . Also, zeroing the accumulator would probably lose steps.
Please Log in or Create an account to join the conversation.
Thanks for your time and expertise. I really appreciate it.
Please Log in or Create an account to join the conversation.