Root/bom/atrf.sub

Source at commit 1a5d9f5a1e1ed02cc887498bd4a1f9223d029ff7 created 9 years 11 months ago.
By Werner Almesberger, bom/: automatic BOM generation (work in progress)
1#SUB
2
3# Taked from gta02-core. Left in the hacks, since we may use similar components
4# in the future.
5
6-> T=unknown
7
8R[0-9P]* { # also handle RP...
9    -> T=R
10    VAL=$R -> R=$VAL
11# -> TOL=5%
12    FN=$% -> TOL=$FN
13}
14
15RP[0-9]* {
16    -> T=RA
17    RP220[123] -> ARRAY=4
18    # the other parameters have already been taken care of by R*
19}
20
21C[0-9]* {
22    -> T=C
23    VAL=$F -> C=$VAL
24    FN=*V -> V=>=$FN
25}
26
27L[0-9]* {
28    -> T=L
29    VAL=$H -> L=$VAL
30    FN=*A -> I=>=$FN
31}
32
33B[0-9]* {
34    -> T=FILTER M=BEAD
35    VAL=$R -> R=$VAL
36    FN=*A -> I=$FN
37    FN=*R -> Rdc=$FN
38    FN=0.45R -> Rdc=450mR # hack
39}
40
41D[0-9]* {
42    -> T=D
43    VAL=*F { # heuristic to detect TVS
44    -> M=TVS
45    VAL=*F -> C=<=$VAL
46    FN=(*V)ac -> Vac=$FN:1
47    FN=(*V)dc -> Vdc=$FN:1
48
49    #
50    # Hack: some companies specify the class of varistors with Vdc = 9 V
51    # as Vac = 6.5 V while others use Vac = 7 V. Sometimes, Vac is even
52    # omitted entirely.
53    #
54    # Here, we work around the issue that Karmax use Vac = 6.5 V,
55    # Cooper/Bussmann use Vac = 7V if at all, and out schematics specify
56    # Vac = 6.5 V.
57    #
58    Vac=6.5V {
59        -> Vac=
60        -> Vdc=9V
61    }
62    }
63}
64
65
66FP=meander -> VAL=meander
67FP=uSD-Card -> VAL=uSD-Card
68

Archive Download this file



interactive