|
发表于 2016-6-17 10:26:04
|
显示全部楼层
procedure(replace_dev(myWorkLib source_lib source_dev target_lib target_dev)
let((cell_list sch_cv targetId w l)
cell_list=ddGetObj(myWorklib)~>cells~>name
foreach(cell cell_list
sch_cv= dbOpenCellViewByType(source_lib cell "schematic" "schematic" "a")
if(sch_cv then
foreach(inst sch_cv~>instances
if(inst~>cellName == source_dev then
targetId=dbOpenCellViewByType(target_lib target_dev "symbol" "" "r")
if(targetId then
w=inst~>w
l=inst~>l
inst~>master=targetId
inst~>w=w
;;need trigger callback for "w"
inst~>l=l
;;need trigger callback for "l“
dbClose(targetId)
);if
);if
);foreach
dbSave(sch_cv)
dbClose(sch_cv)
);if
);foreach
);let
);procedure
没太仔细看你以前code, 现在重新修改了下 , 加了个参数myWorkLib是你要修改的library, source_lib 以及target_lib是 新旧PDK, 默认的替换的view是symbol。你再试试 |
|