2021年9月23日 星期四

如何呼叫API查詢函式

PyAEDT的查詢功能較AEDT內建的API而言,較不容易使用。因為API查詢函數一般不需要下太多參數,我們可以在PyAEDT當中調用API的查詢函數,如下:

import pyaedt

app = pyaedt.Hfss3dLayout("D:/demo_pyaedt/Galileo_G87173_2042.aedt",
'Galileo_G87173_204',
non_graphical=True,
new_desktop_session=True,
close_on_exit=True,
student_version=False)
try:
modeler = app.modeler

oEditor = modeler.oeditor
print(oEditor.GetNets())
print(oEditor.FindObjects('Type', 'poly'))
print(oEditor.GetStackupLayerNames())
for i in oEditor.GetStackupLayerNames():
print(oEditor.GetLayerInfo(i))
except:
pass
finally:
app.close_desktop()
(圖一)查詢結果輸出


沒有留言:

張貼留言

EDB建立PinGroup

為U2A5建立GND PinGroup,儲存之後匯入EDB from pyaedt import Edb edb = Edb(edbpath= r"D:\demo\Galileo_G87173_20454.aedb" , edbversion= '20...