PhotoCAD
stable
  • 快速创建链路指南
    • 步骤1: 搭建链路基础模块
      • 弯曲波导
      • 直波导
      • Taper过渡波导
    • 步骤2: 利用基础模块搭建基本链路
      • 定向耦合器
      • 多模干涉仪
    • 步骤3: 利用基本链路搭建复杂链路
      • U型定长
      • 路径点
      • 路径线
    • 步骤4: 常用图形的绘制以及通过布尔运算实现版图设计
      • 常用图形绘制
        • 矩形
        • 圆形
        • 多边形
        • 圆环
        • 规则多边形
      • 布尔运算
        • 并集
        • 交集
        • 差集
        • 异或集
        • 案例展示
    • 步骤5: MMI级联
  • 快速配置PDK
    • components
      • straight
      • bend_euler
      • grating_coupler
      • mmi
    • routing
      • auto_transitioned
      • comp_scan
      • extended
      • fanout
      • horizontalized
    • technology
      • layers_csv
      • generate_layers_and_display_from_csv_py.rst
      • waveguide_factory_py
        • 直波导
        • 弯曲波导
        • 欧拉弯曲
        • 案例
      • wg_py
      • auto_link_py
      • auto_transition_py
    • util
  • 波导布线详解
    • 单端口至单端口
    • 多端口至多端口
    • 布线路径选择

教程案例

  • 可编程光子集成链路
    • 第一部分 构建矩形网络
    • 第二部分 参数说明
    • 第三部分 测试说明
    • 第四部分 总结
  • 可重构多级交叉链路
    • 第一部分 参数说明
    • 第二部分 原理说明
    • 第三部分 测试说明
    • 第四部分 总结

