A package for reading Altium files
Project description
PyAltium
A tool to process Altium file types. Currently this tool is in alpha and does not have any parts fully functioning, except for the listing of PCBLib and SCHLib libraries.
See full documentation here (WIP): pyaltium.readthedocs.io
Project Progress
The goal of this project is to support most file types used by Altium. Reading is a priority, writing will be implemented for some types. The status of various file types is listed below:
Extension | List Items | Display | Write | Documentation | |
---|---|---|---|---|---|
Binary Schematic Library | .SchLib | ✓ | WIP | WIP | |
Binary PCB Library | .PcbLib | ✓ | WIP | WIP | |
Binary Schematic Doc | .SchDoc | ||||
Binary PCB Doc | .PcbDoc | ||||
Draftsman Doc | .PcbDwf | ||||
PCB Project | .PrjPcb | ||||
Material Library | .xml | ✓ | N/A | ✓ | WIP (see test_matlib in the meantime) |
Any templates | Not Planned |
Usage
SchLib
Sample usage:
import pprint
from pyaltium import SchLib
# Set up our pretty printer so our output is understandable
pp = pprint.PrettyPrinter(indent=4)
sl = SchLib("myfile_name.SchLib")
pp.pprint(SchLib.list_items())
This returns something like the following with more elements:
[
{
"libref": "ref1",
"description": "My description",
"sectionkey": "Section Key" // This is unneeded, just for internals
}
]
PCBLib
Currently the only PCB library capability is creating a list of footprints
Sample usage:
import pprint
from pyaltium import SchLib
# Set up our pretty printer so our output is understandable
pp = pprint.PrettyPrinter(indent=4)
sl = SchLib("myfile_name.SchLib")
pp.pprint(SchLib.list_items())
Returns:
[
{
"footprintref": "ref1",
"height": "2.8", // mm
"description": "My description"
},
// ...
]
Contributing
Have an idea? Open an issue! Have a change? submit a PR!
Note that I have a long ways to go on this so don't expect too much as of now. Help is always welcome.
Licensing
This project is licensed under GPLv3. Basically you can use this however you want but if you distribute (aka sell) something with it, you need to make the source available. Once this project gains some traction, I'll be open to moving to MIT if there's demand for it.
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
File details
Details for the file PyAltium-0.4.0.tar.gz
.
File metadata
- Download URL: PyAltium-0.4.0.tar.gz
- Upload date:
- Size: 27.2 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.4.2 importlib_metadata/4.8.1 pkginfo/1.7.1 requests/2.26.0 requests-toolbelt/0.9.1 tqdm/4.62.2 CPython/3.9.13
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 34e1b0208146470cadb6b180fa6e1220e982cee03c9c43c19c87b79d037839c9 |
|
MD5 | 56b86e1444c6a49f7113fa2a6cd4549c |
|
BLAKE2b-256 | c0f36131e00ee0b72e70c8345672f2b0cf481673cbf9e278a4f30e8721a3672b |
File details
Details for the file PyAltium-0.4.0-py3-none-any.whl
.
File metadata
- Download URL: PyAltium-0.4.0-py3-none-any.whl
- Upload date:
- Size: 30.9 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.4.2 importlib_metadata/4.8.1 pkginfo/1.7.1 requests/2.26.0 requests-toolbelt/0.9.1 tqdm/4.62.2 CPython/3.9.13
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 98fad7b9b1d6b907631cc03294fadec8171ea135829b04a747dc487c7dfa060a |
|
MD5 | a503c4f8333ba4e7451d5396bccf2370 |
|
BLAKE2b-256 | 20e34f37739ded6f66da533d5be103bc45b8407ee97678076788c66ca908bd01 |