DRC does not report violation if via is placed inside pad
Description
Generally it is a mistake to put a via inside a pad. Solder gets wicked down into the hole, potentially leaving the joint with too little solder for a good connection. One common exception would be thermal/die-attach pads on many QFN packages, because there is just so much solder and pad area available, but the point holds.
At the moment the DRC doesn't notice vias accidentally placed inside the pad metal areas, provided the via has the same net name as the pad.
There is a technology called "Via-in-Pad", which is used in high density designs. Here the vias are filled with conductive epoxy (or sometimes non-conductive), and capped with copper plating. It shouldn't be used unless its needed, of course, because it adds time and cost to the fabrication.
Therefore, by default, the Kicad DRC should assume that you don't want Via-in-Pad, and alert you if one of your vias has strayed into a pad.
I just sent a board off for production, and the board house came back asking me if I wanted a Via-in-Pad process as I had a few vias that had strayed into the pads of some SMD caps!
Steps to reproduce
- Go to File -> Board Setup -> DRC -> Violation Severity. Set every violation to be an Error.
- Lay out the simple board as shown in this attachment. Note that Pad2 and the via are both connected to the GND net. The GND zone on B.Cu is required to prevent an error due to the via only being connected on one side.
- Run the DRC. You'll see it reports 0 Errors and 0 Warnings.
KiCad Version
Application: KiCad PCB Editor
Version: 5.99.0-1.20210520gite8102d8.fc33, release build
Libraries:
wxWidgets 3.0.5
libcurl/7.71.1 OpenSSL/1.1.1k-fips zlib/1.2.11 brotli/1.0.9 libidn2/2.3.0 libpsl/0.21.1 (+libidn2/2.3.0) libssh/0.9.5/openssl/zlib nghttp2/1.43.0
Platform: Linux 5.11.18-200.fc33.x86_64 x86_64, 64 bit, Little endian, wxGTK, sway, wayland
Build Info:
Date: May 20 2021 17:26:52
wxWidgets: 3.0.5 (wchar_t,wx containers,compatible with 2.8) GTK+ 3.24
Boost: 1.73.0
OCC: 7.5.0
Curl: 7.71.1
ngspice: 33
Compiler: GCC 10.3.1 with C++ ABI 1014
Build settings:
KICAD_SCRIPTING=ON
KICAD_SCRIPTING_MODULES=ON
KICAD_SCRIPTING_PYTHON3=ON
KICAD_SCRIPTING_WXPYTHON=ON
KICAD_SCRIPTING_WXPYTHON_PHOENIX=ON
KICAD_SCRIPTING_ACTION_MENU=ON
KICAD_USE_OCC=ON
KICAD_SPICE=ON