Skip to content

FEAT: Via Design Toolkit Backend #1236

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 34 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
34 commits
Select commit Hold shift + click to select a range
3206672
incremental path
samomania21 May 16, 2025
2de2513
draft
samomania21 May 16, 2025
802ee61
draft
samomania21 May 17, 2025
79aa039
draft
samomania21 May 17, 2025
c374c5d
Add modeler circle support
samomania21 May 18, 2025
012b0a1
draft difftrace class
samomania21 May 20, 2025
ab2d351
draft
samomania21 May 20, 2025
2037cbc
draft
samomania21 May 20, 2025
053e8fb
Move files
samomania21 May 20, 2025
2390795
Merge branch 'main' into via-design-2
hui-zhou-a May 20, 2025
3083457
MISC: Auto fixes from pre-commit.com hooks
pre-commit-ci[bot] May 20, 2025
b56d50f
draft
samomania21 May 21, 2025
b4741dd
draft
samomania21 May 22, 2025
c9ef85b
draft
samomania21 May 23, 2025
8cdfea0
Merge branch 'refs/heads/main' into via-design-2
samomania21 May 23, 2025
3b97811
Merge branch 'refs/heads/main' into via-design-2
samomania21 May 26, 2025
3fe683d
fix
samomania21 May 26, 2025
8c77d5a
MISC: Auto fixes from pre-commit.com hooks
pre-commit-ci[bot] May 26, 2025
49b98cc
draft
samomania21 May 27, 2025
94c0a40
draft
samomania21 May 27, 2025
6cb9604
Merge branch 'refs/heads/main' into via-design-2
samomania21 May 27, 2025
cd972b7
draft
samomania21 May 27, 2025
d6952ce
MISC: Auto fixes from pre-commit.com hooks
pre-commit-ci[bot] May 27, 2025
37abd0e
fix
samomania21 May 27, 2025
64ccc5a
MISC: Auto fixes from pre-commit.com hooks
pre-commit-ci[bot] May 27, 2025
0270e35
fix board size
samomania21 May 27, 2025
037a446
Merge remote-tracking branch 'origin/via-design-2' into via-design-2
samomania21 May 27, 2025
248d3b1
fix
samomania21 May 27, 2025
d2ec737
draft
samomania21 May 27, 2025
c966e31
fix
samomania21 May 27, 2025
feef520
MISC: Auto fixes from pre-commit.com hooks
pre-commit-ci[bot] May 27, 2025
e589b11
fix
samomania21 May 28, 2025
33b3228
Merge remote-tracking branch 'origin/via-design-2' into via-design-2
samomania21 May 28, 2025
8a1316c
draft
samomania21 May 28, 2025
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
53 changes: 42 additions & 11 deletions src/pyedb/configuration/cfg_modeler.py
Original file line number Diff line number Diff line change
Expand Up @@ -29,13 +29,15 @@ class CfgTrace:
def __init__(self, **kwargs):
self.name = kwargs.get("name", "")
self.layer = kwargs["layer"]
self.path = kwargs["path"]
self.path = kwargs.get("path")
self.width = kwargs["width"]
self.net_name = kwargs.get("net_name", "")
self.start_cap_style = kwargs.get("start_cap_style", "round")
self.end_cap_style = kwargs.get("end_cap_style", "round")
self.corner_style = kwargs.get("corner_style", "sharp")

self.incremental_path = kwargs.get("incremental_path")


class CfgPlane:
def __init__(self, **kwargs):
Expand All @@ -54,6 +56,10 @@ def __init__(self, **kwargs):
# polygon
self.points = kwargs.get("points", [])

# circle
self.radius = kwargs.get("radius", 0)
self.position = kwargs.get("position", [0, 0])


class CfgModeler:
"""Manage configuration general settings."""
Expand Down Expand Up @@ -153,16 +159,30 @@ def __init__(self, parent):
def set_parameter_to_edb(self):
if self.parent.traces:
for t in self.parent.traces:
obj = self._pedb.modeler.create_trace(
path_list=t.path,
layer_name=t.layer,
net_name=t.net_name,
width=t.width,
start_cap_style=t.start_cap_style,
end_cap_style=t.end_cap_style,
corner_style=t.corner_style,
)
obj.aedt_name = t.name
if t.path:
obj = self._pedb.modeler.create_trace(
path_list=t.path,
layer_name=t.layer,
net_name=t.net_name,
width=t.width,
start_cap_style=t.start_cap_style,
end_cap_style=t.end_cap_style,
corner_style=t.corner_style,
)
obj.aedt_name = t.name
else:
obj = self._pedb.modeler.create_trace(
path_list=[t.incremental_path[0]],
layer_name=t.layer,
net_name=t.net_name,
width=t.width,
start_cap_style=t.start_cap_style,
end_cap_style=t.end_cap_style,
corner_style=t.corner_style,
)
obj.aedt_name = t.name
for x, y in t.incremental_path[1:]:
obj.add_point(x, y, True)

if self.parent.padstack_defs:
for p in self.parent.padstack_defs:
Expand Down Expand Up @@ -202,6 +222,17 @@ def set_parameter_to_edb(self):
main_shape=p.points, layer_name=p.layer, net_name=p.net_name
)
obj.aedt_name = p.name
elif p.type == "circle":
obj = self._pedb.modeler.create_circle(
layer_name=p.layer,
net_name=p.net_name,
x=p.position[0],
y=p.position[1],
radius=p.radius,
)
obj.aedt_name = p.name
else:
raise

for v in p.voids:
for i in self._pedb.layout.primitives:
Expand Down
Empty file.
Loading
Loading