|
有人问检查出缺失以后,怎么添加呢? 给一段代码大家自己改下吧!
0 X. L' ]' T2 O9 `' X* @$ z/*下面是给器件添加REF的代码:
$ Q7 _5 p; F# t& |: R8 {if(car(n0->violations)->isMirrored then
, l( ~! N0 o. m* ]( b' ~layer = "BOTTOM"8 y( V$ Q! H7 ?8 r3 H$ @
else* L; s% d) {: l# p, ]+ b1 h
layer = "TOP"! `7 o# U' D# O8 B3 M8 X, H- a
)4 \8 \0 _" c- u
textstru = make_axlTextOrientation(?textBlock 1 ?mirrored car(n0->violations)->isMirrored ?justify "center")
7 ]2 L, H4 o6 o, w/ i2 C( [tt = setof(x0 axlDBGetAttachedText(car(n0->violations)) rexMatchp("REF DES/SILKSCREEN_+" x0->layer))% G$ T* C$ w4 g! |9 f7 {8 \* P
unless(tt
3 Q! k5 f; ?9 `; f' F. iaxlDBCreateText(car(n0->violations)->refdes car(n0->violations)->xy textstru strcat("REF DES/SILKSCREEN_" layer) car(n0->violations))9 S2 K/ i) u3 {# q' E/ q7 N0 s
); o; R( x+ N$ z1 K* o
tt = setof(x0 axlDBGetAttachedText(car(n0->violations)) rexMatchp("REF DES/ASSEMBLY_+" x0->layer))
5 W; {: l1 |* [1 m- G1 v' eunless(tt; d. u+ h) a. y" ], ~) ]$ G6 ~9 T- C
axlDBCreateText(car(n0->violations)->refdes car(n0->violations)->xy textstru strcat("REF DES/ASSEMBLY_" layer) car(n0->violations))7 `$ k) |- z6 H
) |
|