1 | function step_synchro_rafale(DirName) |
---|
2 | % step central and delay on address 3 only |
---|
3 | |
---|
4 | n=1; |
---|
5 | % % central |
---|
6 | % temp=tango_read_attribute2('ANS/SY/CENTRAL', 'TPcStepDelay'); |
---|
7 | % timing.central_pc=temp.value(n); |
---|
8 | % |
---|
9 | % temp=tango_read_attribute2('ANS/SY/CENTRAL', 'TInjStepDelay'); |
---|
10 | % timing.central_inj=temp.value(n); |
---|
11 | % |
---|
12 | % temp=tango_read_attribute2('ANS/SY/CENTRAL', 'TSoftStepDelay'); |
---|
13 | % timing.central_soft=temp.value(n); |
---|
14 | % |
---|
15 | % temp=tango_read_attribute2('ANS/SY/CENTRAL', 'TSprStepDelay'); |
---|
16 | % timing.central_spare=temp.value(n); |
---|
17 | % |
---|
18 | % temp=tango_read_attribute2('ANS/SY/CENTRAL', 'ExtractionOffsetClkStepValue'); |
---|
19 | % timing.central_ext=temp.value(n); |
---|
20 | |
---|
21 | offsettime=70000; |
---|
22 | offset=176*offsettime; |
---|
23 | |
---|
24 | |
---|
25 | % ext on add 3 |
---|
26 | |
---|
27 | temp=tango_read_attribute2('BOO/SY/LOCAL.Bext.1', 'dof.trigStepDelay'); |
---|
28 | tango_write_attribute2('BOO/SY/LOCAL.Bext.1', 'dof.trigStepDelay',temp.value(1)+offset); |
---|
29 | |
---|
30 | |
---|
31 | temp=tango_read_attribute2('BOO/SY/LOCAL.Bext.1', 'sep-p.trigStepDelay'); |
---|
32 | tango_write_attribute2('BOO/SY/LOCAL.Bext.1', 'sep-p.trigStepDelay',temp.value(1)+offset); |
---|
33 | |
---|
34 | temp=tango_read_attribute2('BOO/SY/LOCAL.Bext.1', 'sep-a.trigStepDelay'); |
---|
35 | tango_write_attribute2('BOO/SY/LOCAL.Bext.1', 'sep-a.trigStepDelay',temp.value(1)+offset); |
---|
36 | |
---|
37 | |
---|
38 | temp=tango_read_attribute2('BOO/SY/LOCAL.Bext.1', 'k.trigStepDelay'); |
---|
39 | tango_write_attribute2('BOO/SY/LOCAL.Bext.1', 'k.trigStepDelay',temp.value(1)+offset); |
---|
40 | |
---|
41 | temp=tango_read_attribute2('ANS/SY/LOCAL.SDC.1', 'spareStepDelay'); |
---|
42 | tango_write_attribute2('ANS/SY/LOCAL.SDC.1', 'spareStepDelay',temp.value(1)+offset); |
---|
43 | |
---|
44 | temp=tango_read_attribute2('BOO/SY/LOCAL.DG.3', 'emittanceTimeDelay'); |
---|
45 | tango_write_attribute2('BOO/SY/LOCAL.DG.3', 'emittanceTimeDelay',temp.value(1)+offset); |
---|
46 | |
---|
47 | % LT2 |
---|
48 | temp=tango_read_attribute2('LT2/SY/LOCAL.DG.1', 'mrsvStepDelay'); |
---|
49 | tango_write_attribute2('LT2/SY/LOCAL.DG.1', 'mrsvStepDelay',temp.value(1)+offset); |
---|
50 | |
---|
51 | temp=tango_read_attribute2('LT2/SY/LOCAL.DG.1', 'osc-fctStepDelay'); |
---|
52 | tango_write_attribute2('LT2/SY/LOCAL.DG.1', 'osc-fctStepDelay',temp.value(1)+offset); |
---|
53 | |
---|
54 | temp=tango_read_attribute2('LT2/SY/LOCAL.DG.2', 'bpm.trigStepDelay'); |
---|
55 | tango_write_attribute2('LT2/SY/LOCAL.DG.2', 'bpm.trigStepDelay',temp.value(1)+offset); |
---|
56 | |
---|
57 | % ANS |
---|
58 | temp=tango_read_attribute2('ANS-C01/SY/LOCAL.Ainj.1', 'k1.trigStepDelay'); |
---|
59 | tango_write_attribute2('ANS-C01/SY/LOCAL.Ainj.1', 'k1.trigStepDelay',temp.value(1)+offset); |
---|
60 | |
---|
61 | temp=tango_read_attribute2('ANS-C01/SY/LOCAL.Ainj.1', 'k2.trigStepDelay'); |
---|
62 | tango_write_attribute2('ANS-C01/SY/LOCAL.Ainj.1', 'k2.trigStepDelay',temp.value(1)+offset); |
---|
63 | |
---|
64 | temp=tango_read_attribute2('ANS-C01/SY/LOCAL.Ainj.1', 'k3.trigStepDelay'); |
---|
65 | tango_write_attribute2('ANS-C01/SY/LOCAL.Ainj.1', 'k3.trigStepDelay',temp.value(1)+offset); |
---|
66 | |
---|
67 | temp=tango_read_attribute2('ANS-C01/SY/LOCAL.Ainj.1', 'k4.trigStepDelay'); |
---|
68 | tango_write_attribute2('ANS-C01/SY/LOCAL.Ainj.1', 'k4.trigStepDelay',temp.value(1)+offset); |
---|
69 | |
---|
70 | temp=tango_read_attribute2('ANS-C01/SY/LOCAL.Ainj.2', 'sep-p.trigStepDelay'); |
---|
71 | tango_write_attribute2('ANS-C01/SY/LOCAL.Ainj.2', 'sep-p.trigStepDelay',temp.value(1)+offset); |
---|
72 | |
---|
73 | temp=tango_read_attribute2('ANS-C01/SY/LOCAL.Ainj.2', 'sep-a.trigStepDelay'); |
---|
74 | tango_write_attribute2('ANS-C01/SY/LOCAL.Ainj.2', 'sep-a.trigStepDelay',temp.value(1)+offset); |
---|
75 | |
---|
76 | |
---|
77 | temp=tango_read_attribute2('ANS-C01/SY/LOCAL.DG.2', 'bpm.trigStepDelay'); |
---|
78 | tango_write_attribute2('ANS-C01/SY/LOCAL.DG.2', 'bpm.trigStepDelay',temp.value(1)+offset); |
---|
79 | |
---|
80 | temp=tango_read_attribute2('ANS-C02/SY/LOCAL.DG.1', 'bpm.trigStepDelay'); |
---|
81 | tango_write_attribute2('ANS-C02/SY/LOCAL.DG.1', 'bpm.trigStepDelay',temp.value(1)+offset); |
---|
82 | |
---|
83 | temp=tango_read_attribute2('ANS-C03/SY/LOCAL.DG.1', 'bpm.trigStepDelay'); |
---|
84 | tango_write_attribute2('ANS-C03/SY/LOCAL.DG.1', 'bpm.trigStepDelay',temp.value(1)+offset); |
---|
85 | |
---|
86 | temp=tango_read_attribute2('ANS-C04/SY/LOCAL.DG.1', 'bpm.trigStepDelay'); |
---|
87 | tango_write_attribute2('ANS-C04/SY/LOCAL.DG.1', 'bpm.trigStepDelay',temp.value(1)+offset); |
---|
88 | |
---|
89 | temp=tango_read_attribute2('ANS-C05/SY/LOCAL.DG.1', 'bpm.trigStepDelay'); |
---|
90 | tango_write_attribute2('ANS-C05/SY/LOCAL.DG.1', 'bpm.trigStepDelay',temp.value(1)+offset); |
---|
91 | |
---|
92 | temp=tango_read_attribute2('ANS-C06/SY/LOCAL.DG.1', 'bpm.trigStepDelay'); |
---|
93 | tango_write_attribute2('ANS-C06/SY/LOCAL.DG.1', 'bpm.trigStepDelay',temp.value(1)+offset); |
---|
94 | |
---|
95 | |
---|
96 | temp=tango_read_attribute2('ANS-C07/SY/LOCAL.DG.1', 'bpm.trigStepDelay'); |
---|
97 | tango_write_attribute2('ANS-C07/SY/LOCAL.DG.1', 'bpm.trigStepDelay',temp.value(1)+offset); |
---|
98 | |
---|
99 | temp=tango_read_attribute2('ANS-C08/SY/LOCAL.DG.1', 'bpm.trigStepDelay'); |
---|
100 | tango_write_attribute2('ANS-C08/SY/LOCAL.DG.1', 'bpm.trigStepDelay',temp.value(1)+offset); |
---|
101 | |
---|
102 | temp=tango_read_attribute2('ANS-C09/SY/LOCAL.DG.1', 'bpm.trigStepDelay'); |
---|
103 | tango_write_attribute2('ANS-C09/SY/LOCAL.DG.1', 'bpm.trigStepDelay',temp.value(1)+offset); |
---|
104 | |
---|
105 | temp=tango_read_attribute2('ANS-C10/SY/LOCAL.DG.1', 'bpm.trigStepDelay'); |
---|
106 | tango_write_attribute2('ANS-C10/SY/LOCAL.DG.1', 'bpm.trigStepDelay',temp.value(1)+offset); |
---|
107 | |
---|
108 | temp=tango_read_attribute2('ANS-C11/SY/LOCAL.DG.1', 'bpm.trigStepDelay'); |
---|
109 | tango_write_attribute2('ANS-C11/SY/LOCAL.DG.1', 'bpm.trigStepDelay',temp.value(1)+offset); |
---|
110 | |
---|
111 | temp=tango_read_attribute2('ANS-C12/SY/LOCAL.DG.1', 'bpm.trigStepDelay'); |
---|
112 | tango_write_attribute2('ANS-C12/SY/LOCAL.DG.1', 'bpm.trigStepDelay',temp.value(1)+offset); |
---|
113 | |
---|
114 | temp=tango_read_attribute2('ANS-C13/SY/LOCAL.DG.1', 'bpm.trigStepDelay'); |
---|
115 | tango_write_attribute2('ANS-C13/SY/LOCAL.DG.1', 'bpm.trigStepDelay',temp.value(1)+offset); |
---|
116 | |
---|
117 | temp=tango_read_attribute2('ANS-C14/SY/LOCAL.DG.1', 'bpm.trigStepDelay'); |
---|
118 | tango_write_attribute2('ANS-C14/SY/LOCAL.DG.1', 'bpm.trigStepDelay',temp.value(1)+offset); |
---|
119 | |
---|
120 | temp=tango_read_attribute2('ANS-C15/SY/LOCAL.DG.1', 'bpm.trigStepDelay'); |
---|
121 | tango_write_attribute2('ANS-C15/SY/LOCAL.DG.1', 'bpm.trigStepDelay',temp.value(1)+offset); |
---|
122 | |
---|
123 | |
---|
124 | temp=tango_read_attribute2('ANS-C16/SY/LOCAL.DG.1', 'bpm.trigStepDelay'); |
---|
125 | tango_write_attribute2('ANS-C16/SY/LOCAL.DG.1', 'bpm.trigStepDelay',temp.value(1)+offset); |
---|
126 | |
---|
127 | % |
---|
128 | temp=tango_read_attribute2('ANS-C13/SY/LOCAL.DG.1', 'dcctStepDelay'); |
---|
129 | tango_write_attribute2('ANS-C13/SY/LOCAL.DG.1', 'dcctStepDelay',temp.value(1)+offset); |
---|
130 | |
---|
131 | temp=tango_read_attribute2('ANS-C14/SY/LOCAL.DG.1', 'perteTimeDelay'); |
---|
132 | tango_write_attribute2('ANS-C14/SY/LOCAL.DG.1', 'perteTimeDelay',temp.value(1)+offset); |
---|
133 | |
---|
134 | % kicker machine |
---|
135 | temp=tango_read_attribute2('ANS-C01/SY/LOCAL.EP.1', 'k-hv.pcStepDelay'); |
---|
136 | tango_write_attribute2('ANS-C01/SY/LOCAL.EP.1', 'k-hv.pcStepDelay',temp.value(1)+offset); |
---|
137 | |
---|
138 | |
---|
139 | temp=tango_read_attribute2('ANS-C01/SY/LOCAL.EP.1', 'k-v.trigStepDelay'); |
---|
140 | tango_write_attribute2('ANS-C01/SY/LOCAL.EP.1', 'k-v.trigStepDelay',temp.value(1)+offset); |
---|
141 | |
---|
142 | temp=tango_read_attribute2('ANS-C01/SY/LOCAL.EP.1', 'k-h.trigStepDelay'); |
---|
143 | tango_write_attribute2('ANS-C01/SY/LOCAL.EP.1', 'k-h.trigStepDelay',temp.value(1)+offset); |
---|
144 | |
---|
145 | |
---|
146 | % offset |
---|
147 | FileName = [DirName 'synchro_offset_lin']; |
---|
148 | load(FileName, 'inj_offset' , 'ext_offset', 'lin_fin'); |
---|
149 | ext_offset=ext_offset+offsettime; |
---|
150 | save(FileName, 'inj_offset' , 'ext_offset', 'lin_fin'); |
---|
151 | |
---|
152 | |
---|