常用接口

  • 常用接口
    • 图形类api
    • 链路类api
    • 工具类api
      • translated
      • rotated
      • h_mirrored
      • v_mirrored
      • repositioned
      • position
      • get_bounding_box
  • fnpcell API
    • 关于fnpcell的API文档
      • fnpcell.all
        • Sub-modules
          • Module fnpcell.all.el
          • Module fnpcell.all.g
          • Module fnpcell.all.util
      • fnpcell.ansi
        • Sub-modules
          • Module fnpcell.ansi.term
      • fnpcell.cell
        • Sub-modules
          • Module fnpcell.cell.cell
          • Module fnpcell.cell.cell_array
          • Module fnpcell.cell.cell_ref
          • Module fnpcell.cell.composite
          • Module fnpcell.cell.library
          • Module fnpcell.cell.metal_line
          • Module fnpcell.cell.pin
          • Module fnpcell.cell.port
          • Module fnpcell.cell.waveguide
      • fnpcell.element
        • Sub-modules
          • Module fnpcell.element.all
          • Module fnpcell.element.arc
          • Module fnpcell.element.box
          • Module fnpcell.element.circle
          • Module fnpcell.element.curve
          • Module fnpcell.element.curve_paint
          • Module fnpcell.element.dmtx_code
          • Module fnpcell.element.elliptical_arc
          • Module fnpcell.element.elliptical_ring
          • Module fnpcell.element.group
          • Module fnpcell.element.label
          • Module fnpcell.element.line
          • Module fnpcell.element.polygon
          • Module fnpcell.element.polygon_set
          • Module fnpcell.element.polyline
          • Module fnpcell.element.qr_code
          • Module fnpcell.element.rect
          • Module fnpcell.element.regular_polygon
          • Module fnpcell.element.ring
          • Module fnpcell.element.text
      • fnpcell.errors
        • Classes
          • ConflictError
          • DataTooLongError
          • FlylineWarning
          • FrozenInstanceError
          • InsufficientSpaceError
          • LengthMatchingWarning
          • UserUnitWarning
      • fnpcell.fp
        • Functions
          • is_close
          • is_negative
          • is_non_negative
          • is_non_positive
          • is_nonzero
          • is_one
          • is_positive
          • is_zero
          • round_half_up
      • fnpcell.gdsii
        • Sub-modules
          • fnpcell.gdsii.gds_importer
          • Module fnpcell.gdsii.gds_io
          • Module fnpcell.gdsii.gds_writer
      • fnpcell.geometry
        • Sub-modules
          • Module fnpcell.geometry.arc
          • Module fnpcell.geometry.bezier
          • Module fnpcell.geometry.box
          • Module fnpcell.geometry.circle
          • Module fnpcell.geometry.cosine_bend
          • Module fnpcell.geometry.curve_mixin
          • Module fnpcell.geometry.elliptical_arc
          • Module fnpcell.geometry.elliptical_ring
          • Module fnpcell.geometry.euler_bend
          • Module fnpcell.geometry.euler_bend_function
          • Module fnpcell.geometry.function_curve
          • Module fnpcell.geometry.hybrid_bend
          • Module fnpcell.geometry.line
          • Module fnpcell.geometry.path
          • Module fnpcell.geometry.polyline
          • Module fnpcell.geometry.rect
          • Module fnpcell.geometry.region
          • Module fnpcell.geometry.regular_polygon
          • Module fnpcell.geometry.ring
          • Module fnpcell.geometry.shape
      • fnpcell.hash_code
        • Functions
          • hash_code
      • fnpcell.interfaces
        • Functions
          • Waypoint
          • angle_between
          • cache
          • clamp
          • distance_between
          • is_abstract
          • is_dataclass
          • midpoint_of
          • normalize_angle
          • transform_between
        • Classes
          • Absolute
          • Anchor
          • FrozenDict
          • Glyph
          • Hidden
          • IAffineTransformable
          • IAutoVias
          • IBand
          • IBendCurveFactory
          • IBendWaveguideFactory
          • ICell
          • ICellArray
          • ICellRef
          • IComposite
          • ICurve
          • ICurveLike
          • ICurvePaint
          • ICurved
          • ICurvedCellRef
          • ICurvedElement
          • IElectronicMaterial
          • IElement
          • IGroup
          • ILayer
          • ILayered
          • ILibrary
          • ILinkBetween
          • ILinkType
          • ILinkingPolicy
          • IMaterial
          • IMetalLineBetween
          • IMetalLineLike
          • IMetalLineType
          • IMetalStack
          • IOwned
          • IOwnedPin
          • IOwnedPort
          • IOwnedTerminal
          • IPhotonicMaterial
          • IPin
          • IPolygon
          • IPolygonSet
          • IPolyline
          • IPort
          • IPositioned
          • IPrimitive
          • IProcess
          • IProcessor
          • IPurpose
          • IRay
          • IRegion
          • IRunnable
          • IRunnableContainer
          • IShape
          • IStraightWaveguideFactory
          • ITaperCallable
          • ITerminal
          • IUpdatable
          • IViasFactory
          • IWaveguideBetween
          • IWaveguideLike
          • IWaveguideType
          • Offset
          • Ray
          • RelativeTo
          • SampleInfo
          • TaperFunction
          • TaperFunctionLinear
          • TaperFunctionParabolic
          • TextBaseline
          • Type2TypeMeta
          • Unimplemented
          • UnknownLayer
          • UnknownProcess
          • UnknownPurpose
          • Waypoints
      • fnpcell.internal
        • Sub-modules
          • Module fnpcell.internal.plogic_util
          • fnpcell.internal.util
      • fnpcell.mixin
        • Sub-modules
          • Module fnpcell.mixin.transform_mixin
      • fnpcell.netlist
        • Sub-modules
          • Module fnpcell.netlist.spc_writer
      • fnpcell.pdk
        • Sub-modules
          • Module fnpcell.pdk.classconst
          • Module fnpcell.pdk.collection
          • Module fnpcell.pdk.connected
          • Module fnpcell.pdk.const_property
          • Module fnpcell.pdk.create_links
          • Module fnpcell.pdk.flyline
          • fnpcell.pdk.link_between
          • Module fnpcell.pdk.link_smooth
          • Module fnpcell.pdk.linked
          • Module fnpcell.pdk.named_const
          • Module fnpcell.pdk.pcell
          • Module fnpcell.pdk.pcell_class
          • Module fnpcell.pdk.pcell_params
          • Module fnpcell.pdk.place
          • Module fnpcell.pdk.reexport
          • Module fnpcell.pdk.route
          • Module fnpcell.pdk.staticconst
          • fnpcell.pdk.technology
      • Module fnpcell.polyfill
        • Functions
          • install
      • fnpcell.processors
        • Sub-modules
          • Module fnpcell.processors.matplotlib_shower
          • Module fnpcell.processors.port_owner_checker
      • fnpcell.resource
        • Classes
          • BinaryResource
          • OpenMode
          • TextResource
      • Module fnpcell.transform
        • Functions
          • c_mirror
          • h_mirror
          • rotate
          • scale
          • translate
          • v_mirror
        • Classes
          • Affine2D
      • fnpcell.unique_meta
        • Classes
          • UniqueMeta
  • api_all

服务支持

  • 关于我们
PhotoCAD
  • fnpcell API
  • fnpcell.pdk
  • Module fnpcell.pdk.create_links
  • 在 GitHub 上编辑

Module fnpcell.pdk.create_links

Functions

LinkBetween

def LinkBetween(start: ITerminal, end: ITerminal, **kwargs: Any)

This function is used to link two ports auto link or link two pins auto link.

Usage:

# (link two ports)
fp.LinkBetween(start=cell1["op_1"], end=cell2["op_0"], bend_factory=TECH.WG.MWG.C.WIRE.BEND_EULER)

# (link two pins)
fp.LinkBetween( start=cell1["ep_1"], end=cell2["ep_0"], start_distance=40, metal_line_type=[(0, TECH.METAL.MT.W10)], )

