#print "found sat " + attrs.get('name',"") + " " + str(attrs.get('position',""))
tname = attrs.get('name',"").encode("UTF-8")
tflags = attrs.get('flags',"")
- self.terrestrialsList.append((tname, tname, tflags))
+ self.terrestrialsList.append((tname, tflags))
self.parsedTer = str(tname)
elif (name == "transponder"):
# TODO finish this!
def getTranspondersCable(self, cable):
return self.transponderscable[cable]
+ def getTranspondersTerrestrial(self, region):
+ return self.transpondersterrestrial[region]
+
def getCableDescription(self, nim):
return self.cablesList[config.Nims[nim].cable.value]
+ def getTerrestrialDescription(self, nim):
+ return self.terrestrialsList[config.Nims[nim].terrestrial.value][0]
+
+ def getTerrestrialFlags(self, nim):
+ return self.terrestrialsList[config.Nims[nim].terrestrial.value][1]
+
def getConfiguredSats(self):
return self.sec.getSatList()
self.nimSocketCount += 1
elif line.strip().startswith("Type:"):
self.nimTypes[lastsocket] = str(line.strip()[6:])
+ #self.nimTypes[lastsocket] = str("DVB-T")
elif line.strip().startswith("Name:"):
self.nimNames[lastsocket] = str(line.strip()[6:])
elif line.strip().startswith("empty"):
def getNimConfigMode(self, slotid):
return currentConfigSelectionElement(config.Nims[slotid].configMode)
+
+ def getSatList(self):
+ return self.satList
def getSatListForNim(self, slotid):
list = []
list.append(x)
return list
+ def getRotorSatListForNim(self, slotid):
+ list = []
+ if (self.getNimType(slotid) == self.nimType["DVB-S"]):
+ #print "slotid:", slotid
+
+ #print "self.satellites:", self.satList[config.Nims[slotid].diseqcA.value]
+ #print "diseqcA:", config.Nims[slotid].diseqcA.value
+ configMode = currentConfigSelectionElement(config.Nims[slotid].configMode)
+ if configMode == "simple":
+ if (config.Nims[slotid].diseqcMode.value == 4):
+ for x in self.satList:
+ list.append(x)
+ elif configMode == "advanced":
+ for x in self.satList:
+ nim = config.Nims[slotid]
+ lnbnum = nim.advanced.sat[x[1]].lnb.value
+ if lnbnum != 0:
+ lnb = nim.advanced.lnb[lnbnum]
+ if lnb.diseqcMode.value == 3: # diseqc 1.2
+ list.append(x)
+ return list
+
def nimDiseqcModeChanged(self, slotid, mode):
#print "nimDiseqcModeChanged set to " + str(mode)
pass
elif slot.nimType == nimmgr.nimType["DVB-C"]:
nim.cable = configElement(cname + "cable", configSelection, 0, nimmgr.cablesList, False);
elif slot.nimType == nimmgr.nimType["DVB-T"]:
- nim.terrestrial = configElement(cname + "terrestrial", configSelection, 0, nimmgr.terrestrialsList, False);
+ list = []
+ for x in nimmgr.terrestrialsList:
+ list.append(x[0])
+ nim.terrestrial = configElement(cname + "terrestrial", configSelection, 0, list, False);
else:
print "pls add support for this frontend type!"