Multiple PCB schematic for the same electrical schematic

Hello guys, I have an electrical schematic then I need to design 2 differents boards having 2 different shapes and component placement of course. I made a little experiment saving the PCB files with 2 different names. The original PCB and the electrical schematics work together (if I select a component on one it is highlighted also on the other) but this does not work on the 2nd PCB file. But the worst thig is that if I produce the files for production are saved in production sub folder and they have the same name. Because Kicad delete the folder before to save the new file the last wins. Is there a better way to manage this situation?

I do not know if it is better; however, I have done this before by creating a copy of both the schematic and board with a new name. Then by opening one of them, a new project file is created with that same name. This project can then be maintained separately. The obvious problem is that the schematic needs to be fairly complete before splitting or you will have too much work to do to keep the schematics in sync going forward.
You, might be able to copy the schematic again later, I have not tried that far.

1 Like

To be more clear, you probably were still in the original project when you saved the new file. My method is to have two separate projects so that you have to open each, one at a time. It does not matter if they share the same folder.

1 Like

Hmmm, well, in my case the schematic is the same, also the components are the same, so to prevent any error I would like to have only one copy of the electrical schematic. But, there are some more strange things. This is what I did:

  1. I designed the electrical schematic, ERC, BOM etc. everything needed
  2. I put the data to the PCB editor, verify everything OK using it and the 3D viewer
  3. I defined a rectangular board just to put in all the components
  4. I saved the PCB appending -1 and -2 for the 2 different boards using “Save As…”
  5. Kicad (I didn’t) created 2 more projects with the same name of the 2 boards so now I have the original project and -1 and -2 projects. The original project has the electrical schematic and the “original” PCB layout I used only to verify that components were OK.
  6. -1 and -2 projects have only the respective PCB layout schematic but not the electrical schematic if I try to open EESchema it says there is no electrical schematic in that project and if I want to create it.

So, until now, I worked opening the electrical schematic without any regard of the parent project and I was able to route the 2 boards but without many of the Kicad helpful features. Opening with an editor the 3 projects (.pro) I can read that in the area of the electrical schematic are reported the same original files but anyway if I try to open the buttons for them in the Kicad project manager it asks if I want to create them because are missing.

The basis of KiCad is: one project = one schematic = one PCB.
If your schematic is mature enough, copy it to a new directory and open a second project for a second PCB. It’s simple.

OK, clear but why the projects created by Kicad itself have inside the reference of the original schematic and then it does not open it? I mean the 2 projects it created after I saved the PCB layout file with 2 more file names. Look:

-2:
“sheets”: [
[
“5326f5a5-b50c-4a35-9684-3ae6a8cb6e9b”,
“”
],
[
“6ab3a980-597b-49ae-95be-f0e018b08c5b”,
“ESP32 Main MCU”
],
[
“d031a1dc-2925-4ed1-bc70-165742cf60a5”,
“Proximity Sensing”
],
[
“52ecfb5f-5184-47f5-be1f-786af396f234”,
“Audio DAC”
]
],
“text_variables”: {}
}

-1:
“sheets”: [
[
“5326f5a5-b50c-4a35-9684-3ae6a8cb6e9b”,
“”
],
[
“6ab3a980-597b-49ae-95be-f0e018b08c5b”,
“ESP32 Main MCU”
],
[
“d031a1dc-2925-4ed1-bc70-165742cf60a5”,
“Proximity Sensing”
],
[
“52ecfb5f-5184-47f5-be1f-786af396f234”,
“Audio DAC”
]
],
“text_variables”: {}
}

original:
“sheets”: [
[
“5326f5a5-b50c-4a35-9684-3ae6a8cb6e9b”,
“”
],
[
“6ab3a980-597b-49ae-95be-f0e018b08c5b”,
“ESP32 Main MCU”
],
[
“d031a1dc-2925-4ed1-bc70-165742cf60a5”,
“Proximity Sensing”
],
[
“52ecfb5f-5184-47f5-be1f-786af396f234”,
“Audio DAC”
]
],
“text_variables”: {}
}

I forgot to say that Kicad netlist file contain the scheatic file name and sheets ID and names so the PCB schematic layout knows who is its parent, should not be so difficult to link schematics and PCB schematic in a relation one to many. And it should be very useful.

Hi, which kicad version? (You mentioned netlist file, and I haven’t ever needed these files while using v5, v6 and v6.99)

I am using rel. 6.0.8. Kicad EEschema makes netlist.ipc file that is in the right format for the PCB Editor. You may use it if your PCB design is not “linked” to a corresponding electrical schematics as in my case, normally you do not need it because you can work in PCB Editor just clicking a button.

Thank you for explanation :slightly_smiling_face:

You’re welcome, probably you already knew what I wrote, the text reflects my perplexity about the Kicad assumption 1 schematic → 1 pcb layout that is not reflected in the contents of .pro and .kicad_pcb files.

Simple to do with some file renaming:
Create your schematic → project.sch
Create first pcb → project.kicad_pcb
rename project.kicad_pcb → pcb1.kicad_pcb
create second pcb → project.kicad_pcb
Do later changes: rename project.kicad_pcb->pcb2.kicad_pcb

Yes, I did that but the link between the schematic and the PCB is valid only for the 1st PCB, not for the others. Until I do not add or remove parts on the PCBs but I manage them on the schematic I thought it had to work. I thought about mechanical parts that many times we add at PCB design level but I manage them (also holes) at schematic level.

Just create a base project for the SCH, no PCB.
Then create 2 projects. Each project has a top SCH that uses the first one (using a hierarchical sheet). And its own PCB.

2 Likes

Unfortunately, KiCad provides no mechanism to have multiple PCBs in a single project. KiCad 6 actually reinforced this as it was sorta possible to do in KiCad 5 but KiCad 6 overwrites files, preventing this.

Hopefully a future version of KiCad will allow multiple schematics and multiple PCBs to coexist, but for now, you’ll have to create separate projects, separate folders, etc. and maintain separately.

Others are right. In all the software I have used over the years, it is one schematic and one board. If you want two boards, copy and rename the schematic and make a board for it. They won’t collide on parts, it knows what parts you used on which board. You can call one, “Left…” and the other one, “Right…” or whatever.

This video on schematic sheets in Hierarchical designs has examples that might suggest ways to manage with one schematic multiple PCBs.

1 Like

As I’ll be exploring something related I created a very simple example of 1 schematic with 2 different PCBs.

The idea is simple, we have 1 real schematic and two projects that just uses a hierarchy to include the real one. For ilustration our PCBs will be one circular and the other rectangular. Here are the schematics (almost identical, just different root sheet)

  1. Schematic.pdf (23.9 KB)

  2. Schematic.pdf (23.0 KB)

But here are the PCBs:

  1. PCB_1-assembly.pdf (72.3 KB)

  2. PCB_2-assembly.pdf (64.0 KB)

And their render:

1:


2:


Here are the KiCad projects: 1_SCH_2_diff_PCBs.zip (23.5 KB)

And the KiBot config I used to generate the above files:
simple.kibot.yaml (1.6 KB)

The files are in the KiBot repo

3 Likes

Until now it is the best workaround.

This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.