Main Page | Namespace List | Class Hierarchy | Alphabetical List | Compound List | File List | Compound Members | File Members

clBeamSrv2Master Class Reference

Beamforming input server, root node. More...

#include <BeamSrv2.hh>

Collaboration diagram for clBeamSrv2Master:

Collaboration graph
[legend]
List of all members.

Public Member Functions

 clBeamSrv2Master ()
 ~clBeamSrv2Master ()
int Main (int *, char ***)
void * InDataThread (void *)
void * ServerThread (void *)
void * ServeClientThread (void *)

Static Public Member Functions

void Abort (int=0)

Private Member Functions

bool ReadConfig ()
bool InitFilterBank ()
bool InitProcessing ()
bool WaitReady ()
void ProcessLoop ()
void CompactData (GDT *, const GDT *, long, long, long, long)
bool FilterData (GDT *, const GDT *, long, long, long, long)

Private Attributes

int iFilterType
int iDecimate
int iDecFact
int iChOffset
int iOutDataCount
char cpLogBuf [BS_LOGBUFSIZE]
stRawDataFirst sInHdr
stBeamNodeParams sNodeParams
clAlloc FiltWork
clCfgFile Cfg
clDSPOp DSP
clLogFile Log
clRecDecimator * FilterBank
clSockOp SOpIn
clSockServ SServ
clReBuffer InBuf
clSemaphore SemIn
clMutex MtxIn
clAlloc OutData
clCondition CndOut
clMutex MtxOut

Detailed Description

Beamforming input server, root node.

This node reads data from streamdist, distributes it to slave nodes, collects beamformed data and sends it to clients. Each beam is represented as a channel at output.

Definition at line 63 of file BeamSrv2.hh.


Constructor & Destructor Documentation

clBeamSrv2Master::clBeamSrv2Master  ) 
 

Definition at line 424 of file BeamSrv2.cc.

References clLogFile::Add(), BS_LOGFILE, FilterBank, Log, and clLogFile::Open().

clBeamSrv2Master::~clBeamSrv2Master  ) 
 

Definition at line 432 of file BeamSrv2.cc.

References clLogFile::Add(), FilterBank, and Log.


Member Function Documentation

bool clBeamSrv2Master::ReadConfig  )  [private]
 

Definition at line 159 of file BeamSrv2.cc.

References clLogFile::Add(), Cfg, _stBeamNodeParams::fSoundSpeed, _stBeamNodeParams::fSpacing, clCfgFile::GetFlt(), clCfgFile::GetInt(), _stBeamNodeParams::iBeamCount, _stBeamNodeParams::iBlockSize, iDecimate, _stBeamNodeParams::iSensors, _stBeamNodeParams::iType, _stBeamNodeParams::iWindowSize, Log, and sNodeParams.

Referenced by Main().

bool clBeamSrv2Master::InitFilterBank  )  [private]
 

Definition at line 206 of file BeamSrv2.cc.

References Abort(), clLogFile::Add(), Cfg, cpLogBuf, _stRawDataFirst::dSampleRate, FilterBank, _stBeamNodeParams::fSampleRate, _stBeamNodeParams::fSoundSpeed, _stBeamNodeParams::fSpacing, GDT, clCfgFile::GetInt(), iDecFact, iDecimate, iFilterType, _stBeamNodeParams::iSensors, _stBeamNodeParams::iWindowSize, Log, sInHdr, and sNodeParams.

Referenced by Main().

bool clBeamSrv2Master::InitProcessing  )  [private]
 

Definition at line 251 of file BeamSrv2.cc.

References clLogFile::Add(), BeamCommNodeParams(), _stBeamNodeParams::iBeamCount, _stRawDataFirst::iChannels, iChOffset, _stBeamNodeParams::iSensors, Log, sInHdr, and sNodeParams.

Referenced by Main().

bool clBeamSrv2Master::WaitReady  )  [private]
 

Definition at line 272 of file BeamSrv2.cc.

References clLogFile::Add(), BS_TAG_READY, cpLogBuf, _stBeamNodeParams::iBeamCount, Log, and sNodeParams.

