Home
Name Modified Size InfoDownloads / Week
2019-12-05 2019-12-05
2014-02-20 2015-06-02
2015-06-02 2015-06-02
README.txt 2019-12-05 2.2 kB
Totals: 4 Items   2.2 kB 2
dxf2gbr is a simple commandline tool for converting 2D dxf mask drawings to a gerber file needed by many plotters.

Notes for the pre 2019 versions:

To run it you will need either python2 (2.x, 32 bit version), ttfquery (a python extension), numpy(another python extension needed by ttfquery) and FontTools (needed by ttfquery too). Further instructions how to get and install them can be found here:
http://python.org/download/ 
http://www.scipy.org/Download
http://ttfquery.sourceforge.net/
http://sourceforge.net/projects/fonttools/

-install a pythonversion like  2.7.x 32 bit version. The Pre 2019 versions were tested with that.
-Look out for numpy at the scipy website. Take care it is compatible with your python version.
-ttfquery and fonttools can be installed by opening a console, navigate to the directory and call "[path_to_your_python_installation]python setup.py install"


Note for the >2019 versions:

The custom made dxf parser was replaced with ezdxf. Sadly there seems to be no python3 support for ttfquery so currently the text conversion is non functional. A known issue is that Hatches can accidentally "delete" underlying objects due to the use of LPC/LPD commands. This can be worked around by making sure that Hatches do not overlap other objects or by making sure that "openings" of a Hatch are connected directly to the outline. If you have the time to implement a general solution: Feel free to submit a patch or fork this project; hint for finding a working algorihm: one can cast a ray from the openings of a Hatch and check were it hits the outline. This ray can then be used to split inner part and outline and connect them. 

To run the tool just open a shell or cmd and enter
"python dxf2gbr.py [your_dxf_file_you_want_to_be_converted] [autofill]" (i.e. "python dxf2gbr.py example.dxf" or "python dxf2gbr.py example.dxf autofill" )
OR if your system paths are not setup properly
"[path_to_your_python_installation]/python dxf2gbr.py [your_dxf_file_you_want_to_be_converted] [autofill]" (i.e. "C:/python27/python dxf2gbr.py example.dxf")
OR just call it without any given file so it will convert all dxf files it can find in the very same directory
Source: README.txt, updated 2019-12-05