Differences

This shows you the differences between two versions of the page.

Link to this comparison view

gnucap:user:netlist_import_and_export:geda [2025/05/14 05:30]
felixs fix port names in example
gnucap:user:netlist_import_and_export:geda [2025/05/14 05:54] (current)
felixs describe net override handling
Line 113: Line 113:
 ==== Connections by attribute ==== ==== Connections by attribute ====
  
-A symbol instance that represents a device may have multiple ''net'' attributes with a value like A:B,C,D, see [[https://lepton-eda.github.io/lepton-manual.html/net_003d-attribute-mini_002dHOWTO.html|Lepton manual]]. These are translated to port assignments, and mix with other port assignments. For example+=== Base case === 
 + 
 +A symbol instance that represents a device may have multiple ''net'' attributes with a value like ''A:B,C,D'', see [[https://lepton-eda.github.io/lepton-manual.html/net_003d-attribute-mini_002dHOWTO.html|Lepton manual]]. 
 +These are translated to port assignments, and mix with other port assignments. For example
 <code>some_device #() my_refdes(.B(A), .C(A), .D(A), [..] .other(n17),[..]);.</code> <code>some_device #() my_refdes(.B(A), .C(A), .D(A), [..] .other(n17),[..]);.</code>
 +
 +This reflects that ''A:B,C,D'' is actually a contrived short hand syntax for 3 individual assignments.
 +
 +=== net overrides ===
 +
 +Some situations require untangling identify the intent as illustrated as follows.
 +For example, the data
 +
 +  net=A:B,C // in the symbol
 +  net=A:X,Y // in the instance
 +  net=B:C   // in the instance
 +  net=C:X   // in the instance
 +  
 +would be interpreted as 
 +
 +  .B(A) .C(A) .X(A) .Y(A) .C(B) .X(C) // untangled assignments in order
 +  .B(A) .C(B) .X(C) .Y(A)             // effective port assignment (rightmost wins)
 +  
 +Note that the instance value of "net" does not replace the value assigned in the instance as usual.
 +
 +=== Already visible case ===
  
 Sometimes those "net" connections correspond to named visible pins inside the symbol. The Lepton manual addresses the situation as follows. Sometimes those "net" connections correspond to named visible pins inside the symbol. The Lepton manual addresses the situation as follows.
Line 124: Line 148:
 Using a "net" special device to represent the rail device instance is consistent with use in gEDA/Lepton, since ''gnd-1.sym'' is not meant to carry a "device" attribute that would require otherwise. Using a "net" special device to represent the rail device instance is consistent with use in gEDA/Lepton, since ''gnd-1.sym'' is not meant to carry a "device" attribute that would require otherwise.
 Following our translation, the additional "GND" node connects all gnd-1.sym instances, implementing the "net" logic, as intended. The name of the second port, "rail", is made up, for now. Following our translation, the additional "GND" node connects all gnd-1.sym instances, implementing the "net" logic, as intended. The name of the second port, "rail", is made up, for now.
- 
 ==== Port declarations ==== ==== Port declarations ====
  
gnucap/user/netlist_import_and_export/geda.txt · Last modified: 2025/05/14 05:54 by felixs
 
Recent changes RSS feed Donate Powered by PHP Valid XHTML 1.0 Valid CSS Run by Debian Driven by DokuWiki