Referenced by Main().

void clBeamSrv2Master::ProcessLoop  )  [private]
 

Definition at line 292 of file BeamSrv2.cc.

References clLogFile::Add(), BeamCommInData(), bRun, BS_TAG_RES, CndOut, CompactData(), cpLogBuf, DSP, FilterData(), GDT, _stBeamNodeParams::iBeamCount, _stBeamNodeParams::iBlockSize, _stRawDataFirst::iChannels, iChOffset, iDecFact, InBuf, iOutDataCount, _stBeamNodeParams::iSensors, Log, MtxIn, MtxOut, OutData, SemIn, sInHdr, and sNodeParams.

Referenced by Main().

void clBeamSrv2Master::CompactData GDT *  ,
const GDT *  ,
long  ,
long  ,
long  ,
long 
[private]
 

Definition at line 374 of file BeamSrv2.cc.

Referenced by ProcessLoop().

bool clBeamSrv2Master::FilterData GDT *  ,
const GDT *  ,
long  ,
long  ,
long  ,
long 
[private]
 

Definition at line 394 of file BeamSrv2.cc.

References DSP, FilterBank, FiltWork, and GDT.

Referenced by ProcessLoop().

int clBeamSrv2Master::Main int *  ,
char *** 
 

Definition at line 440 of file BeamSrv2.cc.

References Abort(), clLogFile::Add(), BeamSrvMasterThreads, clSockServ::Bind(), BS_CFGFILE, Cfg, clSockClie::Connect(), cpLogBuf, _stRawDataFirst::dSampleRate, clSockOp::GetErrno(), clSockClie::GetErrno(), clSockServ::GetErrno(), clCfgFile::GetInt(), clCfgFile::GetStr(), _stRawDataReq::iChannel, _stRawDataFirst::iChannels, iChOffset, InDataThread(), InitFilterBank(), InitProcessing(), Log, ProcessLoop(), ReadConfig(), clSockOp::ReadN(), ServerThread(), clCfgFile::SetFileName(), clSockOp::SetHandle(), sInHdr, SOpIn, SServ, WaitReady(), and clSockOp::WriteN().

void clBeamSrv2Master::Abort int  = 0  )  [static]
 

Definition at line 535 of file BeamSrv2.cc.

Referenced by InDataThread(), InitFilterBank(), and Main().

void * clBeamSrv2Master::InDataThread void *   ) 
 

Definition at line 541 of file BeamSrv2.cc.

References Abort(), bRun, GDT, _stBeamNodeParams::iBlockSize, _stRawDataFirst::iChannels, InBuf, MtxIn, clSockOp::ReadN(), SemIn, sInHdr, sNodeParams, and SOpIn.

Referenced by Main().

void * clBeamSrv2Master::ServerThread void *   ) 
 

Definition at line 566 of file BeamSrv2.cc.

References BeamSrvMasterThreads, bRun, BS_ACCEPT_TO, ServeClientThread(), SServ, and clSockServ::WaitForConnect().

Referenced by Main().

void * clBeamSrv2Master::ServeClientThread void *   ) 
 

Definition at line 584 of file BeamSrv2.cc.

References clLogFile::Add(), bRun, CndOut, clSockOp::DisableNagle(), _stSoundStart::dSampleRate, _stBeamNodeParams::fSampleRate, GDT, clSockOp::GetErrno(), GLOBAL_HEADER_LEN, _stBeamNodeParams::iBeamCount, _stSoundStart::iChannels, _stSoundStart::iCompress, _stSoundStart::iFragmentSize, iOutDataCount, Log, MSG_SOUND_COMPRESS_NONE, MtxOut, OutData, clSoundMsg::SetData(), clSockOp::SetHandle(), clSoundMsg::SetStart(), clSockOp::SetTypeOfService(), sNodeParams, SOp, and clSockOp::WriteN().

Referenced by ServerThread().


Member Data Documentation

int clBeamSrv2Master::iFilterType [private]
 

Definition at line 65 of file BeamSrv2.hh.

Referenced by InitFilterBank().

int clBeamSrv2Master::iDecimate [private]
 

