EESchema ERC does not flag unconnected hierarchical pins

Bug #1781725 reported by Victor W on 2018-07-14
10
This bug affects 2 people
Affects Status Importance Assigned to Milestone
KiCad
Medium
Jon Evans

Bug Description

When running ERC on EEScheme, it is possible for exposed hierarchical sheet pins to be unconnected on either the top level or child sheets, without triggering a ERC error.

More specifically, it appears there is no check to confirm that an exposed port is electrically connected across a top level sheet and a child sheet. This can result in parts of the design not being connected.

===
Example 1:

1. On the top level sheet of a hierarchical design, add a child sheet, with some ports.

2. Pick a port that is connected (within the child sheet) to at least two pins. For example, select an IO port that connected within the child sheet to a capacitor and to the input port of an IC.

3. On the top level sheet, delete all connections to that port (the net to the port should be floating).

4. Run eeschema DRC.

===

RESULT:

1. No errors or violations will be noted.

===

Expected:

1. I expect that unconnected sheet ports are flagged; if we've exported them to a sheet, then that sheet should be treated similarly to a symbol; unless you deliberately place an NC on that pin, then it's clear the port should be connected somewhere else in the schematic.

2. It is also possible for this to result in missed connections between child and parent sheets; if the top level net on the parent sheet is otherwise connected (or passes the DRC checks), and the port within the child sheet is unconnected, this also does not flag a DRC check.

===

Note that there already exists a specific error in the event sheet pins are not synchronized (ie; ErrType(6): Mismatch between hierarchical labels and pins sheets), though there is no error if the hierarchical labels or pin sheet are not connected.

===

Version Information

Application: eeschemather
Libraries:
    wxWidgets 3.0.4
    libcurl/7.60.0 OpenSSL/1.1.0h zlib/1.2.11 libidn2/2.0.5 libpsl/0.20.2 (+libidn2/2.0.4) nghttp2/1.32.0
Platform: Linux 4.17.4-1-ARCH x86_64, 64 bit, Little endian, wxGTK
Build Info:
    wxWidgets: 3.0.4 (wchar_t,wx containers,compatible with 2.8) GTK+ 2.24
    Boost: 1.67.0
    OpenCASCADE Community Edition: 6.9.1
    Curl: 7.60.0
    Compiler: GCC 8.1.1 with C++ ABI 1012

Build settings:
    USE_WX_GRAPHICS_CONTEXT=OFF
    USE_WX_OVERLAY=OFF
    KICAD_SCRIPTING=ON
    KICAD_SCRIPTING_MODULES=ON
    KICAD_SCRIPTING_WXPYTHON=OFF
    KICAD_SCRIPTING_ACTION_MENU=ON
    BUILD_GITHUB_PLUGIN=ON
    KICAD_USE_OCE=ON
    KICAD_USE_OCC=OFF
    KICAD_SPICE=ON

tags: added: eeschema erc
Seth Hillbrand (sethh) wrote :

This is a valid request. I think the correct approach to implement is 1) check for unexposed hierarchical pins and 2) check that hierarchical pins are either NC'd or connected at the top level. This should also fix lp:1747310

Changed in kicad:
importance: Undecided → Medium
milestone: none → 6.0.0-rc1
status: New → Confirmed
Victor W (vicw) on 2018-07-17
description: updated
Rene Poeschl (poeschlr) wrote :

The same is true for power symbols and global labels.
For power symbols there exists this report: https://bugs.launchpad.net/kicad/+bug/1639400

Armin (ard2) wrote :

Today this hit me as well. I had not connected 2 global labels (SCL and SDA) to a connector and of cause, my i2c device did not work very well.
Would really help if ERC could at least warn here (like it does on other unconnected pins without the "not connected" symbol attached)
Someone could say that this is visible in the schematic and this is correct but can be easily overseen as i did.

Yanick Poirier (ypoirier) wrote :

I can confirmed this. It seems that no ERC is performed on hierarchical pins. I have an output pin of a chip connected to an output hierarchical pin and the sub-sheet has that same output hierarchical pin connected to an input of the MCU. No ERC error.

Application: kicad
Version: 5.0.0-fee4fd1~66~ubuntu16.04.1, release build
Libraries:
    wxWidgets 3.0.2
    libcurl/7.47.0 OpenSSL/1.0.2g zlib/1.2.8 libidn/1.32 librtmp/2.3
Platform: Linux 4.8.0-53-generic x86_64, 64 bit, Little endian, wxGTK
Build Info:
    wxWidgets: 3.0.2 (wchar_t,wx containers,compatible with 2.8) GTK+ 2.24
    Boost: 1.58.0
    OpenCASCADE Community Edition: 6.8.0
    Curl: 7.47.0
    Compiler: GCC 5.4.0 with C++ ABI 1009
Build settings:
    USE_WX_GRAPHICS_CONTEXT=OFF
    USE_WX_OVERLAY=OFF
    KICAD_SCRIPTING=ON
    KICAD_SCRIPTING_MODULES=ON
    KICAD_SCRIPTING_WXPYTHON=OFF
    KICAD_SCRIPTING_ACTION_MENU=ON
    BUILD_GITHUB_PLUGIN=ON
    KICAD_USE_OCE=ON
    KICAD_USE_OCC=OFF
    KICAD_SPICE=ON

SysInfo:
Linux Mint 18.2 Sonya XFCE

Rene Poeschl (poeschlr) wrote :

Labels are now also reported here: https://bugs.launchpad.net/kicad/+bug/1802008

Jon Evans (craftyjon) on 2019-04-01
Changed in kicad:
assignee: nobody → Jon Evans (craftyjon)
To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers