NAME
Linux::DVB::DVBT::Config - DVBT configuration functions
SYNOPSIS
use Linux::DVB::DVBT::Config ;
DESCRIPTION
Module provides a set of configuration routines used by the DVBT module. It is unlikely that you will need to access these functions directly, but you can if you wish.
Functions
- find_tsid($frequency, $tuning_href)
-
Given a frequency, find the matching TSID.
$tuning_href is the HASH returned by Linux::DVB::DVBT::get_tuning_info().
- tsid_params($tsid, $tuning_href)
-
Given a tsid, return the frontend params (or undef). The frontend params HASH contain the information used to tune the frontend i.e. this is the transponder (TSID) information. It corresponds to the matching 'ts' entry in the tuning info HASH.
$tuning_href is the HASH returned by Linux::DVB::DVBT::get_tuning_info().
- chan_from_pid($tsid, $pid, $tuning_href)
-
Given a tsid and pid, find the matching channel information and returns the program HASH ref if found. This corresponds to the matching 'pr' entry in the tuning info HASH.
$tuning_href is the HASH returned by Linux::DVB::DVBT::get_tuning_info().
- pid_info($pid, $tuning_href)
-
Given a pid, find the matching channel & TSID information
Returns an array of HASH entries, each HASH containing the stream type (video, audio, subtitle, or teletext), along with a copy of the associated program information (i.e. the matching 'pr' entry from the tuning info HASH):
@pid_info = [ { 'type' => video, audio, subtitle, teletext pnr => 4171, tsid => 4107, tuned_freq => 57800000, ... }, ... ]
$tuning_href is the HASH returned by Linux::DVB::DVBT::get_tuning_info().
- find_channel($channel_name, $tuning_href)
-
Given a channel name, do a "fuzzy" search and return an array containing params:
($frontend_params_href, $demux_params_href)
$demux_params_href HASH ref are of the form:
{ pnr => 4171, tsid => 4107, tuned_freq => 57800000, ... },
(i.e. $tuning_href->{'pr'}{$channel_name})
$frontend_params_href HASH ref are of the form:
{ tsid => 4107, frequency => 57800000, ... },
(i.e. $tuning_href->{'ts'}{$tsid} where $tsid is TSID for the channel)
$tuning_href is the HASH returned by Linux::DVB::DVBT::get_tuning_info().
- audio_pids($demux_params_href, $language_spec, $pids_aref)
-
Process the demux parameters and a language specifier to return the list of audio streams required.
demux_params are of the form:
{ pnr => 4171, tsid => 4107, tuned_freq => 57800000, ... },
(i.e. $tuning_href->{'pr'}{$channel_name})
Language specifier string is in the format:
- a)
-
Empty string : just return the default audio stream pid
- b)
-
Comma/space seperated list of one or more language names : returns the audio stream pids for all that match (does not necessarily include default stream)
If the list in (b) contains a '+' character (normally at the start) then the default audio stream is automatically included in teh list, and the extra streams are added to it.
For example, if a channel has the following audio details: eng:100 eng:101 fra:102 deu:103 Then the following specifications result in the lists as shown:
"" => (100)
"eng deu" => (100, 103)
"+eng fra" => (100, 101, 102)
Note that the language names are not case sensitive
- out_pids($demux_params_href, $out_spec, $language_spec, $pids_aref)
-
Process the demux parameters and an output specifier to return the list of all stream pids required.
Output specifier string is in the format such that it just needs to contain the following characters:
a = audio v = video s = subtitle
Returns an array of HASHes of the form:
{'pid' => $pid, 'type' => $type, 'pmt' => $pmt}
- audio_list($demux_params_href)
-
Process the demux parameters and return a list of additional audio streams (or an empty list if none available).
For example:
{ audio => 601, audio_details => eng:601 eng:602, ... },
would return the list: ( 602 )
- read($search_path)
-
Read tuning information from config files. Look in search path and return first set of readable file information.
- write($search_path, $href)
-
Write tuning information into the first writeable area in the search path.
- merge($new_href, $old_href)
-
Merge tuning information - overwrites previous with new - into $old_href and return the HASH ref.
- merge_scan_freqs($new_href, $old_href, $verbose)
-
Merge tuning information - checks to ensure new program info has the best strength, and that new program has all of it's settings
'pr' => BBC ONE => { pnr => 4171, tsid => 4107, tuned_freq => 57800000, ... }, 'ts' => 4107 => { tsid => 4107, frequency => 57800000, ... }, 'freqs' => 57800000 => { strength => aaaa, snr => bbb, ber => ccc, ... },
- read_dir($search_path)
-
Find directory to read from - first readable directory in search path
- write_dir($search_path)
-
Find directory to write to - first writeable directory in search path
- read_dvb_ts($fname)
-
Read the transponder settings file of the form:
[4107] name = Oxford/Bexley frequency = 578000000 bandwidth = 8 modulation = 16 hierarchy = 0 code_rate_high = 34 code_rate_low = 34 guard_interval = 32 transmission = 2
- read_dvb_pr($fname)
-
Read dvb-pr - channel information - of the form:
[4107-4171] video = 600 audio = 601 audio_details = eng:601 eng:602 type = 1 net = BBC name = BBC ONE
- write_dvb_ts($fname, $href)
-
Write transponder config information
- write_dvb_pr($fname, $href)
-
Write program config file.
1 POD Error
The following errors were encountered while parsing the POD:
- Around line 50:
=over without closing =back