Changeset 14570 for trunk


Ignore:
Timestamp:
11/06/12 11:50:28 (12 years ago)
Author:
lyard
Message:
changed day count criterion to MjD
File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/FACT++/src/datalogger.cc

    r14569 r14570  
    811811    const Time timeNow;
    812812    const Time nowMinusTwelve = timeNow-boost::posix_time::hours(12);
    813     fCurrentDay = nowMinusTwelve.M()*31 + nowMinusTwelve.D();//assume 31 days per month. we do not really care, only want unique number per day of the year
     813    fCurrentDay = (int)(timeNow.MjD());//nowMinusTwelve.M()*31 + nowMinusTwelve.D();//assume 31 days per month. we do not really care, only want unique number per day of the year
    814814    lastFlush = Time();
    815815
     
    11631163    const Time timeNow;
    11641164    const Time nowMinusTwelve = timeNow-boost::posix_time::hours(12);
    1165     int newDayNumber = nowMinusTwelve.M()*31 + nowMinusTwelve.D();//assume 31 days per month. we do not really care, only want unique number per day of the year
     1165    int newDayNumber = (int)(timeNow.MjD());//nowMinusTwelve.M()*31 + nowMinusTwelve.D();//assume 31 days per month. we do not really care, only want unique number per day of the year
    11661166
    11671167    //also check if we should flush the nightly files
Note: See TracChangeset for help on using the changeset viewer.