Schematic hierarchial structure

When I started the project I wasn’t thing about the structure of the schematic hierarchical structure and when I have adding new sheets they have end up it a bit of a mess.

What I should have now is perhaps the PSU as the “root” schematic and the others that relied on of the PSU from stem to that.?

How do I restructure the hierarchical structure or must I start again?

KiCAD_Nixie_schematic_hierarchial

You can simply Ctrl X / Ctrl V sheets to other places wherever you like. It is basic stuff, dont be afraid to click on things and try things out. You can always do Ctrl Z and undo any unwanted actions. KiCad schematics work quite intuitive imo.

:coffee: Bas

Thank you. That sounds simply but use CNTL-X and CNTL-V at what page in the structure? In the structure window or on the structure in the sheet?

Well don’t feel too constrained by the hierarchy. The schematic evolves.

My workflow is to first pick landscape or portrait and to use a titleblock format I like (I always use us-letter as I want to print it now and then and big page sizes are stupid :slight_smile: ). It will take as many pages as it takes.

Then I draw a rectangle of no particular size on the root sheet and call it something like “Expansion Sockets.” I go into that new sheet and fill the page with a schematic. I use global power symbols and hierarchical labels into and out of the sheet. I never use global labels. Once I get a page filled with some part of the circuit I go back to the root and pull all the hierarchical labels into the little sheet block and resize it a bit as needed. No point in worrying about size of the block or label placement just yet as the Root sheet is the last thing to finish. Create another new sheet, name it, edit and fill it, pull the labels on root…

Periodically I go to the pcb and update from schematic. I do this at strategic points so the little group of new parts can be plopped in different spots around where the board will be. I don’t even have a board outline yet as I am just working my way through adding schematic sheets and plopping little clusters of parts on the pcb. Those clusters of related parts can be routed as little nuggets before moving them into position. If you wait until the end of schematic capture to generate the pcb, you will get one shitload of parts mashed together that will take ages to drag out and sort.

At various points I will go route some of the nuggets on the pcb and just leave them outside the board area a bit. At another point I will start a corner of the board (lower-left if it is a good place to start, as I will zero my grids there, and use Y-positive-up like any sane person would do). Then add a mounting hole and start placing connectors on the edge. I do as much of the board perimeter as makes sense, and I often find that the center of the board is the last thing I do. Depends of the design of course, but this ramble is one possible way to do things.

Another thing that I find handy is to not wire the root until I get all the blocks (sheets) done, and I can figure out the best way to arrange them for interconnect. That can be a challenge and using buses can keep clutter down or separate signals may be just fine. Another plus to not yet connecting on root is that the ratsnest on pcb is much simpler. This lets you rout those little circuit nuggets (eg: adc and related parts) with minimal distraction. Here is an example of a board I am doing now – the root sheet is finally in good shape as far as sizing the blocks, arranging the labels for interconnect, and verifying label directions (which often need toggled). No buses on this one. A few of these pages are finished and routed, some are still in process, and one is actually still blank – but I put the hierarchical labels in it so I could get the root making sense with all of the sheets and signals.

With the root unwired, I will route as much as I can, and place as much into final position, and then wire up the root for the rest of the routes.

1.pdf (116.2 KB)

Bas is just pointing out that you can easily cut (or copy) bits of a schematic from one page to another. So if a sheet is getting crowded with four nixies, maybe create another sheet and cut two of them out and paste into another page of the schematic. It is easy editing.

Also, you said “perhaps make the PSU root…” but the root page is best used, in my opinion, as just a collection of interconnected sheets. It then is a nice block diagram of the board. If the project is large it gets challenging to manage a lot of sheets – busses will simplify the visual clutter of separate wires. You will have some “main” sheet of some sort, whether you consider it to be the power supply, microcontroller, or whatever. This is also a good place to tuck things like mounting hole symbols (with grounds as needed). Sometimes an “other” page is a place to put misc stuff like mounting holes, plug-in modules, heatsinks, hardware. You need some simple symbols for these of course, but all of these little non-soldered parts on this page will end up in the bom, which ties things together nicely.

That sounds simply but use CNTL-X and CNTL-V at what page in the structure?

I was specifically talking about cutting/pasting the sheets instead of the content. But this is imo not even KiCad related as it is kinda basic every computer operation. It is the same as in word.exe or paint.exe

Just go try and do things. Select a sheet, Ctrl X the sheet, go to the root and hit Ctrl V to paste the sheet.

I pretty much have the same workflow as teletypeguy with the addition that I reuse parts of boards as well. But this is ofcourse project related.
I have a detailed explanation as well. I have not ever used the style sheet tho, bad practice perhaps. But I don’t print or collaborate with my designs.

