13
\$\begingroup\$

How can I implement a common sub-circuit which gets used in multiple places in a schematic with KiCAD 5, so that when only one instance gets edited all the other places it appears are automatically updated? Not by manually repeated copy/pasting.

Example:

multiple duplicate sub-curcuits

\$\endgroup\$
5
  • \$\begingroup\$ Have you done this in KiCad 4 and now it doesn't work in KiCad 5? \$\endgroup\$
    – pipe
    May 24, 2018 at 11:57
  • \$\begingroup\$ No. I use the nightly builds of KiCad 5 which is almost ready for release and don't use the current release KiCad 4, which will soon be redundant. \$\endgroup\$
    – Rob Kam
    May 24, 2018 at 13:58
  • \$\begingroup\$ I'm just wondering because I've done this many times in KiCad 4, and can't remember any difference in version 5. \$\endgroup\$
    – pipe
    May 24, 2018 at 14:01
  • 1
    \$\begingroup\$ @pipe so maybe the question is in reality how to do it in KiCad instead of how to do in in version 5... \$\endgroup\$
    – Arsenal
    May 24, 2018 at 14:09
  • \$\begingroup\$ I am trying to avoid answers which apply only to v4. \$\endgroup\$
    – Rob Kam
    May 24, 2018 at 14:34

2 Answers 2

16
\$\begingroup\$

What you are looking for are sub-sheets (hierarchical sheets).

First, create a new one by going to "Place->Hierarchical Sheet". Once you click to place it, you will have the following dialog.

Hierarchical Properties

Here, the important thing is the "File name". This will be common for all of your copies of the buffer. The "Sheet name" will be unique for each copy.

Then, double-click to enter the sheet and place the common components similar to what I show here:

Example Buffer

The important point in the internals is to use hierarchical labels (again from the "Place" menu). These will be the ports that connect the internal to the external wires. I've labeled "In" as an Input Pin and "Out" as an Output Pin. Don't worry about annotating right now.

Next, right click and leave your hierarchical sheet. Now, you have one copy of the sheet. You now need to import the hierarchical labels. Again from the "Place" menu, choose "Import Hierarchical Label" to get the hierarchical pins you created. Place the input pin on the left and the output pin on the right as shown:

Multiple Buffers

Now you can make as many copies of the hierarchical sheet as you need, just keep the file name the same for each and give each one a new sheet name.

\$\endgroup\$
2
  • 1
    \$\begingroup\$ This deals with the schematic part. What about the layout part? \$\endgroup\$
    – ndim
    Aug 5, 2018 at 17:49
  • 3
    \$\begingroup\$ For pcbnew, you'll need to use a plugin to achieve this. I like Mitja Nemec's "Replicate Layout" plugin from github.com/MitjaNemec/Kicad_action_plugins \$\endgroup\$
    – Seth
    Aug 5, 2018 at 21:34
5
\$\begingroup\$

@pipe so maybe the question is in reality how to do it in KiCad instead of how to do in in version 5...

Of course. Up to now, I see there no great differences between Rev. 4 and 5. Maybe you got a bad nightly build.

For reusing subchematics at KiCad I wrote a tutorial, which can be found here:

https://www.mikrocontroller.net/wikifiles/a/ab/HierarchicalSchematicsAsBuildingblocksAtKiCad_RevC-EN_06May2015.pdf

\$\endgroup\$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.