Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

gerber-to-svg

Package Overview
Dependencies
Maintainers
1
Versions
66
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

gerber-to-svg

Gerber file to SVG converter

  • 0.0.5
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
593
decreased by-25.69%
Maintainers
1
Weekly downloads
 
Created
Source

gerber-to-svg Build Status Version

Gerber file to SVG converter for Node and the browser.

usage

command line (with Node already installed)

  1. $ npm install -g gerber-to-svg
  2. $ gerber2svg /path/to/gerber (writes to stdout)
  • $ gerber2svg /path/to/gerber > file.svg will write to a file

api (with Node or in the Browser with Browserify)

  1. $ npm install --save(-dev) gerber-to-svg

Use in your app with:

var gerberToSvg = require(gerber-to-svg);
var svgString = gerberToSvg(gerberString);

Where gerberString is the gerber file (e.g. from fs.readFile encoded with UTF-8 or FileReader.readAsText).

what you get

Not a whole lot, for now. This converter uses RS-274X and strives to be true to the latest format specification. Most all of the Gerber file features are there.

The returned SVG is going to be black, but you can specify color either in the XML or with CSS to change it.

things to watch out for

Step and repeat is very much a work in progress. If your Gerber file is only one polarity (i.e %LPC*% doesn't appear anywhere in your file), you should be fine. But otherwise, don't trust whatever it returns (if it doesn't throw).

Arcs should work, but they've tended to give me trouble. If you see something circular and weird, that could be why.

if it messes up

Open up an issue and attach your Gerber, if you can. I appreciate files to test on.

Keywords

FAQs

Package last updated on 08 Aug 2014

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc