Hello Guest it is April 27, 2024, 07:27:43 PM

Author Topic: Save tool table information.  (Read 613 times)

0 Members and 1 Guest are viewing this topic.

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.

Chad Byrd

Offline smurph

*
  • *
  •  1,546 1,546
  • "That there... that's an RV."
    • View Profile
Re: Save tool table information.
« Reply #1 on: June 10, 2021, 04:50:37 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.

Chad,

Yes, that is the API call to use.  It will pull all of the current offsets out of the system variables and write them out to your profile's ToolTable.tls file. 

Steve
Re: Save tool table information.
« Reply #2 on: June 11, 2021, 08:23:41 AM »
Awesome!  I’m gonna get this out into my macro. Thanks Steve!
Chad Byrd