|
1 record(ai, "$(P)$(R)GetRadiation_1") |
|
2 { |
|
3 field(DESC, "Get Radiation") |
|
4 field(DTYP, "stream") |
|
5 field(INP, "@fht.proto getRadiation(138) $(BUS)") |
|
6 field(SCAN, "1 second") |
|
7 field(EGU, "uSv/h") |
|
8 field(FLNK, "$(P)$(R)GetRadiation_1:Hour") |
|
9 } |
|
10 |
|
11 record(calc, "$(P)$(R)GetRadiation_1:Add") { |
|
12 field(INPA, "$(P)$(R)GetRadiation_1 CP NMS") |
|
13 field(INPB, "1") |
|
14 field(CALC, "B>0?VAL+A:0;B:=1") |
|
15 field(FLNK, "$(P)$(R)GetRadiation_1:Counter") |
|
16 } |
|
17 |
|
18 record(calc, "$(P)$(R)GetRadiation_1:Counter") { |
|
19 field(INPA, "$(P)$(R)GetRadiation_1:Add NPP ") |
|
20 field(CALC, "A>0?VAL+1:0") |
|
21 field(FLNK, "$(P)$(R)GetRadiation_1:SumOneHour") |
|
22 } |
|
23 |
|
24 record(calc, "$(P)$(R)GetRadiation_1:SumOneHour") { |
|
25 field(INPA, "$(P)$(R)GetRadiation_1:Add NPP ") |
|
26 field(INPB, "$(P)$(R)GetRadiation_1:Counter NPP ") |
|
27 field(CALC, "B>0?A/B:0") |
|
28 field(EGU, "uSv/h") |
|
29 } |
|
30 |
|
31 record(stringin, "$(P)$(R)GetRadiation_1:Hour") { |
|
32 field(DTYP, "Soft Timestamp") |
|
33 field(INP, "@%M") |
|
34 field(TSEL, "$(P)$(R)GetRadiation_1.TIME") |
|
35 field(FLNK, "$(P)$(R)GetRadiation_1:HourClear") |
|
36 } |
|
37 |
|
38 record(calcout, "$(P)$(R)GetRadiation_1:HourClear") { |
|
39 field(INPA, "$(P)$(R)GetRadiation_1:Hour NPP NMS") |
|
40 field(INPB, "0") |
|
41 field(CALC, "A<B?0:1;B:=A") |
|
42 field(DOPT, "Use CALC") |
|
43 field(OOPT, "When Zero") |
|
44 field(OUT, "$(P)$(R)GetRadiation_1:Add.B PP") |
|
45 } |
|
46 |
|
47 |
|
48 record(ai, "$(P)$(R)GetRadiation_2") |
|
49 { |
|
50 field(DESC, "Get Radiation") |
|
51 field(DTYP, "stream") |
|
52 field(INP, "@fht.proto getRadiation(239) $(BUS)") |
|
53 field(EGU, "uSiv") |
|
54 field(SCAN, "1 second") |
|
55 field(FLNK, "$(P)$(R)GetRadiation_2:Hour") |
|
56 } |
|
57 |
|
58 record(calc, "$(P)$(R)GetRadiation_2:Add") { |
|
59 field(INPA, "$(P)$(R)GetRadiation_2 CP NMS") |
|
60 field(INPB, "1") |
|
61 field(CALC, "B>0?VAL+A:0;B:=1") |
|
62 field(FLNK, "$(P)$(R)GetRadiation_2:Counter") |
|
63 } |
|
64 |
|
65 record(calc, "$(P)$(R)GetRadiation_2:Counter") { |
|
66 field(INPA, "$(P)$(R)GetRadiation_2:Add NPP ") |
|
67 field(CALC, "A>0?VAL+1:0") |
|
68 field(FLNK, "$(P)$(R)GetRadiation_2:SumOneHour") |
|
69 } |
|
70 |
|
71 record(calc, "$(P)$(R)GetRadiation_2:SumOneHour") { |
|
72 field(INPA, "$(P)$(R)GetRadiation_2:Add NPP ") |
|
73 field(INPB, "$(P)$(R)GetRadiation_2:Counter NPP ") |
|
74 field(CALC, "B>0?A/B:0") |
|
75 field(EGU, "uSv/h") |
|
76 } |
|
77 |
|
78 record(stringin, "$(P)$(R)GetRadiation_2:Hour") { |
|
79 field(DTYP, "Soft Timestamp") |
|
80 field(INP, "@%M") |
|
81 field(TSEL, "$(P)$(R)GetRadiation_2.TIME") |
|
82 field(FLNK, "$(P)$(R)GetRadiation_2:HourClear") |
|
83 } |
|
84 |
|
85 record(calcout, "$(P)$(R)GetRadiation_2:HourClear") { |
|
86 field(INPA, "$(P)$(R)GetRadiation_2:Hour NPP NMS") |
|
87 field(INPB, "0") |
|
88 field(CALC, "A<B?0:1;B:=A") |
|
89 field(DOPT, "Use CALC") |
|
90 field(OOPT, "When Zero") |
|
91 field(OUT, "$(P)$(R)GetRadiation_2:Add.B PP") |
|
92 } |