Load Gcode using command line

If you have a question about the software please ask it here.

Load Gcode using command line

Postby RsX » Tue Oct 29, 2024 4:54 pm

Is there a way to make UCCNC load a file using a command line?
for example
Code: Select all
C:\Program Files\UCCNC\UCCNC.exe c:\myGcode.nc
User avatar
RsX
 
Posts: 31
Joined: Fri Oct 25, 2024 9:22 pm

Re: Load Gcode using command line

Postby cncdrive » Wed Oct 30, 2024 3:40 am

No, that's not possible, but you could load a file from a macro or from a plugin.
cncdrive
Site Admin
 
Posts: 4887
Joined: Tue Aug 12, 2014 11:17 pm

Re: Load Gcode using command line

Postby RsX » Wed Oct 30, 2024 11:00 am

Thanks for the reply
I followed your advise and ended up with this
macroloop.png

Code: Select all
string AutoloadFile = Environment.GetEnvironmentVariable("TEMP") + @"\UCCNC\Autoload.gcode";
//MessageBox.Show(AutoloadFile);
if(exec.CycleStopped && System.IO.File.Exists(AutoloadFile)){
   exec.Loadfile(AutoloadFile);
   while(exec.IsLoading()){}
   System.IO.File.Delete(AutoloadFile);
}
User avatar
RsX
 
Posts: 31
Joined: Fri Oct 25, 2024 9:22 pm


Return to Ask a question from support here

Who is online

Users browsing this forum: No registered users and 34 guests