Equipment/VinylCutterOld: Difference between revisions

From London Hackspace Wiki

no edit summary
No edit summary
No edit summary
Line 1: Line 1:
[[File:Roland (Large).jpg|thumb|right]]
[[File:Roland (Large).jpg|thumb|right]]
==Status==
==Status==
I have had a certain amount of success running the cutter with a serial connection from Inkscape under Linux.  More messing around is needed.--[[User:Artag|Artag]] 13:32, 19 August 2010 (UTC)
* I have had a certain amount of success running the cutter with a serial connection from Inkscape under Linux.  More messing around is needed.--[[User:Artag|Artag]] 13:32, 19 August 2010 (UTC)
* I have gotten the cutter to reliably cut reasonably complex shapes (see image to the right). See http://github.com/muz/Ruby-PNC950. Looks like the serial port needed negotiating correctly.--[[User:Muz|Muz]] 20 August 2010.
==Model==
==Model==
* Roland CAMM-1 PNC-950. [http://www.signcutpro.com/files/man/roland/pnc950.pdf PDF manual], [http://support.rolanddga.com/Docs/Documents/departments/Product%20Management/Product%20Information/Specialty%20Products/PNC950_FAQ.pdf FAQ].
* Roland CAMM-1 PNC-950. [http://www.signcutpro.com/files/man/roland/pnc950.pdf PDF manual], [http://support.rolanddga.com/Docs/Documents/departments/Product%20Management/Product%20Information/Specialty%20Products/PNC950_FAQ.pdf FAQ].
Line 10: Line 11:
==Instructions==
==Instructions==
====Quick setup guide====
====Quick setup guide====
* Set inkscape to hpgl output
* Set inkscape to HPGL output. File > Save As > HPGL format.
* draw figure and print to a file
* Draw your figure.
* set serial port to 9600 8n1, crtscts.
* Connect the cutter via USB to Lovelace. This is done with a serial port converter from 25-pins -> 9-pins -> USB.
* connect blue cable (a 9-pin gender-changer is needed at the PC end)
* Load vinyl, making sure that it is flush with the left edge and has some slack for being pulled to and fro.
* load vinyl, switch cutter on. cutter should park at right hand side
* Turn on the cutter, the cutter head should fly to the right edge.
* press Setup, cutter parks at left. Move cutter if necessary with cursor buttons, press Origin Set to mark lower right corner of drawing
* Press Setup, cutter parks at left.  
* cat the inkscape output file to the serial port
* Move cutter if necessary with cursor buttons, press Origin Set to mark lower right corner of drawing
* Run '~/serialshite.rb <HPGL filename>' from a Terminal.


It should be possible to enable the serial port as a printer and print direct to it, but I found this produced cutter errors (flashing power light) and no cut.
It should be possible to enable the serial port as a printer and print direct to it, but I found this produced cutter errors (flashing power light) and no cut.


The following file was generated by inkscape for a star shape. This almost works : the first leg is replaced by a poorly cut arc. May imply a need for some sort of initialisation data.
The following file was generated by inkskape for a star shape. This works.


  IN;
  IN;
Line 36: Line 38:
  PD3999,6429;
  PD3999,6429;
  PD3999,6429;
  PD3999,6429;
====Creating Images for Cutting====
'''Converting an existing SVG'''
For some reason, Inkscape doesn't like going straight from SVG to HPGL. This can be fixed by:
* Open up the SVG file
* File > Save As > select the DXF file format.
* Open the DXF
* File > Save As > HPGL
'''Creating your own image in Inkscape'''
Inkscape seems to play nicely if you just create a new image and lay down some paths or polygons of your own. You can save this data for the cutter by just going to File > Save As > HPGL
'''Avoiding overloading the cutter with TOO MUCH DATA'''
The cutter doesn't seem to happy when it recieves a large set of instructions in one fell swoop. As such, it is highly recommended that you format your HPGL files nicely.
* vim yourhpglfile.hpgl
* <Esc>
* :% s/;/;<C-x><C-m>/g
* <Return>
* :wq
This will place each command on its own line, and in the case of more complex drawing patterns, avoid having the cutter throw a hissy fit and get confused.


==Tips==
==Tips==
Line 62: Line 88:
==Consumables==
==Consumables==
There is a [[Pledges/Vinyl|pledge]] running for the purchase of more vinyl.
There is a [[Pledges/Vinyl|pledge]] running for the purchase of more vinyl.
==Example code==
require "rubygems"
require "serialport"
if (!ARGV[0])
puts "Yo dawg, I need a file."
exit
end
plotter = SerialPort.new("/dev/ttyUSB2")
plotter.baud=(9600)
plotter.flow_control=(SerialPort::HARD)
plotter.rts=(1)
plotter.data_bits=(8)
plotter.stop_bits=(1)
begin
        File.open(ARGV[0], "r") do |inFile|
                while (line = inFile.gets)
                        puts line
                        plotter.write(line)
                        # sleep(1)
                end
        end
rescue
        puts "Failed to open #{ARGV[0]}"
        exit
end
24

edits