开云体育

ctrl + shift + ? for shortcuts
© 2025 开云体育

Lathe G-code question, issue similar to threading.


 

n the attached pic, there is an oil grove that starts at the end, goes in roughly an inch in 270 degrees and then backs out in 270 degrees. In the pic you can't see the exit, but is 180 degrees from the entrance.

I could write a threading G-code, or use a canned Mach4 threading program to do the inbound groove and then do a second program to do the outbound. But how would one "connect" the grooves together? How does Mach determine at what point in the circumference to start?

Another option would be an inbound G-code followed by an outbound G-code. Then move the tool in the X direction. then do the same in and out G-code. But would the tool start at the same spot like threading?

Thanks for any insight. I guess I need to go experiment.

Dale Grice


 

In general practice the Z axis in a lathe is converted by logic to a c axis(rotary) to perform these tasks. To do that a 0 degree point (master slot) is used to find this point. From there it is a simple process of moving the c axis interpolated degrees for x axis linear movement. Example would be 360 degree rotation for the length of the bush in movement. Second groove would index the c axis to (example) 45 degrees and perform the same function. Etc. it is a fairly easy logic function once the zero point is found to advance the required degrees by working on 1.8 degrees per step of the rotary axis(standard stepper step per move) by the reduction ratio to achieve the degrees required.


 

As I don't have an encoder on my lathe spindle, only a single slot for Mach3 threading, I would consider doing this on my mill using a thread milling type of process and a thread milling type of tool. It would give all the control needed to put the grooves exactly where they are needed and hand writing some code to do it would be quite an easy task. The biggest issue would be the depth the tool had to overhang in a deep bore, you would have to go shallow and do a number of passes. 1" should not be too bad. I don't think the profile of the groove is critical but the cross section of it may be.


 

When ever I have performed this I work out the tool profile the same as you would for a Multi Start thread. Not sure how that would collate to Mill threading.


 
Edited

couldn't you string a couple of G33's together?