I also need sheets in order to use the replicate layout plugin.

One of my latest designs. I also use dummy symbols and additional graphics so one can see in an instance where the connectors to the outside world are. So DC jacks, screw terminals, OLED, RJ12 connectors. All is there. I even try to place schematic sheets on the same places as the content will be in the board design.

Anything with 2 or more connections, gets a bus.

Kind regards,

Bas

So OK I can cut and paste as I want, but in basics how do a make a root schematic as a link to the other pages and not of the PSU in the root page? I must be missing here. My you, I have had a double stroke and so understanding all the points above is difficult. :frowning:

You can read the manual for the use of hierarchical schematics:

You can make connections between sheets and “daughter sheets” as shown in the screenshot from bask185, but there is no similar way to make such links to sheets on the same hierarchical level.

What you can do is use global labels. A power supply is an important part of any electronic design, but traditionally it is not put at the root of the hierarchy. The power supply is so ubiquitous that it is usually just connected with global labels or power symbols. Power symbols are very much alike global labels in KiCad. They just have some extra graphics to put a bit more emphasis on them, but the function is very similar. As long as there are no multiple isolated power supplies, there is not much need to put emphasis on power distribution in the schematic. It’s just simple and straightforward.

As long as you only have a schematic it’s easy to cut and paste to move things to other pages, once you have a PCB, (and links to footprints on the PCB) it becomes more complicated.

When you are designing your hierarchy it can be a bit of a struggle on how to divide stuff over pages. Usually the microcontroller is quite high in the hierarchy, because it has connections to a lot of other parts of the schematic. To design your hierarchy, it may help to simply print out all the pages, cut them to pieces and lay them next to each other on your desk. This helps to get an overview of your design.

1 Like

Bas: I like the connector symbols in the sheet blocks – nice touch. Gotta ask: what is a frogJuicer? Sounds messy :slight_smile:

I make stuff for the model railway folks. That center part of a turnout or point is what we call a ‘frog’. The frog needs to be ‘juiced’ (polarized) depending if the point is set straight or turnout. The center piece gets tied to either the left or the right rails. Or in other words: the frog gets juiced.

This can be done by setting a physical relay, but a typical frogJuicer circuit works by detecting a short circuit. This happens when a train drives over the frog when it is polarized wrong. Via means of mosfets the frog may be switched soo fast so that the rest of the layout remains unaffected. The short typically lasts shorter than 1ms. Some circuits even switch in the order of nano seconds.

Ahh, that’s interesting.

When I saw “frog-juicer” I had a flashback to Dan Akroyd’s Bass-o-Matic sketch:
https://www.youtube.com/watch?v=2HKTx5WFcs0

Thank you for everyone who shared their experiences and working to arrange the hierarchical sheets. I didn’t realise how relative it was easy. I was worried about losing the PCB layout.

Now that I have taken PSU out of the root, and leaving that sheet to the sheets links, how do I organise the sheets that they are in an “organised” or “logical” arrange?

KiCAD_Nixie_schematic_hierarchial

If you look close at my example, you’ll see that the power sheet has no hierachial labels. I use global power labels.

I did use hierachial power labels once. The idea was that I could see better where 12V, 5V and GND went to. But it didn’t improve readability that much and the power is often implied.Therefor I deemed that global power labels were good enough.

how do I organise the sheets that they are in an “organised” or “logical” arrange?

The main aim of hierarchial labels is readability above all else. Otherwise we would all be using global labels everywhere.

So just think logically and draw hierarchial busses and wires where you deem needed. You haven’t shown a schematic. But I see nixie tubes. So I googled (never touched nixies meself) and I would place one nixie tube in the schematic sheet. I would use a bus with 4 lines A, B, C and D (or 1 - 4 for vector busses)

Than Ctrl C and Ctrl V the schematic sheet, for every nixie tube that you have. The sheets share the same schematic, it is just like with Object Orientated programming, one class → several objects.

On the ESP side you can use a prefices to make more than 1 nixie bus. Than draw the busses.

See the manual for more stuff about busses:

Something like this

ESP sheet:

Nixie sheet:
afbeelding

When making the board, you can check the airwires if the connections are there. And run the ERC. It is easy to make a mistake and miss the connections.

Regards,

Bas

1 Like

I’d love to see pics of your project. You got me interested in digging out my boxes of nixies that I collected years ago. I have always wanted to do some projects with them and now you got me thinking. I also found some bar-graph tubes, dekatron tubes (circle of dots), some VFDs (love the blue-green glow and voltages are lower), and even some Burroughs B-7971 giant 14-seg alphanumeric tubes I think they used for stock market displays way back when. They called those nixie tubes also (same neon glow), though I always considered a true nixie to have the individual digit segments.

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