Data Structures | |
struct | DVBAdapterPIDFilter_s |
Structure used to keep track of hardware pid filters. More... | |
struct | DVBAdapter_t |
Structure representing a DVB Adapter, that is a frontend, a demux and a dvr device. More... | |
struct | DVBDiSEqCSettings_s |
Structure used to hold the information necessary to setup DiSEqC switches to receive a specifiec satellite. More... | |
Defines | |
#define | DVB_MAX_PID_FILTERS 15 |
Maximum number of PID filters when running in hardware restricted mode. | |
Typedefs | |
typedef struct DVBAdapterPIDFilter_s | DVBAdapterPIDFilter_t |
typedef struct DVBDiSEqCSettings_s | DVBDiSEqCSettings_t |
Enumerations | |
enum | Polarisation_e { POL_HORIZONTAL = 0, POL_VERTICAL } |
Enum to represent the different polarisation available for satellite transmission. | |
Functions | |
DVBAdapter_t * | DVBInit (int adapter, bool hwRestricted) |
Open a DVB Adapter. | |
void | DVBDispose (DVBAdapter_t *adapter) |
Close a DVPAdapter. | |
int | DVBFrontEndTune (DVBAdapter_t *adapter, struct dvb_frontend_parameters *frontend, DVBDiSEqCSettings_t *diseqc) |
Tune the frontend to the specified parameters. | |
void | DVBFrontEndLNBInfoSet (DVBAdapter_t *adapter, int lowFreq, int highFreq, int switchFreq) |
Set the LNB LO frequencies. | |
int | DVBFrontEndStatus (DVBAdapter_t *adapter, fe_status_t *status, unsigned int *ber, unsigned int *strength, unsigned int *snr, unsigned int *ucblocks) |
Retrieve the status of the frontend of the specified adapter. | |
int | DVBDemuxSetBufferSize (DVBAdapter_t *adapter, unsigned long size) |
Set the size of the circular buffer used by the demux. | |
int | DVBDemuxAllocateFilter (DVBAdapter_t *adapter, uint16_t pid, bool system) |
Allocate a new PID Filter, indicating whether it is a system PID or not. | |
int | DVBDemuxReleaseFilter (DVBAdapter_t *adapter, uint16_t pid) |
Release a specific PID filter. | |
int | DVBDemuxReleaseAllFilters (DVBAdapter_t *adapter, bool system) |
Release all application or system PID filters. | |
int | DVBDVRRead (DVBAdapter_t *adapter, char *data, int max, int timeout) |
Read upto max bytes from the dvr device belonging to the specified adapter. |
By default the entire transport stream is routed to the DVR device, although for hardware restricted devices it is possible to allocate PID filters that are routed to the DVR device. These PID filters are grouped into system and application filters, making it easier to release a specific set of PID filters that are being used to filter a service say.
payload
= The adapter that has locked.payload
= The adapter that has lost locked.payload
= The adapter that failed to tune. int DVBDemuxAllocateFilter | ( | DVBAdapter_t * | adapter, | |
uint16_t | pid, | |||
bool | system | |||
) |
Allocate a new PID Filter, indicating whether it is a system PID or not.
adapter | The adapter to allocate the filter on, | |
pid | The PID to filter. | |
system | Whether this filter is a 'system' filter or not. |
int DVBDemuxReleaseAllFilters | ( | DVBAdapter_t * | adapter, | |
bool | system | |||
) |
Release all application or system PID filters.
adapter | The adapter to release the filters on. | |
system | Whether to release system or application filters. |
int DVBDemuxReleaseFilter | ( | DVBAdapter_t * | adapter, | |
uint16_t | pid | |||
) |
Release a specific PID filter.
adapter | The adapter to release the filter on. | |
pid | The PID of the filter to release. |
int DVBDemuxSetBufferSize | ( | DVBAdapter_t * | adapter, | |
unsigned long | size | |||
) |
Set the size of the circular buffer used by the demux.
adapter | The adapter to set size of the buffer on. | |
size | Size of the buffer to set. |
void DVBDispose | ( | DVBAdapter_t * | adapter | ) |
Close a DVPAdapter.
Close the frontend,demux and dvr devices and free the DVBAdapter_t structure.
adapter | The DVBAdapter_t structure to free. |
int DVBDVRRead | ( | DVBAdapter_t * | adapter, | |
char * | data, | |||
int | max, | |||
int | timeout | |||
) |
Read upto max bytes from the dvr device belonging to the specified adapter.
adapter | The adapter to read from. | |
data | Buffer to read into. | |
max | Maximum number of bytes to read. | |
timeout | Maximum amount of time to wait for data. |
void DVBFrontEndLNBInfoSet | ( | DVBAdapter_t * | adapter, | |
int | lowFreq, | |||
int | highFreq, | |||
int | switchFreq | |||
) |
Set the LNB LO frequencies.
adapter | The adapter to set the LNB information on. | |
lowFreq | Low LO frequency. | |
highFreq | high LO frequency. | |
switchFreq | switch LO frequency. |
int DVBFrontEndStatus | ( | DVBAdapter_t * | adapter, | |
fe_status_t * | status, | |||
unsigned int * | ber, | |||
unsigned int * | strength, | |||
unsigned int * | snr, | |||
unsigned int * | ucblocks | |||
) |
Retrieve the status of the frontend of the specified adapter.
adapter | The adapter to check. | |
status | Used to return the status flags (may be NULL). | |
ber | Used to return the Bit Error Rate (may be NULL). | |
strength | Used to return the signal strength (may be NULL). | |
snr | Used to return the signal to noise ratio (may be NULL). | |
ucblocks | Used to return the uncorrected block count (may be NULL). |
int DVBFrontEndTune | ( | DVBAdapter_t * | adapter, | |
struct dvb_frontend_parameters * | frontend, | |||
DVBDiSEqCSettings_t * | diseqc | |||
) |
Tune the frontend to the specified parameters.
adapter | The adapter to tune. | |
frontend | The parameters to use to tune. | |
diseqc | DiSEqC settings, may be NULL if not a satellite frontend. |
DVBAdapter_t* DVBInit | ( | int | adapter, | |
bool | hwRestricted | |||
) |
Open a DVB Adapter.
This will open the frontend, demux and dvr devices.
adapter | The adapter number of the devices to open. | |
hwRestricted | Whether the adapter can only stream a portion of the transport stream. |