开云体育

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

Mach4 Lathe - Turn Cycles


 

开云体育

Hi Brian,

?

I just found this quite old mail about a new LUA roughing routine for Mach4 Lathe…

Did there arise any news on this? - I would love to give it a try.


best regards, Konrad

?

Von: [email protected] <[email protected]> Im Auftrag von Brian Barker
Gesendet: Freitag, 11. September 2020 18:36
An: [email protected]
Betreff: Re: [MachCNC] Mach4 Lathe-G76 and Turn Cycles

?

I think we can now send attachments ... I did a new roughing bit of code for turn in LUA! I just got it to work on my test profile. This is going to be as good as Cam software.

______________________________
?
Brian Barker
?
Webpage: 

On 9/10/2020 4:43 PM, Andy Wander wrote:

Hey, man, any word?

?

From: [email protected] <[email protected]> On Behalf Of Brian Barker
Sent: Wednesday, September 2, 2020 7:29 AM
To: [email protected]
Subject: Re: [MachCNC] Mach4 Lathe-G76 and Turn Cycles

?

Good question! Let me talk to the guys. This slipped my mind. I am getting old or something :)

______________________________

?

?


 

开云体育

Funny I was playing with that code 2 days ago for fun... My goal is go get back on it as soon as I finish the engraving software update we are doing. I try to do little pet projects like this for some fun night time programming :)


I can give you the code as it is but it needs an interface to feed in the "profile"


______________________________

Brian Barker

Webpage: 
On 12/3/2021 7:19 AM, Konrad Krüger wrote:

Hi Brian,

?

I just found this quite old mail about a new LUA roughing routine for Mach4 Lathe…

Did there arise any news on this? - I would love to give it a try.


best regards, Konrad

?

Von: [email protected] <[email protected]> Im Auftrag von Brian Barker
Gesendet: Freitag, 11. September 2020 18:36
An: [email protected]
Betreff: Re: [MachCNC] Mach4 Lathe-G76 and Turn Cycles

?

I think we can now send attachments ... I did a new roughing bit of code for turn in LUA! I just got it to work on my test profile. This is going to be as good as Cam software.

______________________________
?
Brian Barker
?
Webpage: 

On 9/10/2020 4:43 PM, Andy Wander wrote:

Hey, man, any word?

?

From: [email protected] <[email protected]> On Behalf Of Brian Barker
Sent: Wednesday, September 2, 2020 7:29 AM
To: [email protected]
Subject: Re: [MachCNC] Mach4 Lathe-G76 and Turn Cycles

?

Good question! Let me talk to the guys. This slipped my mind. I am getting old or something :)

______________________________

?

?


 

开云体育

Hi Brian,

it’s great news that the idea and the code is still alive.

Although I fear programming the interface will be beyond my abilities, I would love to have a look on it just for couriosity.


Have a nice day,
Konrad

Von: [email protected] <[email protected]> Im Auftrag von Brian Barker
Gesendet: Freitag, 3. Dezember 2021 14:23
An: [email protected]
Betreff: Re: [MachCNC] Mach4 Lathe - Turn Cycles

?

Funny I was playing with that code 2 days ago for fun... My goal is go get back on it as soon as I finish the engraving software update we are doing. I try to do little pet projects like this for some fun night time programming :)

?

I can give you the code as it is but it needs an interface to feed in the "profile"

?

______________________________
?
Brian Barker
?
Webpage: 

On 12/3/2021 7:19 AM, Konrad Krüger wrote:

Hi Brian,

?

I just found this quite old mail about a new LUA roughing routine for Mach4 Lathe…

Did there arise any news on this? - I would love to give it a try.


best regards, Konrad

?

Von: [email protected] <[email protected]> Im Auftrag von Brian Barker
Gesendet: Freitag, 11. September 2020 18:36
An: [email protected]
Betreff: Re: [MachCNC] Mach4 Lathe-G76 and Turn Cycles

?

I think we can now send attachments ... I did a new roughing bit of code for turn in LUA! I just got it to work on my test profile. This is going to be as good as Cam software.

______________________________
?
Brian Barker
?
Webpage: 

On 9/10/2020 4:43 PM, Andy Wander wrote:

Hey, man, any word?

?

