MythTV  master
dtvmultiplex.cpp
Go to the documentation of this file.
1 // MythTV headers
2 #include "dtvmultiplex.h"
3 
4 #include "mpeg/dvbdescriptors.h"
5 #include "mythdb.h"
6 #include "mythlogging.h"
7 #include "cardutil.h"
8 #include <utility>
9 
10 #define LOC QString("DTVMux: ")
11 
13 {
14  return ((m_frequency == m.m_frequency) &&
15  (m_modulation == m.m_modulation) &&
16  (m_inversion == m.m_inversion) &&
17  (m_bandwidth == m.m_bandwidth) &&
18  (m_hpCodeRate == m.m_hpCodeRate) &&
19  (m_lpCodeRate == m.m_lpCodeRate) &&
20  (m_transMode == m.m_transMode) &&
22  (m_fec == m.m_fec) &&
23  (m_modSys == m.m_modSys) &&
24  (m_rolloff == m.m_rolloff) &&
25  (m_polarity == m.m_polarity) &&
26  (m_hierarchy == m.m_hierarchy) &&
28  );
29 }
30 
32 // Gets
33 
34 QString DTVMultiplex::toString() const
35 {
36  QString ret = QString("%1 %2 %3 ")
38 
39  ret += QString("%1 %2 %3 %4 %5 %6 %7")
43  .arg(m_polarity.toString());
44  ret += QString(" fec: %1 msys: %2 rolloff: %3")
45  .arg(m_fec.toString()).arg(m_modSys.toString()).arg(m_rolloff.toString());
46 
47  return ret;
48 }
49 
51  uint freq_range, bool fuzzy) const
52 {
53  if ((m_frequency + freq_range < other.m_frequency ) ||
54  (m_frequency > other.m_frequency + freq_range))
55  {
56  return false;
57  }
58 
60  {
61  if (fuzzy)
62  return
64  (m_symbolrate == other.m_symbolrate) &&
65  m_fec.IsCompatible(other.m_fec) &&
67  return
68  (m_inversion == other.m_inversion) &&
69  (m_symbolrate == other.m_symbolrate) &&
70  (m_fec == other.m_fec) &&
71  (m_modulation == other.m_modulation);
72  }
73 
76  {
77  if (fuzzy)
78  return
88  return
89  (m_inversion == other.m_inversion) &&
90  (m_bandwidth == other.m_bandwidth) &&
91  (m_hpCodeRate == other.m_hpCodeRate) &&
92  (m_lpCodeRate == other.m_lpCodeRate) &&
93  (m_modulation == other.m_modulation) &&
94  (m_guardInterval == other.m_guardInterval) &&
95  (m_transMode == other.m_transMode) &&
96  (m_hierarchy == other.m_hierarchy) &&
97  (m_modSys == other.m_modSys);
98  }
99 
101  {
102  if (fuzzy)
103  return m_modulation.IsCompatible(other.m_modulation);
104  return (m_modulation == other.m_modulation);
105  }
106 
109  {
110  bool ret =
111  (m_symbolrate == other.m_symbolrate) &&
112  (m_polarity == other.m_polarity) &&
113  (m_modSys == other.m_modSys);
114 
115  if (fuzzy)
116  return ret &&
118  m_fec.IsCompatible(other.m_fec) &&
120  return ret &&
121  (m_inversion == other.m_inversion) &&
122  (m_fec == other.m_fec) &&
123  (m_rolloff == other.m_rolloff);
124  }
125 
127  {
128  return (m_iptvTuning == other.m_iptvTuning);
129  }
130 
131  return false;
132 }
133 
135 // Parsers
136 
137 bool DTVMultiplex::ParseATSC(const QString &_frequency,
138  const QString &_modulation)
139 {
140  bool ok = true;
141  m_frequency = _frequency.toULongLong(&ok);
142  if (!ok)
143  {
144  LOG(VB_GENERAL, LOG_ERR, LOC +
145  QString("Failed to parse ATSC frequency %1").arg(_frequency));
146  return false;
147  }
148 
149  ok = m_modulation.Parse(_modulation);
150  if (!ok)
151  {
152  LOG(VB_GENERAL, LOG_ERR, LOC +
153  QString("Failed to parse ATSC modulation %1").arg(_modulation));
154  }
155  return ok;
156 }
157 
159  const QString &_frequency, const QString &_inversion,
160  const QString &_bandwidth, const QString &_coderate_hp,
161  const QString &_coderate_lp, const QString &_modulation,
162  const QString &_trans_mode, const QString &_guard_interval,
163  const QString &_hierarchy)
164 {
165  bool ok = m_inversion.Parse(_inversion);
166  if (!ok)
167  {
168  LOG(VB_GENERAL, LOG_WARNING, LOC +
169  QString("Invalid inversion parameter '%1', falling back to 'auto'.")
170  .arg(_inversion));
171  ok = true;
172  }
173 
174  ok &= m_modSys.Parse("DVB-T");
175  ok &= m_bandwidth.Parse(_bandwidth);
176  ok &= m_hpCodeRate.Parse(_coderate_hp);
177  ok &= m_lpCodeRate.Parse(_coderate_lp);
178  ok &= m_modulation.Parse(_modulation);
179  ok &= m_transMode.Parse(_trans_mode);
180  ok &= m_hierarchy.Parse(_hierarchy);
181  ok &= m_guardInterval.Parse(_guard_interval);
182  if (ok)
183  m_frequency = _frequency.toInt(&ok);
184 
185  return ok;
186 }
187 
189  const QString &_frequency, const QString &_inversion,
190  const QString &_symbol_rate, const QString &_fec_inner,
191  const QString &_modulation, const QString &_polarity)
192 {
193  bool ok = m_inversion.Parse(_inversion);
194  if (!ok)
195  {
196  LOG(VB_GENERAL, LOG_WARNING, LOC +
197  QString("Invalid inversion parameter '%1', falling back to 'auto'.")
198  .arg(_inversion));
199 
200  ok = true;
201  }
202 
203  m_symbolrate = _symbol_rate.toInt();
204  if (!m_symbolrate)
205  {
206  LOG(VB_GENERAL, LOG_ERR, LOC + "Invalid symbol rate " +
207  QString("parameter '%1', aborting.").arg(_symbol_rate));
208 
209  return false;
210  }
211 
212  ok &= m_fec.Parse(_fec_inner);
213  ok &= m_modulation.Parse(_modulation);
214 
215  if (!_polarity.isEmpty())
216  m_polarity.Parse(_polarity.toLower());
217 
218  if (ok)
219  m_frequency = _frequency.toInt(&ok);
220 
221  return ok;
222 }
223 
225  const QString &_frequency, const QString &_inversion,
226  const QString &_symbol_rate, const QString &_fec_inner,
227  const QString &_modulation, const QString &_polarity)
228 {
229  bool ok = ParseDVB_S_and_C(_frequency, _inversion, _symbol_rate,
230  _fec_inner, _modulation, _polarity);
232  return ok;
233 }
234 
236  const QString &_frequency, const QString &_inversion,
237  const QString &_symbol_rate, const QString &_fec_inner,
238  const QString &_modulation, const QString &_polarity,
239  const QString &_mod_sys)
240 {
241  bool ok = ParseDVB_S_and_C(_frequency, _inversion, _symbol_rate,
242  _fec_inner, _modulation, _polarity);
243 
244  m_modSys.Parse(_mod_sys);
246  {
248  }
249 
250  LOG(VB_GENERAL, LOG_DEBUG, LOC +
251  QString("%1 ").arg(__FUNCTION__) +
252  QString("_mod_sys:%1 ok:%2 ").arg(_mod_sys).arg(ok) +
253  QString("m_mod_sys:%1 %2 ").arg(m_modSys).arg(m_modSys.toString()));
254 
258  {
259  LOG(VB_GENERAL, LOG_ERR, LOC + "Unsupported DVB-C modulation system " +
260  QString("parameter '%1', aborting.").arg(_mod_sys));
261  return false;
262  }
263 
264  return ok;
265 }
266 
268  const QString &_frequency, const QString &_inversion,
269  const QString &_symbol_rate, const QString &_fec_inner,
270  const QString &_modulation, const QString &_polarity,
271  const QString &_mod_sys, const QString &_rolloff)
272 {
273  bool ok = ParseDVB_S_and_C(_frequency, _inversion, _symbol_rate,
274  _fec_inner, _modulation, _polarity);
275 
276  if (!m_modSys.Parse(_mod_sys))
277  {
278  LOG(VB_GENERAL, LOG_ERR, LOC + "Invalid DVB-S2 modulation system " +
279  QString("parameter '%1', aborting.").arg(_mod_sys));
280  return false;
281  }
282 
283  // For #10153, guess at modulation system based on modulation
285  {
289  }
290 
293  {
294  LOG(VB_GENERAL, LOG_ERR, LOC + "Unsupported DVB-S2 modulation system " +
295  QString("parameter '%1', aborting.").arg(_mod_sys));
296  return false;
297  }
298 
299  if (!_rolloff.isEmpty())
300  ok &= m_rolloff.Parse(_rolloff);
301 
302  return ok;
303 }
304 
306  const QString &_frequency, const QString &_inversion,
307  const QString &_bandwidth, const QString &_coderate_hp,
308  const QString &_coderate_lp, const QString &_modulation,
309  const QString &_trans_mode, const QString &_guard_interval,
310  const QString &_hierarchy, const QString &_mod_sys)
311 {
312  bool ok = ParseDVB_T(_frequency, _inversion, _bandwidth,
313  _coderate_hp, _coderate_lp, _modulation,
314  _trans_mode, _guard_interval, _hierarchy);
315 
316  QString l_mod_sys = _mod_sys;
317 
318  // Accept "0" for "DVB-T" and "1" for "DVB-T2"
319  if (_mod_sys == "1")
320  {
321  LOG(VB_GENERAL, LOG_WARNING, LOC + "Invalid DVB-T2 modulation system " +
322  QString("parameter '%1', using DVB-T2.").arg(_mod_sys));
324  l_mod_sys = m_modSys.toString();
325  }
326  else if (_mod_sys == "0")
327  {
328  LOG(VB_GENERAL, LOG_WARNING, LOC + "Invalid DVB-T modulation system " +
329  QString("parameter '%1', using DVB-T.").arg(_mod_sys));
331  l_mod_sys = m_modSys.toString();
332  }
333 
334  if (!m_modSys.Parse(l_mod_sys))
335  {
336  LOG(VB_GENERAL, LOG_WARNING, LOC + "Invalid DVB-T/T2 modulation system " +
337  QString("parameter '%1', aborting.").arg(l_mod_sys));
338  return false;
339  }
340 
342  {
344  }
345 
348  {
349  LOG(VB_GENERAL, LOG_ERR, LOC + "Unsupported DVB-T2 modulation system " +
350  QString("parameter '%1', aborting.").arg(l_mod_sys));
351  return false;
352  }
353 
354  return ok;
355 }
356 
359  const QString& _frequency, const QString& _inversion, const QString& _symbolrate,
360  const QString& _fec, const QString& _polarity,
361  const QString& _hp_code_rate, const QString& _lp_code_rate, const QString& _ofdm_modulation,
362  const QString& _trans_mode, const QString& _guard_interval, const QString& _hierarchy,
363  const QString& _modulation, const QString& _bandwidth,
364  const QString& _mod_sys, const QString& _rolloff)
365 {
367  {
368  return ParseDVB_T(
369  _frequency, _inversion, _bandwidth,
370  _hp_code_rate, _lp_code_rate, _ofdm_modulation,
371  _trans_mode, _guard_interval, _hierarchy);
372  }
373 
375  {
376  return ParseDVB_C(
377  _frequency, _inversion, _symbolrate,
378  _fec, _modulation, _polarity,
379  _mod_sys);
380  }
381 
383  {
384  return ParseDVB_S(
385  _frequency, _inversion, _symbolrate,
386  _fec, _modulation, _polarity);
387  }
388 
390  {
391  return ParseDVB_S2(
392  _frequency, _inversion, _symbolrate,
393  _fec, _modulation, _polarity,
394  _mod_sys, _rolloff);
395  }
396 
398  {
399  return ParseDVB_T2(
400  _frequency, _inversion, _bandwidth,
401  _hp_code_rate, _lp_code_rate, _ofdm_modulation,
402  _trans_mode, _guard_interval, _hierarchy,
403  _mod_sys);
404  }
405 
407  {
408  return ParseATSC(_frequency, _modulation);
409  }
410 
411  LOG(VB_GENERAL, LOG_ERR, LOC +
412  QString("ParseTuningParams -- Unknown tuner type = 0x%1")
413  .arg(type,0,16,QChar('0')));
414 
415  return false;
416 }
417 
419 {
420  Clear();
421 
422  MSqlQuery query(MSqlQuery::InitCon());
423  query.prepare(
424  "SELECT frequency, inversion, symbolrate, "
425  " fec, polarity, "
426  " hp_code_rate, lp_code_rate, constellation, "
427  " transmission_mode, guard_interval, hierarchy, "
428  " modulation, bandwidth, sistandard, "
429  " mod_sys, rolloff "
430  "FROM dtv_multiplex "
431  "WHERE dtv_multiplex.mplexid = :MPLEXID");
432  query.bindValue(":MPLEXID", mplexid);
433 
434  if (!query.exec())
435  {
436  MythDB::DBError("DVBTuning::FillFromDB", query);
437  return false;
438  }
439 
440  if (!query.next())
441  {
442  LOG(VB_GENERAL, LOG_ERR, LOC +
443  QString("Could not find tuning parameters for mplex %1")
444  .arg(mplexid));
445 
446  return false;
447  }
448 
449  m_mplex = mplexid;
450  m_sistandard = query.value(13).toString();
451 
452  // Parse the query into our DVBTuning class
453  return ParseTuningParams(
454  type,
455  query.value(0).toString(), query.value(1).toString(),
456  query.value(2).toString(), query.value(3).toString(),
457  query.value(4).toString(), query.value(5).toString(),
458  query.value(6).toString(), query.value(7).toString(),
459  query.value(8).toString(), query.value(9).toString(),
460  query.value(10).toString(), query.value(11).toString(),
461  query.value(12).toString(), query.value(14).toString(),
462  query.value(15).toString());
463 }
464 
465 
467  const MPEGDescriptor &desc)
468 {
469  uint tag = desc.DescriptorTag();
470  m_sistandard = "dvb";
471 
472  switch (tag)
473  {
475  {
477 
479  {
480  return ParseDVB_T(
481  QString::number(cd.FrequencyHz()), "a",
485  cd.HierarchyString());
486  }
487 
489  {
490  return ParseDVB_T2(
491  QString::number(cd.FrequencyHz()), "a",
495  cd.HierarchyString(), "DVB-T");
496  }
497 
498  break;
499  }
501  {
502  const SatelliteDeliverySystemDescriptor cd(desc);
503 
505  {
506  if (cd.ModulationSystem())
507  {
508  LOG(VB_CHANSCAN, LOG_NOTICE, LOC +
509  "Ignoring DVB-S2 transponder with DVB-S card");
510  return false;
511  }
512 
513  return ParseDVB_S_and_C(
514  QString::number(cd.FrequencykHz()), "a",
515  QString::number(cd.SymbolRateHz()), cd.FECInnerString(),
516  cd.ModulationString(),
517  cd.PolarizationString());
518  }
519 
521  {
522  return ParseDVB_S2(
523  QString::number(cd.FrequencykHz()), "a",
524  QString::number(cd.SymbolRateHz()), cd.FECInnerString(),
525  cd.ModulationString(),
526  cd.PolarizationString(),
528  }
529 
530  break;
531  }
533  {
535  break;
536 
537  const CableDeliverySystemDescriptor cd(desc);
538 
539  return ParseDVB_C(
540  QString::number(cd.FrequencyHz()), "a",
541  QString::number(cd.SymbolRateHz()), cd.FECInnerString(),
542  cd.ModulationString(), QString(),
543  "DVB-C/A");
544  }
545  default:
546  LOG(VB_CHANSCAN, LOG_ERR, LOC +
547  "unknown delivery system descriptor");
548  return false;
549  }
550 
551  LOG(VB_CHANSCAN, LOG_ERR, LOC +
552  QString("Tuner type %1 does not match delivery system")
553  .arg(type.toString()));
554  return false;
555 }
556 
557 
560 
562 {
563  if (!DTVMultiplex::FillFromDB(type, mplexid))
564  return false;
565 
566  MSqlQuery query(MSqlQuery::InitCon());
567  query.prepare(
568  "SELECT c.mplexid, c.sourceid, c.chanid, "
569  " c.callsign, c.name, c.channum, "
570  " c.serviceid, c.atsc_major_chan, c.atsc_minor_chan, "
571  " c.useonairguide, c.visible, c.freqid, "
572  " c.icon, c.tvformat, c.xmltvid, "
573  " d.transportid, d.networkid, c.default_authority,"
574  " c.service_type "
575  "FROM channel AS c, dtv_multiplex AS d "
576  "WHERE c.deleted IS NULL AND "
577  " c.mplexid = :MPLEXID AND"
578  " c.mplexid = d.mplexid");
579  query.bindValue(":MPLEXID", mplexid);
580 
581  if (!query.exec())
582  {
583  MythDB::DBError("ScanDTVTransport::FillFromDB", query);
584  return false;
585  }
586 
587  while (query.next())
588  {
589  ChannelInsertInfo chan(
590  query.value(0).toUInt(), query.value(1).toUInt(),
591  query.value(2).toUInt(), query.value(3).toString(),
592  query.value(4).toString(), query.value(5).toString(),
593  query.value(6).toUInt(),
594  query.value(7).toUInt(), query.value(8).toUInt(),
595  query.value(9).toBool(), !query.value(10).toBool(),
596  false,
597  query.value(11).toString(), query.value(12).toString(),
598  query.value(13).toString(), query.value(14).toString(),
599  0, 0, 0,
600  query.value(15).toUInt(), query.value(16).toUInt(),
601  0,
602  QString(),
603  false, false, false, false,
604  false, false, false, false,
605  false, false, false, 0,
606  query.value(17).toString(), /* default_authority */
607  query.value(18).toUInt()); /* service_type */
608 
609  m_channels.push_back(chan);
610  }
611 
612  return true;
613 }
614 
616 {
617  uint transportid = 0;
618 
619  MSqlQuery query(MSqlQuery::InitCon());
620  query.prepare(
621  "INSERT INTO channelscan_dtv_multiplex "
622  " ( scanid, "
623  " mplexid, frequency, inversion, "
624  " symbolrate, fec, polarity, "
625  " hp_code_rate, lp_code_rate, modulation, "
626  " transmission_mode, guard_interval, hierarchy, "
627  " mod_sys, rolloff, "
628  " bandwidth, sistandard, tuner_type "
629  " ) "
630  "VALUES "
631  " ( :SCANID, "
632  " :MPLEXID, :FREQUENCY, :INVERSION, "
633  " :SYMBOLRATE, :FEC, :POLARITY, "
634  " :HP_CODE_RATE, :LP_CODE_RATE, :MODULATION, "
635  " :TRANSMISSION_MODE, :GUARD_INTERVAL, :HIERARCHY, "
636  " :MOD_SYS, :ROLLOFF, "
637  " :BANDWIDTH, :SISTANDARD, :TUNER_TYPE "
638  " );");
639 
640  query.bindValue(":SCANID", scanid);
641  query.bindValue(":MPLEXID", m_mplex);
642  query.bindValue(":FREQUENCY", QString::number(m_frequency));
643  query.bindValue(":INVERSION", m_inversion.toString());
644  query.bindValue(":SYMBOLRATE", QString::number(m_symbolrate));
645  query.bindValue(":FEC", m_fec.toString());
646  query.bindValue(":POLARITY", m_polarity.toString());
647  query.bindValue(":HP_CODE_RATE", m_hpCodeRate.toString());
648  query.bindValue(":LP_CODE_RATE", m_lpCodeRate.toString());
649  query.bindValue(":MODULATION", m_modulation.toString());
650  query.bindValue(":TRANSMISSION_MODE", m_transMode.toString());
651  query.bindValue(":GUARD_INTERVAL", m_guardInterval.toString());
652  query.bindValue(":HIERARCHY", m_hierarchy.toString());
653  query.bindValue(":MOD_SYS", m_modSys.toString());
654  query.bindValue(":ROLLOFF", m_rolloff.toString());
655  query.bindValue(":BANDWIDTH", m_bandwidth.toString());
656  query.bindValue(":SISTANDARD", m_sistandard);
657  query.bindValue(":TUNER_TYPE", (uint)m_tuner_type);
658 
659  if (!query.exec())
660  {
661  MythDB::DBError("ScanDTVTransport::SaveScan 1", query);
662  return transportid;
663  }
664 
665  query.prepare("SELECT MAX(transportid) FROM channelscan_dtv_multiplex");
666  if (!query.exec())
667  MythDB::DBError("ScanDTVTransport::SaveScan 2", query);
668  else if (query.next())
669  transportid = query.value(0).toUInt();
670 
671  if (!transportid)
672  return transportid;
673 
674  for (size_t i = 0; i < m_channels.size(); i++)
675  m_channels[i].SaveScan(scanid, transportid);
676 
677  return transportid;
678 }
679 
682  const QString& _frequency, const QString& _inversion, const QString& _symbolrate,
683  const QString& _fec, const QString& _polarity,
684  const QString& _hp_code_rate, const QString& _lp_code_rate, const QString& _ofdm_modulation,
685  const QString& _trans_mode, const QString& _guard_interval, const QString& _hierarchy,
686  const QString& _modulation, const QString& _bandwidth, const QString& _mod_sys,
687  const QString& _rolloff)
688 {
689  m_tuner_type = type;
690 
692  type,
693  _frequency, _inversion, _symbolrate,
694  _fec, _polarity,
695  _hp_code_rate, _lp_code_rate, _ofdm_modulation,
696  _trans_mode, _guard_interval, _hierarchy,
697  _modulation, _bandwidth, _mod_sys,
698  _rolloff);
699 }
bool next(void)
Wrap QSqlQuery::next() so we can display the query results.
Definition: mythdbcon.cpp:781
uint64_t m_symbolrate
Definition: dtvmultiplex.h:95
bool IsCompatible(const DTVGuardInterval &other) const
bool Parse(const QString &_value)
DTVGuardInterval m_guardInterval
Definition: dtvmultiplex.h:102
void bindValue(const QString &placeholder, const QVariant &val)
Add a single binding.
Definition: mythdbcon.cpp:862
bool ParseDVB_C(const QString &frequency, const QString &inversion, const QString &symbol_rate, const QString &fec_inner, const QString &modulation, const QString &polarity, const QString &mod_sys)
bool Parse(const QString &_value)
bool operator==(const DTVMultiplex &m) const
static const int kTunerTypeDVBT
DTVBandwidth m_bandwidth
Definition: dtvmultiplex.h:97
static const int kTunerTypeATSC
DTVHierarchy m_hierarchy
Definition: dtvmultiplex.h:103
DTVPolarity m_polarity
Definition: dtvmultiplex.h:104
bool Parse(const QString &_value)
QSqlQuery wrapper that fetches a DB connection from the connection pool.
Definition: mythdbcon.h:125
bool IsCompatible(const DTVHierarchy &other) const
bool IsCompatible(const DTVTransmitMode &other) const
IPTVTuningData m_iptvTuning
Definition: dtvmultiplex.h:112
QString FECInnerString(void) const
uint DescriptorTag(void) const
bool Parse(const QString &_value)
QString toString() const
DTVInversion m_inversion
Definition: dtvmultiplex.h:96
static const int kTunerTypeDVBS1
QString toString() const
bool Parse(const QString &_value)
bool ParseDVB_T(const QString &frequency, const QString &inversion, const QString &bandwidth, const QString &coderate_hp, const QString &coderate_lp, const QString &modulation, const QString &trans_mode, const QString &guard_interval, const QString &hierarchy)
DTVTunerType m_tuner_type
Definition: dtvmultiplex.h:137
bool ParseATSC(const QString &frequency, const QString &modulation)
QString toString() const
ChannelInsertInfoList m_channels
Definition: dtvmultiplex.h:139
DTVCodeRate m_fec
Inner Forward Error Correction rate.
Definition: dtvmultiplex.h:105
bool ParseDVB_S2(const QString &frequency, const QString &inversion, const QString &symbol_rate, const QString &fec_inner, const QString &modulation, const QString &polarity, const QString &mod_sys, const QString &rolloff)
QVariant value(int i) const
Definition: mythdbcon.h:198
QString toString() const
bool FillFromDeliverySystemDesc(DTVTunerType type, const MPEGDescriptor &desc)
bool Parse(const QString &_value)
static const int kTunerTypeDVBS2
DTVModulation m_modulation
Definition: dtvmultiplex.h:100
QString toString() const
static const int kTunerTypeDVBT2
bool IsEqual(DTVTunerType type, const DTVMultiplex &other, uint freq_range=0, bool fuzzy=false) const
static const int kTunerTypeDVBC
bool Parse(const QString &_value)
uint SaveScan(uint scanid) const
bool ParseDVB_T2(const QString &frequency, const QString &inversion, const QString &bandwidth, const QString &coderate_hp, const QString &coderate_lp, const QString &modulation, const QString &trans_mode, const QString &guard_interval, const QString &hierarchy, const QString &mod_sys)
QString toString() const
bool IsCompatible(const DTVCodeRate &other) const
QString ModulationString(void) const
QString toString() const
QString ConstellationString(void) const
bool ParseDVB_S(const QString &frequency, const QString &inversion, const QString &symbol_rate, const QString &fec_inner, const QString &modulation, const QString &polarity)
unsigned int uint
Definition: compat.h:140
bool IsCompatible(const DTVRollOff &other) const
static MSqlQueryInfo InitCon(ConnectionReuse=kNormalConnection)
Only use this in combination with MSqlQuery constructor.
Definition: mythdbcon.cpp:534
bool ParseTuningParams(DTVTunerType type, const QString &frequency, const QString &inversion, const QString &symbolrate, const QString &fec, const QString &polarity, const QString &hp_code_rate, const QString &lp_code_rate, const QString &ofdm_modulation, const QString &trans_mode, const QString &guard_interval, const QString &hierarchy, const QString &modulation, const QString &bandwidth, const QString &mod_sys, const QString &rolloff)
bool ParseDVB_S_and_C(const QString &frequency, const QString &inversion, const QString &symbol_rate, const QString &fec_inner, const QString &modulation, const QString &polarity)
DTVTransmitMode m_transMode
Definition: dtvmultiplex.h:101
QString m_sistandard
Definition: dtvmultiplex.h:111
QString toString() const
bool prepare(const QString &query)
QSqlQuery::prepare() is not thread safe in Qt <= 3.3.2.
Definition: mythdbcon.cpp:806
static const int kTunerTypeIPTV
bool IsCompatible(const DTVInversion &other) const
DTVRollOff m_rolloff
Definition: dtvmultiplex.h:107
#define LOG(_MASK_, _LEVEL_, _STRING_)
Definition: mythlogging.h:41
QString toString() const
QString toString() const
QString TransmissionModeString(void) const
QString FECInnerString(void) const
bool FillFromDB(DTVTunerType type, uint mplexid) override
unsigned long long FrequencyHz(void) const
void Clear(void)
Definition: dtvmultiplex.h:34
bool IsCompatible(const DTVModulation &other) const
QString ModulationSystemString(void) const
bool Parse(const QString &_value)
DTVCodeRate m_hpCodeRate
High Priority FEC rate.
Definition: dtvmultiplex.h:98
bool exec(void)
Wrap QSqlQuery::exec() so we can display SQL.
Definition: mythdbcon.cpp:602
bool IsCompatible(const DTVBandwidth &other) const
static void DBError(const QString &where, const MSqlQuery &query)
Definition: mythdb.cpp:179
unsigned long long FrequencykHz(void) const
bool IsCompatible(const DTVModulationSystem &other) const
QString ModulationString(void) const
#define LOC
bool Parse(const QString &_value)
bool ParseTuningParams(DTVTunerType type, const QString &frequency, const QString &inversion, const QString &symbolrate, const QString &fec, const QString &polarity, const QString &hp_code_rate, const QString &lp_code_rate, const QString &ofdm_modulation, const QString &trans_mode, const QString &guard_interval, const QString &hierarchy, const QString &modulation, const QString &bandwidth, const QString &mod_sys, const QString &rolloff)
DTVCodeRate m_lpCodeRate
Low Priority FEC rate.
Definition: dtvmultiplex.h:99
virtual bool FillFromDB(DTVTunerType type, uint mplexid)
DTVModulationSystem m_modSys
Modulation system.
Definition: dtvmultiplex.h:106
uint64_t m_frequency
Definition: dtvmultiplex.h:94
bool Parse(const QString &_value)