Hello Guest it is March 28, 2024, 10:19:33 PM

Author Topic: M6 start macro for lathe  (Read 1110 times)

0 Members and 1 Guest are viewing this topic.

M6 start macro for lathe
« on: October 20, 2021, 10:41:25 AM »
Hi Everyone..

The issue i have is when i call up the tool lets say t0101m6 the machine moves and hits the limit switch which then gives me the limit switched has been triggered issue.. when i home my machine it homes fine. i have attached my m6 start macro but what is it i need to change in order to stop this, can i add a g28 or g53 somewhere to make sure it doesn't triggered the limit switch when i does a tool change

thanks in advance

Online Graham Waterworth

*
  • *
  •  2,668 2,668
  • Yorkshire Dales, England
    • View Profile
Re: M6 start macro for lathe
« Reply #1 on: October 21, 2021, 08:47:02 PM »
I would try putting a Sleep(50) in all your While IsMoving() loops :-

While IsMoving()
  Sleep(50)
Wend

This will give Mach3 time to update in the background.
Without engineers the world stops
Re: M6 start macro for lathe
« Reply #2 on: October 24, 2021, 05:02:13 PM »
I would try putting a Sleep(50) in all your While IsMoving() loops :-

While IsMoving()
  Sleep(50)
Wend

This will give Mach3 time to update in the background.


Hi,

Thanks for the reply gave this a go but made no difference.. need to incorporate the g28 into It somewhere just not sure where it needs to go.

Thanks

Online Graham Waterworth

*
  • *
  •  2,668 2,668
  • Yorkshire Dales, England
    • View Profile
Re: M6 start macro for lathe
« Reply #3 on: October 25, 2021, 05:33:55 PM »
Here is a Macro I did some time back for pawl lock turrets.  Have a look and see if it works for you.

You can edit the values to what you need and it has a move safe built in.

It works fine on Boxford 125/160 turrets once the steps per are set and sensible feed speeds.

Note the safe move is normally minus values as they are from the home position, home being X0, Z0 so normally they would be set to X-5. Z-10.

Its all commented in the code so all you need to do is rename the file to M6Start.m1s and check it out.

Without engineers the world stops
Re: M6 start macro for lathe
« Reply #4 on: August 22, 2022, 03:20:46 AM »
very good post