Definition at line 66 of file BeamSrv2.hh.

Referenced by InitFilterBank(), and ReadConfig().

int clBeamSrv2Master::iDecFact [private]
 

Definition at line 67 of file BeamSrv2.hh.

Referenced by InitFilterBank(), and ProcessLoop().

int clBeamSrv2Master::iChOffset [private]
 

Definition at line 68 of file BeamSrv2.hh.

Referenced by InitProcessing(), Main(), and ProcessLoop().

int clBeamSrv2Master::iOutDataCount [private]
 

Definition at line 69 of file BeamSrv2.hh.

Referenced by ProcessLoop(), and ServeClientThread().

char clBeamSrv2Master::cpLogBuf[BS_LOGBUFSIZE] [private]
 

Definition at line 70 of file BeamSrv2.hh.

Referenced by InitFilterBank(), Main(), ProcessLoop(), and WaitReady().

stRawDataFirst clBeamSrv2Master::sInHdr [private]
 

Definition at line 71 of file BeamSrv2.hh.

Referenced by InDataThread(), InitFilterBank(), InitProcessing(), Main(), and ProcessLoop().

stBeamNodeParams clBeamSrv2Master::sNodeParams [private]
 

Definition at line 72 of file BeamSrv2.hh.

Referenced by InDataThread(), InitFilterBank(), InitProcessing(), ProcessLoop(), ReadConfig(), ServeClientThread(), and WaitReady().

clAlloc clBeamSrv2Master::FiltWork [private]
 

Definition at line 73 of file BeamSrv2.hh.

Referenced by FilterData().

clCfgFile clBeamSrv2Master::Cfg [private]
 

Definition at line 74 of file BeamSrv2.hh.

Referenced by InitFilterBank(), Main(), and ReadConfig().

clDSPOp clBeamSrv2Master::DSP [private]
 

Definition at line 75 of file BeamSrv2.hh.

Referenced by FilterData(), and ProcessLoop().

clLogFile clBeamSrv2Master::Log [private]
 

Definition at line 76 of file BeamSrv2.hh.

Referenced by clBeamSrv2Master(), InitFilterBank(), InitProcessing(), Main(), ProcessLoop(), ReadConfig(), ServeClientThread(), WaitReady(), and ~clBeamSrv2Master().

clRecDecimator* clBeamSrv2Master::FilterBank [private]
 

Definition at line 77 of file BeamSrv2.hh.

Referenced by clBeamSrv2Master(), FilterData(), InitFilterBank(), and ~clBeamSrv2Master().

clSockOp clBeamSrv2Master::SOpIn [private]
 

Definition at line 78 of file BeamSrv2.hh.

Referenced by InDataThread(), and Main().

clSockServ clBeamSrv2Master::SServ [private]
 

Definition at line 79 of file BeamSrv2.hh.

Referenced by Main(), and ServerThread().

clReBuffer clBeamSrv2Master::InBuf [private]
 

Definition at line 81 of file BeamSrv2.hh.

Referenced by InDataThread(), and ProcessLoop().

clSemaphore clBeamSrv2Master::SemIn [private]
 

Definition at line 82 of file BeamSrv2.hh.

Referenced by InDataThread(), and ProcessLoop().

clMutex clBeamSrv2Master::MtxIn [private]
 

Definition at line 83 of file BeamSrv2.hh.

Referenced by InDataThread(), and ProcessLoop().

clAlloc clBeamSrv2Master::OutData [private]
 

Definition at line 85 of file BeamSrv2.hh.

Referenced by ProcessLoop(), and ServeClientThread().

clCondition clBeamSrv2Master::CndOut [private]
 

Definition at line 86 of file BeamSrv2.hh.

Referenced by ProcessLoop(), and ServeClientThread().

clMutex clBeamSrv2Master::MtxOut [private]
 

Definition at line 87 of file BeamSrv2.hh.

Referenced by ProcessLoop(), and ServeClientThread().


The documentation for this class was generated from the following files:
Generated on Sun Oct 26 19:12:13 2003 for HASAS by doxygen 1.3.3