From: [email protected] <[email protected]> On Behalf Of Brian Barker
Sent: Wednesday, September 2, 2020 7:29 AM
To: [email protected]
Subject: Re: [MachCNC] Mach4 Lathe-G76 and Turn Cycles

?

Good question! Let me talk to the guys. This slipped my mind. I am getting old or something :)

______________________________

?

?


 

开云体育

Hi Konrad,

My current plan is to get this working after a few other projects I am working on. I want to make something like the Mach Motion cycles but with a much better "part" designer. I want this for my machine so everyone else will get it too. The interface is not to bad, here is how you feed moves to the profile:


local profile = {};
?? ?local startp = {};
?? ?local endp = {};
?? ?local movenum = 1
?? ?startp.x = .1
?? ?startp.z = 0.0
?? ?endp.x = .5
?? ?endp.z = -.4
?? ?profile[movenum] = ProArcCreate(startp, endp, .4, "CW")
?? ?movenum = movenum +1
?? ?startp.x = endp.x
?? ?startp.z = endp.z
?? ?endp.x = .5
?? ?endp.z = -1
?? ?profile[movenum] = ProLineCreate(startp, endp)


That code makes an Arc than it makes a line.. My test had many more entities. Then when that is finished you can fillet the corners with commands like this :

??? profile = ProFilletCorner(profile,7,.5)
?? ?profile = ProFilletCorner(profile,6,.25)

The 6 and 7 are the entities that it would like to fillet the end of in the profile


Then you have to run some magic like this:

roughGcode = roughGcode .. ProfileRoughX(profile, .05, .01, -.12)--rough

That tells it to rough the profile with .05 left in the X, .01 in the Z and doing passes of .12 DOC.

For a finish pass


??? roughGcode = roughGcode .. "(Finish Pass)\n".. ProfileFinish(profile,.030, .003)--semi finish, this will be taken out at some point

That is all you need to do to make it work at this point but I really want to have some way to pump the settings in graphically on the screen. I made this for a customer that had to make the same-ish parts. I wanted to make a more generic? solution and in the end figured out that I made a full roughing cycle for turn.


I hope that gives you a little light into what it is and how it works for an interface. It is a bit raw :( but I think with a little work we can make this into something that is a ton of fun to use on the machines!

______________________________

Brian Barker

Webpage: 
On 12/7/2021 4:29 AM, Konrad Krüger wrote:

Hi Brian,

it’s great news that the idea and the code is still alive.

Although I fear programming the interface will be beyond my abilities, I would love to have a look on it just for couriosity.


Have a nice day,
Konrad

Von: [email protected] <[email protected]> Im Auftrag von Brian Barker
Gesendet: Freitag, 3. Dezember 2021 14:23
An: [email protected]
Betreff: Re: [MachCNC] Mach4 Lathe - Turn Cycles

?

Funny I was playing with that code 2 days ago for fun... My goal is go get back on it as soon as I finish the engraving software update we are doing. I try to do little pet projects like this for some fun night time programming :)

?

I can give you the code as it is but it needs an interface to feed in the "profile"

?

______________________________
?
Brian Barker
?
Webpage: 

On 12/3/2021 7:19 AM, Konrad Krüger wrote:

Hi Brian,

?

I just found this quite old mail about a new LUA roughing routine for Mach4 Lathe…

Did there arise any news on this? - I would love to give it a try.


best regards, Konrad

?

Von: [email protected] <[email protected]> Im Auftrag von Brian Barker
Gesendet: Freitag, 11. September 2020 18:36
An: [email protected]
Betreff: Re: [MachCNC] Mach4 Lathe-G76 and Turn Cycles

?

I think we can now send attachments ... I did a new roughing bit of code for turn in LUA! I just got it to work on my test profile. This is going to be as good as Cam software.

______________________________
?
Brian Barker
?
Webpage: 

On 9/10/2020 4:43 PM, Andy Wander wrote:

Hey, man, any word?

?

From: [email protected] <[email protected]> On Behalf Of Brian Barker
Sent: Wednesday, September 2, 2020 7:29 AM
To: [email protected]
Subject: Re: [MachCNC] Mach4 Lathe-G76 and Turn Cycles

?

Good question! Let me talk to the guys. This slipped my mind. I am getting old or something :)

______________________________

?

?