nidas  v1.2-1520
Public Member Functions | Static Public Member Functions | Protected Member Functions | Protected Attributes | Static Protected Attributes | Private Member Functions | List of all members
ExtractFast2D Class Reference
Inheritance diagram for ExtractFast2D:
Inheritance graph
[legend]

Public Member Functions

 ExtractFast2D ()
 
int run () throw ()
 
virtual int parseRunstring (int argc, char **argv) throw ()
 
virtual int usage (const char *argv0)
 
void sendHeader (dsm_time_t, SampleOutput *out) throw (nidas::util::IOException)
 Method called to write a header to an SampleOutput. More...
 

Static Public Member Functions

static int main (int argc, char **argv) throw ()
 
static void sigAction (int sig, siginfo_t *siginfo, void *)
 
static void setupSignals ()
 
static void setDefaults (SampleInputHeader &header)
 
static void sendDefaultHeader (SampleOutput *output) throw (nidas::util::IOException)
 

Protected Member Functions

void setTimeStamp (P2d_rec &record, Sample *samp)
 Decode Sample time tag and place into outgoing record. More...
 
void setTimeStamp (PADS_rec &record, Sample *samp)
 

Protected Attributes

bool outputHeader
 
bool outputDiodeCount
 Whether to output diode count histogram. More...
 
bool outputParticleCount
 Whether to output particle count histogram. More...
 
bool copyAllRecords
 Copy 100% of 2D records from source file to output file, no filtering. More...
 
string xmlFileName
 
list< string > inputFileNames
 
string outputFileName
 
int outputFileLength
 
SampleInputHeader header
 
set< dsm_sample_id_tincludeIds
 
set< dsm_sample_id_texcludeIds
 
map< dsm_sample_id_t,
dsm_sample_id_t
newids
 
size_t minNumberParticlesRequired
 

Static Protected Attributes

static bool interrupted = false
 

Private Member Functions

size_t countParticles (Probe *probe, const unsigned char *record)
 Count number of particles in a record, also report miss-aligned data. More...
 
size_t computeDiodeCount (Probe *probe, const unsigned char *record)
 Sum occluded diodes along the flight path. More...
 

Constructor & Destructor Documentation

ExtractFast2D::ExtractFast2D ( )
inline

Member Function Documentation

size_t ExtractFast2D::computeDiodeCount ( Probe probe,
const unsigned char *  record 
)
privatevirtual

Sum occluded diodes along the flight path.

This increments for the whole flight. Help find stuck bits.

Returns
the number of diodes that had positives in the record.

Implements nidas::dynld::raf::Extract2D.

References nidas::dynld::raf::Probe::diodeCount, Fast2DsyncStr, FastOverloadSync, nidas::dynld::raf::Probe::nDiodes, and P2D_DATA.

size_t ExtractFast2D::countParticles ( Probe probe,
const unsigned char *  record 
)
privatevirtual
int ExtractFast2D::main ( int  argc,
char **  argv 
)
throw (
)
static
int Extract2D::parseRunstring ( int  argc,
char **  argv 
)
throw (
)
virtualinherited

Reimplemented in ExtractDMT.

References usage().

Referenced by main().

int ExtractFast2D::run ( )
throw (
)
virtual

Implements nidas::dynld::raf::Extract2D.

