diff --git a/qa/data/complex_hierarchy.kicad_prl b/qa/data/complex_hierarchy.kicad_prl index 2c0f55376e..262356faf1 100644 --- a/qa/data/complex_hierarchy.kicad_prl +++ b/qa/data/complex_hierarchy.kicad_prl @@ -57,8 +57,8 @@ 28, 29, 30, - 36, - 37 + 37, + 38 ], "visible_layers": "007ffff_ffffffff" }, diff --git a/qa/data/complex_hierarchy.kicad_pro b/qa/data/complex_hierarchy.kicad_pro index f3a493b081..09ff48ad10 100644 --- a/qa/data/complex_hierarchy.kicad_pro +++ b/qa/data/complex_hierarchy.kicad_pro @@ -108,6 +108,7 @@ "min_hole_to_hole": 0.25, "min_microvia_diameter": 0.508, "min_microvia_drill": 0.2032, + "min_silk_clearance": 0.0, "min_through_hole_diameter": 0.508, "min_track_width": 0.2032, "min_via_annular_width": 0.049999999999999996, diff --git a/qa/eeschema/data/netlists/bus_junctions/bus_junctions.kicad_prl b/qa/eeschema/data/netlists/bus_junctions/bus_junctions.kicad_prl new file mode 100644 index 0000000000..23e84c6d6f --- /dev/null +++ b/qa/eeschema/data/netlists/bus_junctions/bus_junctions.kicad_prl @@ -0,0 +1,72 @@ +{ + "board": { + "active_layer": 0, + "active_layer_preset": "", + "hidden_nets": [], + "high_contrast_mode": 0, + "net_color_mode": 1, + "opacity": { + "pads": 1.0, + "tracks": 1.0, + "vias": 1.0, + "zones": 0.6 + }, + "ratsnest_display_mode": 0, + "selection_filter": { + "dimensions": true, + "footprints": true, + "graphics": true, + "keepouts": true, + "lockedItems": true, + "otherItems": true, + "pads": true, + "text": true, + "tracks": true, + "vias": true, + "zones": true + }, + "visible_items": [ + 0, + 1, + 2, + 3, + 4, + 5, + 6, + 8, + 9, + 10, + 11, + 12, + 13, + 14, + 15, + 16, + 17, + 18, + 19, + 20, + 21, + 22, + 23, + 24, + 27, + 28, + 29, + 30, + 31, + 32, + 33, + 37, + 38 + ], + "visible_layers": "fffffff_ffffffff" + }, + "meta": { + "filename": "bus_junctions.kicad_prl", + "version": 2 + }, + "project": { + "files": [] + } +} diff --git a/qa/eeschema/data/netlists/bus_junctions/bus_junctions.kicad_pro b/qa/eeschema/data/netlists/bus_junctions/bus_junctions.kicad_pro new file mode 100644 index 0000000000..6e2ce4e318 --- /dev/null +++ b/qa/eeschema/data/netlists/bus_junctions/bus_junctions.kicad_pro @@ -0,0 +1,261 @@ +{ + "board": { + "layer_presets": [] + }, + "boards": [], + "cvpcb": { + "equivalence_files": [] + }, + "erc": { + "meta": { + "version": 0 + }, + "pin_map": [ + [ + 0, + 0, + 0, + 0, + 0, + 1, + 0, + 0, + 0, + 0, + 2 + ], + [ + 0, + 2, + 0, + 1, + 0, + 1, + 0, + 2, + 2, + 2, + 2 + ], + [ + 0, + 0, + 0, + 0, + 0, + 1, + 0, + 1, + 0, + 1, + 2 + ], + [ + 0, + 1, + 0, + 0, + 0, + 1, + 1, + 2, + 1, + 1, + 2 + ], + [ + 0, + 0, + 0, + 0, + 0, + 1, + 0, + 0, + 0, + 0, + 2 + ], + [ + 1, + 1, + 1, + 1, + 1, + 1, + 1, + 1, + 1, + 1, + 2 + ], + [ + 0, + 0, + 0, + 1, + 0, + 1, + 0, + 0, + 0, + 0, + 2 + ], + [ + 0, + 2, + 1, + 2, + 0, + 1, + 0, + 2, + 2, + 2, + 2 + ], + [ + 0, + 2, + 0, + 1, + 0, + 1, + 0, + 2, + 0, + 0, + 2 + ], + [ + 0, + 2, + 1, + 1, + 0, + 1, + 0, + 2, + 0, + 0, + 2 + ], + [ + 2, + 2, + 2, + 2, + 2, + 2, + 2, + 2, + 2, + 2, + 2 + ] + ], + "rule_severities": { + "bus_definition_conflict": "error", + "bus_label_syntax": "error", + "bus_to_bus_conflict": "error", + "bus_to_net_conflict": "error", + "different_unit_footprint": "error", + "different_unit_net": "error", + "duplicate_sheet_names": "error", + "global_label_dangling": "warning", + "hier_label_mismatch": "error", + "label_dangling": "error", + "lib_symbol_issues": "warning", + "multiple_net_names": "warning", + "net_not_bus_member": "warning", + "no_connect_connected": "warning", + "no_connect_dangling": "warning", + "pin_not_connected": "error", + "pin_not_driven": "error", + "pin_to_pin": "warning", + "similar_labels": "warning", + "unresolved_variable": "error", + "wire_dangling": "error" + } + }, + "libraries": { + "pinned_footprint_libs": [], + "pinned_symbol_libs": [] + }, + "meta": { + "filename": "bus_junctions.kicad_pro", + "version": 1 + }, + "net_settings": { + "classes": [ + { + "bus_width": 12.0, + "clearance": 0.2, + "diff_pair_gap": 0.25, + "diff_pair_via_gap": 0.25, + "diff_pair_width": 0.2, + "line_style": 0, + "microvia_diameter": 0.3, + "microvia_drill": 0.1, + "name": "Default", + "pcb_color": "rgba(0, 0, 0, 0.000)", + "schematic_color": "rgba(0, 0, 0, 0.000)", + "track_width": 0.25, + "via_diameter": 0.8, + "via_drill": 0.4, + "wire_width": 6.0 + } + ], + "meta": { + "version": 0 + }, + "net_colors": null + }, + "pcbnew": { + "last_paths": { + "gencad": "", + "idf": "", + "netlist": "", + "specctra_dsn": "", + "step": "", + "vrml": "" + }, + "page_layout_descr_file": "" + }, + "schematic": { + "drawing": { + "default_bus_thickness": 12.0, + "default_junction_size": 40.0, + "default_line_thickness": 6.0, + "default_text_size": 50.0, + "default_wire_thickness": 6.0, + "field_names": [], + "intersheets_ref_prefix": "", + "intersheets_ref_short": false, + "intersheets_ref_show": false, + "intersheets_ref_suffix": "", + "pin_symbol_size": 25.0, + "text_offset_ratio": 0.3 + }, + "legacy_lib_dir": "", + "legacy_lib_list": [], + "meta": { + "version": 0 + }, + "net_format_name": "Pcbnew", + "page_layout_descr_file": "", + "plot_directory": "", + "spice_adjust_passive_values": false, + "spice_external_command": "spice \"%I\"", + "subpart_first_id": 65, + "subpart_id_separator": 0 + }, + "sheets": [ + [ + "47d1867f-133f-4cc6-87f5-3b6d876726fe", + "" + ] + ], + "text_variables": {} +} diff --git a/qa/eeschema/data/netlists/bus_junctions/bus_junctions.kicad_sch b/qa/eeschema/data/netlists/bus_junctions/bus_junctions.kicad_sch new file mode 100644 index 0000000000..b99a4de15d --- /dev/null +++ b/qa/eeschema/data/netlists/bus_junctions/bus_junctions.kicad_sch @@ -0,0 +1,204 @@ +(kicad_sch (version 20201015) (generator eeschema) + + (page 1 1) + + (paper "A4") + + (lib_symbols + (symbol "Device:R" (pin_numbers hide) (pin_names (offset 0)) (in_bom yes) (on_board yes) + (property "Reference" "R" (id 0) (at 2.032 0 90) + (effects (font (size 1.27 1.27))) + ) + (property "Value" "R" (id 1) (at 0 0 90) + (effects (font (size 1.27 1.27))) + ) + (property "Footprint" "" (id 2) (at -1.778 0 90) + (effects (font (size 1.27 1.27)) hide) + ) + (property "Datasheet" "~" (id 3) (at 0 0 0) + (effects (font (size 1.27 1.27)) hide) + ) + (property "ki_keywords" "R res resistor" (id 4) (at 0 0 0) + (effects (font (size 1.27 1.27)) hide) + ) + (property "ki_description" "Resistor" (id 5) (at 0 0 0) + (effects (font (size 1.27 1.27)) hide) + ) + (property "ki_fp_filters" "R_*" (id 6) (at 0 0 0) + (effects (font (size 1.27 1.27)) hide) + ) + (symbol "R_0_1" + (rectangle (start -1.016 -2.54) (end 1.016 2.54) + (stroke (width 0.254)) (fill (type none)) + ) + ) + (symbol "R_1_1" + (pin passive line (at 0 3.81 270) (length 1.27) + (name "~" (effects (font (size 1.27 1.27)))) + (number "1" (effects (font (size 1.27 1.27)))) + ) + (pin passive line (at 0 -3.81 90) (length 1.27) + (name "~" (effects (font (size 1.27 1.27)))) + (number "2" (effects (font (size 1.27 1.27)))) + ) + ) + ) + (symbol "power:GND" (power) (pin_names (offset 0)) (in_bom yes) (on_board yes) + (property "Reference" "#PWR" (id 0) (at 0 -6.35 0) + (effects (font (size 1.27 1.27)) hide) + ) + (property "Value" "GND" (id 1) (at 0 -3.81 0) + (effects (font (size 1.27 1.27))) + ) + (property "Footprint" "" (id 2) (at 0 0 0) + (effects (font (size 1.27 1.27)) hide) + ) + (property "Datasheet" "" (id 3) (at 0 0 0) + (effects (font (size 1.27 1.27)) hide) + ) + (property "ki_keywords" "power-flag" (id 4) (at 0 0 0) + (effects (font (size 1.27 1.27)) hide) + ) + (property "ki_description" "Power symbol creates a global label with name \"GND\" , ground" (id 5) (at 0 0 0) + (effects (font (size 1.27 1.27)) hide) + ) + (symbol "GND_0_1" + (polyline + (pts + (xy 0 0) + (xy 0 -1.27) + (xy 1.27 -1.27) + (xy 0 -2.54) + (xy -1.27 -1.27) + (xy 0 -1.27) + ) + (stroke (width 0)) (fill (type none)) + ) + ) + (symbol "GND_1_1" + (pin power_in line (at 0 0 270) (length 0) hide + (name "GND" (effects (font (size 1.27 1.27)))) + (number "1" (effects (font (size 1.27 1.27)))) + ) + ) + ) + ) + + (junction (at 139.7 63.5) (diameter 1.016) (color 0 0 0 0)) + + (bus_entry (at 139.7 63.5) (size -2.54 2.54) + (stroke (width 0.1524) (type solid) (color 0 0 0 0)) + ) + (bus_entry (at 142.24 66.04) (size -2.54 -2.54) + (stroke (width 0.1524) (type solid) (color 0 0 0 0)) + ) + + (wire (pts (xy 128.27 66.04) (xy 137.16 66.04)) + (stroke (width 0) (type solid) (color 0 0 0 0)) + ) + (wire (pts (xy 142.24 66.04) (xy 152.4 66.04)) + (stroke (width 0) (type solid) (color 0 0 0 0)) + ) + (bus (pts (xy 139.7 49.53) (xy 139.7 63.5)) + (stroke (width 0) (type solid) (color 0 0 0 0)) + ) + (bus (pts (xy 139.7 63.5) (xy 139.7 88.9)) + (stroke (width 0) (type solid) (color 0 0 0 0)) + ) + (bus (pts (xy 139.7 63.5) (xy 152.4 63.5)) + (stroke (width 0) (type solid) (color 0 0 0 0)) + ) + + (label "D0" (at 133.35 66.04 180) + (effects (font (size 1.27 1.27)) (justify right bottom)) + ) + (label "D1" (at 148.59 66.04 180) + (effects (font (size 1.27 1.27)) (justify right bottom)) + ) + (label "D[3..0]" (at 152.4 63.5 180) + (effects (font (size 1.27 1.27)) (justify right bottom)) + ) + + (symbol (lib_id "power:GND") (at 128.27 73.66 0) (unit 1) + (in_bom yes) (on_board yes) + (uuid "5b5f14d2-321f-4cc3-b212-963f7c9ce9c1") + (property "Reference" "#PWR?" (id 0) (at 128.27 80.01 0) + (effects (font (size 1.27 1.27)) hide) + ) + (property "Value" "GND" (id 1) (at 128.3843 77.9844 0)) + (property "Footprint" "" (id 2) (at 128.27 73.66 0) + (effects (font (size 1.27 1.27)) hide) + ) + (property "Datasheet" "" (id 3) (at 128.27 73.66 0) + (effects (font (size 1.27 1.27)) hide) + ) + ) + + (symbol (lib_id "power:GND") (at 152.4 73.66 0) (unit 1) + (in_bom yes) (on_board yes) + (uuid "80e533c6-0cf0-4e62-8ca1-9889f3b13a0b") + (property "Reference" "#PWR?" (id 0) (at 152.4 80.01 0) + (effects (font (size 1.27 1.27)) hide) + ) + (property "Value" "GND" (id 1) (at 152.5143 77.9844 0)) + (property "Footprint" "" (id 2) (at 152.4 73.66 0) + (effects (font (size 1.27 1.27)) hide) + ) + (property "Datasheet" "" (id 3) (at 152.4 73.66 0) + (effects (font (size 1.27 1.27)) hide) + ) + ) + + (symbol (lib_id "Device:R") (at 128.27 69.85 0) (unit 1) + (in_bom yes) (on_board yes) + (uuid "4f87bd79-9cd8-49be-8f56-d3edf633bdbc") + (property "Reference" "R1" (id 0) (at 130.048 68.707 0) + (effects (font (size 1.27 1.27)) (justify left)) + ) + (property "Value" "R" (id 1) (at 130.0481 70.9993 0) + (effects (font (size 1.27 1.27)) (justify left)) + ) + (property "Footprint" "" (id 2) (at 126.492 69.85 90) + (effects (font (size 1.27 1.27)) hide) + ) + (property "Datasheet" "~" (id 3) (at 128.27 69.85 0) + (effects (font (size 1.27 1.27)) hide) + ) + ) + + (symbol (lib_id "Device:R") (at 152.4 69.85 0) (unit 1) + (in_bom yes) (on_board yes) + (uuid "1a4870a5-c247-437a-9d15-5fb81804ce85") + (property "Reference" "R2" (id 0) (at 154.178 68.707 0) + (effects (font (size 1.27 1.27)) (justify left)) + ) + (property "Value" "R" (id 1) (at 154.1781 70.9993 0) + (effects (font (size 1.27 1.27)) (justify left)) + ) + (property "Footprint" "" (id 2) (at 150.622 69.85 90) + (effects (font (size 1.27 1.27)) hide) + ) + (property "Datasheet" "~" (id 3) (at 152.4 69.85 0) + (effects (font (size 1.27 1.27)) hide) + ) + ) + + (sheet_instances + (path "/" (page "")) + ) + + (symbol_instances + (path "/5b5f14d2-321f-4cc3-b212-963f7c9ce9c1" + (reference "#PWR?") (unit 1) (value "GND") (footprint "") + ) + (path "/80e533c6-0cf0-4e62-8ca1-9889f3b13a0b" + (reference "#PWR?") (unit 1) (value "GND") (footprint "") + ) + (path "/4f87bd79-9cd8-49be-8f56-d3edf633bdbc" + (reference "R1") (unit 1) (value "R") (footprint "") + ) + (path "/1a4870a5-c247-437a-9d15-5fb81804ce85" + (reference "R2") (unit 1) (value "R") (footprint "") + ) + ) +) diff --git a/qa/eeschema/data/netlists/bus_junctions/bus_junctions.net b/qa/eeschema/data/netlists/bus_junctions/bus_junctions.net new file mode 100644 index 0000000000..40c9c624c4 --- /dev/null +++ b/qa/eeschema/data/netlists/bus_junctions/bus_junctions.net @@ -0,0 +1,62 @@ +(export (version "D") + (design + (source "/home/jon/work/kicad/qa/eeschema/data/netlists/bus_junctions/bus_junctions.kicad_sch") + (date "Tue 27 Oct 2020 23:01:38 EDT") + (tool "Eeschema (5.99.0-6634-g49fd95f58-dirty)") + (sheet (number "1") (name "/") (tstamps "/") + (title_block + (title) + (company) + (rev) + (date) + (source "bus_junctions.kicad_sch") + (comment (number "1") (value "")) + (comment (number "2") (value "")) + (comment (number "3") (value "")) + (comment (number "4") (value "")) + (comment (number "5") (value "")) + (comment (number "6") (value "")) + (comment (number "7") (value "")) + (comment (number "8") (value "")) + (comment (number "9") (value ""))))) + (components + (comp (ref "R1") + (value "R") + (datasheet "~") + (libsource (lib "Device") (part "R") (description "Resistor")) + (property (name "Sheet name") (value "")) + (property (name "Sheet file") (value "/home/jon/work/kicad/qa/eeschema/data/netlists/bus_junctions/bus_junctions.kicad_sch")) + (sheetpath (names "/") (tstamps "/")) + (tstamp "4f87bd79-9cd8-49be-8f56-d3edf633bdbc")) + (comp (ref "R2") + (value "R") + (datasheet "~") + (libsource (lib "Device") (part "R") (description "Resistor")) + (property (name "Sheet name") (value "")) + (property (name "Sheet file") (value "/home/jon/work/kicad/qa/eeschema/data/netlists/bus_junctions/bus_junctions.kicad_sch")) + (sheetpath (names "/") (tstamps "/")) + (tstamp "1a4870a5-c247-437a-9d15-5fb81804ce85"))) + (libparts + (libpart (lib "Device") (part "R") + (description "Resistor") + (docs "~") + (footprints + (fp "R_*")) + (fields + (field (name "Reference") "R") + (field (name "Value") "R") + (field (name "Datasheet") "~")) + (pins + (pin (num "1") (name "~") (type "passive")) + (pin (num "2") (name "~") (type "passive"))))) + (libraries + (library (logical "Device") + (uri "/home/jon/kicad-library/kicad-symbols//Device.kicad_sym"))) + (nets + (net (code "1") (name "/D0") + (node (ref "R1") (pin "1"))) + (net (code "2") (name "/D1") + (node (ref "R2") (pin "1"))) + (net (code "3") (name "GND") + (node (ref "R1") (pin "2")) + (node (ref "R2") (pin "2"))))) \ No newline at end of file diff --git a/qa/eeschema/test_netlists.cpp b/qa/eeschema/test_netlists.cpp index 980ff4ddea..1b16926860 100644 --- a/qa/eeschema/test_netlists.cpp +++ b/qa/eeschema/test_netlists.cpp @@ -247,5 +247,11 @@ BOOST_AUTO_TEST_CASE( WeakVectorBusDisambiguation ) } +BOOST_AUTO_TEST_CASE( BusJunctions ) +{ + doNetlistTest( "bus_junctions" ); +} + + BOOST_AUTO_TEST_SUITE_END()