add_ecad_component_model#
- MCADAssembly.add_ecad_component_model(name: str, path: str)#
Register an ECAD component model.
Add a named ECAD (layout/PCB) component model that can be referenced when instantiating components in the assembly. This is the first step in using a PCB layout - register it before creating instances.
- Parameters:
Examples
Register PCB layout models:
>>> assembly = MCADAssembly() >>> assembly.add_ecad_component_model(name="MainBoard", path="pcb/main_assembly.aedb") >>> assembly.add_ecad_component_model(name="DaughterBoard", path="pcb/daughter_card.aedb")
Create instances from registered models:
>>> main_pcb = assembly.add_sub_ecad_component(name="PCB_1", model="MainBoard")