9610
|
1
|
|
2 #ifndef DVBIN_H
|
|
3 #define DVBIN_H
|
|
4
|
10560
|
5 #include "dvb_defaults.h"
|
|
6 #include "stream.h"
|
|
7
|
9610
|
8 #ifdef HAVE_DVB_HEAD
|
|
9 #include <linux/dvb/dmx.h>
|
|
10 #include <linux/dvb/frontend.h>
|
|
11 #else
|
|
12 #include <ost/dmx.h>
|
|
13 #include <ost/sec.h>
|
|
14 #include <ost/frontend.h>
|
|
15 #define fe_status_t FrontendStatus
|
|
16 #define fe_spectral_inversion_t SpectralInversion
|
|
17 #define fe_modulation_t Modulation
|
|
18 #define fe_code_rate_t CodeRate
|
|
19 #define fe_transmit_mode_t TransmitMode
|
|
20 #define fe_guard_interval_t GuardInterval
|
|
21 #define fe_bandwidth_t BandWidth
|
|
22 #define fe_sec_voltage_t SecVoltage
|
|
23 #define dmx_pes_filter_params dmxPesFilterParams
|
|
24 #define dmx_sct_filter_params dmxSctFilterParams
|
|
25 #define dmx_pes_type_t dmxPesType_t
|
|
26 #endif
|
|
27
|
|
28
|
|
29
|
|
30 #define DVB_CHANNEL_LOWER -1
|
|
31 #define DVB_CHANNEL_HIGHER 1
|
|
32
|
10395
|
33 #include "inttypes.h"
|
9610
|
34
|
|
35
|
|
36 typedef struct {
|
|
37 char *name;
|
|
38 int freq, srate, diseqc, tone;
|
|
39 char pol;
|
|
40 int vpid, apid1, apid2, tpid, dpid1, dpid2, progid, ca;
|
|
41 fe_spectral_inversion_t inv;
|
|
42 fe_modulation_t mod;
|
|
43 fe_transmit_mode_t trans;
|
|
44 fe_bandwidth_t bw;
|
|
45 fe_guard_interval_t gi;
|
|
46 fe_code_rate_t cr;
|
|
47 } dvb_channel_t;
|
|
48
|
|
49
|
|
50 typedef struct {
|
|
51 uint16_t NUM_CHANNELS;
|
|
52 uint16_t current;
|
12309
|
53 dvb_channel_t *channels;
|
9610
|
54 } dvb_channels_list;
|
|
55
|
12309
|
56 typedef struct {
|
|
57 int type;
|
|
58 dvb_channels_list *list;
|
|
59 char *name;
|
|
60 int devno;
|
|
61 } dvb_card_config_t;
|
|
62
|
|
63 typedef struct {
|
|
64 int count;
|
|
65 dvb_card_config_t *cards;
|
|
66 void *priv;
|
|
67 } dvb_config_t;
|
9610
|
68
|
|
69
|
|
70 typedef struct {
|
10560
|
71 int card;
|
9610
|
72 int fe_fd;
|
|
73 int sec_fd;
|
|
74 int demux_fd[3];
|
|
75 int dvr_fd;
|
|
76
|
12309
|
77 dvb_config_t *config;
|
9610
|
78 dvb_channels_list *list;
|
10560
|
79 int tuner_type;
|
|
80 int is_on;
|
|
81 stream_t *stream;
|
|
82 char new_tuning[256], prev_tuning[256];
|
|
83 int retry;
|
9610
|
84 } dvb_priv_t;
|
|
85
|
|
86
|
10560
|
87 #define TUNER_SAT 1
|
|
88 #define TUNER_TER 2
|
|
89 #define TUNER_CBL 3
|
9610
|
90
|
10560
|
91 extern int dvb_step_channel(dvb_priv_t *, int);
|
12309
|
92 extern int dvb_set_channel(dvb_priv_t *, int, int);
|
|
93 extern dvb_config_t *dvb_get_config();
|
9610
|
94
|
|
95 #endif
|