PRO readlog1,ar,n ; ;Reading and management of La Palma logfiles of 1995. ;Creating an array with seq.numbers of existing images ;and corresponding times (in hours). ; n = number of rows (i.e. images) in the logfile ; file1='logs/m14b_lg30Jun95' ; NAME TO BE CHANGED print,'opening ',file1 openr,1,file1 a=bytarr(8) ;to read serial no. b=bytarr(20) ;to read time c=bytarr(33) ;the rest (33) for Unix, (34) for DOS ar=fltarr(2,n) for i=0,n-1 do begin readu,1,a readu,1,b readu,1,c sa=strtrim(string(a),2) sb=strtrim(string(b),2) sb=' '+sb+' ' p1=strpos(sb,':') p2=strpos(sb,'.') hour=float(strmid(sb,p1-2,2)) min=float(strmid(sb,p1+1,p2-p1-1)) sec=float(strmid(sb,p2+1,2)) print,hour,min,sec ar(0,i)=float(sa) ar(1,i)=hour+min/60.+sec/3600. ; print,ar(0,i),ar(1,i) endfor close,1 END