Jump to content

Recommended Posts

Posted · use cura from windows cmd

Hi im George this is my first post here. I use cura with all my printers and now i have a msc thesis assignment and i want to control cura through windows terminal. I can open a stl file, i used cura -s and sliced it. Finally i want to use cura -r in order to open the print interface and print the object. The problem is that i get

AttributeError module object has no attibute startPrintInterface

and it gives me errors in some lines in the cura.py and runpy.py files. Do you know how i can make it works?

Thanks!

 

  • Link to post
    Share on other sites

    Posted · use cura from windows cmd

    Ok. I can send the command from windows cmd to slice the file. I have done it and create a gcode file. And then send the command to open cura the gcode file. This is almost there i believe is good enough. It would be nicer if i could get the print info (estimated time, weight of object and cost) do they stored somewher? I cant find them in gcode file.somewhere else maybe where i can have access? I want to find them and send them through a web service.

  • Link to post
    Share on other sites

    Posted · use cura from windows cmd

    Hi,

    How to generate gcode file from STL file using CMD prompt in Windows.

    Installed with CuraEngine-14.05.3. Want to convert STL file to gcode file and print from CMD prompt.

    Please tell me the exact command.

    Thanks,

    Debaknta

  • Link to post
    Share on other sites

    Posted · use cura from windows cmd

    Hi,

    While running CuraEngine -s "C:\path\to\STL File\" I'm getting the below output:-

    This program is free software: you can redistribute it and/or modify

    it under the terms of the GNU Affero General Public License as published by

    the Free Software Foundation, either version 3 of the License, or

    (at your option) any later version.

    This program is distributed in the hope that it will be useful,

    but WITHOUT ANY WARRANTY; without even the implied warranty of

    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the

    GNU Affero General Public License for more details.

    You should have received a copy of the GNU Affero General Public License

    along with this program. If not, see .

    Default config 'default.cfg' not used

    M107

    G1 F2700 E-4.50000

    G0 F9000 X0.00 Y0.00 Z5.00

    M104 S0 ;extruder heater off

    M140 S0 ;heated bed heater off (if you have it)

    G91 ;relative positioning

    G1 E-1 F300 ;retract the filament a bit before lifting the

    nozzle, to release some of the pressure

    G1 Z+0.5 E-5 X-20 Y-20 F9000 ;move Z up a bit and retract filament even more

    G28 X0 Y0 ;move X/Y to min endstops, so the head is out of

    the way

    M84 ;steppers off

    G90 ;absolute positioning

    Please let me know how can I get a correct gcode file

    Thanks & Regards,

    Debakanta

  • Link to post
    Share on other sites

    Posted · use cura from windows cmd

    Hi geosfi,

    Can you please let us know what exact command you have given to produce a gcode file from CMD prompt.

    I don't have .ini file. I just use to give CuraEngine -s "C:\path\to\STL File\"

    Though it is producing .gcode file the contents are not the expected stuffs.

    I get the out put as below:

    This program is free software: you can redistribute it and/or modify

    it under the terms of the GNU Affero General Public License as published by

    the Free Software Foundation, either version 3 of the License, or

    (at your option) any later version.

    This program is distributed in the hope that it will be useful,

    but WITHOUT ANY WARRANTY; without even the implied warranty of

    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the

    GNU Affero General Public License for more details.

    You should have received a copy of the GNU Affero General Public License

    along with this program. If not, see .

    Default config 'default.cfg' not used

    M107

    G1 F2700 E-4.50000

    G0 F9000 X0.00 Y0.00 Z5.00

    M104 S0 ;extruder heater off

    M140 S0 ;heated bed heater off (if you have it)

    G91 ;relative positioning

    G1 E-1 F300 ;retract the filament a bit before lifting the

    nozzle, to release some of the pressure

    G1 Z+0.5 E-5 X-20 Y-20 F9000 ;move Z up a bit and retract filament even more

    G28 X0 Y0 ;move X/Y to min endstops, so the head is out of

    the way

    M84 ;steppers off

    G90 ;absolute positioning

    Please let me know how can I get a correct gcode file.

    Thanks & Regards,

    Debakanta

  • Link to post
    Share on other sites

    Posted · use cura from windows cmd

    For Cura 15.04.4 (and probably 14.x.x.), Enter: CuraEngine.exe -help

    For Cura 2.1.2, Enter: CuraEngine.exe help

    Those will show you the command line parameters for both versions of the CuraEngine.exe program.

  • Link to post
    Share on other sites

    Posted · use cura from windows cmd

    Hi,

    Tried passing all kind of arguments with all possible ways but every time gcode is produced with unexpected contents. They seems to be of around 15 lines of info without gcode complete contents.

    Without -o C:\Path\to\fileName.gcode option the output is coming as below:

    While running the CuraEngine -s "C:\Path\to\file.stl" I'm getting the output as below:

    This program is free software: you can redistribute it and/or modify

    it under the terms of the GNU Affero General Public License as published by

    the Free Software Foundation, either version 3 of the License, or

    (at your option) any later version.

    This program is distributed in the hope that it will be useful,

    but WITHOUT ANY WARRANTY; without even the implied warranty of

    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the

    GNU Affero General Public License for more details.

    You should have received a copy of the GNU Affero General Public License

    along with this program. If not, see .

    Default config 'default.cfg' not used

    M107

    G1 F2700 E-4.50000

    G0 F9000 X0.00 Y0.00 Z5.00

    M104 S0 ;extruder heater off

    M140 S0 ;heated bed heater off (if you have it)

    G91 ;relative positioning

    G1 E-1 F300 ;retract the filament a bit before lifting the

    nozzle, to release some of the pressure

    G1 Z+0.5 E-5 X-20 Y-20 F9000 ;move Z up a bit and retract filament even more

    G28 X0 Y0 ;move X/Y to min endstops, so the head is out of

    the way

    M84 ;steppers off

    G90 ;absolute positioning

    Kindly let us know the exact command.

    I do not have .ini file.

    Please let me know how can I get a correct gcode file

    Thanks & Regards,

    Debakanta

  • Link to post
    Share on other sites

    Posted · use cura from windows cmd

    I don't know why you're doing: CuraEngine -s "C:\Path\to\file.stl"

    That's not what the -s switch does.

    Following the CuraEngine usage help works fine for me.

  • Link to post
    Share on other sites

    Posted · use cura from windows cmd

    Hi,

    It is generating the .gcode file but contents are not expected.

    We get the below error message:

    -------------------------------------------------------------------------------------

    Default config 'default.cfg' not used

    Config(part1.ini): Line 1: No key value pair found

    Failed to read config 'part1.ini'

    Failed to open part1.gcode for output.

    --------------------------------------------------------------------------------------

    It is generating well from UI.

    Do we need any licence or rights to run it from command prompt?

    We do not get .ini file any where.

    If no licence is required then can you please share the exact command using which we can generate a .gcode file

    Please guide me what ideally I should be doing.

    Thanks & Regards,

    Debakanta

  • Link to post
    Share on other sites

    Posted · use cura from windows cmd

    Well, I don't know what command line you are using that results in your 'Config(part1.ini): Line 1:No key value pair found" error. I don't know what part1.ini file is from your set up.

    I also didn't know how to do any of this until just over a few hours ago when I saw your post and decided to see if I could figure it out for myself. So I'm no expert. But I did get it working to a degree.

    In addition, I'm using Cura 15.04.4 which is newer than yours and so yours may contain bugs that are hampering your progress.

    All that said, from following the -'help' switch output from CuraEngine, the most basic slicing command for .stl in and .gcode out would be:

     

    CuraEngine.exe -o c:\path\to\output.gcode c:\path\to\input.stl

     

    If you wish to supply an .ini file for your printer's setting, you need to: File / Save Profile in the Cura GUI and then use that .ini file on the command line in Cura:

     

    CuraEngine.exe -c c:\path\to\profile.ini -o c:\path\to\output.gcode c:\path\to\input.stl

     

    However, I have been unable to get the CuraEngine to read the .ini file. It always returns this error:

    Line zd: No key value pair found

    Not sure if your older version of Cura will work on reading the .ini or not.

  • Link to post
    Share on other sites

    Posted · use cura from windows cmd

    For Cura 15.04.4 (and probably 14.x.x.), Enter: CuraEngine.exe -help

    For Cura 2.1.2, Enter: CuraEngine.exe help

    Getting below message:

    Default config 'default.cfg' not used

    Thanks,

    Debakanta

  • Link to post
    Share on other sites

    Posted · use cura from windows cmd

    Hi,

    I'm able to generate .gcode file using below command

    CuraEngine -c "C:\path\to\preferences.ini" -o "C:\path\to\test1.gcode" "C:\path\to\\snowManAll.stl"

    It is failing to load if I pass .obj or .amf file instead of .stl files

    Need your guidance in this concern.

    Thanks & Regards,

    Debakanta

  • Link to post
    Share on other sites

    Posted (edited) · use cura from windows cmd

    Hi George,

    Try below command from CMD prompt

    CuraEngine -c "C:\path\to\preferences.ini" -o "C:\path\to\test1.gcode" "C:\path\to\\snowManAll.stl"

    Thanks,

    Debakanta

    Edited by Guest
  • Link to post
    Share on other sites

    Posted · use cura from windows cmd

    Hi,

    Can you please suggest me how to give print command option to a gcode file.

    Thanks,

    Debakanta

  • Link to post
    Share on other sites

    Create an account or sign in to comment

    You need to be a member in order to leave a comment

    Create an account

    Sign up for a new account in our community. It's easy!

    Register a new account

    Sign in

    Already have an account? Sign in here.

    Sign In Now
    • Our picks

      • UltiMaker Cura 5.9 stable released!
        Here comes Cura 5.9 and in this stable release we have lots of material and printer profiles for UltiMaker printers, including the newly released Sketch Sprint. Additionally, scarf seams have been introduced alongside even more print settings and improvements.  Check out the rest of this article to find out the details on all of that and more
          • Like
        • 5 replies
      • Introducing the UltiMaker Factor 4
        We are happy to announce the next evolution in the UltiMaker 3D printer lineup: the UltiMaker Factor 4 industrial-grade 3D printer, designed to take manufacturing to new levels of efficiency and reliability. Factor 4 is an end-to-end 3D printing solution for light industrial applications
          • Heart
          • Thanks
          • Like
        • 4 replies
    ×
    ×
    • Create New...