Returns An instance of LinkBetween() or None when start and end matches directly.

def create_links(*, specs: Iterable[Union[None, IWaveguideBetween, IMetalLineBetween,
                    Tuple[IOwnedTerminal, IOwnedTerminal], Tuple[Tuple[IOwnedTerminal, IOwnedTerminal],
                    Optional[float]], Waypoints[IOwnedTerminal, IOwnedTerminal], Tuple[Waypoints[IOwnedTerminal,
                    IOwnedTerminal], Optional[float]], Iterable[Union[None, IWaveguideBetween, IMetalLineBetween,
                    Tuple[IOwnedTerminal, IOwnedTerminal], Tuple[Tuple[IOwnedTerminal, IOwnedTerminal],
                    Optional[float]], Waypoints[IOwnedTerminal, IOwnedTerminal], Tuple[Waypoints[IOwnedTerminal,
                    IOwnedTerminal], Optional[float]]]]]], flyline_layer: Optional[ILayer] = None,
                    linking_policy: Optional[LinkingPolicy] = None, link_type: Optional[IWaveguideType] = None,
                    straight_factory: Optional[IStraightWaveguideFactory] = None,
                    bend_factory: Optional[IBendWaveguideFactory] = None,
                    metal_min_distance: Optional[float] = None, metal_start_distance: Optional[float] = None,
                    metal_end_distance: Optional[float] = None, metal_line_type: Union[None, IMetalLineType,
                    Iterable[Tuple[float, IMetalLineType]]] = None,
                    metal_fitting_function: Optional[Callable[[Tuple[Tuple[float, float], ...]], ICurve]] = None,
                    auto_vias: Optional[AutoVias] = None) -> Tuple[Optional[ICurvedCellRef], ...]

Create links between ports and returns all generated links.

Args

flyline_layer:

Optional, flyline is generated if there's no spacing to insert bend/transition/taper etc.
If absent, default to use TECH.LAYER.FLYLINE_MARK

linking_policy:

Optional, providing default link_type and default bend_factory for each port pairs. If absent,
TECH.LINKING_POLICY.DEFAULT will be used.

link_type:

Optional, waveguide type to be used to generate waveguide links.
LinkBetween() has a parameter link_type which has priority over Linked's link_type.

bend_factory:

Optional, a factory function to generate bend.

specs

like this:

[cell1["op_0"] >> cell2["op_0"], cell1["op_1"] >> cell2["op_1"],]
or [cell1["op_0"] >> to(750, 300, 0) >> cell1["op_0"],]

metal_line_width:

Optional, default line width of metal line links which are generated from pin pairs.
If absent, default to use TECH.METAL.DEFAULT_LINE_WIDTH.

metal_min_distance:

Optional, default minimum distance before turning around. LinkBetween() has a parameter
min_distance which has priority over metal_min_distance. AssertionError will be raised
if neither min_distance nor metal_min_distance is provided.

metal_start_distance:

Optional, default minimum distance (from start port) before turning around. LinkBetween()
has a parameter start_distance which has priority over metal_start_distance. AssertionError
will be raised if neither start_distance nor metal_start_distance is provided.

metal_end_distance:

Optional, default minimum distance (from end port) before turning around. LinkBetween()
has a parameter end_distance which has priority over metal_end_distance. AssertionError
will be raised if neither end_distance nor metal_end_distance is provided.

metal_via_spacing:

Optional, default via spacing. This affects how vias are inserted: less vias for larger via
spacing LinkBetween() has a parameter via_spacing which has priority over metal_via_spacing.
AssertionError will be raised if neither via_spacing nor metal_via_spacing is provided.

metal_overlap_distance:

Optional, default overlap distance when metal line go to another layer. This affects how vias
are inserted: more vias for larger overlap distance LinkBetween() has a parameter overlap_distance
which has priority over metal_overlap_distance. AssertionError will be raised if neither
overlap_distance nor metal_overlap_distance is provided.

auto_vias:

Optional, a registry contains functions which generate vias for a specific layer pair.
LinkBetween() has a parameter auto_vias which has priority over Linke's auto_vias.
AssertionError will be raised if neither is provided.

auto_metal_line_type:

Optional, a registry contains metal line type for a specific layer. LinkBetween() has
a parameter auto_metal_line_type which has priority over Linke's auto_metal_line_type.
AssertionError will be raised if neither is provided.

Returns

All generated links Usage:

links = fp.create_links(link_type=TECH.WG.MWG.C.WIRE, bend_type=TECH.WG.MWG.C.WIRE,
                        specs=[cell1["op_0"] >> cell2["op_0"],],)
上一页 下一页

© 版权所有 2022, Latitudeda.com. 版本 45cbbbbd.

利用 Sphinx 构建,使用的 主题 由 Read the Docs 开发.