ICP  1
crptdef.h
Go to the documentation of this file.
1 C Fixed limits on the parameters that define the length of a run file
2  INTEGER*4 MAX_CRPT
3  INTEGER*4 MAXDET,MAXSPEC,MAXCHAN,MAXMON,MAXVAX,MAXDAE
4  INTEGER*4 MAXSEP,MAXTRG,MAXNUT,MAXUDAT,MAXPER
5  REAL RMIN_CHAN
6  INTEGER*4 NCOMPTYPE,MAXTOTSPEC
7 C Maximum number of blocks that can be used by CRPT
8 C Make sure MAX_CRPT is a multiple of "4"
9  PARAMETER (MAX_CRPT=900000+36000)
10 C number of detector entries MAXDET
11  PARAMETER (MAXDET=640000)
12 C number of user defined tables for detectors MAXNUT
13  PARAMETER (MAXNUT=14)
14 C no. of spectra (add 1 to allow space for 0th spectrum) MAXSPEC
15  PARAMETER (MAXSPEC=64000)
16 C no. of time channels (add 1 to allow space for 0th chan) MAXCHAN
17  PARAMETER (MAXCHAN=32760)
18 C number of monitors MAXMON
19  PARAMETER (MAXMON=12)
20 C vax memory size (words) in total number of channels allowed VAXMAX
21 C probably something like (MAXDAE / 4)
22  PARAMETER (MAXVAX=(6*64*1024*1024)/4)
23 C DAE memory size in bytes DAEMAX
24  PARAMETER (MAXDAE=6*64*1024*1024)
25 C number of sample environment parameters
26  PARAMETER (MAXSEP=50)
27 C number of time regimes
28  PARAMETER (MAXTRG=1)
29 C number of user defined variables
30  PARAMETER (MAXUDAT=400)
31 C Minimum time channel width (in microsecs) that is safe to be used with the DAE
32  PARAMETER (RMIN_CHAN=0.25)
33 C PARAMETER (RMIN_CHAN=0.5) ! for ROTAX/ALF testing
34 C Max periods
35  PARAMETER (MAXPER=256)
36 C Compression type used in files: 0 - nocompression, 1 - byte relative
37  PARAMETER (NCOMPTYPE=1)
38 C Maximum combined periods*spectra
39  PARAMETER (MAXTOTSPEC=64000)
40 
41 
42 c
43 C***************************************************************************
44 C Instrument control program for the MAY85
45 C Current Run Parameter Table as described in IDG/ /85 CRPT RELEASE 2.1
46 C Section and parameter position definitions
47 C***************************************************************************
48 C
49 C ** NOTE: the run section begins at 129 because space after the format
50 C section is used for storing various status flags. This space
51 C will be removed when writing to the file.
52 C The start of each section is calculated from the previous section start
53 C + the MAXimium length of the previous section, and then adjusted to start
54 C on a block boundary.
55 C The MAX values are also parameters, kept in file LIMITSDEF.PAR
56 C
57  INCLUDE 'limitsdef.par'
58  REAL RCRPT(MAX_CRPT * 128)
59  INTEGER ICRPT(MAX_CRPT * 128)
60  COMMON /CRPT/ PTR_ICRPT, PTR_RCRPT
61  SAVE /CRPT/
62 C this done by pointer aliasing
63 C EQUIVALENCE (ICRPT,RCRPT)
64  POINTER (PTR_ICRPT, ICRPT), (PTR_RCRPT, RCRPT)
65 C
66 C
67  INTEGER*4 STATUS_SECT,RUN_SECT,INST_SECT,SE_SECT,
68  + DAE_SECT,TCB_SECT,USER_SECT,DATA_SECT,END_DATA_SECT
69  INTEGER*4 CRPT_VERS,RUN_VERS,INST_VERS,SE_VERS,
70  + DAE_VERS,TCB_VERS,USER_VERS,DATA_VERS,LOG_VERS
71  INTEGER*4 HD_RUN,HD_USER,HD_TITLE,HD_DATE,HD_TIME,
72  + HD_DUR,FRMT_VER_NO,AD_RUN,AD_INST,AD_SE,AD_DAE,
73  + AD_TCB,AD_USER,AD_DATA,AD_LOG,DATA_FORMAT
74  INTEGER*4 ST_RUN,ST_START,ST_PAUSED,ST_PREV,
75  + ST_ICPCODE,ST_SYSCODE,ST_SPECT,ST_FIRST,ST_LAST,
76  + ST_TCB1,ST_TCB2,ST_CAMACFLAGS,ST_HEARTBEAT,
77  + ST_SEP_RUN_OK,ST_SIMULATE,ST_NOMSG,ST_HOLD,ST_ENDWANTED,
78  + ST_GOODFRM,ST_RAWFRM,ST_MAX_CRPT,ST_MAX_DET,ST_MAX_NUT,
79  + ST_MAX_SPEC,ST_MAX_CHAN,ST_MAX_MON,ST_MAX_VAX,
80  + ST_MAX_DAE,ST_MAX_SEP,ST_MAX_TRG,ST_MAX_UDAT,ST_MAX_PER,
81  + ST_MAX_TOTSPEC,
82 c
83  + ST_CPERIOD,ST_PERMAX,ST_TPOFFSET,ST_COUNTSUM,
84  + ST_TABLES
85  INTEGER*4 R_NUMBER,R_TITLE,R_USER,
86  + R_DAYTEL,R_DAYTEL2,R_NIGHT,R_INSTIT,
87  + R_DUR,R_DURUNITS,R_DUR_FREQ,R_DMP,R_DMP_UNITS,
88  + R_DMP_FREQ,R_FREQ,R_GD_PRTN_CHRG,R_TOT_PRTN_CHRG,
89  + R_GOODFRM,R_RAWFRM,R_DUR_WANTED,R_DUR_SECS,R_MON_SUM1,
90  + R_MON_SUM2,R_MON_SUM3,R_ENDDATE,R_ENDTIME,R_PROP
91  INTEGER*4 I_INST,I_MAINSHUT,I_THERMSHUT,
92  + I_XSECT,I_YSECT,I_POSN,I_MOD,
93  + I_VACUUM,I_L1,I_DET,I_MON,I_NUSE,
94  + I_TABLES
95 C Instrument specific:
96 C HET:
97  INTEGER I_RFREQ,I_RENERGY,I_RPHASE,I_RSLIT,I_SLOWCHOP
98 C LOQ:
99  INTEGER I_XCEN,I_YCEN,I_BESTOP,I_RADBEST,I_SDDIST,
100  + I_CHOPSIZ,I_CHFREQ,I_FOEANG
101 C CRISP:
102  INTEGER I_AOFI
103  INTEGER*4 E_POSN,E_TYPE,E_GEOM,
104  + E_THICK,E_HEIGHT,E_WIDTH,
105  + E_OMEGA,E_CHI,E_PHI,E_SCATT,E_XSECT,E_DENS,
106  + E_CANTHICK,E_CANXSECT,E_NAME,E_NSE,E_SEBLOCK,
107  + E_EQUIP,E_EQNAME
108  INTEGER*4 SEP_LENGTH,SEP_NAME,SEP_VALUE,SEP_EXPONENT,
109  + SEP_UNITS,SEP_LOW_TRIP,SEP_HIGH_TRIP,
110  + SEP_CUR_VAL,SEP_STATUS,SEP_CONTROL,SEP_RUN,
111  + SEP_LOG,SEP_STABLE,SEP_PERIOD,SEP_CAM_ADDR,
112  + SEP_CAM_SUB,SEP_OFFSET,SEP_CAM_RGRP,
113  + SEP_PRE_PROC,SEP_CAM_VALS
114  INTEGER*4 A_PARS,A_minppp,A_delay,A_synch,A_SMP,A_TABLES
115  INTEGER*4 T_NTRG,T_NFPP,T_NPER,T_PMAP,
116  + T_NSP1,T_NTC1,T_TCM1,T_TCP1,
117  + T_PRE1,T_TCB1
118  INTEGER*4 U_len,U_dat
119  INTEGER*4 D_comp,D_offset,D_CRdata,D_CRfile,D_exp_filesize,
120  + D_DATA
121 C
122  PARAMETER (SEP_LENGTH=32)
123 C
124  PARAMETER (STATUS_SECT=32)
125  PARAMETER (RUN_SECT=129)
126  PARAMETER (INST_SECT=((RUN_SECT+94)/128+1)*128 +1)
127  PARAMETER (SE_SECT=
128  + ((INST_SECT+70+(2*MAXMON)+(5+MAXNUT)*MAXDET)/128+1)*128 +1)
129  PARAMETER (DAE_SECT=
130  + ((SE_SECT+66+MAXSEP*SEP_LENGTH)/128+1)*128 +1)
131  PARAMETER (TCB_SECT=((DAE_SECT+65+MAXDET*5)/128+1)*128 +1)
132  PARAMETER (USER_SECT=
133  + ((TCB_SECT+260+(MAXCHAN+29))/128+1)*128 +1)
134  PARAMETER (DATA_SECT=((USER_SECT+2+MAXUDAT)/128 +1)*128 +1)
135 C
136 C Define the offsets within the first page of CRPT which include the
137 C header and address pointers to other sections of the CRPT
138 C
139  PARAMETER (HD_RUN=1,HD_USER=3,HD_TITLE=8,HD_DATE=14,
140  + HD_TIME=17,HD_DUR=19,FRMT_VER_NO=21,AD_RUN=22,
141  + AD_INST=23,AD_SE=24,AD_DAE=25,AD_TCB=26,AD_USER=27,
142  + AD_DATA=28,AD_LOG=29,DATA_FORMAT=31)
143 C
144  PARAMETER (CRPT_VERS=2,RUN_VERS=1,INST_VERS=2,
145  + SE_VERS=2,DAE_VERS=2,
146  + TCB_VERS=1,USER_VERS=1,DATA_VERS=2,LOG_VERS=2)
147  PARAMETER (ST_RUN=0,ST_START=1,ST_PAUSED=3,ST_PREV=5,
148  + ST_ICPCODE=7,ST_SYSCODE=8,ST_SPECT=9,
149  + ST_FIRST=10,ST_LAST=11,ST_TCB1=12,ST_TCB2=13,
150  + ST_CAMACFLAGS=14,ST_HEARTBEAT=15,
151  + ST_SEP_RUN_OK=16,ST_SIMULATE=17,ST_NOMSG=18,
152  + ST_HOLD=19,ST_ENDWANTED=20,ST_GOODFRM=25,ST_RAWFRM=26,
153  + ST_MAX_CRPT=27,ST_MAX_DET=28,ST_MAX_NUT=29,
154  + ST_MAX_SPEC=30,ST_MAX_CHAN=31,ST_MAX_MON=32,
155  + ST_MAX_VAX=33,ST_MAX_DAE=34,ST_MAX_SEP=35,
156  + ST_MAX_TRG=36,ST_MAX_UDAT=37,ST_MAX_PER=38,
157  + ST_MAX_TOTSPEC=39,
158 c space for other MAXes
159  + ST_CPERIOD=45,ST_PERMAX=46,ST_TPOFFSET=47,
160  + ST_COUNTSUM=63,ST_TABLES=64)
161 C
162  PARAMETER (R_NUMBER=1,R_TITLE=2,R_USER=22,
163  + R_DAYTEL=27,R_DAYTEL2=32,R_NIGHT=37,R_INSTIT=42,
164  + R_DUR=62,R_DURUNITS=63,R_DUR_FREQ=64,R_DMP=65,
165  + R_DMP_UNITS=66,R_DMP_FREQ=67,R_FREQ=68,
166  + R_GD_PRTN_CHRG=69,R_TOT_PRTN_CHRG=70,R_GOODFRM=71,
167  + R_RAWFRM=72,R_DUR_WANTED=73,R_DUR_SECS=74,
168  + R_MON_SUM1=75,R_MON_SUM2=76,R_MON_SUM3=77,
169  + R_ENDDATE=78,R_ENDTIME=81,R_PROP=83)
170 C
171  PARAMETER (I_INST=1,I_MAINSHUT=18,I_THERMSHUT=19,
172  + I_XSECT=20,I_YSECT=21,I_POSN=22,I_MOD=23,
173  + I_VACUUM=24,I_L1=25,I_DET=67,I_MON=68,I_NUSE=69,
174  + I_TABLES=70)
175 C Instrument Specific:
176 C HET:
177  PARAMETER (I_RFREQ=26,I_RENERGY=27,I_RPHASE=28,I_RSLIT=29,
178  + I_SLOWCHOP=30)
179 C LOQ:
180  PARAMETER (I_XCEN=31,I_YCEN=32,I_BESTOP=33,I_RADBEST=34,
181  + I_SDDIST=35,I_CHOPSIZ=12,I_CHFREQ=3,I_FOEANG=36)
182 C CRISP:
183  PARAMETER (I_AOFI=37)
184 C
185  PARAMETER (E_POSN=1,E_TYPE=2,E_GEOM=3,
186  + E_THICK=4,E_HEIGHT=5,E_WIDTH=6,
187  + E_OMEGA=7,E_CHI=8,E_PHI=9,E_SCATT=10,E_XSECT=11,
188  + E_DENS=14,E_CANTHICK=15,E_CANXSECT=16,
189  + E_NAME=20,E_EQUIP=30,E_EQNAME=31,E_NSE=65,E_SEBLOCK=66)
190 C
191 C Offsets within sample enviroment parameter blocks defining variables that
192 C contain SE data. The first sample enviroment block follows
193 C CRPT(SE_SECT+E_NSE) and is SEP_LENGTH*4 bytes long.
194 C
195  PARAMETER (SEP_NAME=0,SEP_VALUE=2,SEP_EXPONENT=3,
196  + SEP_UNITS=4,SEP_LOW_TRIP=6,SEP_HIGH_TRIP=7,
197  + SEP_CUR_VAL=8,SEP_STATUS=9,SEP_CONTROL=10,
198  + SEP_RUN=11,SEP_LOG=12,SEP_STABLE=13,
199  + SEP_PERIOD=14,SEP_CAM_ADDR=15,SEP_CAM_SUB=16,
200  + SEP_OFFSET=17,SEP_CAM_RGRP=18,
201  + SEP_PRE_PROC=19,SEP_CAM_VALS=20)
202 C
203  PARAMETER (A_PARS=1,A_minppp=3,A_delay=24,A_synch=25,A_SMP=26,
204  + A_TABLES=65)
205 C
206  PARAMETER (T_NTRG=1,T_NFPP=2,T_NPER=3,T_PMAP=4,
207  + T_NSP1=260,T_NTC1=261,T_TCM1=262,T_TCP1=267,
208  + T_PRE1=287,T_TCB1=288)
209 C
210  PARAMETER (U_len=1,U_dat=2)
211 C
212  PARAMETER (D_comp=1,D_offset=3,D_CRdata=4,D_CRfile=5,
213  + D_exp_filesize=6,
214  + D_DATA=33)
215 C
216 C check on sizes
217 C
218  PARAMETER(END_DATA_SECT = DATA_SECT+D_DATA+MAXVAX)
219 C
C Fixed limits on the parameters that define the length of a run file INTEGER *MAX_CRPT INTEGER MAXVAX
Definition: crptdef.h:3
C Fixed limits on the parameters that define the length of a run file INTEGER *MAX_CRPT INTEGER MAXSPEC
Definition: crptdef.h:3
C Fixed limits on the parameters that define the length of a run file INTEGER *MAX_CRPT INTEGER MAXDAE INTEGER MAXPER REAL RMIN_CHAN INTEGER * NCOMPTYPE
Definition: crptdef.h:3
C Fixed limits on the parameters that define the length of a run file INTEGER *MAX_CRPT INTEGER * MAXDET
Definition: crptdef.h:3
C Fixed limits on the parameters that define the length of a run file INTEGER *MAX_CRPT INTEGER MAXDAE INTEGER MAXUDAT
Definition: crptdef.h:3
C Fixed limits on the parameters that define the length of a run file INTEGER *MAX_CRPT INTEGER MAXDAE INTEGER MAXTRG
Definition: crptdef.h:3
C Fixed limits on the parameters that define the length of a run file INTEGER *MAX_CRPT INTEGER MAXCHAN
Definition: crptdef.h:3
C Fixed limits on the parameters that define the length of a run file INTEGER *MAX_CRPT INTEGER MAXDAE INTEGER MAXNUT
Definition: crptdef.h:3
C Fixed limits on the parameters that define the length of a run file INTEGER *MAX_CRPT INTEGER MAXDAE INTEGER * MAXSEP
Definition: crptdef.h:3
C Fixed limits on the parameters that define the length of a run file INTEGER *MAX_CRPT INTEGER MAXMON
Definition: crptdef.h:3