本帖最后由 dianzi1987 于 2018-6-26 12:36 编辑 ( P$ }. D. A' |; l
3 n0 t% n0 m) l( i5 S2 Q7 T; cAD语法是精华,可以说,只有想不到的,没有做不到的。做好用过的语法可以添加到喜爱,按快捷键Y调用。当前用到的:
% e: D! s; U% F. L1 v目的1:是选中,然后按需要编辑。
9 Q. N; Z0 O. M0 y* _8 d# C目的2:定义规则或者条件筛选
. x( K0 K% i/ m% ?% }) I; |* j T1 ?" W" U8 Q9 }+ o
1.180度 0度 360度元件:IsComponent And(Rotation = 180)or IsComponent And(Rotation = 0)or IsComponent And(Rotation = 360) 5 U( h4 H* z6 K7 H; r3 _- D
2 .底层90度与270度元件:OnBottomLayer and IsComponent And(Rotation = 90)or OnBottomLayer and IsComponent And(Rotation = 270) * `( {+ i! T2 G, F4 s4 y+ @+ T( W
3. 顶层90度与270度元件:OnTopLayer and IsComponent And(Rotation = 90)or OnTopLayer and IsComponent And(Rotation = 270) 4.非GND网络焊盘:(ObjectKind = 'Via') And (Net <> 'GND') OR(ObjectKind = 'Pad') And (Net <> 'GND') 5.顶层元件: IsComponent and OnTopLayer 6.底层元件:IsComponent and OnBottomLayer 7.顶层到3.3V层面的过孔:(ObjectKind = 'Via') And (StartLayer = 'Top Layer') And (StopLayer = '3.3V')
4 }, {3 p; c( e5 {5 y+ u& R: y5 n8.选取的封装决定铺铜类型,规则设置用: HasFootprint('USB4PIN') 9.选取某一焊盘:Haspad 10.板挖空与电气部分短路设置为允许的语法。 11.IsBoardCutoutRegion 12.选择不是standard的元件,用在BOM数量对照上。 (ObjectKind = 'Component') And (ComponentType <> 'Standard') 8 _9 X9 w6 [: I3 |& x ]
X6 S2 V4 L2 _4 P% e, p: d% ^: K6 v' E以下来自网友“星罗棋布”,是通过定义命令菜单实现的,相对麻烦一些。 只操作顶层走线的表达式为:expr=IsTrack and OnTopLayer|mask=True|apply=True
4 n) o- Q+ V! I) x4 B/ I只操作底层走线的表达式为:expr=IsTrack and OnBottomLayer|mask=True|apply=True+ W( V7 m0 h$ V/ d& t
只操作电气走线的表达式为:expr=IsTrack and IsElectrical|mask=True|apply=True( F* a, V, h4 ]* w& \
只操作过孔的表达式为: expr=IsVia|mask=True|apply=True
0 \& b! u. i9 Y只操作顶层元件的表达式为:expr=IsComponent and OnTopLayer|mask=True|apply=True 0 T& w8 [/ y% y
expr,表达式;
% d) h3 o4 A6 }iscomponent,对象是元件;
v% ^% @' ]7 N0 e1 ]4 Band,并且;: R3 g- o! A! r9 a0 a
onbottomlayer,在底层;
4 z; y; b6 M6 R, ~- K, Vmask=true,进行掩码操作;
: ?% \+ \ h4 X0 r, }/ n. P( N3 papply=true,应用确认。 2 u$ A C4 x6 d$ K* U
|