InkCut Extension, send HPGL directly to cutter from Inkscape

Post about using Inkscape with cutters or plotters.
syb3ria
Posts: 2
Joined: Thu Nov 01, 2012 2:04 am

Re: InkCut Extension, send HPGL directly to cutter from Inks

Postby syb3ria » Thu Nov 01, 2012 2:29 am

Hello everyone.
Can someone help me with inkcut extension problem I have. Running Ubuntu 12.10, inkscape 0.48 and latest inkcut. The first and the less important problem is I need to run

Code: Select all

sudo chmod 777 /dev/ttyUSB0

every now and then in order to cut objects.

The second and the most important issue I have is, somethnig is going wrong between inkcut and the plotter. I am having this result:
Image with this settings Image and the plotter hangs up on "now cutting..."

Any help would be gladly appreciated.
Regards

OttoHermansson
Posts: 1
Joined: Tue Dec 04, 2012 9:20 am

Re: InkCut Extension, send HPGL directly to cutter from Inks

Postby OttoHermansson » Tue Dec 04, 2012 9:23 am

This is how I got Inkcut to run on windows step by step.

* Install Inkscape (0.48.2)
* Install Inkcut (1.0)
* Download GTK+ bundle (http://ftp.gnome.org/pub/gnome/binaries ... _win32.zip)
* Copy bin, etc, lib, share from the zip file to your ...\Inkscape\python directory
* Download PyGTK (http://ftp.gnome.org/pub/GNOME/binaries ... -py2.6.msi)
* Extract files from msi installer (http://blog.dotsmart.net/2009/05/13/unz ... msi-files/)
* Copy the extracted folder (include, Lib, Scripts, share) to your ...\Inkscape\python directory
* Edit Inkscape:
.\inkcut\app\bin\device.py
Comment out line 27.

.\inkcut\app\main.py
Comment out line 143 to 148.
Comment out line 165 to 167. (This removes scanning of serial ports but I have not been able to get it to work on windows 7)
Add after line 167 (This will add the ports in the array to your settings. My plotter is located at port COM1 and I could stop there but why not be able to use a couple of extra?):
> ports = ["COM1","COM2","COM3"]


Comment out line 241 to 252. This will remove the preview from within the extention, you can still use preview in Inkscape and I hope to solve the preview issue.

Now you should be able to start the extention and set it up to a serial port. This worked for me on windows 7 and a converted HP 7580B plotter.

Edit: I tried this on a fresh computer at work. I got some permission issues with the logging in Inkcut, I solved it by changing the permissions on the folder .\inkcut\app\tmp to allow all users read/write. It might be that my workstation is locked down a tad but worth mentioning.
Last edited by OttoHermansson on Tue Dec 04, 2012 8:01 pm, edited 1 time in total.

User avatar
brynn
Posts: 9584
Joined: Wed Sep 26, 2007 4:34 pm
Location: western USA
Contact:

Re: InkCut Extension, send HPGL directly to cutter from Inks

Postby brynn » Tue Dec 04, 2012 10:28 am

This will make a LOT of Windows and cutter/plotter users very happy! Thank you so much for sharing :D

AndyJ
Posts: 1
Joined: Sat Dec 08, 2012 4:06 pm

Re: InkCut Extension, send HPGL directly to cutter from Inks

Postby AndyJ » Sat Dec 08, 2012 4:07 pm

Any chance of line-scan raster for laser engravers?

User avatar
Inkspots
Posts: 232
Joined: Sat Dec 03, 2011 3:16 am

Re: InkCut Extension, send HPGL directly to cutter from Inks

Postby Inkspots » Mon Dec 10, 2012 12:45 pm

OttoHermansson ,
thanks for sharing your fix. This will help a lot of people.

emax
Posts: 2
Joined: Sat Jan 12, 2013 8:42 pm

Re: InkCut Extension, send HPGL directly to cutter from Inks

Postby emax » Sat Jan 12, 2013 8:51 pm

syb3ria wrote:Can someone help me with inkcut extension problem I have. Running Ubuntu 12.10, inkscape 0.48 and latest inkcut. The first and the less important problem is I need to run

Code: Select all

sudo chmod 777 /dev/ttyUSB0

every now and then in order to cut objects.


Do this (blue is input, red is output):

$ ls -l /dev/ttyUSB0
crw-rw---- 1 root dialout 188, 0 Jan 12 11:23 /dev/ttyUSB0

Add yourself to the 'dialout' group or whatever the underlined group name on your system is.

emax
Posts: 2
Joined: Sat Jan 12, 2013 8:42 pm

Re: InkCut Extension, send HPGL directly to cutter from Inks

Postby emax » Sun Jan 20, 2013 12:02 am

I have a Silhouette Cameo running here, everthings works fine on the Linux side.

However, when the blade moves to the starting position and from cutting-path to cutting path, it doesn't seem to have the blade 'up'. It cuts the moving legs as well. apparently the blade is down all the time.

I have controlled HPGL output starts like that: 'IN;SP1;PU160,328;PD299,328;PD299,309;PD241,309;PD241,163;PD218,163;PD218,309;PD160,309;PD160,328;PU387,230;PD387,220;PD294,220...'

so there are 'PEN UP' commands in the file. And if I view the hpgl-file in a hp2xx (an hpgl-viewer), everthing looks fine. So it perhapd has to do with particular configuration options?

Does anybody have an idea?
Attachments
Bildschirmfoto1.png
Bildschirmfoto1.png (79.71 KiB) Viewed 21188 times
Bildschirmfoto2.png
Bildschirmfoto2.png (60.61 KiB) Viewed 21188 times

Michielio
Posts: 5
Joined: Mon Feb 11, 2013 8:15 am

Re: InkCut Extension, send HPGL directly to cutter from Inks

Postby Michielio » Fri Feb 15, 2013 7:09 pm

Hi all,

My setup is a Roland CAMM-1 (PNC-960) on Ubuntu 12.04 (inkcut and inkscape latest stable releases)
For no apparent reason I get this error:

Traceback (most recent call last):
File "inkcutext.py", line 71, in <module>
effect.affect()
File "/usr/share/inkscape/extensions/inkex.py", line 215, in affect
self.effect()
File "inkcutext.py", line 50, in effect
InkscapePlugin(self.document,nodes.keys(),inkex)
File "/home/michiel/.config/inkscape/extensions/inkcut/app/main.py", line 473, in InkscapePlugin
app = Application(svg,nodes,inkex)
File "/home/michiel/.config/inkscape/extensions/inkcut/app/main.py", line 114, in __init__
self.on_preview_clicked('first')
File "/home/michiel/.config/inkscape/extensions/inkcut/app/main.py", line 227, in on_preview_clicked
psvg = preview.hpgl(self.plot)
File "/home/michiel/.config/inkscape/extensions/inkcut/app/bin/preview.py", line 56, in hpgl
svg.set('width',str(plot.getSize()[0]+plot.startPosition[0]+plot.finishPosition[0]))
File "/home/michiel/.config/inkscape/extensions/inkcut/app/bin/path.py", line 180, in getSize
self.createTiledClones() # will set self.size
File "/home/michiel/.config/inkscape/extensions/inkcut/app/bin/path.py", line 94, in createTiledClones
if (dm[0] == 0): limit[0]=pos[0] + pad[0] + 2*sz[0]+1 # should result in an always true test
TypeError: 'tuple' object does not support item assignment


The last time this happened, I "fixed" it by re-installing inkcut. That worked for a few days, but now it's back.
Before I re-install inkcut again, I really want to know what is happening for this error to appear.

PS: I'm a linux noob, so please be gentle.. lol

Michielio
Posts: 5
Joined: Mon Feb 11, 2013 8:15 am

Re: InkCut Extension, send HPGL directly to cutter from Inks

Postby Michielio » Sun Feb 17, 2013 7:57 pm

Again I managed to "fix" it, by simply re-extracting the package to the extensions folder.
But I'm still clueless as to what happened.
Does anyone have any ideas where to look?

Brockettman
Posts: 1
Joined: Sun Mar 17, 2013 10:05 am

Re: InkCut Extension, send HPGL directly to cutter from Inks

Postby Brockettman » Sun Mar 17, 2013 11:14 am

Hi all! I am new to this forum and am excited to get to cutting in Ubuntu!

I have been trying to get InkCut to work, but I am running into some problems. I have the extension in the extensions folder and it shows up in the menu.
When I select the InkCut it pops up a quick dialog box and says "'InkCut v1.0' is working, please wait..." super fast, then It returns with another dialog box that gives me this error info.

"Traceback (most recent call last):
File "inkcutext.py", line 71, in <module>
effect.affect()
File "/usr/share/inkscape/extensions/inkex.py", line 215, in affect
self.effect()
File "inkcutext.py", line 50, in effect
InkscapePlugin(self.document,nodes.keys(),inkex)
File "/usr/share/inkscape/extensions/inkcut/app/main.py", line 473, in InkscapePlugin
app = Application(svg,nodes,inkex)
File "/usr/share/inkscape/extensions/inkcut/app/main.py", line 86, in __init__
self.plot.loadGraphic(self.nodes)
File "/usr/share/inkscape/extensions/inkcut/app/bin/path.py", line 69, in loadGraphic
self.graphic = Graphic(svgPathNodes)
File "/usr/share/inkscape/extensions/inkcut/app/bin/path.py", line 408, in __init__
self.data = self.toBasicPaths(self.fromSVG(svgElements))
File "/usr/share/inkscape/extensions/inkcut/app/bin/path.py", line 546, in fromSVG
raise AssertionError("Cannot handle tag '%s'"%(tag))
AssertionError: Cannot handle tag 'flowRoot'"

Any help is very appreciated!

I am running
-Ubuntu 12.10
-Inkscape 0.48.3.1 r9886
-InkCut v1.0
Plotter
-seiki plotter sk870t with USB to Serial adaptor

Again, any help is very appreciated!

Thanks,
~B

Michielio
Posts: 5
Joined: Mon Feb 11, 2013 8:15 am

Re: InkCut Extension, send HPGL directly to cutter from Inks

Postby Michielio » Tue Apr 23, 2013 11:17 pm

First try if you can get a simple form (a circle) to plot.
Draw a circle
click "Object - object to path"
select the object
then invoke inkcut from the extensions menu

What happens?

abrax
Posts: 2
Joined: Wed May 22, 2013 4:55 pm

Re: InkCut Extension, send HPGL directly to cutter from Inks

Postby abrax » Wed May 22, 2013 6:47 pm

Hi guys,

I'm a happy user of xubuntu running Inkscape with InkCut 1.0 WITH A SUCCESS! (or at last my vinyl cutter reacts :-( )

Unfortunately i use Redsail 1360 and this is a problem as it seems that this software is not Redsail specific enough...

I can test the connection and every time a nice 50mmx50mm rectangle is drawn. But when it comes to any ellipse or anything more complicated than a single rectangle, strange things happen. Seems that the interpreter should give my plotter Redsail specific code. When I take a look into TuxPlot -> it seems that they know the issue because there is even a special setting especially for the Redsail. However I cannot work with TuxPlot - It's not the way to go.
I am using the cutter with SignCut on my Mac but it seems that I will have to leave this comp and take up my work with Linux.

Anyone with the same problem? Or ANY ideas on how to fix this? I'd love to use this vinylcutter with this linux machine so much... I mean -> I need this badly! :-) Help!

abrax
Posts: 2
Joined: Wed May 22, 2013 4:55 pm

Re: InkCut Extension, send HPGL directly to cutter from Inks

Postby abrax » Thu May 23, 2013 7:02 am

Some more informations:
I've done this with TuxPlot. It IS WORKING CORRECTLY. But just when I select direct port feeding. When I try to use standard method with a proposed driver via a fake printer, everything looks exactly the same as it was with InkCut. So I still want to make it with InkCut :-) I'm curious if it can be done with the InkCut. Is there any option to directly feed serial port? Heh, I will check things, bete test or even do something, just reply me :-)

User avatar
brynn
Posts: 9584
Joined: Wed Sep 26, 2007 4:34 pm
Location: western USA
Contact:

Re: InkCut Extension, send HPGL directly to cutter from Inks

Postby brynn » Tue May 28, 2013 6:39 am

Hi abrax,
Welcome to the forum! The author of this extension used to keep up with replies in this topic, but doesn't seem to be around much anymore. I wonder if you could find some contact info with the download? I'm not familiar with InkCut, unforunately.

incan
Posts: 1
Joined: Thu Aug 15, 2013 11:11 pm

Re: InkCut Extension, send HPGL directly to cutter from Inks

Postby incan » Thu Aug 15, 2013 11:15 pm

Trying to make this work in Windows. After making a circle and using "object to path" I got this error message:

'import site' failed; use -v for traceback

Traceback (most recent call last):

File "C:\Program Files\Inkscape\share\extensions\inkcut/inkcutext.py", line 71, in <module>

syb3ria
Posts: 2
Joined: Thu Nov 01, 2012 2:04 am

Re: InkCut Extension, send HPGL directly to cutter from Inks

Postby syb3ria » Fri Sep 20, 2013 2:58 am

@emax thx, i'll check that when i switch again to my ubuntu box

@OttoHermansson can you come up with somehow more detailed info about inkcut and win, i tried many variations of your tutotial, even fresh install of win, but always end up with some output like this :

Code: Select all

Traceback (most recent call last):

  File "inkcutext.py", line 71, in <module>

    effect.affect()

  File "C:\Program Files\Inkscape\share\extensions\inkex.py", line 215, in affect

    self.effect()

  File "inkcutext.py", line 47, in effect

    from app.main import InkscapePlugin

  File "C:\Documents and Settings\Administrator\Application Data\inkscape\extensions\inkcut\app\main.py", line 240

    else:

        ^

IndentationError: unindent does not match any outer indentation level

Inkscape 0.48.4, latest inkcut, windows XP

Kid riddlin
Posts: 59
Joined: Thu Jun 21, 2012 5:03 am
Location: york pa
Contact:

Re: InkCut Extension, send HPGL directly to cutter from Inks

Postby Kid riddlin » Thu Oct 03, 2013 9:56 am

hey everybody. this seems like an awesome extension for people like me who make alot of decals and signs and such.

my issue:

i have it installed on windows 7 and it shows up in the extension dropdown in inkscape but thats about it, when i go to
the cutter/plotter extension the box that expands out the side is empty.

any suggestions? im really trying to learn to use this program for everything i do because im tired of bootleging the $6,000 programs i cant afford. rite now im using flexi 10 for my cutter software and want to ween off of it if i can get this thing crackin. thanks

Kid riddlin
Posts: 59
Joined: Thu Jun 21, 2012 5:03 am
Location: york pa
Contact:

Re: InkCut Extension, send HPGL directly to cutter from Inks

Postby Kid riddlin » Fri Oct 04, 2013 10:52 am

any help would be a push in the rite direction. thanks

User avatar
ragstian
Posts: 1158
Joined: Thu Oct 11, 2012 2:44 am
Location: Stavanger-Norway

Re: InkCut Extension, send HPGL directly to cutter from Inks

Postby ragstian » Fri Oct 04, 2013 2:20 pm

Hi Kid riddlin

The error you see is most likely caused by incorrect copying of the extension files to your share\extensions folder.
( Please be aware of the fact that there are two different places where extensions can be installed - under the Inkscape install directory and also under your user applications Inkscape directory.
IMHO - the "best" place for them is in your "user" directory as they will then survive an uninstall/reinstall of Inkscape.)

On my system - also Win 7 - the file "inkutext1.inx" is in the "install_directory\Inkscape\Share\extensions\" directory.
(On my system the "install_directory" is "C:\Graphics\Inkscape\" - if you did a standard install yours will most likely be "C:\Program Files (X86)\Inkscape\" )

The "inkucutext.py" file has to be in a separate directory one level further down; "install_directory\Inkscape\Share\extensions\inkcut\"
( The full path & filename on my system; - "C:\Graphics\Inkscape\share\extensions\inkcut\inkutext.py"

On loading inkscape it creates an extension error log file - mine is in; "C:\Users\Ragnar\AppData\Roaming\inkscape" - the file is called "extension-errors.log"
Open the file in a text editor (Notepad) and look for an error associated with Inkcut- when I "hide" the python file (for testing this error) the entry in the log file looks like this;

Code: Select all

Extension "InkCut v1.0" failed to load because a dependency was not met.
Dependency:
  type: executable
  location: extensions
  string: inkcut/inkcutext.py

If you still have problems after getting the inx file "inkcutext1.inx" and the python file "inkcutext.py" to the correct locations please chime back for more help.
Hope this is a push in the "rite" (right?) direction! (By the way - you need a new keyboard as the Shift key to get uppercase characters does not work - ;) )

Good Luck.
RGDS
Ragnar
Good Luck!
( ͡° ͜ʖ ͡°)
RGDS
Ragnar

Kid riddlin
Posts: 59
Joined: Thu Jun 21, 2012 5:03 am
Location: york pa
Contact:

Re: InkCut Extension, send HPGL directly to cutter from Inks

Postby Kid riddlin » Tue Oct 08, 2013 3:29 am

:) thanks for the help and no my keyboard isnt broke lol when i type on forums i just dont use caps for some reason.

the extension is now working in the dropdown but when i go to use it this is the error i get:

Traceback (most recent call last):

File "inkcutext.py", line 71, in <module>

effect.affect()

File "C:\Program Files (x86)\Inkscape\share\extensions\inkex.py", line 215, in affect

self.effect()

File "inkcutext.py", line 47, in effect

from app.main import InkscapePlugin

File "C:\Program Files (x86)\Inkscape\share\extensions\inkcut\app\main.py", line 25, in <module>

import pygtk,sys,os,logging

ImportError: No module named pygtk

User avatar
ragstian
Posts: 1158
Joined: Thu Oct 11, 2012 2:44 am
Location: Stavanger-Norway

Re: InkCut Extension, send HPGL directly to cutter from Inks

Postby ragstian » Tue Oct 08, 2013 9:33 am

Hi.

Just pulling your leg with regards to the keyboard! ;)

The error you get is due to a module depreciated on the python version used on Inkscape and is easy to fix.

See here; http://laconsigna.wordpress.com/2010/11/13/fixing-textext-on-inkscape-0-48/

[*]First you need to download the python packages that are missing, thanks to David Gleich whom packed everything together, avoiding us the trouble of download them and put the pieces together.
[*] Unzip them C:\Program Files\Inkscape\python\Lib\site-packages

You might some error messages about untrusted sertificates from the site. Just go ahead and accept the risks.
After copying the site-packages your extension should work.

Disregard the rest of the instructions about how to get textext to work (unless you want/need that as well ;) ).

