subroutine lmstss (kode, is, ie) c c------------------------------------------------------------------------ c c Compares the start and stop times of the data presently in the c /blktim/ common area with the start and stop times currently c defined in the /com_times/ common area. If any of the samples are c within the current processing time limits kode is return = 0 and is c is the starting sample and ie is the ending sample. c c------------------------------------------------------------------------ c c kode = -1 not reached required data yet c kode = 0 at least one data sample is within start, stop times c kode = 1 this data past current defined limits. c c------------------------------------------------------------------------ c integer*4 icollect_times(4), idms, idur, ie, iflag, inc, * irun_times(4), is, it, iyd, kode c common /blktim/iyd, it, * /com_times/irun_times, icollect_times, idur, inc c data f,nsamp/0.064,512/ c c------------------------------------------------------------------------ c *** see if some of the record is within time limits *** c------------------------------------------------------------------------ c call lmstst (kode) if (kode .ne. 0) return c c------------------------------------------------------------------------ c *** find time difference from record time to start time *** c------------------------------------------------------------------------ c is = 1 call diftms (icollect_times(1), icollect_times(2), iyd, it, iflag, * idms) if (iflag .ne. 0) go to 20 c c------------------------------------------------------------------------ c *** convert time difference to start sample number *** c------------------------------------------------------------------------ c ms = 1+ (float(idms) * f) if (ms .gt. 0) is = ms if (ms .lt. 1) is = 1 c c------------------------------------------------------------------------ c *** find time difference from record time to stop time *** c------------------------------------------------------------------------ c 20 ie = nsamp call diftms (icollect_times(3), icollect_times(4), iyd, it, iflag, * idms) c c------------------------------------------------------------------------ c *** convert time difference to end sample number *** c------------------------------------------------------------------------ c me = 1 + (float(idms) * f) if (me. le. nsamp) ie = me if (me. gt. nsamp) ie = nsamp c c------------------------------------------------------------------------ c------------------------------------------------------------------------ c return end