Hello Guest it is March 28, 2024, 06:08:21 AM

Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.


Messages - Cbyrdtopper

141
Mach4 General Discussion / Re: Tool Length Offset Macro Program
« on: June 15, 2021, 06:59:29 PM »
Kenny,
mach4 emulates a fanuc 24i if I recall correctly.
So I just looked up fanuc macro variables and found some.
I also did a lot of playing around with ranges in the register and found the numbers pop up for the tool length offset haha.

142
Mach4 General Discussion / Re: Tool Length Offset Macro Program
« on: June 15, 2021, 06:38:48 PM »
It should save the tool length in the tool table. It does for me anyway.
I can watch it change when I probe a tool. Also, it picks up the diameter for me as well.
Not sure if it is a version thing or not. I’m not at the shop so I can’t check the machines to see what version. But I know one is on build 4300.

143
Mach4 General Discussion / Re: Save tool table information.
« on: June 11, 2021, 08:23:41 AM »
Awesome!  I’m gonna get this out into my macro. Thanks Steve!

144
Mach4 General Discussion / Save tool table information.
« on: June 07, 2021, 12:10:40 PM »
So, I've got a mill that had some issues about freezing and closing Mach4 more often than I liked.  We got a new computer on it and that pretty much took care of the issues.
My biggest hassle when this happened was the tool table not saving when Mach4 closed unexpectedly.  I would have to re probe all of my tools again.
I was looking for a way to save my tool table information continuously in the PLC script ever so often and then automatically load in that information on startup.

I found this API call...mcToolSaveFile

If I ran this every time I set a tool offset, would this save my information and then load the new file on startup?

I don't get into LUA much anymore.  I have almost everything already written and I just transfer it all to new machines when we get them ready.


145
Mach4 General Discussion / Re: Problems with A-Axis
« on: June 04, 2021, 01:02:00 PM »
Just to throw this out there....
Is this a Mach4 Issue or a Motion Controller issue?
Rollover would be for continuous motion on the axis, but would it actually affect the planner and the trajectory of the next move. 
This really may be something that would need to be taken care of through the motion controller.

146
Mach4 General Discussion / Re: Tool Length Offset Macro Program
« on: May 24, 2021, 11:52:25 AM »
Put this line in your M6.  rc = mc.mcCntlGcodeExecuteWait(inst, "M98 P9001")

This works stepping through the zero brane editor and from G Code; but for some reason it doesn't work when you call it from MDI.
So....When you call an M6 from MDI.... just be sure it acts like it is supposed to.   Otherwise just make a program and call toolchanges.

Maybe Steve can give insight as to why it isn't working in MDI.

147
Mach4 General Discussion / Re: CONVERT HYDRULIC GRINDER
« on: May 21, 2021, 01:03:49 PM »
That's kind of what I was getting at. 
You should be able to do that with X+, X-, Y+, and Y-. 
Jog the machine to each position and then add a button that will store that position into the corresponding DRO.
You can also add DROs to be able to set your Y increment per pass, X feedrate and Y Feedrate and make it do exactly what you want. 

You can do this in a macro and a button press, it will work but I'm sure it isn't the best way to do it. 
You can't exactly stop the execution of a Macro without having some funny things happen.  You may have to use co routines to do it "Correctly".

Someone smarter than me should be able to answer that for you.   

I'm testing some stuff just in a macro with a button to execute it.  It is working ok; but when you try and stop the execution entirely, it does weird stuff.  So, as long as you just let it finish, you should be good lol.  Again, not the best way to do it I'm sure; but it works.

MacroB is very awesome if you're willing to get the industrial version.  But, it sounds like you want the easiest way to get this going and that's just fine.

148
Mach4 General Discussion / Re: CONVERT HYDRULIC GRINDER
« on: May 21, 2021, 12:05:30 PM »
I'm sure what you want to do can be done using LUA (Mach4's Scripting Language).   I get my tool changes working in LUA and have my control panel script already finished; so I don't mess with LUA a great deal anymore. 

If I need to do something like you're asking, I would just get the industrial version of Mach4 and use MacroB.  Much easier to program and it's G Code. 

That being said, is there any particular reason you still want to use switches to set the machine travel limits? 
It's going to be CNC after you add motors and ball screws to it; let the machine do the work. 
Instead of moving switches, make a custom screen (Sounds scary but it really isn't bad).  Add DROs to the screen for your X Left, X Right, Y Start, Y Finish, and your feedrates for each Axis; then use those values to traverse until finished then wait for the operator to manually move the Z and start again. 

149
Can you be more specific? 
What about your 3D Programs won't run?  The program should stop at a point and let you know what it doesn't like.
Same for the Canned Cycle.  Check out the Programming Manual and be sure your canned cycle is all correct.
Mach3 cared a lot less about what you had in a canned cycle line. Mach4 adheres to standards much more than Mach3 ever did, it is much more concerned about having proper syntax on your canned cycle lines.

150
That'll do it!  HAHA  Why didn't I think of that!?!? Thanks Jbuehn!