Good Luck
RGDS
Ragnar
Good Luck!
( ͡° ͜ʖ ͡°)
RGDS
Ragnar

Kid riddlin
Posts: 59
Joined: Thu Jun 21, 2012 5:03 am
Location: york pa
Contact:

Re: InkCut Extension, send HPGL directly to cutter from Inks

Postby Kid riddlin » Wed Oct 09, 2013 12:57 pm

darn i thought that was going to be it but it didnt work i got the same error message. im scratching my head again. what is textext?

User avatar
ragstian
Posts: 1158
Joined: Thu Oct 11, 2012 2:44 am
Location: Stavanger-Norway

Re: InkCut Extension, send HPGL directly to cutter from Inks

Postby ragstian » Wed Oct 09, 2013 2:44 pm

Hi.
textext is an extension that will let you use tex commands directly in Inkscape - often used for entering mathematical formulas etc in documents.
Tex can be used for making complete books, brochures, technical papers etc as well.
See this;
http://en.wikipedia.org/wiki/TeX

Hm, reckon you have to do some "manual" faultfinding.
Use Windows explorer and navigate to the "C:\Program Files (x86)\Inkscape\python\Lib\site-packages"

Do you see the file "pygtk.py" in the directory?
If no - make sure you follow the instructions on how to copy the site-packages to your inkscape directory.

