Viewing contents of file '../idllib/astron/contrib/varosi/code/allpro/def_stat_struct.pro'
function def_stat_struct, mstat
;+
; Define status block (structure) for receiving info. from -macq-
;
; To define short structure without the hot-spot array:
;
; mstat = def_stat_struct( )
;
; To get FULL structure with hot-spot array, pass previously obtained status:
;
; mstat = def_stat_struct( mstat )
;-
common def_stat_struct, status
if N_struct( status ) NE 1 then begin
status = { mode:0L, $
psize:0L, $
res:0L, $
sim:0L, $
save:0L, $
format:1L, $
nsegs:0L, $
nbufs:0L, $
waits:0L, $
bufno:0L, $
dmaerr:0L, $
it0:lonarr(4), $
its:lonarr(4), $
ite:lonarr(4), $
plant:0.0, $
dtime:0.0, $
counts:0L, $
ydhms:lonarr(5), $
imex:intarr(8), $
startt:bytarr(28), $
errmsg:bytarr(80), $
bstat:lonarr(20), $
simfile:bytarr(60), $
Hot_Loc:intarr(2,2) }
endif
if N_struct( mstat ) EQ 1 then begin
hl = mstat.Hot_Loc
hsz = ( hl(*,1) - hl(*,0) -1 ) > 1
hotspot = Lonarr( hsz(0), hsz(1) )
return, { mode:0L, $
psize:0L, $
res:0L, $
sim:0L, $
save:0L, $
format:0L, $
nsegs:0L, $
nbufs:0L, $
waits:0L, $
bufno:0L, $
dmaerr:0L, $
it0:lonarr(4), $
its:lonarr(4), $
ite:lonarr(4), $
plant:0.0, $
dtime:0.0, $
counts:0L, $
ydhms:lonarr(5), $
imex:intarr(8), $
startt:bytarr(28), $
errmsg:bytarr(80), $
bstat:lonarr(20), $
simfile:bytarr(60), $
Hot_Loc: intarr(2,2), $
hotspot: hotspot }
endif else return, status
end