cDvbTuner Class Reference

Inheritance diagram for cDvbTuner:

Inheritance graph
[legend]
Collaboration diagram for cDvbTuner:

Collaboration graph
[legend]

List of all members.

Public Member Functions

 cDvbTuner (int Fd_Frontend, int CardIndex, fe_type_t FrontendType)
virtual ~cDvbTuner ()
bool IsTunedTo (const cChannel *Channel) const
void Set (const cChannel *Channel, bool Tune)
bool Locked (int TimeoutMs=0)

Private Types

enum  eTunerStatus { tsIdle, tsSet, tsTuned, tsLocked }

Private Member Functions

bool GetFrontendStatus (fe_status_t &Status, int TimeoutMs=0)
bool SetFrontend (void)
virtual void Action (void)

Private Attributes

int fd_frontend
int cardIndex
int tuneTimeout
int lockTimeout
time_t lastTimeoutReport
fe_type_t frontendType
cChannel channel
const char * diseqcCommands
eTunerStatus tunerStatus
cMutex mutex
cCondVar locked
cCondVar newSet


Detailed Description

Definition at line 71 of file dvbdevice.c.


Member Enumeration Documentation

enum cDvbTuner::eTunerStatus [private]

Enumerator:
tsIdle 
tsSet 
tsTuned 
tsLocked 

Definition at line 73 of file dvbdevice.c.


Constructor & Destructor Documentation

cDvbTuner::cDvbTuner ( int  Fd_Frontend,
int  CardIndex,
fe_type_t  FrontendType 
)

Definition at line 97 of file dvbdevice.c.

References cardIndex, CHECK, diseqcCommands, fd_frontend, frontendType, lastTimeoutReport, lockTimeout, cThread::SetDescription(), cThread::Start(), tsIdle, tunerStatus, and tuneTimeout.

Here is the call graph for this function:

cDvbTuner::~cDvbTuner (  )  [virtual]

Definition at line 113 of file dvbdevice.c.

References cCondVar::Broadcast(), cThread::Cancel(), locked, newSet, tsIdle, and tunerStatus.

Here is the call graph for this function:


Member Function Documentation

bool cDvbTuner::GetFrontendStatus ( fe_status_t &  Status,
int  TimeoutMs = 0 
) [private]

Definition at line 148 of file dvbdevice.c.

References fd_frontend, and cPoller::Poll().

Referenced by Action().

Here is the call graph for this function:

bool cDvbTuner::SetFrontend ( void   )  [private]

void cDvbTuner::Action ( void   )  [private, virtual]

A derived cThread class must implement the code it wants to execute as a separate thread in this function. If this is a loop, it must check Running() repeatedly to see whether it's time to stop.

Implements cThread.

Definition at line 290 of file dvbdevice.c.

References cCondVar::Broadcast(), cardIndex, channel, diseqcCommands, GetFrontendStatus(), isyslog, lastTimeoutReport, locked, lockTimeout, mutex, newSet, cChannel::Number(), cThread::Running(), cTimeMs::Set(), SetFrontend(), cTimeMs::TimedOut(), cCondVar::TimedWait(), cChannel::Transponder(), tsIdle, tsLocked, tsSet, tsTuned, tunerStatus, and tuneTimeout.

Here is the call graph for this function:

bool cDvbTuner::IsTunedTo ( const cChannel Channel  )  const

Definition at line 121 of file dvbdevice.c.

References channel, cChannel::Source(), cChannel::Transponder(), tsIdle, and tunerStatus.

Referenced by cDvbDevice::IsTunedToTransponder(), cDvbDevice::ProvidesChannel(), and cDvbDevice::SetChannelDevice().

Here is the call graph for this function:

void cDvbTuner::Set ( const cChannel Channel,
bool  Tune 
)

Definition at line 126 of file dvbdevice.c.

References cCondVar::Broadcast(), channel, lastTimeoutReport, mutex, newSet, tsSet, and tunerStatus.

Referenced by cDvbDevice::SetChannelDevice().

Here is the call graph for this function:

bool cDvbTuner::Locked ( int  TimeoutMs = 0  ) 

Definition at line 136 of file dvbdevice.c.

References locked, mutex, cCondVar::TimedWait(), tsLocked, and tunerStatus.

Referenced by cDvbDevice::HasLock().

Here is the call graph for this function:


Member Data Documentation

int cDvbTuner::fd_frontend [private]

Definition at line 74 of file dvbdevice.c.

Referenced by cDvbTuner(), GetFrontendStatus(), and SetFrontend().

int cDvbTuner::cardIndex [private]

Definition at line 75 of file dvbdevice.c.

Referenced by Action(), cDvbTuner(), and SetFrontend().

int cDvbTuner::tuneTimeout [private]

Definition at line 76 of file dvbdevice.c.

Referenced by Action(), cDvbTuner(), and SetFrontend().

int cDvbTuner::lockTimeout [private]

Definition at line 77 of file dvbdevice.c.

Referenced by Action(), cDvbTuner(), and SetFrontend().

time_t cDvbTuner::lastTimeoutReport [private]

Definition at line 78 of file dvbdevice.c.

Referenced by Action(), cDvbTuner(), and Set().

fe_type_t cDvbTuner::frontendType [private]

Definition at line 79 of file dvbdevice.c.

Referenced by cDvbTuner(), and SetFrontend().

Definition at line 80 of file dvbdevice.c.

Referenced by Action(), IsTunedTo(), Set(), and SetFrontend().

const char* cDvbTuner::diseqcCommands [private]

Definition at line 81 of file dvbdevice.c.

Referenced by Action(), cDvbTuner(), and SetFrontend().

Definition at line 82 of file dvbdevice.c.

Referenced by Action(), cDvbTuner(), IsTunedTo(), Locked(), Set(), and ~cDvbTuner().

Reimplemented from cThread.

Definition at line 83 of file dvbdevice.c.

Referenced by Action(), Locked(), and Set().

Definition at line 84 of file dvbdevice.c.

Referenced by Action(), Locked(), and ~cDvbTuner().

Definition at line 85 of file dvbdevice.c.

Referenced by Action(), Set(), and ~cDvbTuner().


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

Generated on Tue Nov 4 19:58:50 2008 for VDR by  doxygen 1.5.6