#include <stdlib.h>#include <stdio.h>#include <time.h>#include <ctype.h>#include <math.h>#include <errno.h>#include <unistd.h>#include <string.h>#include <sys/types.h>#include <sys/stat.h>#include <fcntl.h>#include <dirent.h>#include <assert.h>#include <signal.h>#include "common.h"
Go to the source code of this file.
Defines | |
| #define | CR 13 |
| #define | LF 10 |
| #define | BLOCK_LENGTH 1024 |
| #define | BLOCK_SIZE (BLOCK_LENGTH/sizeof(int32_t)) |
Functions | |
| FILE * | OpenSisBinFile (void) |
| open a sisbin file for output | |
| void | AbortSisBinFile (void) |
| close and remove the file | |
| void | AddSisData (int channel) |
| process one channel | |
| char * | time2strSismalp (double temps) |
| format the time for sismalp ndx file | |
| void | CloseSisFile (void) |
| end a binary file After closing the file, the image is built and the bin file is removed. | |
Variables | |
| int64_t | avg [MAX_CHANNEL] |
| int64_t | ndata [MAX_CHANNEL] |
| FILE * | sisBinFile = NULL |
| char | sisBinFileName [255] |
| int | sisOffset [MAX_CHANNEL] |
| #define BLOCK_SIZE (BLOCK_LENGTH/sizeof(int32_t)) |
| #define CR 13 |
| #define LF 10 |
| void AbortSisBinFile | ( | void | ) |
close and remove the file
Definition at line 89 of file sis.c.
References sisBinFile, and sisBinFileName.
Referenced by AddSisData().
| void AddSisData | ( | int | channel | ) |
process one channel
| channel | the channel to process |
Definition at line 101 of file sis.c.
References AbortSisBinFile(), avg, CloseSisFile(), HWConfigType::data, HWConfig, infoHeader, MAX_CHANNEL, ndata, InfoHeaderType::npts, Titan2SRType::npts, OpenSisBinFile(), PrintError, removeMean, sisBinFile, sisBinFileName, HWConfigType::srExp, and HWConfigType::srObs.
Referenced by EndSuperFrame().
| void CloseSisFile | ( | void | ) |
end a binary file After closing the file, the image is built and the bin file is removed.
Definition at line 173 of file sis.c.
References ADD_CHANNEL_CODE, avg, Titan2SRType::base, BLOCK_SIZE, correctedTime, CR, Titan2SRType::div, FileName(), fileNameOptions, infoHeader, LF, MAX_CHANNEL, ndata, InfoHeaderType::npts, oldHWConfig, PrintError, PrintLog, removeMean, sisBinFile, sisBinFileName, sisOffset, skipTime, HWConfigType::srExp, station, time2strSismalp(), UpdateInfoHeader(), and Titan2TimeType::usecond.
Referenced by AddSisData(), and FlushDataFiles().
| FILE* OpenSisBinFile | ( | void | ) |
open a sisbin file for output
Definition at line 61 of file sis.c.
References avg, FILE_BUFFER_SIZE, HWConfig, infoHeader, InitInfoHeader(), MAX_CHANNEL, ndata, InfoHeaderType::npts, Titan2SRType::npts, OpenTempFile(), sisBinFile, sisBinFileName, and HWConfigType::srObs.
Referenced by AddSisData().
| char* time2strSismalp | ( | double | temps | ) |
format the time for sismalp ndx file
| temps | the time to represent |
Definition at line 156 of file sis.c.
Referenced by CloseSisFile().
| int64_t avg[MAX_CHANNEL] |
Definition at line 49 of file sis.c.
Referenced by AddSisData(), CloseSisFile(), and OpenSisBinFile().
| int64_t ndata[MAX_CHANNEL] |
Definition at line 50 of file sis.c.
Referenced by AddSisData(), CloseMSeedSteim1File(), CloseSisFile(), OpenSisBinFile(), and PulseFilter().
| FILE* sisBinFile = NULL |
Definition at line 52 of file sis.c.
Referenced by AbortSisBinFile(), AddSisData(), CloseSisFile(), and OpenSisBinFile().
| char sisBinFileName[255] |
Definition at line 53 of file sis.c.
Referenced by AbortSisBinFile(), AddSisData(), CloseSisFile(), and OpenSisBinFile().
| int sisOffset[MAX_CHANNEL] |
1.5.6