loading and saving the cable transponders to lamedb works now
authorStefan Pluecken <stefan.pluecken@multimedia-labs.de>
Fri, 24 Feb 2006 03:47:26 +0000 (03:47 +0000)
committerStefan Pluecken <stefan.pluecken@multimedia-labs.de>
Fri, 24 Feb 2006 03:47:26 +0000 (03:47 +0000)
lib/dvb/db.cpp
lib/python/Screens/ScanSetup.py

index 5791614..2d609bd 100644 (file)
@@ -318,9 +318,15 @@ void eDVBDB::reloadServicelist()
                                feparm->setDVBT(ter);
                        } else if (line[1]=='c')
                        {
                                feparm->setDVBT(ter);
                        } else if (line[1]=='c')
                        {
+                               eDVBFrontendParametersCable cab;
                                int frequency, symbol_rate, inversion=0, modulation=3;
                                sscanf(line+2, "%d:%d:%d:%d", &frequency, &symbol_rate, &inversion, &modulation);
                                int frequency, symbol_rate, inversion=0, modulation=3;
                                sscanf(line+2, "%d:%d:%d:%d", &frequency, &symbol_rate, &inversion, &modulation);
-//                             t.setCable(frequency, symbol_rate, inversion, modulation);
+                               cab.frequency = frequency;
+                               cab.symbol_rate = symbol_rate;
+                               cab.modulation = modulation;
+                               cab.fec_inner = 6;
+                               cab.inversion = inversion;
+                               feparm->setDVBC(cab);
                        }
                }
                addChannelToList(channelid, feparm);
                        }
                }
                addChannelToList(channelid, feparm);
@@ -431,6 +437,7 @@ void eDVBDB::saveServicelist()
                                chid.transport_stream_id.get(), chid.original_network_id.get());
                eDVBFrontendParametersSatellite sat;
                eDVBFrontendParametersTerrestrial ter;
                                chid.transport_stream_id.get(), chid.original_network_id.get());
                eDVBFrontendParametersSatellite sat;
                eDVBFrontendParametersTerrestrial ter;
+               eDVBFrontendParametersCable cab;
                if (!ch.m_frontendParameters->getDVBS(sat))
                {
                        fprintf(f, "\ts %d:%d:%d:%d:%d:%d\n",
                if (!ch.m_frontendParameters->getDVBS(sat))
                {
                        fprintf(f, "\ts %d:%d:%d:%d:%d:%d\n",
@@ -446,6 +453,11 @@ void eDVBDB::saveServicelist()
                                ter.code_rate_LP, ter.modulation, ter.transmission_mode,
                                ter.guard_interval, ter.hierarchy, ter.inversion);
                }
                                ter.code_rate_LP, ter.modulation, ter.transmission_mode,
                                ter.guard_interval, ter.hierarchy, ter.inversion);
                }
+               if (!ch.m_frontendParameters->getDVBC(cab))
+               {
+                       fprintf(f, "\tc %d:%d:%d:%d\n",
+                               cab.frequency, cab.symbol_rate, cab.inversion, cab.modulation);
+               }
                fprintf(f, "/\n");
                channels++;
        }
                fprintf(f, "/\n");
                channels++;
        }
index cd9a8f9..2755e31 100644 (file)
@@ -36,11 +36,9 @@ def getInitialCableTransponderList(tlist, cable):
                        parm = eDVBFrontendParametersCable()
                        parm.frequency = x[1]
                        parm.symbol_rate = x[2]
                        parm = eDVBFrontendParametersCable()
                        parm.frequency = x[1]
                        parm.symbol_rate = x[2]
-                       parm.modulation = 2 # x[3] # eDVBFrontendParametersSatellite.Polarisation.Verti 
-                       parm.fec = 6# x[4]                      # eDVBFrontendParametersSatellite.FEC.f3_4;
-                       #parm.fec = 6                                   # AUTO
+                       parm.modulation = 5 # AUTO
+                       parm.fec_inner = 6 # AUTO
                        parm.inversion = 2 # AUTO
                        parm.inversion = 2 # AUTO
-                       #parm.inversion = 2             #AUTO
                        tlist.append(parm)
 
 class ScanSetup(Screen):
                        tlist.append(parm)
 
 class ScanSetup(Screen):