HatchGround#
- class pyedb.libraries.rf_libraries.base_functions.HatchGround(edb_cell: Edb | None = None, pitch: str | float = 0.01707, width: str | float = 0.005, fill_target: str | float = 50.0, ground_width: str | float = 0.1, ground_length: str | float = 0.1, layer_gnd: str = 'GND', angle: float = 0.0)#
Create a rectangular demo board whose ground layer is filled with an orthogonal hatched copper pattern.
Any requested copper fill ratio between 10 % and 90 % can be realised. The hatch is generated by drawing orthogonal copper stripes and then punching square voids to achieve the desired fill percentage.
- Parameters:
- edb_cell
Edb,optional EDB layout database in which the geometry will be created. If omitted, the object is created in a detached state and must be attached to an EDB instance via the
_edbattribute before callingcreate().- pitch
floatorstr,default17.07e-3 Centre-to-centre distance between adjacent hatch bars [m].
- width
floatorstr,default5.0e-3 Width of each copper bar [m].
- fill_target
floatorstr,default50.0 Desired copper area in percent (10 … 90).
- ground_width
floatorstr,default100.0e-3 Width (x-span) of the rectangular board [m].
- ground_length
floatorstr,default100.0e-3 Length (y-span) of the rectangular board [m].
- layer_gnd
str,default“GND” Name of the layer that receives the hatch pattern.
- angle
float,default0.0 Rotation angle of the hatch pattern in degrees. A positive value rotates the pattern counter-clockwise around the board centre.
- edb_cell
Examples
>>> hatch = HatchGround(pitch=0.5e-3, width=0.2e-3, fill_target=70, ground_width=5e-3, ground_length=5e-3) >>> edb = Edb("demo.aedb") >>> hatch._edb = edb >>> hatch.create() >>> round(hatch.copper_fill_ratio, 1) 70.0
- Attributes:
copper_fill_ratiofloatReturn the actual copper fill ratio in percent.
Methods
Generate the stack-up, board outline and hatch pattern.