summaryrefslogtreecommitdiff
path: root/device.c
diff options
context:
space:
mode:
authorLars Heer <l.heer@gmx.de>2013-09-18 05:52:31 +0200
committerLars Heer <l.heer@gmx.de>2013-09-18 05:52:31 +0200
commitd3dd23ff071b3f0650e28448b12c1d640f697a8c (patch)
treeb69c2bc94b7c20c088f744824e1874785c60a1d0 /device.c
parentccf6e0f9c6b0481ed13e0f4794e3fbead750f385 (diff)
downloadvdr-plugin-mcli-d3dd23ff071b3f0650e28448b12c1d640f697a8c.tar.gz
vdr-plugin-mcli-d3dd23ff071b3f0650e28448b12c1d640f697a8c.tar.bz2
patch system_s2.patch.txt applied
Diffstat (limited to 'device.c')
-rw-r--r--device.c24
1 files changed, 21 insertions, 3 deletions
diff --git a/device.c b/device.c
index 2acabe0..68324f2 100644
--- a/device.c
+++ b/device.c
@@ -23,6 +23,9 @@
#define st_Pos 0x07FF
#define st_Neg 0x0800
+#define DVB_SYSTEM_1 0
+#define DVB_SYSTEM_2 1
+
using namespace std;
static int handle_ts (unsigned char *buffer, size_t len, void *p)
@@ -132,9 +135,14 @@ void cMcliDevice::SetEnable (bool val)
bool s2=m_chan.Modulation() == QPSK_S2 || m_chan.Modulation() == PSK8;
#elif VDRVERSNUM < 10714
bool s2=m_chan.System() == SYS_DVBS2;
-#else
+#elif VDRVERSNUM < 10722
cDvbTransponderParameters dtp(m_chan.Parameters());
bool s2=dtp.System() == SYS_DVBS2;
+#elif VDRVERSNUM < 10723
+ #error "vdr version not supported"
+#else
+ cDvbTransponderParameters dtp(m_chan.Parameters());
+ bool s2=dtp.System() == DVB_SYSTEM_2;
#endif
bool ret = false;
int pos;
@@ -311,9 +319,14 @@ bool cMcliDevice::ProvidesTransponder (const cChannel * Channel) const
bool s2=Channel->Modulation() == QPSK_S2 || Channel->Modulation() == PSK8;
#elif VDRVERSNUM < 10714
bool s2=Channel->System() == SYS_DVBS2;
-#else
+#elif VDRVERSNUM < 10722
cDvbTransponderParameters dtp(Channel->Parameters());
bool s2=dtp.System() == SYS_DVBS2;
+#elif VDRVERSNUM < 10723
+ #error "vdr version not supported"
+#else
+ cDvbTransponderParameters dtp(Channel->Parameters());
+ bool s2=dtp.System() == DVB_SYSTEM_2;
#endif
bool ret=ProvidesSource (Channel->Source ());
if(ret) {
@@ -526,9 +539,14 @@ bool cMcliDevice::SetChannelDevice (const cChannel * Channel, bool LiveView)
s2=Channel->Modulation() == QPSK_S2 || Channel->Modulation() == PSK8;
#elif VDRVERSNUM < 10714
s2=Channel->System() == SYS_DVBS2;
-#else
+#elif VDRVERSNUM < 10722
cDvbTransponderParameters dtp(Channel->Parameters());
s2=dtp.System() == SYS_DVBS2;
+#elif VDRVERSNUM < 10723
+ #error "vdr version not supported"
+#else
+ cDvbTransponderParameters dtp(Channel->Parameters());
+ s2=dtp.System() == DVB_SYSTEM_2;
#endif
if(s2) {
type = FE_DVBS2;