Inkscape.org
Using Inkscape with Cutters/Plotters Error producing GCode output
  1. #1
    AnOther AnOther @AnOther

    I am a new user of Inkscape, so no expert - using Inkscape 1.1 on Linux Mint 20.2, installed using the /Stable PPA.

    I set up a test file to produce a GCode output to test a CNC router - just a simple shape, the letter A.  I followed various online instructions for this - set document properties, created a shape, Object to Path, selected the Tool from the Gcode Extension Menu. Finally I selected 'Path to Gcode', gave the file a name  - and get an error message "Can not write to specified file!". This happens every time I try, and also on three machines, all running some variation of LInux Mint. I have spent hours searching for possible help with no success (actually no help appears to exist to produce Gcode or diagnose errors that I can find). Can someone suggest what I doing wrong please?

  2. #2
    Joe Moran Joe Moran @joem7504

    I havent had any luck with gcodetools extension. I downloaded J tech laser extension for inkscape and installed per their direction. One installed and reopen inkscape it will appear in extensions as Generate Laser Gcode. 

    Draw a box, select it , Path,object to path, Generate Laser Gcode extension, J tech, fill in the settings and use Z positions instead of the laser on and off

    send gcode to your machine. 

    Not the best solution but should get you started.  Another option is Gcodeplotter extension 

  3. #3
    AnOther AnOther @AnOther

    Thanks Joe - I'll give it a try. I'm surprised there isn't morre on the Web about this, because everywhere you look on the subject of 3D printing or CNC work, Inkscape gets a mention as being able to produce GCode - but it seems it doesn't - maybe the moderators of this forum can escalate this and get it sorted.

  4. #4
    Maren Hachmann Maren Hachmann @Moini

    The extension works for me, but depending on your operating system and specific setup, bugs may crop up. I would recommend you search the bug reports at https://inkscape.org/report , and perhaps open one if you cannot find what you're looking for.

  5. #5
    AnOther AnOther @AnOther

    Hallo, Maren,

    I have already searched through the bug reports, with no luck. I was unable to find anything related to my problem, so perhaps the way to go is a bug report. I am at a bit of dead end now - I have done things like remove and re-install Inkscape, with no luck. I do appreciate that my particular machine configuration(s) may be causing the problem. One machine is a relatively new Vivobook, which I bought to run my 'machine' software on - like my CNC machine. It is a basic Linux MInt installation (which I have used for many years), and almost all the normally installed applications have been removed, because on this machine I have no need of them. (but the problem is present on 2 other 'fully-eqipped' machines). As I have been learning what to do with CNC, I have installed various things like Candle2 and UGS. I also want (eventually) to use CAD with the machine so I have FreeCad installed. I also wanted to so some simple 2D CNC stuff - such as experimenting with milling printed circuit board, and Inkscape seemed perfect for this, so that was why I started to use it. I have slowly taught myself to produce 2D drawings with it, and was very happy with the results, so then decided to transfer them to GCode - and came unstuck. There is some stuff online (but nothing I could find in the Inkscape Forum, Bugs, etc), so I was following help on other sites - but they all apparently have working GCode tools - so I came to a halt. The only thing I can see that I could do now is completely clean off one of my computers, re-install a basic Linux OS, then re-install Inkscape, but thats a very drastic step which I am reluctant to do. It would help if I could find some kind of diagnostic help to try and trace the cause of the problem - Inkscape only tells me it cannot save the GCode file - no reasons, no help, no indication why. Its also the final step of the process, so quite time-consuming to test each time.

    Anyway, thanks for the advice.

  6. #6
    Joe Moran Joe Moran @joem7504

    Hey another I got gcodetools extension to work

    Inkscape.92 (important)

    Draw a box or something, select, object to path

     gcodetools/orientation points 2point mode(I guess)apply close

      gcodetools/tool  library. Default apply close

    gcodetools/path to gcode/fill out info as needed and output directory

    go to path to gcode tab BEFORE you apply.  Check your Directory for an .ngc file with good gcode in it.

    Good luck

     

     

     

     

     

     

     

     

     

     

     

     

  7. #7
    AnOther AnOther @AnOther

    Well Guys, I much appreciate your attempts to help me, but I'm getting nowhere. - I've tried the various extensions mentioned above, and followed your instructions carefully - regarding the 'path to Gcode' step, when you mention go to the 'path to Gcode' tab before pressing apply, Inkscape issues a warning if you don't do that, but no matter what I do, in every case, when I try to produce an output file, I get a message telling me Inkscape cannot save.

    I purged the latest Inkscape, and installed 0.92.5, with exactly the same results as with the later version. It seems to me that more than likely something in my configuration is causing the problem, but with no way to diagnose what or why, I am stuck. I have searched for some kind of log file which may indicate what is going on, but nothing. Its almost as though I don't have some necessary permission, but I don't know what.

    As far as I know, there is nothing unusual about my LinuxMint installation, and as I said previously, there isn't much else there to cause problems, so I'll search for a different application, or write the Gcode manually, as I used to do. Thanks all.

  8. #8
    Maren Hachmann Maren Hachmann @Moini

    @AnOther  It would have helped if you had posted screenshots of your GCodetools dialog settings and about the exact error message that you're getting. Possibly the path you're trying to write to does not exist?...

  9. #9
    AnOther AnOther @AnOther

    Hi, Maren - thanks for your patience: below is my step by step approach, with screenshots - I hope its some help, because I have no idea. Sorry If I have done the picture upload all wrong - I had to find out how to do in in very short order.

    To begin:

    1) page sized to 100mm x 100mm

    2) Letter ‘A’ inserted using text tool

    3) ‘A’ selected, then horizontal and vertical co-ordinates set to 0

    4) ‘A’ selected, and set to 100mm wide and 100mm high.

    5) File saved as ‘testA.svg’ in ./home

    6) Select object (‘A’) and apply Path/Object to Path.  (Was uncertain about this, because nothing appears to happen when I do this).

    7) Select Extensions/Gcodetools/Tools Library. - (1-Tools_Library).Since I was only testing to see what happened, I left the tool at ‘Cone’, and pressed ‘Apply’ then ‘Close’ – and the result was this - (2-Tools_Applied).

    8) I edited some of the values here, reduced the size of the box, then moved it to touch the ‘A” – a small blue box appeared at the junction saying ‘Cusp Node to Cusp Node. (3 - Orientation Points).

    9} Then I selected the ‘A’, and then Extensions/Gcode Tools/Orientation Points, and below is the result. (3 - Orientation Points) I left this at ‘2-points mode’, pressed ‘Apply’ then ‘Close’, so I now had this: (4 - Orientation Selection)

    11) I then selected Extensions/Gcode tools / Path to Gcode, and got this: (5 - Path to Gcode)

    I made no changes to ‘Path to Gcode’ or to ‘Options’ tabs, and left the default file name as ‘output.ngc’, and default path as /home on the preferences page. (6 - FilePath).

    I then returned to the ‘Path to Gcode’ tab, and pressed ‘Apply’ – and got this error message (7 - Error Message)

    This has always happened, no matter what I have done, also with an older version of Inkscape. I guess I have done something wrong, but there is no indication (to me) what.

    Thanks again for your efforts.

    7   Error Message
    6   Filepath
    5   Path To Gcode
    4 Orientation Selection
    3   Orientation Points
    2  Tools Applied
  10. #10
    Maren Hachmann Maren Hachmann @Moini

    Thanks for the very good step by step description with the screenshots, @AnOther !

    It's true that you don't have write access in the /home folder. That's normal. Add your user name after that to get into your actual home folder, e.g. /home/AnOther .

    For the next time you encounter a similar issue: the easiest way to check whether there might be something correct about a message about a non-writable location is to open a file manager and then to see whether the location is writable by trying to create a file (it's not in this case, write access for the folder that holds the users' home folders is limited to root user).

  11. #11
    AnOther AnOther @AnOther

    Maren - you're the best - and I feel like a total fool. I did actually open my file manager and create a file to check this, but thats where the senility hit me! - opening the file manager at /home is actually already in /home/username, so it was possible to create a file - and it never crossed my mind that I was not in the correct location.

    Just shows how a simple thing can foul you up

    Many thanks once again for all your patience - now I can make some progress - I'll be in touch when I make my next mistake.

  12. #12
    Maren Hachmann Maren Hachmann @Moini

    Heh... , sorry for assuming you didn't test! Glad it works now :) Do let us know about potential bugs (if you're 100% sure it's a bug, use https://inkscape.org/report ) or weird behavior mysteries, that's what the forum is for.