8 |
C |
C |
9 |
integer lung |
integer lung |
10 |
integer*1 vecta(lung) |
integer*1 vecta(lung) |
11 |
|
integer*2 ibuf |
12 |
integer me |
integer me |
13 |
integer*2 check, crctrig |
integer*2 check, crctrig |
14 |
integer ic0,sup,inf |
integer ic0,sup,inf |
55 |
c vecta(ic) is the CRC |
c vecta(ic) is the CRC |
56 |
c Check consistency of CRC. |
c Check consistency of CRC. |
57 |
c |
c |
58 |
if (vecta(ic).lt.0) vecta(ic)=vecta(ic)+256 |
ibuf=0 |
59 |
|
do bit = 0, 7 |
60 |
|
bi = ibits(vecta(ic),bit,1) |
61 |
|
if (bi.eq.1) ibuf = ibset(ibuf,bit) |
62 |
|
enddo |
63 |
|
c |
64 |
check = 0 |
check = 0 |
65 |
inf = ic0 |
inf = ic0 |
66 |
sup = ic - 1 |
sup = ic - 1 |
67 |
do i = inf,sup |
do i = inf,sup |
68 |
check=crctrig(check,vecta(i)) |
check=crctrig(check,vecta(i)) |
69 |
enddo |
enddo |
70 |
if (check.ne.vecta(ic)) then |
if (check.ne.ibuf) then |
71 |
c print *,'crc sbagliato ',vecta(ic), check |
c print *,'crc wrong ',ibuf, check |
72 |
me = 1 |
me = 1 |
|
else |
|
|
c print *,'crc corretto ',vecta(ic) |
|
73 |
endif |
endif |
74 |
c |
c |
75 |
ic = ic + 1 |
ic = ic + 1 |
91 |
c vecta(ic) is the CRC |
c vecta(ic) is the CRC |
92 |
c Check consistency of CRC. |
c Check consistency of CRC. |
93 |
c |
c |
94 |
if(vecta(ic).lt.0)vecta(ic)=vecta(ic)+256 |
ibuf=0 |
95 |
|
do bit = 0, 7 |
96 |
|
bi = ibits(vecta(ic),bit,1) |
97 |
|
if (bi.eq.1) ibuf = ibset(ibuf,bit) |
98 |
|
enddo |
99 |
|
c |
100 |
check = 0 |
check = 0 |
101 |
inf = ic0 |
inf = ic0 |
102 |
sup = ic - 1 |
sup = ic - 1 |
103 |
do i = inf,sup |
do i = inf,sup |
104 |
check=crctrig(check,vecta(i)) |
check=crctrig(check,vecta(i)) |
105 |
enddo |
enddo |
106 |
if (check.ne.vecta(ic)) then |
if (check.ne.ibuf) then |
107 |
c print *,'crc sbagliato ',vecta(ic), check |
c print *,'crc wrong ',ibuf, check |
108 |
me = 1 |
me = 1 |
|
else |
|
|
c print *,'crc corretto ',vecta(ic) |
|
109 |
endif |
endif |
110 |
c |
c |
111 |
c |
c |
137 |
c vecta(ic) is the CRC |
c vecta(ic) is the CRC |
138 |
c Check consistency of CRC. |
c Check consistency of CRC. |
139 |
c |
c |
140 |
if(vecta(ic).lt.0)vecta(ic)=vecta(ic)+256 |
ibuf=0 |
141 |
|
do bit = 0, 7 |
142 |
|
bi = ibits(vecta(ic),bit,1) |
143 |
|
if (bi.eq.1) ibuf = ibset(ibuf,bit) |
144 |
|
enddo |
145 |
|
c |
146 |
check = 0 |
check = 0 |
147 |
inf = ic0 |
inf = ic0 |
148 |
sup = ic - 1 |
sup = ic - 1 |
149 |
do i = inf,sup |
do i = inf,sup |
150 |
check=crctrig(check,vecta(i)) |
check=crctrig(check,vecta(i)) |
151 |
enddo |
enddo |
152 |
if (check.ne.vecta(ic)) then |
if (check.ne.ibuf) then |
153 |
c print *,'crc sbagliato ',vecta(ic), check |
c print *,'crc wrong ',ibuf, check |
154 |
me = 1 |
me = 1 |
|
else |
|
|
c print *,'crc corretto ',vecta(ic) |
|
155 |
endif |
endif |
156 |
c |
c |
157 |
c |
c |
179 |
c vecta(ic) is the CRC |
c vecta(ic) is the CRC |
180 |
c Check consistency of CRC. |
c Check consistency of CRC. |
181 |
c |
c |
182 |
if(vecta(ic).lt.0)vecta(ic)=vecta(ic)+256 |
ibuf=0 |
183 |
|
do bit = 0, 7 |
184 |
|
bi = ibits(vecta(ic),bit,1) |
185 |
|
if (bi.eq.1) ibuf = ibset(ibuf,bit) |
186 |
|
enddo |
187 |
|
c |
188 |
check = 0 |
check = 0 |
189 |
inf = ic0 |
inf = ic0 |
190 |
sup = ic - 1 |
sup = ic - 1 |
191 |
do i = inf,sup |
do i = inf,sup |
192 |
check=crctrig(check,vecta(i)) |
check=crctrig(check,vecta(i)) |
193 |
enddo |
enddo |
194 |
if (check.ne.vecta(ic)) then |
if (check.ne.ibuf) then |
195 |
c print *,'crc sbagliato ',vecta(ic), check |
c print *,'crc wrong ',ibuf, check |
196 |
me = 1 |
me = 1 |
|
else |
|
|
c print *,'crc corretto ',vecta(ic) |
|
197 |
endif |
endif |
198 |
c |
c |
199 |
c |
c |
221 |
c vecta(ic) is the CRC |
c vecta(ic) is the CRC |
222 |
c Check consistency of CRC. |
c Check consistency of CRC. |
223 |
c |
c |
224 |
if(vecta(ic).lt.0)vecta(ic)=vecta(ic)+256 |
ibuf=0 |
225 |
|
do bit = 0, 7 |
226 |
|
bi = ibits(vecta(ic),bit,1) |
227 |
|
if (bi.eq.1) ibuf = ibset(ibuf,bit) |
228 |
|
enddo |
229 |
|
c |
230 |
check = 0 |
check = 0 |
231 |
inf = ic0 |
inf = ic0 |
232 |
sup = ic - 1 |
sup = ic - 1 |
233 |
do i = inf,sup |
do i = inf,sup |
234 |
check=crctrig(check,vecta(i)) |
check=crctrig(check,vecta(i)) |
235 |
enddo |
enddo |
236 |
if (check.ne.vecta(ic)) then |
if (check.ne.ibuf) then |
237 |
c print *,'crc sbagliato ',vecta(ic), check |
c print *,'crc wrong ',ibuf, check |
238 |
me = 1 |
me = 1 |
|
else |
|
|
c print *,'crc corretto ',vecta(ic) |
|
239 |
endif |
endif |
|
c |
|
240 |
C |
C |
241 |
ic = ic + 1 |
ic = ic + 1 |
242 |
ic0 = ic |
ic0 = ic |
267 |
c vecta(ic) is the CRC |
c vecta(ic) is the CRC |
268 |
c Check consistency of CRC. |
c Check consistency of CRC. |
269 |
c |
c |
270 |
if(vecta(ic).lt.0)vecta(ic)=vecta(ic)+256 |
ibuf=0 |
271 |
|
do bit = 0, 7 |
272 |
|
bi = ibits(vecta(ic),bit,1) |
273 |
|
if (bi.eq.1) ibuf = ibset(ibuf,bit) |
274 |
|
enddo |
275 |
|
c |
276 |
check = 0 |
check = 0 |
277 |
inf = ic0 |
inf = ic0 |
278 |
sup = ic - 1 |
sup = ic - 1 |
279 |
do i = inf,sup |
do i = inf,sup |
280 |
check=crctrig(check,vecta(i)) |
check=crctrig(check,vecta(i)) |
281 |
enddo |
enddo |
282 |
if (check.ne.vecta(ic)) then |
if (check.ne.ibuf) then |
283 |
c print *,'crc sbagliato ',vecta(ic), check |
c print *,'crc wrong ',ibuf, check |
284 |
me = 1 |
me = 1 |
|
else |
|
|
c print *,'crc corretto ',vecta(ic) |
|
285 |
endif |
endif |
286 |
c |
c |
287 |
c |
c |
307 |
c print *,pmtcount2(13),pmtcount2(14),pmtcount2(15),pmtcount2(16) |
c print *,pmtcount2(13),pmtcount2(14),pmtcount2(15),pmtcount2(16) |
308 |
c print *,pmtcount2(17),pmtcount2(18),pmtcount2(19),pmtcount2(20) |
c print *,pmtcount2(17),pmtcount2(18),pmtcount2(19),pmtcount2(20) |
309 |
c print *,pmtcount2(21),pmtcount2(22),pmtcount2(23),pmtcount2(24) |
c print *,pmtcount2(21),pmtcount2(22),pmtcount2(23),pmtcount2(24) |
310 |
c |
|
311 |
c |
c |
312 |
c vecta(ic) is the CRC |
c vecta(ic) is the CRC |
313 |
c Check consistency of CRC. |
c Check consistency of CRC. |
314 |
c |
c |
315 |
if(vecta(ic).lt.0)vecta(ic)=vecta(ic)+256 |
ibuf=0 |
316 |
|
do bit = 0, 7 |
317 |
|
bi = ibits(vecta(ic),bit,1) |
318 |
|
if (bi.eq.1) ibuf = ibset(ibuf,bit) |
319 |
|
enddo |
320 |
|
c |
321 |
check = 0 |
check = 0 |
322 |
inf = ic0 |
inf = ic0 |
323 |
sup = ic - 1 |
sup = ic - 1 |
324 |
do i = inf,sup |
do i = inf,sup |
325 |
check=crctrig(check,vecta(i)) |
check=crctrig(check,vecta(i)) |
326 |
enddo |
enddo |
327 |
if (check.ne.vecta(ic)) then |
if (check.ne.ibuf) then |
328 |
c print *,'crc sbagliato ',vecta(ic), check |
c print *,'crc wrong ',ibuf, check |
329 |
me = 1 |
me = 1 |
|
else |
|
|
c print *,'crc corretto ',vecta(ic) |
|
330 |
endif |
endif |
331 |
c |
c |
|
c |
|
332 |
|
|
333 |
ic = ic + 1 |
ic = ic + 1 |
334 |
ic0 = ic |
ic0 = ic |
392 |
c vecta(ic) is the CRC |
c vecta(ic) is the CRC |
393 |
c Check consistency of CRC. |
c Check consistency of CRC. |
394 |
c |
c |
395 |
if(vecta(ic).lt.0)vecta(ic)=vecta(ic)+256 |
ibuf=0 |
396 |
|
do bit = 0, 7 |
397 |
|
bi = ibits(vecta(ic),bit,1) |
398 |
|
if (bi.eq.1) ibuf = ibset(ibuf,bit) |
399 |
|
enddo |
400 |
|
c |
401 |
check = 0 |
check = 0 |
402 |
inf = ic0 |
inf = ic0 |
403 |
sup = ic - 1 |
sup = ic - 1 |
404 |
do i = inf,sup |
do i = inf,sup |
405 |
check=crctrig(check,vecta(i)) |
check=crctrig(check,vecta(i)) |
406 |
enddo |
enddo |
407 |
if (check.ne.vecta(ic)) then |
if (check.ne.ibuf) then |
408 |
c print *,'crc sbagliato ',vecta(ic), check |
c print *,'crc wrong ',ibuf, check |
409 |
me = 1 |
me = 1 |
|
else |
|
|
c print *,'crc corretto ',vecta(ic) |
|
410 |
endif |
endif |
411 |
c |
c |
412 |
c |
c |
503 |
c vecta(ic) is the CRC |
c vecta(ic) is the CRC |
504 |
c Check consistency of CRC. |
c Check consistency of CRC. |
505 |
c |
c |
506 |
if(vecta(ic).lt.0)vecta(ic)=vecta(ic)+256 |
ibuf=0 |
507 |
|
do bit = 0, 7 |
508 |
|
bi = ibits(vecta(ic),bit,1) |
509 |
|
if (bi.eq.1) ibuf = ibset(ibuf,bit) |
510 |
|
enddo |
511 |
|
c |
512 |
check = 0 |
check = 0 |
513 |
inf = ic0 |
inf = ic0 |
514 |
sup = ic - 1 |
sup = ic - 1 |
515 |
do i = inf,sup |
do i = inf,sup |
516 |
check=crctrig(check,vecta(i)) |
check=crctrig(check,vecta(i)) |
517 |
enddo |
enddo |
518 |
if (check.ne.vecta(ic)) then |
if (check.ne.ibuf) then |
519 |
c print *,'crc sbagliato ',vecta(ic), check |
c print *,'crc wrong ',ibuf, check |
520 |
me = 1 |
me = 1 |
|
else |
|
|
c print *,'crc corretto ',vecta(ic) |
|
521 |
endif |
endif |
522 |
c |
c |
523 |
c |
c |
544 |
c vecta(ic) is the CRC |
c vecta(ic) is the CRC |
545 |
c Check consistency of CRC. |
c Check consistency of CRC. |
546 |
c |
c |
547 |
if(vecta(ic).lt.0)vecta(ic)=vecta(ic)+256 |
ibuf=0 |
548 |
|
do bit = 0, 7 |
549 |
|
bi = ibits(vecta(ic),bit,1) |
550 |
|
if (bi.eq.1) ibuf = ibset(ibuf,bit) |
551 |
|
enddo |
552 |
|
c |
553 |
check = 0 |
check = 0 |
554 |
inf = ic0 |
inf = ic0 |
555 |
sup = ic - 1 |
sup = ic - 1 |
556 |
do i = inf,sup |
do i = inf,sup |
557 |
check=crctrig(check,vecta(i)) |
check=crctrig(check,vecta(i)) |
558 |
enddo |
enddo |
559 |
if (check.ne.vecta(ic)) then |
if (check.ne.ibuf) then |
560 |
c print *,'crc sbagliato ',vecta(ic), check |
c print *,'crc wrong ',ibuf, check |
561 |
me = 1 |
me = 1 |
|
else |
|
|
c print *,'crc corretto ',vecta(ic) |
|
562 |
endif |
endif |
563 |
c |
c |
|
|
|
564 |
RETURN |
RETURN |
565 |
END |
END |
|
|
|
|
|
|
|
|
|