-
-
Notifications
You must be signed in to change notification settings - Fork 112
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Adds support for hierarchical sheets when rewriting schematics files. #506
Conversation
@gonzalop the plugin already supports generating design packages for hierarchical sheets. Is this adding support to another feature area of the plugin? If so, can the commit subject be clarified? |
Updated. the subject The code makes it rewrite schematics files when exporting changes made by the plugin. Before this change, only the main schematics file was updated. |
@gonzalop ahh gotcha, can you update the commit message itself? The subject of the PR might default to the subject of the first commit or something but editing the PR subject doesn't directly edit the commit log message. Should be possible to edit it via 'git commit --amend' or with a git rebase. |
Done. Thanks. |
@chmorgan Did you already test this PR? I have never before used hierarchical sheets in KiCAD, so I canno really test this ... |
I haven’t. I haven’t used that export feature before, not sure what it’s
used for actually….
…On Tue, Jul 30, 2024 at 6:40 AM bouni ***@***.***> wrote:
@chmorgan <https://github.com/chmorgan> Did you already test this PR? I
have never before used hierarchical sheets in KiCAD, so I canno really test
this ...
—
Reply to this email directly, view it on GitHub
<#506 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AAJH4ACTCMPR5AHD6BTARKTZO5UQTAVCNFSM6AAAAABLSOUQKWVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDENJYGAZTQNZQGE>
.
You are receiving this because you were mentioned.Message ID:
***@***.***>
|
The export function writes LCSC data that was set via the Plugin back to the schematic. @gonzalop Can you provide an example project so that I can test this PR? |
Here's an example project: 6-example.prj.zip |
For whatever reason this does not work for me ... I run KiCAD 8.0.4 If I extract your zip and open the project, the export to schematic function does not find the correct kicad_sch file because of the
Nothing happens to the Furthermore, none of the two resistors in the schematic files gets the LCSC property set ... |
That's odd. It might be some windows oddity. I'll find a windows machine to test on later today and report back. |
Very strange. Let me look into it on Friday again, tomorrow is a public holiday 😁 |
Enjoy the holiday! FWIW, this was a fresh install of KiCAD 8.0.4 on a Windows 10 machine, and I cloned the branch with this pull request into the scripting/ folder, then cloned the example project and loaded it up in KiCAD. |
Ok, I think I figured it out! This returns a dict after #487 was merged: kicad-jlcpcb-tools/schematicexport.py Line 47 in ec4aee0
so this no longer works: kicad-jlcpcb-tools/schematicexport.py Lines 89 to 92 in ec4aee0
replaceing for part in store_parts:
if value == part[0]:
newLcsc = part[3] with this for part in store_parts:
if value == part["reference"]:
newLcsc = part["lcsc"] solves the issue. Can you please update and rebase your PR |
Done. |
Recursively proceses hierarchical sheets when rewriting schematics files. This only affects KiCad 8+.
Recursively proceses hierarchical sheets when rewriting schematics files.