Hello Guest it is December 26, 2024, 06:27:56 PM

Author Topic: gcode changing tools lathe  (Read 6907 times)

0 Members and 1 Guest are viewing this topic.

gcode changing tools lathe
« on: October 31, 2012, 01:41:59 PM »
Hi
I'm new in cnc.
I made ​​a drawing with Bobcad I converted to gcode. i put code on Mach3 for lathe.
My problem is when I call t0101 in my code the  tools go to 0 and after my code executes , the tools hit my live center !
do you have idee what i'm doing wrong.
thank you
Alain

Offline Hood

*
  •  25,835 25,835
  • Carnoustie, Scotland
Re: gcode changing tools lathe
« Reply #1 on: October 31, 2012, 02:32:57 PM »
What do you mean by "the tools go to zero"? Are you meaning the axis moves or something else?
Hood
Re: gcode changing tools lathe
« Reply #2 on: October 31, 2012, 02:39:42 PM »
yes the axis move.
when i insert t0101 the axis move to 0 on DRO and hit live center.
thank you

Offline Hood

*
  •  25,835 25,835
  • Carnoustie, Scotland
Re: gcode changing tools lathe
« Reply #3 on: October 31, 2012, 02:46:04 PM »
The axis should not move unless you have something in your M6Start.m1s macro to make it do so or your code is telling it to move..
When you call a tool all that should happen is the DROs change to reflect any offsets for that tool that you have set up in the tool table.
If you call a tool from MDI line does the axis move?
Hood
Re: gcode changing tools lathe
« Reply #4 on: October 31, 2012, 02:54:08 PM »
i restart pc and i put t0101 in mdi and click cycle start and axis move
sorry for my englsh
alain

Offline Hood

*
  •  25,835 25,835
  • Carnoustie, Scotland
Re: gcode changing tools lathe
« Reply #5 on: October 31, 2012, 02:59:36 PM »
Ok if you are meaning the axis physically moves then your m6start macro must have something in it to tell it to do so. Go to the Operator menu then Edit VB Script. A window will pop up and if you choose open you can browse to your lathes macro folder and you will see m6start.m1s, open it and see whats in there and copy and paste it here.
Hood
Re: gcode changing tools lathe
« Reply #6 on: October 31, 2012, 03:13:24 PM »

script
tool = GetSelectedTool()
  SetCurrentTool( tool )



alain

Offline Hood

*
  •  25,835 25,835
  • Carnoustie, Scotland
Re: gcode changing tools lathe
« Reply #7 on: October 31, 2012, 03:17:38 PM »
Ok thats fine, is there anything ing the m6end.m1s?
Hood
Re: gcode changing tools lathe
« Reply #8 on: October 31, 2012, 03:20:10 PM »
scripts
m6end.m1s
rem nothing here in lathe

Offline Hood

*
  •  25,835 25,835
  • Carnoustie, Scotland
Re: gcode changing tools lathe
« Reply #9 on: October 31, 2012, 03:21:48 PM »
Ok something strange is going on, can you attach your xml and I will have a look.
Hood