KiCad Hierarchical Sheets for Enhanced Schematics

By Jeremy S. Cook

Freelance Tech Journalist / Technical Writer, Engineering Consultant

Jeremy Cook Consulting

April 28, 2022

Blog

For simple KiCad circuit designs, a sheet with lines going from one component to another is good enough. Add in net labels, and slightly more complicated drawings can be cleaned up nicely. At some point, however, your design may become too large to fit onto a standard sheet. You’re faced with a choice: expand the sheet to cover more area–useful, but often clumsy–or break schematic data up into a series of linked hierarchical sheets.

What Are Hierarchical Sheets?

Hierarchical sheets, in the context of KiCad, are interrelated schematic pages that work in a similar manner to a computer’s directory structure. Typically a top sheet would link a number of lower-level sheets, which can reference lower-level sheets of their own and so on. Such an organization can make a potentially massive design manageable.

Caption: A work-in-progress top-level hierarchical sheet, and one of its lower-level sheets

Image Credit: Screencap

Hierarchical Linking Concepts

Lower-level sheets are laid out as components on a higher-level drawing and linked together with the help of labels. KiCad features three different types of labels:

  • Net Label – Used to organized and link signals within a single sheet
  • Global Label – Apply to every sheet within a design
  • Hierarchical Label – Applied within a sheet, used for linking between sheets

In the schematic above (which is still a bit of a work-in-progress), LEDPWR is designated as a global label and is used in every sheet. The digital_in and digital_out hierarchical labels allow signals to be passed from sheet to sheet on the top-level sheet. The dev board and various connectors are explicitly broken out on the top sheet, but could also be placed on a lower-level sheet.

Alternatively, this schematic could have been drawn on one sheet. Shown below is an even earlier version of the pictured design that was thankfully never finished. Inelegant to say the least:

Caption: Early non-hierarchical layout

Image Credit: Screencap

Hierarchical Commands: Getting Started

To get started with hierarchical sheets, the shortcut s allows you add a lower-level hierarchy sheet to a schematic, or there’s an icon in the sidebar. Draw a box, then name the sheet, and the sheet file. Double-click to enter this new sheet, where you can add components, connections, and more sheets as needed. You can also add hierarchical labels with the shortcut h or icon. Right click and select Leave Sheet to return to the higher level.

To access hierarchical labels created in a lower level, right-click on the sheet icon, then Import Sheet Pin. With the pins visible, you can link inputs and outputs between lower sheets, along with the current layer. Global labels can be applied to any sheet without an explicit connection, and net labels are there if needed, for connections within a sheet.

Caption: Icons, from top to bottom: net label, global label, hierarchical label, hierarchical sheet, import hierarchical sheet pin.

Image Credit: Screencap

Lower-level sheets can be duplicated in a drawing in the same manner as components (cmd-d or cmd-c, cmd-v on a Macintosh), but note that on-sheet copies will be the same file with a different sheet name. Therefore, any changes will be applied across sheets that use the same file, even if the individual name is different. It’s a great way to simplify the design process, but something that you’ll need to be aware of. Sheets can also be copied and reused across projects.

Hierarchical Sheets: Simplifying and “Elegantizing” Your Design

While you could expand a single sheet to fit things as needed, this type of organized multi-sheet arrangement can be extremely helpful for project organization. For a visual demonstration of how this works (in the context of KiCad 5), Chris Gammel of Contextual Electronics presents a nice overview of this feature in the video below:

Jeremy Cook is a freelance tech journalist and engineering consultant with over 10 years of factory automation experience. An avid maker and experimenter, you can follow him on Twitter, or see his electromechanical exploits on the Jeremy Cook YouTube Channel!

 

Jeremy Cook is a freelance tech journalist and engineering consultant with over 10 years of factory automation experience. An avid maker and experimenter, you can follow him on Twitter, or see his electromechanical exploits on the Jeremy S. Cook YouTube Channel!

More from Jeremy