libdvbv5: fix terrestrial delivery constellation table
authorMauro Carvalho Chehab <m.chehab@samsung.com>
Wed, 27 Nov 2013 21:23:23 +0000 (19:23 -0200)
committerMauro Carvalho Chehab <m.chehab@samsung.com>
Wed, 27 Nov 2013 21:43:03 +0000 (19:43 -0200)
constellation == 2 means QAM64, according with ETSI EN 300 468 V1.11.1.

Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
lib/include/descriptors/desc_terrestrial_delivery.h
lib/libdvbv5/descriptors/desc_terrestrial_delivery.c
lib/libdvbv5/dvb-scan.c

index 390df5a..9404169 100644 (file)
@@ -17,6 +17,8 @@
  * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
  * Or, point your browser to http://www.gnu.org/licenses/old-licenses/gpl-2.0.html
  *
+ * Based on ETSI EN 300 468 V1.11.1 (2010-04)
+ *
  */
 
 #ifndef _TERRESTRIAL_DELIVERY_H
index 9449354..ce3fefe 100644 (file)
@@ -17,6 +17,8 @@
  * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
  * Or, point your browser to http://www.gnu.org/licenses/old-licenses/gpl-2.0.html
  *
+ * Based on ETSI EN 300 468 V1.11.1 (2010-04)
+ *
  */
 
 #include "descriptors/desc_terrestrial_delivery.h"
@@ -39,7 +41,7 @@ void dvb_desc_terrestrial_delivery_print(struct dvb_v5_fe_parms *parms, const st
        const struct dvb_desc_terrestrial_delivery *tdel = (const struct dvb_desc_terrestrial_delivery *) desc;
        dvb_log("|       terrestrial delivery");
        dvb_log("|           length                %d", tdel->length);
-       dvb_log("|           centre frequency      %d", tdel->centre_frequency);
+       dvb_log("|           centre frequency      %d", tdel->centre_frequency * 10);
        dvb_log("|           mpe_fec_indicator     %d", tdel->mpe_fec_indicator);
        dvb_log("|           time_slice_indicator  %d", tdel->time_slice_indicator);
        dvb_log("|           priority              %d", tdel->priority);
@@ -63,7 +65,7 @@ const unsigned dvbt_bw[] = {
 const unsigned dvbt_modulation[] = {
        [0] = QPSK,
        [1] = QAM_16,
-       [2] = QAM_32,
+       [2] = QAM_64,
        [3] = QAM_AUTO  /* Reserved */
 };
 const unsigned dvbt_hierarchy[] = {
index f3352d3..849f25a 100644 (file)
@@ -819,10 +819,21 @@ static void add_update_nit_dvbt2(struct dvb_table_nit *nit,
 
        for (i = 0; i < t2->frequency_loop_length; i++) {
                new = dvb_scan_add_entry(tr->parms, tr->first_entry, tr->entry,
-                                        t2->centre_frequency[i],
+                                        t2->centre_frequency[i] * 10,
                                         tr->shift, tr->pol);
                if (!new)
                        return;
+
+               store_entry_prop(new, DTV_DELIVERY_SYSTEM,
+                                SYS_DVBT2);
+               store_entry_prop(new, DTV_STREAM_ID,
+                               t2->plp_id);
+               store_entry_prop(new, DTV_BANDWIDTH_HZ,
+                               dvbt2_bw[t2->bandwidth]);
+               store_entry_prop(new, DTV_GUARD_INTERVAL,
+                               dvbt2_interval[t2->guard_interval]);
+               store_entry_prop(new, DTV_TRANSMISSION_MODE,
+                               dvbt2_transmission_mode[t2->transmission_mode]);
        }
 }
 
@@ -839,7 +850,7 @@ static void add_update_nit_dvbt(struct dvb_table_nit *nit,
                return;
 
        new = dvb_scan_add_entry(tr->parms, tr->first_entry, tr->entry,
-                               d->centre_frequency, tr->shift, tr->pol);
+                               d->centre_frequency * 10, tr->shift, tr->pol);
        if (!new)
                return;