C+ C NAME: C smei_orb_mkname C PURPOSE: C Constructs file name of for orbital "on-the-fly" pattern C CATEGORY: C gen/for/lib/cal C CALLING SEQUENCE: subroutine smei_orb_mkname(tt,cname) C INPUTS: C tt(2) integer time on which to base the filename C Should be the first frame C in an orbit C OUTPUTS: C cname*(*) character name of orbital pattern C in format c3orb_YYYY_hhmmss C (i.e. NO extension) C CALLS: C smei_orbit2, smei_orbit_time2, Str2Str, Time2Str C INCLUDE: include 'smei_frm_layout.h' C RESTRICTIONS: C Both smei_base and smei_orb call this routine. C smei_base uses it to set the expected name of the orbital pattern C for a camera 3 frame and adds it to the header of the frame. C smei_orb uses it when it creates the orbital pattern. C C The names in smei_base and smei_orb MUST match. If they do not C then smei_skyd will not be able to produce skymaps (it will C abort). C C Both programs pass the time for the first frame into an orbit C to this subroutine. C C Note that smei_orb has a keyword that will force an update of C the frame headers with the name of orbital patterns it creates. C This is a more foolproof way of setting the orbital pattern C name, but also makes smei_orb a lot slower since all frames C need to be rewritten (unzip,read,update header,write,zip for C every frame). C PROCEDURE: C The time in the file name is the start time C (rounded to the nearest second) of the orbit of which C tt is part. C MODIFICATION HISTORY: C APR-2007, Paul Hick (UCSD/CASS; pphick@ucsd.edu) C- integer tt(2) character cname*(*) double precision dorb integer torb(2) integer Time2Str integer Str2Str call smei_orbit2(tt,i,dorb) call smei_orbit_time2(i,0.0d0,torb) torb(2) = nint(dble(torb(2))/1000.0d0)*1000 ! Round to nearest second i = 0 i = i+Str2Str ('c3orb_' , cname(i+1:)) i = i+Time2Str(SMEI__UT_FORMAT,torb, cname(i+1:)) return end