PyEAGLE - Read / Write Cadsoft EAGLE Files¶
PyEAGLE is an interchange API to read and write Cadsoft EAGLE XML (v6 and later) schematic, library, and PCB layout files.
Some long term goals are:
- Comprehensive and round-trip-capable interface between Pythonic data structures and EAGLE’s XML format, eliminating the impedance mismatch involved in manipulating EAGLE files in Python scripts.
- Traversal and net analysis helpers, to serve as a foundation for higher-level tools.
- Rendering capability in SVG.
- Command-line tools, including basic
grep
andlint
tools.
At this point it is fairly incomplete and not ‘production useful’.
Example Usage¶
lib = pyeagle.open('SparkFun-Sensors.lbr')
for part in lib:
print part
Screenshot¶
Everyone loves screenshots.
Contents¶
Quick Start¶
Use¶
Open a library file, print some info about the contents.
import pyeagle
lib = pyeagle.open('SparkFun-Sensors.lbr')
for device_set in lib: # could also use lib.device_sets
print device_set
for symbol in lib.symbols:
print symbol
for package in lib.packages:
print package
API Reference¶
Contributing¶
Patches and suggestions are strongly encouraged! GitHub pull requests are preferred, but other mechanisms of feedback are welcome.
PyEAGLE hopes to have a comprehensive test suite with 100% line and branch
coverage, as reported by the excellent coverage
module. To run the tests,
simply run in the top level of the repo:
$ tox
This will also ensure that the Sphinx documentation builds correctly, and that there are no PEP8 or Pyflakes warnings in the codebase.
Contributors¶
Thanks to Bernard “Guyzmo” Pratz for
zc.buildout
support.