Net classes across the hierarchical sheets

Hi

How can I apply net classes across all hierarchical sheets?

It seems I cannot select multiple nets and apply a net class I have to apply net classes one at a time to just one net at a time.

Once I have gone through and added net classes they are then not replicated on hierarchical sheets.

This seems quite labour intensive and I feel sure I am missing something.

Thanks

I’m not quite sure what workflow you’re using - can you share some screenshots (or a video) to show what you’re doing?

Hi,

Just tried a video screen capture but oddly not recording popup menu so limited use!

Let me try again explaining.

I am working on improving a layout and I have several hundred Via’s

Area’s in red need to look a lot more like the areas in orange…

I wondered if there was any way to bulk edit Via’s (edit track and via properties) - Net classes.

I have all my nets labelled but I did not have them in classes.

I started by trying to group-select nets in my schematic thinking I could right click and ‘Assign Netclass’

When I select more than one net, of different net names, the option to assign netclass is not in the right click menu.

If I select a single net the option is there - meaning I need to assign a net class to one net at a time.

I did all this on my first channel and as you can see the outputs from the sheet are all in the colour of the assigned netclass, same is true of all other net classes within the channel 1 sheet.

Channel 2 onward has not picked up the assigned net classes - which being hierarchical I expected

So I am wondering how the feature works, if I want to use net classes to achieve automated options in the Edit track and via properties dialog, do I have to assign a netclass to every single net one at a time?

Thanks

Okie dokie. Netclasses are a property of the net, and each of your nets in the hierarchy has a different name, so this behaviour is correct.

There is a way to allocate nets to multiple netclasses though - take a look at schematic rule areas: Schematic Editor | 9.0 | English | Documentation | KiCad

(Although I can’t remember if I tested this with hierarchical pins / global labels - if the rule areas don’t work if you enclose the labels, just add a wire between each pin and label and it should work then)

What I’d probably do is use a schematic rule area to assign the netclass inside the hierarchical sheet. In that case, every net in every instance of the sheet will get the netclass. Like this (NETCLASS is set to red wire color):

Chanel shared sheet:

Root sheet:

1 Like

Thanks

I think this works for me, the learning curve is steep at the moment!

1 Like

Ha think I spoke too soon!

I just did the rule area and assigned the netclass, all my Grounds schematic wide picked up the class as I have a few Gnd’s within the rule area.

I might need to find a better solution.

I wonder if it might be better for it to be the other way around - as in a Netclass has many nets, in the same way a class of people or a school/uni class has many differences.

I had initially assumed it was this way but maybe there is another intended use for net classes that means they cannot be added by group selecting nets.

Thanks

You can just use netclass directive labels on each net in the hierarchical sheet to avoid the ground nets:

In terms of your group selection point… There are two way to assign netclasses to nets: Use net directive labels, or set up netclass pattern assignments. The context menu option to set up netclass assignments is just a shortcut for a pattern assignment. (Open up the schematic setup dialog and you’ll see the entries):

The fact the menu option is not implemented for multiple selections is just a UI limitation - you could file a feature request on gitlab for this.

1 Like

I’m not so sure about that. In your screenshot, you show Channel_1 in the pattern:

image

But the patterns support wildcards. So I suppose you can use a wildcard to select all the channels at once for assigning a net name, but I have not tested this explicitly.

1 Like

Yeah the screenshot only shows the result of the UI interaction - you are quite right in that one can replace the /Channel_1/NET_2 with /Channel_*/NET_2 and it works for all sheets:

1 Like

Hi

@paulvdh @JamesJ thanks for the help here guys really appreciate it.

I’m not on gitlab so the UI feature request might have to wait, that said the wild card route is good enough for cutting down the work!

Cheers