References bigEndian, nidas::dynld::raf::Probe::clockFreq, nidas::dynld::raf::P2d_rec::data, nidas::dynld::raf::Probe::diodeCount, _Tap2D_v2::div10, nidas::util::Process::expandEnvVars(), FILE_VERSION, nidas::core::Sample::freeReference(), nidas::core::Project::fromDOMElement(), nidas::core::DSMSensor::getCatalogName(), nidas::core::Sample::getConstVoidDataPtr(), nidas::core::Sample::getDataByteLength(), nidas::core::Project::getDSMConfigIterator(), nidas::core::FileSet::getFileSet(), nidas::core::Sample::getId(), nidas::dynld::SampleInputStream::getInputHeader(), nidas::core::Project::getInstance(), nidas::core::Parameter::getNumericValue(), nidas::core::DSMSensor::getParameter(), nidas::core::DSMConfig::getSensors(), nidas::core::Parameter::getStringValue(), nidas::core::DSMSensor::getSuffix(), nidas::core::DSMConfigIterator::hasNext(), nidas::dynld::raf::Probe::hasOverloadCount, nidas::dynld::raf::P2d_rec::id, nidas::dynld::raf::Probe::id, nidas::dynld::raf::Probe::inDOF, nidas::util::EndianConverter::int32Value(), interrupted, nidas::dynld::raf::Probe::nDiodes, nidas::core::DSMConfigIterator::next(), _Tap2D_v2::ntap, nidas::dynld::raf::P2d_rec::overld, overLoadSync, P2D_DATA, nidas::core::parseXMLConfigFile(), nidas::dynld::raf::Probe::particleCount, nidas::dynld::SampleInputStream::readInputHeader(), nidas::dynld::SampleInputStream::readSample(), nidas::dynld::raf::Probe::recordCount, nidas::dynld::raf::Probe::rejectRecordCount, nidas::dynld::raf::Probe::rejectTooFewDiodesCount, nidas::dynld::raf::Probe::rejectTooFewParticleCount, nidas::dynld::raf::Probe::resolution, nidas::dynld::raf::Probe::resolutionM, nidas::dynld::raf::Probe::sensor, nidas::dynld::raf::Probe::serialNumber, nidas::dynld::raf::P2d_rec::tas, nidas::dynld::raf::Probe::totalParticles, TWOD_IMG_TYPE, TWOD_IMGv2_TYPE, TWOD_IMGv3_TYPE, nidas::dynld::raf::Probe::waveLength, and nidas::util::Exception::what().

Referenced by main().

void HeaderSource::sendDefaultHeader ( SampleOutput output)
throw (nidas::util::IOException
)
staticinherited
void Extract2D::sendHeader ( dsm_time_t  ,
SampleOutput output 
)
throw (nidas::util::IOException
)
virtualinherited

Method called to write a header to an SampleOutput.

Derived classes implement as they see fit.

Implements nidas::core::HeaderSource.

void HeaderSource::setDefaults ( SampleInputHeader header)
staticinherited
void Extract2D::setTimeStamp ( P2d_rec record,
Sample samp 
)
protectedinherited
void Extract2D::setTimeStamp ( PADS_rec record,
Sample samp 
)
protectedinherited
void Extract2D::setupSignals ( )
staticinherited

References sigAction().

void Extract2D::sigAction ( int  sig,
siginfo_t *  siginfo,
void *   
)
staticinherited

References interrupted.

int Extract2D::usage ( const char *  argv0)
virtualinherited

Reimplemented in ExtractDMT.

Member Data Documentation

bool nidas::dynld::raf::Extract2D::copyAllRecords
protectedinherited

Copy 100% of 2D records from source file to output file, no filtering.

set<dsm_sample_id_t> nidas::dynld::raf::Extract2D::excludeIds
protectedinherited
SampleInputHeader nidas::dynld::raf::Extract2D::header
protectedinherited
set<dsm_sample_id_t> nidas::dynld::raf::Extract2D::includeIds
protectedinherited
list<string> nidas::dynld::raf::Extract2D::inputFileNames
protectedinherited
bool Extract2D::interrupted = false
staticprotectedinherited
size_t nidas::dynld::raf::Extract2D::minNumberParticlesRequired
protectedinherited
map<dsm_sample_id_t,dsm_sample_id_t> nidas::dynld::raf::Extract2D::newids
protectedinherited
bool nidas::dynld::raf::Extract2D::outputDiodeCount
protectedinherited

Whether to output diode count histogram.

int nidas::dynld::raf::Extract2D::outputFileLength
protectedinherited
string nidas::dynld::raf::Extract2D::outputFileName
protectedinherited
bool nidas::dynld::raf::Extract2D::outputHeader
protectedinherited
bool nidas::dynld::raf::Extract2D::outputParticleCount
protectedinherited

Whether to output particle count histogram.

string nidas::dynld::raf::Extract2D::xmlFileName
protectedinherited

The documentation for this class was generated from the following file: