586,096 active members*
3,109 visitors online*
Register for free
Login
Results 1 to 7 of 7
  1. #1
    Join Date
    Jul 2003
    Posts
    92

    Confusion about macros

    I have a macro I've written and I'd like it to run when a file is loaded into Mach3.

    Is that possible?

    If yes, any tips on how to get Mach3 to run the macro when a file is loaded? Like, what would the macro need to be named? And how to instruct Mach3 to run it?

    If that isn't possible, it would be okay to run the macro when the user clicks "Cycle Start." I had this working before but reloaded my PC and now it doesn't work. The file is named M1000.M1S and it is in the proper macros folder but when I click on Cycle Start, it just starts the cycle.

    I think last time I had to "tell" Mach3 to run the Macro on the button click but not sure how that was accomplished.

    Basically I've re-written my LazyCAM Z-Optimizer as a macro and would like to post it on my website for free downloads, but also provide some instructions for installing it. So any help would be appreciated.

  2. #2
    Join Date
    Jul 2003
    Posts
    92

    Re: Confusion about macros

    Any ideas on this?

    Bump.

  3. #3
    Join Date
    Mar 2003
    Posts
    35538

    Re: Confusion about macros

    Add M1000 as the first line of your g-code.
    Gerry

    UCCNC 2017 Screenset
    http://www.thecncwoodworker.com/2017.html

    Mach3 2010 Screenset
    http://www.thecncwoodworker.com/2010.html

    JointCAM - CNC Dovetails & Box Joints
    http://www.g-forcecnc.com/jointcam.html

    (Note: The opinions expressed in this post are my own and are not necessarily those of CNCzone and its management)

  4. #4
    Join Date
    Jul 2003
    Posts
    92

    Re: Confusion about macros

    Thanks for the help.

    I figured out a way to make it sorta work the way I intended.

    Here is the page if anyone is interested:

    J. Phil Thien's LazyCam Z-Optimizer

  5. #5
    Join Date
    Mar 2003
    Posts
    35538

    Re: Confusion about macros

    Yeah, I don't think putting it in the g-code would work.

    I think a better option would be to either use MDI, or create a custom button on the screen to call the macro.
    Gerry

    UCCNC 2017 Screenset
    http://www.thecncwoodworker.com/2017.html

    Mach3 2010 Screenset
    http://www.thecncwoodworker.com/2010.html

    JointCAM - CNC Dovetails & Box Joints
    http://www.g-forcecnc.com/jointcam.html

    (Note: The opinions expressed in this post are my own and are not necessarily those of CNCzone and its management)

  6. #6
    Join Date
    Jul 2003
    Posts
    92

    Re: Confusion about macros

    Thanks Gerry.

    I'm trying to make it as easy as possible for someone even more inexperienced than I to get it working.

    It seems to work fine as-is.

  7. #7
    Join Date
    Mar 2003
    Posts
    35538

    Re: Confusion about macros

    Yes, I realize that. It just may not be desirable to run it every time the reset button is pressed.
    But that is the easiest option.
    Gerry

    UCCNC 2017 Screenset
    http://www.thecncwoodworker.com/2017.html

    Mach3 2010 Screenset
    http://www.thecncwoodworker.com/2010.html

    JointCAM - CNC Dovetails & Box Joints
    http://www.g-forcecnc.com/jointcam.html

    (Note: The opinions expressed in this post are my own and are not necessarily those of CNCzone and its management)

Similar Threads

  1. Cam Confusion!
    By Mr Sprue in forum Uncategorised CAM Discussion
    Replies: 1
    Last Post: 02-22-2014, 06:24 AM
  2. G52 confusion
    By davek in forum G-Code Programing
    Replies: 2
    Last Post: 09-08-2007, 02:01 PM
  3. confusion
    By serry in forum DIY CNC Router Table Machines
    Replies: 4
    Last Post: 04-28-2007, 12:40 AM
  4. Manual.doc vs. .ini confusion
    By medved in forum CNC (Mill / Lathe) Control Software (NC)
    Replies: 2
    Last Post: 04-04-2006, 04:18 PM
  5. Jog Confusion Help Needed
    By Gads in forum Mach Software (ArtSoft software)
    Replies: 1
    Last Post: 03-27-2006, 02:19 PM

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •