Hello Guest it is February 27, 2021, 02:30:59 AM

Author Topic: How to launch Mach3 and open automatically a file  (Read 9950 times)

0 Members and 1 Guest are viewing this topic.

How to launch Mach3 and open automatically a file
« on: January 30, 2009, 02:20:30 PM »
I am searching for a Windows command line option to launch Mach3 and open and load automatically a g-code file.

I have a CAM program tha can save automatically the g-code file in the folder :

c:\mach3\gcode.iso

and then launch Mach3 with a line :

c:\mach3\mach3.exe /p smoothstepper

I am searching an option like the /p for the profile to open automatically in Mach 3 the file, something like :

c:\mach3\mach3.exe /p smoothstepper /o gcode.iso

I have search the documentation with no success someone know a trick to do this ?

Thanks in advance, ciao from Italy  8)

Mauro


Offline ger21

*
  • *
  •  6,289 6,289
    • View Profile
    • The CNC Woodworker
Re: How to launch Mach3 and open automatically a file
« Reply #1 on: January 30, 2009, 07:22:39 PM »
You can put a macro in the initialization string, and in the macro, load the file.
Gerry

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

JointCAM Dovetail and Box Joint software
http://www.g-forcecnc.com/jointcam.html
Re: How to launch Mach3 and open automatically a file
« Reply #2 on: January 30, 2009, 08:31:13 PM »
HI Gerry,
  I could use this also...would you mind to elaborate ? ?  Give an example ?
Thanks much,
RC

Offline ger21

*
  • *
  •  6,289 6,289
    • View Profile
    • The CNC Woodworker
Re: How to launch Mach3 and open automatically a file
« Reply #3 on: January 30, 2009, 09:46:08 PM »
In Notepad, type the path to the g-code file, like this:

Loadfile("C:\CNC-parts-Files\Button1.TAP")

and save as a macro file, like M777.m1s

In General Config, put M777 in the initialization string.

When mach3 starts, and you click reset, the file will load.

Thanks to Scott for the Loadfile info I saved a while back. :)
Gerry

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

JointCAM Dovetail and Box Joint software
http://www.g-forcecnc.com/jointcam.html
Re: How to launch Mach3 and open automatically a file
« Reply #4 on: January 30, 2009, 10:01:37 PM »
GREAT ! ! !
Thanks Ger,
RC
Re: How to launch Mach3 and open automatically a file
« Reply #5 on: February 02, 2009, 07:42:46 AM »
Thanks a lot !
;-)
Mauro