Changeset 11441 for trunk/FACT++/src/Fits.cc
- Timestamp:
- 07/18/11 16:22:42 (13 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/FACT++/src/Fits.cc
r11405 r11441 258 258 } 259 259 260 //As requested by Roland, the reference MjD is 0.0261 fRefMjD = 0;//* static_cast<double*>(fStandardPointers[0]);262 260 if (!updating) 263 261 return WriteHeaderKeys(); … … 293 291 bool Fits::WriteHeaderKeys() 294 292 { 295 if (!fTable) 296 return false; 297 298 string stringValue = Time().GetAsStr(); 299 stringValue[10]= 'T'; 300 301 if (!WriteSingleHeaderKey("EXTREL", 1.0f, "Release Number")) return false; 302 if (!WriteSingleHeaderKey("TELESCOP", "FACT", "Telescope that acquired this data")) return false; 303 if (!WriteSingleHeaderKey("ORIGIN", "ISDC", "Institution that wrote the file")) return false; 304 if (!WriteSingleHeaderKey("CREATOR", "FACT++ DataLogger", "Program that wrote this file")) return false; 305 if (!WriteSingleHeaderKey("DATE", stringValue, "File creation data")) return false; 306 if (!WriteSingleHeaderKey("TIMESYS", "TT", "Time frame system")) return false; 307 if (!WriteSingleHeaderKey("TIMEUNIT", "d", "Time unit")) return false; 308 if (!WriteSingleHeaderKey("TIMEREF", "UTC", "Time reference frame")) return false; 309 if (!WriteSingleHeaderKey("MJDREF", fRefMjD, "Modified Julian Date of origin")) return false; 310 if (!WriteSingleHeaderKey("TSTOP", fEndMjD, "Time of the last receied data")) return false; 293 if (!fTable) 294 return false; 295 296 const Time now; 297 if (!WriteSingleHeaderKey("EXTREL", 1.0f, "Release Number")) return false; 298 if (!WriteSingleHeaderKey("TELESCOP", "FACT", "Telescope that acquired this data")) return false; 299 if (!WriteSingleHeaderKey("ORIGIN", "ISDC", "Institution that wrote the file")) return false; 300 if (!WriteSingleHeaderKey("CREATOR", "fadctrl", "Program that wrote this file (FACT++ datalogger)")) return false; 301 if (!WriteSingleHeaderKey("PACKAGE", PACKAGE_NAME, "Package name")) return false; 302 if (!WriteSingleHeaderKey("VERSION", PACKAGE_VERSION, "Package description")) return false; 303 if (!WriteSingleHeaderKey("COMPILED", __DATE__" "__TIME__, "Compile time")) return false; 304 if (!WriteSingleHeaderKey("REVISION", REVISION, "SVN revision")) return false; 305 if (!WriteSingleHeaderKey("DATE", now.Iso(), "File creation date")) return false; 306 if (!WriteSingleHeaderKey("NIGHT", now.NightAsInt(), "Night as int")) return false; 307 if (!WriteSingleHeaderKey("TIMESYS", "UTC", "Time systen")) return false; 308 if (!WriteSingleHeaderKey("TSTART", "", "Time of the first receied data")) return false; 309 if (!WriteSingleHeaderKey("TSTOP", "", "Time of the last receied data")) return false; 311 310 return true; 312 311 } … … 360 359 { 361 360 const double doubleValue = *reinterpret_cast<double*>(fStandardPointers[0]); 362 WriteSingleHeaderKey("TSTART", doubleValue,361 WriteSingleHeaderKey("TSTART", Time(doubleValue).Iso(), 363 362 "Time of the first received data"); 364 363 } … … 393 392 // CCfits::FITS* backupFits = fFile; 394 393 // fFile = NULL; 395 WriteSingleHeaderKey("TSTOP", fEndMjD, "Time of the last receied data");394 WriteSingleHeaderKey("TSTOP", Time(fEndMjD).Iso(), "Time of the last receied data"); 396 395 delete fFile; 397 396
Note:
See TracChangeset
for help on using the changeset viewer.