If yes - start python from a CMD window.
In the examples you type what's in blue.
Your Inkscape Directory is most likely different from mine - see earlier post in this thread.

    C:\Graphics\Inkscape\python>python
    Python 2.6.5 (r265:79096, Mar 19 2010, 21:48:26) [MSC v.1500 32 bit (Intel)] on win32
    Type "help", "copyright", "credits" or "license" for more information.
    >>> import pygtk
    Traceback (most recent call last):
    File "<stdin>", line 1, in <module>
    ImportError: No module named pygtk
Here I installed pygtk as per instructions.
And tried again;

    >>> import pygtk
    >>>

If python just accepts the command - Success!

To quit python after this test enter; "quit()"
If this fails chime back - list your directory - copy & paste errormessages etc.

Good Luck.
RGDS
Ragnar
Good Luck!
( ͡° ͜ʖ ͡°)
RGDS
Ragnar

Kid riddlin
Posts: 59
Joined: Thu Jun 21, 2012 5:03 am
Location: york pa
Contact:

Re: InkCut Extension, send HPGL directly to cutter from Inks

Postby Kid riddlin » Thu Oct 10, 2013 1:54 pm

yea looks like its not accepting the command. heres what comes up:


traceback (most recent call last) :
file "<stdin>" , line 1 , in <module>
ImportError: No module named pygtk


dont know if it matters but that btk file is a .py when you look at the properties but is considered a notepad file by the computer?? maybe thats the way its supposed to be? but ...

User avatar
ragstian
Posts: 1158
Joined: Thu Oct 11, 2012 2:44 am
Location: Stavanger-Norway

Re: InkCut Extension, send HPGL directly to cutter from Inks

Postby ragstian » Fri Oct 11, 2013 1:28 am

Hi

Your python does not find the pygtk.py in the inkscape\python\lib\site-packages\ folder
Do you see the pygtk.py file in the Inkscape python directory?
Like this;
pyGTK.png
pyGTK.png (115.94 KiB) Viewed 18211 times

The more info you post the easier it is to get you up and going - quicker as well!
Post screendumps like in this post - then we can "see" what's (not) going on.

Go through the install procedure once more and make sure you copy to the correct location.

RGDS
Ragnar
Good Luck!
( ͡° ͜ʖ ͡°)
RGDS
Ragnar


Return to “Inkscape & Cutters/Plotters”

Who is online

Users browsing this forum: No registered users and 2 guests