This affects also the outer edge, not just the holes, so that’s no option.
Definitely.
I’ve tried that. But I need to create each shape twice, once for the hole and then a second time for the margin. That’s much more work compared to the old version. And I ran into the problem that in contrast to the board edge lines, the inside of the shape is not ignored and filled with copper, see the example here:
Then the real board edge was made a bit thicker so the rule doesn’t apply to the board edge. I could not change the line width of the mounting hole, but I’ll create another thread for that.
I’ve tried that. But I need to create each shape twice, once for the hole and then a second time for the margin. That’s much more work compared to the old version.
you have not to draw a second “margin”-shape. You can copy the existing “hole”-outline to the margins-layer (better: don’t copy, use “Create polygon from selection”, this will set directly the correct layer) and change the line-width of the margins-polygon to 2.8mm.
How to modify the rule so that routing tracks in that area is not allowed –or if that’s not possible– at least a DRC error is produced? I found the “disallow” keyword, but don’t know how to apply it to this case. rule.kicad_pro (9.0 KB) rule.kicad_pcb (26.5 KB) rule.kicad_dru (131 Bytes)
As a last(?) resort you can draw a circle, use RMB on it, use Create from Selection context menu item → Create Rule Area. Press Del to delete the original circle. Now you have a circular rule area (keep out zone). This works even with other closed shapes made of arcs and lines.
I can’t, because the mounting holes are in a group and I can’t select the tracks when I entered the group. And when I delete the group, the clearance is different, that’s the whole point of having the group.
I had the files attached a few posts prior, so you can try for yourself. If there’s a way to select one grouped and one non-grouped component, please let me know.
I can’t, because the mounting holes are in a group…
Well, now that’s annoying. I’m not coming up with any easy solutions either.
Anyway, the problem is probably that clearance is an electrical clearance, and a NPTH mounting hole has no electrical potential. Try hole_clearance or edge_clearance (either should work).
I have tried that: hole_clearance only affects the hole and edge_clearance affects only the board edge. Using just “clearance” both are affected (the desired outcome).
[quote=“JeffYoung, post:14, topic:34662”]
Anyway, the problem is probably that clearance is an electrical clearance, and a NPTH mounting hole has no electrical potential.[/quote]
The problem is that tracks can be routed close to the mounting hole, in the area that should be kept empty. KiCAD is happy to route tracks in this area (and not even trigger a DRC warning). That is the actual issue here:
Note that the DRC warning here is not the trace but the mounting hole. Remove the trace and you’ll still get the DRC warning. I need it the other way round. Mounting holes close to the board edge are perfectly fine and should not trigger a DRC warning. But I don’t want traces or copper pours close to the mounting holes.
So all in all this does not solve the problem of routing traces within the clearance area.
In the latest (self compiled) 6.99 (NOT 7.0 although Jeff said so!) there are no problems, it works now as expected. 6.0 is of course a different story.