PRO ct1,yr,mo,day,oneday=oneday ; This procedure used to be a program, but it's needed as a procedure. time = fltarr(2500) tei = time tfw=tei tcf=tei tfw=tei tee=tei td=tei heater=tei i=0 openr, 1, 'tei5' while not eof(1) do begin readf, 1, t, d tei(i) = d/10.0 & time(i) = t i = i + 1 endwhile close, 1 i=0 openr, 1, 'tee5' while not eof(1) do begin readf, 1, t, d tee(i) = d/10.0 i = i + 1 endwhile close, 1 i=0 openr, 1, 'tcf5' while not eof(1) do begin readf, 1, t, d tcf(i) = d/10.0 i = i + 1 endwhile close, 1 i=0 openr, 1, 'tfw5' while not eof(1) do begin readf, 1, t, d tfw(i) = d/10.0 i = i + 1 endwhile close, 1 i=0 openr, 1, 'td5' while not eof(1) do begin readf, 1, t, d td(i) = d/10.0 i = i + 1 endwhile close, 1 i=0 openr, 1, 'heater5' while not eof(1) do begin readf, 1, t, d heater(i) = d/10.0 i = i + 1 endwhile close, 1 foo = indgen(i-1) time =time(foo) tei =tei(foo) & tee=tee(foo) & tfw=tfw(foo) & tcf=tcf(foo) & td=td(foo) heater=heater(foo) mx=fltarr(5) mx(0)=MAX(tee) & mx(1)=MAX(tei) & mx(2)=MAX(tfw) & mx(3)=MAX(td) mx(4)=MAX(tcf) PRINT,MIN(time,MAX=mt),mt, $ FORMAT='("Time spans ",F4.1," - ",F4.1," hrs UT")' xt='UT (hours, '+ymd2date(yr,mo,day,format='d$ n$ y$')+')' pt='Camera 1 Temperature Parameters, '+ymd2date(yr,mo,day,format='d$ n$ y$') IF KEYWORD_SET(oneday) THEN BEGIN IF mt GT 24. THEN BEGIN PRINT,'Only data from the first 24 hours UT will be plotted!' PRINT,'Divide this temperature log file into separate days' PRINT,'to see the data from later times!' ENDIF ; Truncate all data arrays to the first UT day represented le24=WHERE(time LE 24) i=N_ELEMENTS(le24) time=time(le24) tfw=tfw(le24) tei=tei(le24) td=td(le24) tee=tee(le24) tcf=tcf(le24) heater=heater(le24) PLOT,time,tee,XRANGE=[0,24],/XSTYLE $ ,YRANGE=[-50,MAX([40,mx])],/YSTYLE $ ,XTITLE=xt,TITLE=pt,PSYM=3 $ ,YTITLE="Temperature (!9%!xC), Heater Status (DN/10)" $ ,XTICKS=5,XTICKV=INDGEN(5)*6,XMINOR=6 ENDIF ELSE PLOT,time,tee,XRANGE=[MIN(time),mt],/XSTYLE $ ,YRANGE=[-50,MAX([40,mx])],/YSTYLE $ ,XTITLE=xt,TITLE=pt,PSYM=3 $ ,YTITLE="Temperature (!9%!xC), Heater Status (DN/10)" plots,[time(0),time(i-2)],[tee(0),tee(i-2)],psym=1 oplot, time, tei,psym=3 plots,[time(0),time(i-2)],[tei(0),tei(i-2)],psym=2 oplot, time, tfw,psym=3 plots,[time(0),time(i-2)],[tfw(0),tfw(i-2)],psym=4 oplot, time, tcf,psym=3 plots,[time(0),time(i-2)],[tcf(0),tcf(i-2)],psym=5 oplot,time,td,psym=3 plots,[time(0),time(i-2)],[td(0),td(i-2)],psym=6 oplot, time, heater plots,[time(0),time(i-2)],[heater(0),heater(i-2)],psym=7 items=['tfw','tei','td','tee','tcf','heater'] psym=[4,2,6,1,5,7] xdvpos=!P.CLIP(0) ydvpos=!P.CLIP(3) npos=CONVERT_COORD([xdvpos,ydvpos],/DEVICE,/TO_NORMAL) npos=npos(0:1) legend,items,psym=psym,position=npos timestmp RETURN END