pyedb 0.53.0__py3-none-any.whl → 0.54.0__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Potentially problematic release.
This version of pyedb might be problematic. Click here for more details.
- pyedb/__init__.py +1 -1
- pyedb/configuration/cfg_ports_sources.py +6 -8
- pyedb/configuration/configuration.py +2 -1
- pyedb/dotnet/database/cell/hierarchy/model.py +1 -1
- pyedb/dotnet/database/cell/layout.py +1 -1
- pyedb/dotnet/database/cell/layout_obj.py +3 -3
- pyedb/dotnet/database/cell/primitive/path.py +1 -1
- pyedb/dotnet/database/cell/primitive/primitive.py +8 -8
- pyedb/dotnet/database/cell/terminal/pingroup_terminal.py +1 -1
- pyedb/dotnet/database/cell/terminal/point_terminal.py +1 -1
- pyedb/dotnet/database/cell/terminal/terminal.py +24 -26
- pyedb/dotnet/database/components.py +24 -24
- pyedb/dotnet/database/definition/component_def.py +3 -3
- pyedb/dotnet/database/definition/component_model.py +1 -1
- pyedb/dotnet/database/definition/package_def.py +1 -1
- pyedb/dotnet/database/dotnet/database.py +43 -38
- pyedb/dotnet/database/dotnet/primitive.py +16 -16
- pyedb/dotnet/database/edb_data/hfss_extent_info.py +6 -6
- pyedb/dotnet/database/edb_data/layer_data.py +14 -14
- pyedb/dotnet/database/edb_data/padstacks_data.py +12 -12
- pyedb/dotnet/database/edb_data/primitives_data.py +3 -3
- pyedb/dotnet/database/edb_data/sources.py +6 -6
- pyedb/dotnet/database/edb_data/variables.py +7 -3
- pyedb/dotnet/database/geometry/point_data.py +1 -1
- pyedb/dotnet/database/geometry/polygon_data.py +2 -4
- pyedb/dotnet/database/hfss.py +7 -7
- pyedb/dotnet/database/materials.py +2 -2
- pyedb/dotnet/database/modeler.py +8 -11
- pyedb/dotnet/database/nets.py +1 -1
- pyedb/dotnet/database/padstack.py +72 -1
- pyedb/dotnet/database/sim_setup_data/data/settings.py +24 -0
- pyedb/dotnet/database/sim_setup_data/io/siwave.py +26 -1
- pyedb/dotnet/database/siwave.py +5 -5
- pyedb/dotnet/database/stackup.py +74 -77
- pyedb/dotnet/database/utilities/heatsink.py +4 -4
- pyedb/dotnet/database/utilities/obj_base.py +1 -1
- pyedb/dotnet/database/utilities/value.py +116 -0
- pyedb/dotnet/edb.py +43 -43
- pyedb/generic/design_types.py +12 -3
- pyedb/grpc/__init__.py +0 -0
- pyedb/grpc/database/components.py +53 -17
- pyedb/grpc/database/definition/materials.py +23 -30
- pyedb/grpc/database/definition/package_def.py +15 -15
- pyedb/grpc/database/definition/padstack_def.py +51 -51
- pyedb/grpc/database/geometry/arc_data.py +7 -5
- pyedb/grpc/database/geometry/point_3d_data.py +8 -7
- pyedb/grpc/database/geometry/polygon_data.py +3 -2
- pyedb/grpc/database/hierarchy/component.py +43 -38
- pyedb/grpc/database/hierarchy/pin_pair_model.py +15 -14
- pyedb/grpc/database/hierarchy/pingroup.py +9 -9
- pyedb/grpc/database/layers/stackup_layer.py +45 -44
- pyedb/grpc/database/layout/layout.py +9 -8
- pyedb/grpc/database/layout/voltage_regulator.py +7 -7
- pyedb/grpc/database/layout_validation.py +13 -12
- pyedb/grpc/database/modeler.py +51 -54
- pyedb/grpc/database/nets.py +42 -31
- pyedb/grpc/database/padstacks.py +270 -175
- pyedb/grpc/database/ports/ports.py +5 -6
- pyedb/grpc/database/primitive/bondwire.py +8 -7
- pyedb/grpc/database/primitive/circle.py +4 -4
- pyedb/grpc/database/primitive/padstack_instance.py +18 -18
- pyedb/grpc/database/primitive/path.py +7 -7
- pyedb/grpc/database/primitive/polygon.py +3 -3
- pyedb/grpc/database/primitive/primitive.py +13 -17
- pyedb/grpc/database/primitive/rectangle.py +13 -13
- pyedb/grpc/database/simulation_setup/hfss_general_settings.py +1 -1
- pyedb/grpc/database/simulation_setup/hfss_simulation_setup.py +10 -0
- pyedb/grpc/database/simulation_setup/siwave_simulation_setup.py +17 -1
- pyedb/grpc/database/siwave.py +30 -24
- pyedb/grpc/database/source_excitations.py +333 -229
- pyedb/grpc/database/stackup.py +164 -147
- pyedb/grpc/database/terminal/bundle_terminal.py +17 -7
- pyedb/grpc/database/terminal/edge_terminal.py +10 -0
- pyedb/grpc/database/terminal/padstack_instance_terminal.py +15 -4
- pyedb/grpc/database/terminal/pingroup_terminal.py +11 -10
- pyedb/grpc/database/terminal/point_terminal.py +4 -3
- pyedb/grpc/database/terminal/terminal.py +9 -9
- pyedb/grpc/database/utility/value.py +109 -0
- pyedb/grpc/edb.py +59 -38
- pyedb/grpc/edb_init.py +0 -7
- {pyedb-0.53.0.dist-info → pyedb-0.54.0.dist-info}/METADATA +3 -3
- {pyedb-0.53.0.dist-info → pyedb-0.54.0.dist-info}/RECORD +84 -81
- {pyedb-0.53.0.dist-info → pyedb-0.54.0.dist-info}/WHEEL +0 -0
- {pyedb-0.53.0.dist-info → pyedb-0.54.0.dist-info}/licenses/LICENSE +0 -0
|
@@ -40,11 +40,11 @@ from ansys.edb.core.definition.material_def import MaterialDef as GrpcMaterialDe
|
|
|
40
40
|
from ansys.edb.core.definition.multipole_debye_model import (
|
|
41
41
|
MultipoleDebyeModel as GrpcMultipoleDebyeModel,
|
|
42
42
|
)
|
|
43
|
-
from ansys.edb.core.utility.value import Value as GrpcValue
|
|
44
43
|
from pydantic import BaseModel, confloat
|
|
45
44
|
|
|
46
45
|
from pyedb import Edb
|
|
47
46
|
from pyedb.exceptions import MaterialModelException
|
|
47
|
+
from pyedb.grpc.database.utility.value import Value
|
|
48
48
|
|
|
49
49
|
logger = logging.getLogger(__name__)
|
|
50
50
|
|
|
@@ -181,8 +181,7 @@ class Material(GrpcMaterialDef):
|
|
|
181
181
|
Conductivity value.
|
|
182
182
|
"""
|
|
183
183
|
try:
|
|
184
|
-
|
|
185
|
-
return value
|
|
184
|
+
return Value(self.get_property(GrpcMaterialProperty.CONDUCTIVITY))
|
|
186
185
|
except:
|
|
187
186
|
return 0.0
|
|
188
187
|
|
|
@@ -195,7 +194,7 @@ class Material(GrpcMaterialDef):
|
|
|
195
194
|
f"Changing conductivity is only allowed when no dielectric model is assigned."
|
|
196
195
|
)
|
|
197
196
|
else:
|
|
198
|
-
self.set_property(GrpcMaterialProperty.CONDUCTIVITY,
|
|
197
|
+
self.set_property(GrpcMaterialProperty.CONDUCTIVITY, Value(value))
|
|
199
198
|
|
|
200
199
|
@property
|
|
201
200
|
def dc_conductivity(self):
|
|
@@ -310,15 +309,14 @@ class Material(GrpcMaterialDef):
|
|
|
310
309
|
|
|
311
310
|
"""
|
|
312
311
|
try:
|
|
313
|
-
|
|
314
|
-
return value
|
|
312
|
+
return Value(self.get_property(GrpcMaterialProperty.PERMITTIVITY))
|
|
315
313
|
except:
|
|
316
314
|
return 0.0
|
|
317
315
|
|
|
318
316
|
@permittivity.setter
|
|
319
317
|
def permittivity(self, value):
|
|
320
318
|
"""Set material permittivity."""
|
|
321
|
-
self.set_property(GrpcMaterialProperty.PERMITTIVITY,
|
|
319
|
+
self.set_property(GrpcMaterialProperty.PERMITTIVITY, Value(value))
|
|
322
320
|
|
|
323
321
|
@property
|
|
324
322
|
def permeability(self) -> float:
|
|
@@ -331,15 +329,14 @@ class Material(GrpcMaterialDef):
|
|
|
331
329
|
|
|
332
330
|
"""
|
|
333
331
|
try:
|
|
334
|
-
|
|
335
|
-
return value
|
|
332
|
+
return Value(self.get_property(GrpcMaterialProperty.PERMEABILITY))
|
|
336
333
|
except:
|
|
337
334
|
return 0.0
|
|
338
335
|
|
|
339
336
|
@permeability.setter
|
|
340
337
|
def permeability(self, value):
|
|
341
338
|
"""Set material permeability."""
|
|
342
|
-
self.set_property(GrpcMaterialProperty.PERMEABILITY,
|
|
339
|
+
self.set_property(GrpcMaterialProperty.PERMEABILITY, Value(value))
|
|
343
340
|
|
|
344
341
|
@property
|
|
345
342
|
def loss_tangent(self):
|
|
@@ -369,7 +366,7 @@ class Material(GrpcMaterialDef):
|
|
|
369
366
|
|
|
370
367
|
"""
|
|
371
368
|
try:
|
|
372
|
-
return self.get_property(GrpcMaterialProperty.DIELECTRIC_LOSS_TANGENT)
|
|
369
|
+
return Value(self.get_property(GrpcMaterialProperty.DIELECTRIC_LOSS_TANGENT))
|
|
373
370
|
except:
|
|
374
371
|
return 0.0
|
|
375
372
|
|
|
@@ -386,7 +383,7 @@ class Material(GrpcMaterialDef):
|
|
|
386
383
|
@dielectric_loss_tangent.setter
|
|
387
384
|
def dielectric_loss_tangent(self, value):
|
|
388
385
|
"""Set material loss tangent."""
|
|
389
|
-
self.set_property(GrpcMaterialProperty.DIELECTRIC_LOSS_TANGENT,
|
|
386
|
+
self.set_property(GrpcMaterialProperty.DIELECTRIC_LOSS_TANGENT, Value(value))
|
|
390
387
|
|
|
391
388
|
@property
|
|
392
389
|
def magnetic_loss_tangent(self) -> float:
|
|
@@ -398,15 +395,14 @@ class Material(GrpcMaterialDef):
|
|
|
398
395
|
Magnetic loss tangent value.
|
|
399
396
|
"""
|
|
400
397
|
try:
|
|
401
|
-
|
|
402
|
-
return value
|
|
398
|
+
return Value(self.get_property(GrpcMaterialProperty.MAGNETIC_LOSS_TANGENT))
|
|
403
399
|
except:
|
|
404
400
|
return 0.0
|
|
405
401
|
|
|
406
402
|
@magnetic_loss_tangent.setter
|
|
407
403
|
def magnetic_loss_tangent(self, value):
|
|
408
404
|
"""Set material magnetic loss tangent."""
|
|
409
|
-
self.set_property(GrpcMaterialProperty.MAGNETIC_LOSS_TANGENT,
|
|
405
|
+
self.set_property(GrpcMaterialProperty.MAGNETIC_LOSS_TANGENT, Value(value))
|
|
410
406
|
|
|
411
407
|
@property
|
|
412
408
|
def thermal_conductivity(self) -> float:
|
|
@@ -419,15 +415,14 @@ class Material(GrpcMaterialDef):
|
|
|
419
415
|
|
|
420
416
|
"""
|
|
421
417
|
try:
|
|
422
|
-
|
|
423
|
-
return value
|
|
418
|
+
return Value(self.get_property(GrpcMaterialProperty.THERMAL_CONDUCTIVITY))
|
|
424
419
|
except:
|
|
425
420
|
return 0.0
|
|
426
421
|
|
|
427
422
|
@thermal_conductivity.setter
|
|
428
423
|
def thermal_conductivity(self, value):
|
|
429
424
|
"""Set material thermal conductivity."""
|
|
430
|
-
self.set_property(GrpcMaterialProperty.THERMAL_CONDUCTIVITY,
|
|
425
|
+
self.set_property(GrpcMaterialProperty.THERMAL_CONDUCTIVITY, Value(value))
|
|
431
426
|
|
|
432
427
|
@property
|
|
433
428
|
def mass_density(self) -> float:
|
|
@@ -440,15 +435,14 @@ class Material(GrpcMaterialDef):
|
|
|
440
435
|
|
|
441
436
|
"""
|
|
442
437
|
try:
|
|
443
|
-
|
|
444
|
-
return value
|
|
438
|
+
return Value(self.get_property(GrpcMaterialProperty.MASS_DENSITY))
|
|
445
439
|
except:
|
|
446
440
|
return 0.0
|
|
447
441
|
|
|
448
442
|
@mass_density.setter
|
|
449
443
|
def mass_density(self, value):
|
|
450
444
|
"""Set material mass density."""
|
|
451
|
-
self.set_property(GrpcMaterialProperty.MASS_DENSITY,
|
|
445
|
+
self.set_property(GrpcMaterialProperty.MASS_DENSITY, Value(value))
|
|
452
446
|
|
|
453
447
|
@property
|
|
454
448
|
def youngs_modulus(self) -> float:
|
|
@@ -461,15 +455,14 @@ class Material(GrpcMaterialDef):
|
|
|
461
455
|
|
|
462
456
|
"""
|
|
463
457
|
try:
|
|
464
|
-
|
|
465
|
-
return value
|
|
458
|
+
return Value(self.get_property(GrpcMaterialProperty.YOUNGS_MODULUS))
|
|
466
459
|
except:
|
|
467
460
|
return 0.0
|
|
468
461
|
|
|
469
462
|
@youngs_modulus.setter
|
|
470
463
|
def youngs_modulus(self, value):
|
|
471
464
|
"""Set material young modulus."""
|
|
472
|
-
self.set_property(GrpcMaterialProperty.YOUNGS_MODULUS,
|
|
465
|
+
self.set_property(GrpcMaterialProperty.YOUNGS_MODULUS, Value(value))
|
|
473
466
|
|
|
474
467
|
@property
|
|
475
468
|
def specific_heat(self) -> float:
|
|
@@ -481,14 +474,14 @@ class Material(GrpcMaterialDef):
|
|
|
481
474
|
Material specific heat value.
|
|
482
475
|
"""
|
|
483
476
|
try:
|
|
484
|
-
return self.get_property(GrpcMaterialProperty.SPECIFIC_HEAT)
|
|
477
|
+
return Value(self.get_property(GrpcMaterialProperty.SPECIFIC_HEAT))
|
|
485
478
|
except:
|
|
486
479
|
return 0.0
|
|
487
480
|
|
|
488
481
|
@specific_heat.setter
|
|
489
482
|
def specific_heat(self, value):
|
|
490
483
|
"""Set material specific heat."""
|
|
491
|
-
self.set_property(GrpcMaterialProperty.SPECIFIC_HEAT,
|
|
484
|
+
self.set_property(GrpcMaterialProperty.SPECIFIC_HEAT, Value(value))
|
|
492
485
|
|
|
493
486
|
@property
|
|
494
487
|
def poisson_ratio(self) -> float:
|
|
@@ -500,14 +493,14 @@ class Material(GrpcMaterialDef):
|
|
|
500
493
|
Material poisson ratio value.
|
|
501
494
|
"""
|
|
502
495
|
try:
|
|
503
|
-
return self.get_property(GrpcMaterialProperty.POISSONS_RATIO)
|
|
496
|
+
return Value(self.get_property(GrpcMaterialProperty.POISSONS_RATIO))
|
|
504
497
|
except:
|
|
505
498
|
return 0.0
|
|
506
499
|
|
|
507
500
|
@poisson_ratio.setter
|
|
508
501
|
def poisson_ratio(self, value):
|
|
509
502
|
"""Set material poisson ratio."""
|
|
510
|
-
self.set_property(GrpcMaterialProperty.POISSONS_RATIO,
|
|
503
|
+
self.set_property(GrpcMaterialProperty.POISSONS_RATIO, Value(value))
|
|
511
504
|
|
|
512
505
|
@property
|
|
513
506
|
def thermal_expansion_coefficient(self) -> float:
|
|
@@ -520,14 +513,14 @@ class Material(GrpcMaterialDef):
|
|
|
520
513
|
|
|
521
514
|
"""
|
|
522
515
|
try:
|
|
523
|
-
return self.get_property(GrpcMaterialProperty.THERMAL_EXPANSION_COEFFICIENT)
|
|
516
|
+
return Value(self.get_property(GrpcMaterialProperty.THERMAL_EXPANSION_COEFFICIENT))
|
|
524
517
|
except:
|
|
525
518
|
return 0.0
|
|
526
519
|
|
|
527
520
|
@thermal_expansion_coefficient.setter
|
|
528
521
|
def thermal_expansion_coefficient(self, value):
|
|
529
522
|
"""Set material thermal coefficient."""
|
|
530
|
-
self.set_property(GrpcMaterialProperty.THERMAL_EXPANSION_COEFFICIENT,
|
|
523
|
+
self.set_property(GrpcMaterialProperty.THERMAL_EXPANSION_COEFFICIENT, Value(value))
|
|
531
524
|
|
|
532
525
|
def set_debye_model(self):
|
|
533
526
|
"""Set Debye model on current material."""
|
|
@@ -22,10 +22,10 @@
|
|
|
22
22
|
|
|
23
23
|
from ansys.edb.core.definition.package_def import PackageDef as GrpcPackageDef
|
|
24
24
|
from ansys.edb.core.geometry.polygon_data import PolygonData as GrpcPolygonData
|
|
25
|
-
from ansys.edb.core.utility.value import Value as GrpcValue
|
|
26
25
|
|
|
27
26
|
from pyedb.edb_logger import pyedb_logger
|
|
28
27
|
from pyedb.grpc.database.utility.heat_sink import HeatSink
|
|
28
|
+
from pyedb.grpc.database.utility.value import Value
|
|
29
29
|
from pyedb.misc.misc import deprecated_property
|
|
30
30
|
|
|
31
31
|
|
|
@@ -115,11 +115,11 @@ class PackageDef(GrpcPackageDef):
|
|
|
115
115
|
float
|
|
116
116
|
maximum power value.
|
|
117
117
|
"""
|
|
118
|
-
return super().maximum_power
|
|
118
|
+
return Value(super().maximum_power)
|
|
119
119
|
|
|
120
120
|
@maximum_power.setter
|
|
121
121
|
def maximum_power(self, value):
|
|
122
|
-
super(PackageDef, self.__class__).maximum_power.__set__(self,
|
|
122
|
+
super(PackageDef, self.__class__).maximum_power.__set__(self, Value(value))
|
|
123
123
|
|
|
124
124
|
@property
|
|
125
125
|
def therm_cond(self) -> float:
|
|
@@ -131,11 +131,11 @@ class PackageDef(GrpcPackageDef):
|
|
|
131
131
|
Thermal conductivity value.
|
|
132
132
|
|
|
133
133
|
"""
|
|
134
|
-
return super().thermal_conductivity
|
|
134
|
+
return Value(super().thermal_conductivity)
|
|
135
135
|
|
|
136
136
|
@therm_cond.setter
|
|
137
137
|
def therm_cond(self, value):
|
|
138
|
-
super(PackageDef, self.__class__).thermal_conductivity.__set__(self,
|
|
138
|
+
super(PackageDef, self.__class__).thermal_conductivity.__set__(self, Value(value))
|
|
139
139
|
|
|
140
140
|
@property
|
|
141
141
|
def theta_jb(self) -> float:
|
|
@@ -146,11 +146,11 @@ class PackageDef(GrpcPackageDef):
|
|
|
146
146
|
float
|
|
147
147
|
Theta jb value.
|
|
148
148
|
"""
|
|
149
|
-
return super().theta_jb
|
|
149
|
+
return Value(super().theta_jb)
|
|
150
150
|
|
|
151
151
|
@theta_jb.setter
|
|
152
152
|
def theta_jb(self, value):
|
|
153
|
-
super(PackageDef, self.__class__).theta_jb.__set__(self,
|
|
153
|
+
super(PackageDef, self.__class__).theta_jb.__set__(self, Value(value))
|
|
154
154
|
|
|
155
155
|
@property
|
|
156
156
|
def theta_jc(self) -> float:
|
|
@@ -161,11 +161,11 @@ class PackageDef(GrpcPackageDef):
|
|
|
161
161
|
float
|
|
162
162
|
Theta jc value.
|
|
163
163
|
"""
|
|
164
|
-
return super().theta_jc
|
|
164
|
+
return Value(super().theta_jc)
|
|
165
165
|
|
|
166
166
|
@theta_jc.setter
|
|
167
167
|
def theta_jc(self, value):
|
|
168
|
-
super(PackageDef, self.__class__).theta_jc.__set__(self,
|
|
168
|
+
super(PackageDef, self.__class__).theta_jc.__set__(self, Value(value))
|
|
169
169
|
|
|
170
170
|
@property
|
|
171
171
|
def height(self) -> float:
|
|
@@ -176,11 +176,11 @@ class PackageDef(GrpcPackageDef):
|
|
|
176
176
|
float
|
|
177
177
|
Height value.
|
|
178
178
|
"""
|
|
179
|
-
return super().height
|
|
179
|
+
return Value(super().height)
|
|
180
180
|
|
|
181
181
|
@height.setter
|
|
182
182
|
def height(self, value):
|
|
183
|
-
super(PackageDef, self.__class__).height.__set__(self,
|
|
183
|
+
super(PackageDef, self.__class__).height.__set__(self, Value(value))
|
|
184
184
|
|
|
185
185
|
@property
|
|
186
186
|
def heat_sink(self) -> HeatSink:
|
|
@@ -235,10 +235,10 @@ class PackageDef(GrpcPackageDef):
|
|
|
235
235
|
super(PackageDef, self.__class__).heat_sink.__set__(
|
|
236
236
|
self,
|
|
237
237
|
GrpcHeatSink(
|
|
238
|
-
|
|
239
|
-
|
|
240
|
-
|
|
241
|
-
|
|
238
|
+
Value(fin_thickness),
|
|
239
|
+
Value(fin_spacing),
|
|
240
|
+
Value(fin_base_height),
|
|
241
|
+
Value(fin_height),
|
|
242
242
|
fin_orientation,
|
|
243
243
|
),
|
|
244
244
|
)
|
|
@@ -35,9 +35,9 @@ from ansys.edb.core.geometry.polygon_data import PolygonData as GrpcPolygonData
|
|
|
35
35
|
from ansys.edb.core.hierarchy.structure3d import MeshClosure as GrpcMeshClosure
|
|
36
36
|
from ansys.edb.core.hierarchy.structure3d import Structure3D as GrpcStructure3D
|
|
37
37
|
from ansys.edb.core.primitive.circle import Circle as GrpcCircle
|
|
38
|
-
from ansys.edb.core.utility.value import Value as GrpcValue
|
|
39
38
|
|
|
40
39
|
from pyedb.generic.general_methods import generate_unique_name
|
|
40
|
+
from pyedb.grpc.database.utility.value import Value
|
|
41
41
|
|
|
42
42
|
|
|
43
43
|
class PadProperties:
|
|
@@ -119,7 +119,7 @@ class PadProperties:
|
|
|
119
119
|
List of parameters.
|
|
120
120
|
"""
|
|
121
121
|
try:
|
|
122
|
-
return [i
|
|
122
|
+
return [Value(i) for i in self._pad_parameter_value[1]]
|
|
123
123
|
except TypeError:
|
|
124
124
|
return []
|
|
125
125
|
|
|
@@ -158,7 +158,7 @@ class PadProperties:
|
|
|
158
158
|
str
|
|
159
159
|
Offset for the X axis.
|
|
160
160
|
"""
|
|
161
|
-
return self._pad_parameter_value[2]
|
|
161
|
+
return Value(self._pad_parameter_value[2])
|
|
162
162
|
|
|
163
163
|
@property
|
|
164
164
|
def offset_y(self) -> float:
|
|
@@ -170,7 +170,7 @@ class PadProperties:
|
|
|
170
170
|
Offset for the Y axis.
|
|
171
171
|
"""
|
|
172
172
|
|
|
173
|
-
return self._pad_parameter_value[3]
|
|
173
|
+
return Value(self._pad_parameter_value[3])
|
|
174
174
|
|
|
175
175
|
@offset_x.setter
|
|
176
176
|
def offset_x(self, value):
|
|
@@ -190,7 +190,7 @@ class PadProperties:
|
|
|
190
190
|
Value for the rotation.
|
|
191
191
|
"""
|
|
192
192
|
|
|
193
|
-
return self._pad_parameter_value[4]
|
|
193
|
+
return Value(self._pad_parameter_value[4])
|
|
194
194
|
|
|
195
195
|
@rotation.setter
|
|
196
196
|
def rotation(self, value):
|
|
@@ -218,27 +218,27 @@ class PadProperties:
|
|
|
218
218
|
if params is None:
|
|
219
219
|
params = self._pad_parameter_value[1]
|
|
220
220
|
elif isinstance(params, list):
|
|
221
|
-
offsetx = [
|
|
221
|
+
offsetx = [Value(i, self._pedbpadstack._pedb.db) for i in params]
|
|
222
222
|
if rotation is None:
|
|
223
223
|
rotation = self._pad_parameter_value[4]
|
|
224
224
|
elif isinstance(rotation, (str, float, int)):
|
|
225
|
-
rotation =
|
|
225
|
+
rotation = Value(rotation, self._pedbpadstack._pedb.db)
|
|
226
226
|
if offsetx is None:
|
|
227
227
|
offsetx = self._pad_parameter_value[2]
|
|
228
228
|
elif isinstance(offsetx, (str, float, int)):
|
|
229
|
-
offsetx =
|
|
229
|
+
offsetx = Value(offsetx, self._pedbpadstack._pedb.db)
|
|
230
230
|
if offsety is None:
|
|
231
231
|
offsety = self._pad_parameter_value[3]
|
|
232
232
|
elif isinstance(offsety, (str, float, int)):
|
|
233
|
-
offsety =
|
|
233
|
+
offsety = Value(offsety, self._pedbpadstack._pedb.db)
|
|
234
234
|
self._edb_padstack.set_pad_parameters(
|
|
235
235
|
layer=layer_name,
|
|
236
236
|
pad_type=pad_type,
|
|
237
237
|
type_geom=geom_type,
|
|
238
|
-
offset_x=
|
|
239
|
-
offset_y=
|
|
240
|
-
rotation=
|
|
241
|
-
sizes=[
|
|
238
|
+
offset_x=Value(offsetx, self._pedbpadstack._pedb.db),
|
|
239
|
+
offset_y=Value(offsety, self._pedbpadstack._pedb.db),
|
|
240
|
+
rotation=Value(rotation, self._pedbpadstack._pedb.db),
|
|
241
|
+
sizes=[Value(i, self._pedbpadstack._pedb.db) for i in params],
|
|
242
242
|
)
|
|
243
243
|
|
|
244
244
|
|
|
@@ -324,7 +324,7 @@ class PadstackDef(GrpcPadstackDef):
|
|
|
324
324
|
try:
|
|
325
325
|
hole_parameter = self.data.get_hole_parameters()
|
|
326
326
|
if hole_parameter[0].name.lower() == "padgeomtype_circle":
|
|
327
|
-
return
|
|
327
|
+
return Value(hole_parameter[1][0])
|
|
328
328
|
except:
|
|
329
329
|
return 0.0
|
|
330
330
|
|
|
@@ -332,9 +332,9 @@ class PadstackDef(GrpcPadstackDef):
|
|
|
332
332
|
def hole_diameter(self, value):
|
|
333
333
|
hole_parameter = self.data.get_hole_parameters()
|
|
334
334
|
if not isinstance(value, list):
|
|
335
|
-
value = [
|
|
335
|
+
value = [Value(value)]
|
|
336
336
|
else:
|
|
337
|
-
value = [
|
|
337
|
+
value = [Value(p) for p in value]
|
|
338
338
|
hole_size = value
|
|
339
339
|
geometry_type = hole_parameter[0]
|
|
340
340
|
hole_offset_x = hole_parameter[2]
|
|
@@ -359,7 +359,7 @@ class PadstackDef(GrpcPadstackDef):
|
|
|
359
359
|
hole type.
|
|
360
360
|
|
|
361
361
|
"""
|
|
362
|
-
return self.data.get_hole_parameters()[0]
|
|
362
|
+
return Value(self.data.get_hole_parameters()[0])
|
|
363
363
|
|
|
364
364
|
@property
|
|
365
365
|
def edb_hole_type(self):
|
|
@@ -383,14 +383,14 @@ class PadstackDef(GrpcPadstackDef):
|
|
|
383
383
|
Hole offset value for the X axis.
|
|
384
384
|
"""
|
|
385
385
|
try:
|
|
386
|
-
return
|
|
386
|
+
return Value(self.data.get_hole_parameters()[2])
|
|
387
387
|
except:
|
|
388
388
|
return 0.0
|
|
389
389
|
|
|
390
390
|
@hole_offset_x.setter
|
|
391
391
|
def hole_offset_x(self, value):
|
|
392
392
|
hole_parameter = list(self.data.get_hole_parameters())
|
|
393
|
-
hole_parameter[2] =
|
|
393
|
+
hole_parameter[2] = Value(value, self._pedb.db)
|
|
394
394
|
self.data.set_hole_parameters(
|
|
395
395
|
offset_x=hole_parameter[2],
|
|
396
396
|
offset_y=hole_parameter[3],
|
|
@@ -409,14 +409,14 @@ class PadstackDef(GrpcPadstackDef):
|
|
|
409
409
|
Hole offset value for the Y axis.
|
|
410
410
|
"""
|
|
411
411
|
try:
|
|
412
|
-
return
|
|
412
|
+
return Value(self.data.get_hole_parameters()[3])
|
|
413
413
|
except:
|
|
414
414
|
return 0.0
|
|
415
415
|
|
|
416
416
|
@hole_offset_y.setter
|
|
417
417
|
def hole_offset_y(self, value):
|
|
418
418
|
hole_parameter = list(self.data.get_hole_parameters())
|
|
419
|
-
hole_parameter[3] =
|
|
419
|
+
hole_parameter[3] = Value(value, self._pedb.db)
|
|
420
420
|
self.data.set_hole_parameters(
|
|
421
421
|
offset_x=hole_parameter[2],
|
|
422
422
|
offset_y=hole_parameter[3],
|
|
@@ -435,14 +435,14 @@ class PadstackDef(GrpcPadstackDef):
|
|
|
435
435
|
Value for the hole rotation.
|
|
436
436
|
"""
|
|
437
437
|
try:
|
|
438
|
-
return
|
|
438
|
+
return Value(self.data.get_hole_parameters()[4])
|
|
439
439
|
except:
|
|
440
440
|
return 0.0
|
|
441
441
|
|
|
442
442
|
@hole_rotation.setter
|
|
443
443
|
def hole_rotation(self, value):
|
|
444
444
|
hole_parameter = list(self.data.get_hole_parameters())
|
|
445
|
-
hole_parameter[4] =
|
|
445
|
+
hole_parameter[4] = Value(value, self._pedb.db)
|
|
446
446
|
self.data.set_hole_parameters(
|
|
447
447
|
offset_x=hole_parameter[2],
|
|
448
448
|
offset_y=hole_parameter[3],
|
|
@@ -511,11 +511,11 @@ class PadstackDef(GrpcPadstackDef):
|
|
|
511
511
|
float
|
|
512
512
|
Percentage for the hole plating.
|
|
513
513
|
"""
|
|
514
|
-
return
|
|
514
|
+
return Value(self.data.plating_percentage)
|
|
515
515
|
|
|
516
516
|
@hole_plating_ratio.setter
|
|
517
517
|
def hole_plating_ratio(self, ratio):
|
|
518
|
-
self.data.plating_percentage =
|
|
518
|
+
self.data.plating_percentage = Value(ratio)
|
|
519
519
|
|
|
520
520
|
@property
|
|
521
521
|
def hole_plating_thickness(self) -> float:
|
|
@@ -543,7 +543,7 @@ class PadstackDef(GrpcPadstackDef):
|
|
|
543
543
|
float
|
|
544
544
|
Thickness of the hole plating if present.
|
|
545
545
|
"""
|
|
546
|
-
hr = 200 *
|
|
546
|
+
hr = 200 * Value(value) / self.hole_diameter
|
|
547
547
|
self.hole_plating_ratio = hr
|
|
548
548
|
|
|
549
549
|
@property
|
|
@@ -671,9 +671,9 @@ class PadstackDef(GrpcPadstackDef):
|
|
|
671
671
|
layout,
|
|
672
672
|
self.start_layer,
|
|
673
673
|
via.net,
|
|
674
|
-
|
|
675
|
-
|
|
676
|
-
|
|
674
|
+
Value(pos[0]),
|
|
675
|
+
Value(pos[1]),
|
|
676
|
+
Value(self.pad_by_layer[self.start_layer].parameters_values[0] / 2),
|
|
677
677
|
)
|
|
678
678
|
if len(self.pad_by_layer[self.stop_layer].parameters_values) == 0:
|
|
679
679
|
self._pedb.modeler.create_polygon(
|
|
@@ -686,9 +686,9 @@ class PadstackDef(GrpcPadstackDef):
|
|
|
686
686
|
layout,
|
|
687
687
|
self.stop_layer,
|
|
688
688
|
via.net,
|
|
689
|
-
|
|
690
|
-
|
|
691
|
-
|
|
689
|
+
Value(pos[0]),
|
|
690
|
+
Value(pos[1]),
|
|
691
|
+
Value(self.pad_by_layer[self.stop_layer].parameters_values[0] / 2),
|
|
692
692
|
)
|
|
693
693
|
for layer_name in layer_names:
|
|
694
694
|
stop = ""
|
|
@@ -699,17 +699,17 @@ class PadstackDef(GrpcPadstackDef):
|
|
|
699
699
|
layout,
|
|
700
700
|
start,
|
|
701
701
|
via.net,
|
|
702
|
-
|
|
703
|
-
|
|
704
|
-
|
|
702
|
+
Value(pos[0]),
|
|
703
|
+
Value(pos[1]),
|
|
704
|
+
Value(rad1),
|
|
705
705
|
)
|
|
706
706
|
cloned_circle2 = GrpcCircle.create(
|
|
707
707
|
layout,
|
|
708
708
|
stop,
|
|
709
709
|
via.net,
|
|
710
|
-
|
|
711
|
-
|
|
712
|
-
|
|
710
|
+
Value(pos[0]),
|
|
711
|
+
Value(pos[1]),
|
|
712
|
+
Value(rad2),
|
|
713
713
|
)
|
|
714
714
|
s3d = GrpcStructure3D.create(
|
|
715
715
|
layout, generate_unique_name("via3d_" + via.aedt_name.replace("via_", ""), n=3)
|
|
@@ -771,9 +771,9 @@ class PadstackDef(GrpcPadstackDef):
|
|
|
771
771
|
new_padstack_definition.data.set_pad_parameters(
|
|
772
772
|
layer=layer,
|
|
773
773
|
pad_type=GrpcPadType.REGULAR_PAD,
|
|
774
|
-
offset_x=
|
|
775
|
-
offset_y=
|
|
776
|
-
rotation=
|
|
774
|
+
offset_x=Value(pl.offset_x, self._pedb.db),
|
|
775
|
+
offset_y=Value(pl.offset_y, self._pedb.db),
|
|
776
|
+
rotation=Value(pl.rotation, self._pedb.db),
|
|
777
777
|
type_geom=pl._edb_geometry_type,
|
|
778
778
|
sizes=pl.parameters_values,
|
|
779
779
|
)
|
|
@@ -783,9 +783,9 @@ class PadstackDef(GrpcPadstackDef):
|
|
|
783
783
|
new_padstack_definition.data.set_pad_parameters(
|
|
784
784
|
layer=layer,
|
|
785
785
|
pad_type=GrpcPadType.ANTI_PAD,
|
|
786
|
-
offset_x=
|
|
787
|
-
offset_y=
|
|
788
|
-
rotation=
|
|
786
|
+
offset_x=Value(pl.offset_x, self._pedb.db),
|
|
787
|
+
offset_y=Value(pl.offset_y, self._pedb.db),
|
|
788
|
+
rotation=Value(pl.rotation, self._pedb.db),
|
|
789
789
|
type_geom=pl._edb_geometry_type,
|
|
790
790
|
sizes=pl.parameters_values,
|
|
791
791
|
)
|
|
@@ -795,21 +795,21 @@ class PadstackDef(GrpcPadstackDef):
|
|
|
795
795
|
new_padstack_definition.data.set_pad_parameters(
|
|
796
796
|
layer=layer,
|
|
797
797
|
pad_type=GrpcPadType.THERMAL_PAD,
|
|
798
|
-
offset_x=
|
|
799
|
-
offset_y=
|
|
800
|
-
rotation=
|
|
798
|
+
offset_x=Value(pl.offset_x, self._pedb.db),
|
|
799
|
+
offset_y=Value(pl.offset_y, self._pedb.db),
|
|
800
|
+
rotation=Value(pl.rotation, self._pedb.db),
|
|
801
801
|
type_geom=pl._edb_geometry_type,
|
|
802
802
|
sizes=pl.parameters_values,
|
|
803
803
|
)
|
|
804
804
|
new_padstack_definition.data.set_hole_parameters(
|
|
805
|
-
offset_x=
|
|
806
|
-
offset_y=
|
|
807
|
-
rotation=
|
|
805
|
+
offset_x=Value(self.hole_offset_x, self._pedb.db),
|
|
806
|
+
offset_y=Value(self.hole_offset_y, self._pedb.db),
|
|
807
|
+
rotation=Value(self.hole_rotation, self._pedb.db),
|
|
808
808
|
type_geom=self.edb_hole_type,
|
|
809
809
|
sizes=[self.hole_diameter],
|
|
810
810
|
)
|
|
811
811
|
new_padstack_definition.data.material = self.material
|
|
812
|
-
new_padstack_definition.data.plating_percentage =
|
|
812
|
+
new_padstack_definition.data.plating_percentage = Value(self.hole_plating_ratio, self._pedb.db)
|
|
813
813
|
new_instances.append(PadstackDef(self._pedb, new_padstack_definition))
|
|
814
814
|
started = True
|
|
815
815
|
if self.stop_layer == stop:
|
|
@@ -23,6 +23,8 @@
|
|
|
23
23
|
|
|
24
24
|
from ansys.edb.core.geometry.arc_data import ArcData as GrpcArcData
|
|
25
25
|
|
|
26
|
+
from pyedb.grpc.database.utility.value import Value
|
|
27
|
+
|
|
26
28
|
|
|
27
29
|
class ArcData(GrpcArcData):
|
|
28
30
|
"""Class managing ArcData."""
|
|
@@ -42,7 +44,7 @@ class ArcData(GrpcArcData):
|
|
|
42
44
|
[x value, y value]
|
|
43
45
|
|
|
44
46
|
"""
|
|
45
|
-
return [
|
|
47
|
+
return [Value(super().center.x), Value(super().center.y)]
|
|
46
48
|
|
|
47
49
|
@property
|
|
48
50
|
def start(self) -> list[float]:
|
|
@@ -54,7 +56,7 @@ class ArcData(GrpcArcData):
|
|
|
54
56
|
[x value, y value]
|
|
55
57
|
|
|
56
58
|
"""
|
|
57
|
-
return [
|
|
59
|
+
return [Value(super().start.x), Value(super().start.y)]
|
|
58
60
|
|
|
59
61
|
@property
|
|
60
62
|
def end(self) -> list[float]:
|
|
@@ -66,7 +68,7 @@ class ArcData(GrpcArcData):
|
|
|
66
68
|
[x value, y value]
|
|
67
69
|
|
|
68
70
|
"""
|
|
69
|
-
return [self.end.x
|
|
71
|
+
return [Value(self.end.x), Value(self.end.y)]
|
|
70
72
|
|
|
71
73
|
@property
|
|
72
74
|
def mid_point(self) -> list[float]:
|
|
@@ -78,7 +80,7 @@ class ArcData(GrpcArcData):
|
|
|
78
80
|
[x value, y value]
|
|
79
81
|
|
|
80
82
|
"""
|
|
81
|
-
return [self.midpoint.x
|
|
83
|
+
return [Value(self.midpoint.x), Value(self.midpoint.y)]
|
|
82
84
|
|
|
83
85
|
@property
|
|
84
86
|
def points(self) -> list[list[float]]:
|
|
@@ -90,4 +92,4 @@ class ArcData(GrpcArcData):
|
|
|
90
92
|
[[x value, y value]]
|
|
91
93
|
|
|
92
94
|
"""
|
|
93
|
-
return [[pt.x
|
|
95
|
+
return [[Value(pt.x), Value(pt.y)] for pt in self.points]
|