1 Index: libs/libmythtv/videosource.cpp
2 ===================================================================
3 --- libs/libmythtv/videosource.cpp (revision 8614)
4 +++ libs/libmythtv/videosource.cpp (working copy)
6 addSelection("DiSEqC v1.2 Positioner","6");
7 addSelection("DiSEqC v1.3 Positioner (Goto X)","7");
8 addSelection("DiSEqC v1.1 or 2.1 (10-way method2)","8");
9 + addSelection("SW21 Switch","98");
10 + addSelection("SW64 Switch","99");
11 setHelpText(QObject::tr("Select the input type for DVB-S cards. "
12 "Leave as Single LNB/Input for DVB-C or DVB-T. "
13 "The inputs are mapped from Input Connections option "
15 QString stxt = "DiSEqC Switch Input %1";
16 QString mtxt = "DiSEqC v1.2 Motor Position %1";
17 QString itxt = "DiSEqC v1.3 Input %1";
18 + QString l21txt = "SW21 Input %1";
19 + QString l64txt = "SW64 Input %1";
22 switch (dvb_diseqc_type)
23 @@ -2433,6 +2437,16 @@
24 list.append(DVBDiSEqCInputList(
25 stxt.arg(i+1,2), QString::number(i), ""));
28 + for (i = 0; i < 2; ++i)
29 + list.append(DVBDiSEqCInputList(
30 + l21txt.arg(i+1,2), QString::number(i), ""));
33 + for (i = 0; i < 3; ++i)
34 + list.append(DVBDiSEqCInputList(
35 + l64txt.arg(i+1,2), QString::number(i), ""));
38 list.append(DVBDiSEqCInputList(
39 QString("DVBInput"), QString(""), QString("")));
40 Index: libs/libmythtv/dvbdiseqc.h
41 ===================================================================
42 --- libs/libmythtv/dvbdiseqc.h (revision 8614)
43 +++ libs/libmythtv/dvbdiseqc.h (working copy)
46 bool ToneVoltageLnb(DVBTuning& tuning, bool reset, bool& havetuned);
47 bool ToneSwitch(DVBTuning& tuning, bool reset, bool& havetuned);
48 + bool LegacyDishSwitch(DVBTuning& tuning, bool reset, bool& havetuned);
49 bool Diseqc1xSwitch(DVBTuning& tuning, bool reset, bool& havetuned,
51 bool PositionerGoto(DVBTuning& tuning, bool reset, bool& havetuned);
52 Index: libs/libmythtv/dvbdiseqc.cpp
53 ===================================================================
54 --- libs/libmythtv/dvbdiseqc.cpp (revision 8614)
55 +++ libs/libmythtv/dvbdiseqc.cpp (working copy)
57 if (!Diseqc1xSwitch(tuning, reset, havetuned, 10))
62 + if (!LegacyDishSwitch(tuning, reset, havetuned))
67 VERBOSE(VB_IMPORTANT, LOC_ERR + "Unsupported DiSEqC type("
72 +bool DVBDiSEqC::LegacyDishSwitch(DVBTuning& tuning, bool reset,
77 + //Do legacy switches need to be reset?
79 + GENERAL(QString("Legacy Dish Switch - Port %1").arg(tuning.diseqc_port));
80 + if ((prev_tuning.diseqc_port != tuning.diseqc_port ||
81 + prev_tuning.tone != tuning.tone ||
82 + prev_tuning.voltage != tuning.voltage) || reset)
87 + switch(tuning.diseqc_type) {
88 + //is there a pattern here?
90 + if(! tuning.diseqc_port)
96 + if(tuning.diseqc_port == 0)
97 + if(tuning.voltage == SEC_VOLTAGE_13)
101 + else if(tuning.diseqc_port == 1)
102 + if(tuning.voltage == SEC_VOLTAGE_13)
107 + if(tuning.voltage == SEC_VOLTAGE_13)
113 + if(tuning.voltage == SEC_VOLTAGE_18)
116 +#ifdef FE_DISHNETWORK_SEND_LEGACY_CMD
117 + if (ioctl(fd_frontend, FE_DISHNETWORK_SEND_LEGACY_CMD, cmd) <0)
119 + ERRNO("Setup: Sending init command failed.");
123 + VERBOSE(VB_IMPORTANT, "Kernel does not support Legacy Dish Switch!");
125 + usleep(DISEQC_SHORT_WAIT);
127 + prev_tuning.diseqc_port = tuning.diseqc_port;
128 + prev_tuning.tone = tuning.tone;
129 + prev_tuning.voltage = tuning.voltage;
135 /*****************************************************************************
136 Backward Compatible Methods
137 ****************************************************************************/