当前位置: 首页>>代码示例>>Python>>正文


Python ScanSetup.ScanSetup类代码示例

本文整理汇总了Python中Screens.ScanSetup.ScanSetup的典型用法代码示例。如果您正苦于以下问题:Python ScanSetup类的具体用法?Python ScanSetup怎么用?Python ScanSetup使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。


在下文中一共展示了ScanSetup类的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Python代码示例。

示例1: createConfig

	def createConfig(self):
		ScanSetup.createConfig(self)
		for x in (
			self.scan_sat.frequency,
			self.scan_satselection[int(self.scan_nims.value)],
			self.scan_sat.symbolrate,
			self.scan_sat.is_id,
			self.scan_sat.pls_mode,
			self.scan_sat.pls_code,

			self.scan_ter.channel,
			self.scan_ter.frequency,
			self.scan_ter.inversion,
			self.scan_ter.bandwidth, self.scan_ter.fechigh, self.scan_ter.feclow,
			self.scan_ter.modulation, self.scan_ter.transmission,
			self.scan_ter.guard, self.scan_ter.hierarchy,
			self.scan_ter.plp_id,
			self.scan_cab.frequency, self.scan_cab.inversion, self.scan_cab.symbolrate,
			self.scan_cab.modulation, self.scan_cab.fec,
			self.scan_ats.frequency, self.scan_ats.modulation, self.scan_ats.inversion,
			self.scan_ats.system,

			):
			if x is not None:
				x.clearNotifiers()
				x.addNotifier(self.TriggeredByConfigElement, initial_call = False)
开发者ID:Open-Plus,项目名称:opgui,代码行数:26,代码来源:plugin.py

示例2: createConfig

	def createConfig(self, foo):
		self.preDefTransponders = None
		self.tuning_type = ConfigSelection(choices = [("manual_transponder", _("User defined transponder")), ("predefined_transponder", _("Predefined transponder"))], default = "predefined_transponder")
		self.orbital_position = 192
		if self.frontendData and self.frontendData.has_key('orbital_position'):
			self.orbital_position = self.frontendData['orbital_position']
		ScanSetup.createConfig(self, self.frontendData)

		for x in (self.tuning_type, self.scan_sat.frequency,
			self.scan_sat.inversion, self.scan_sat.symbolrate,
			self.scan_sat.polarization, self.scan_sat.fec, self.scan_sat.pilot,
			self.scan_sat.fec_s2, self.scan_sat.fec, self.scan_sat.modulation,
			self.scan_sat.rolloff, self.scan_sat.system):
			x.addNotifier(self.retune, initial_call = False)

		satfinder_nim_list = []
		for n in nimmanager.nim_slots:
			if not n.isCompatible("DVB-S"):
				continue
			if n.config_mode  in ("loopthrough", "satposdepends", "nothing"):
				continue
			if n.config_mode == "advanced" and len(nimmanager.getSatListForNim(n.slot)) < 1:
				continue
			satfinder_nim_list.append((str(n.slot), n.friendly_full_description))
		self.satfinder_scan_nims = ConfigSelection(choices = satfinder_nim_list)
		self.feid = int(self.satfinder_scan_nims.value)

		self.satList = []
		self.scan_satselection = []
		for slot in nimmanager.nim_slots:
			if slot.isCompatible("DVB-S"):
				self.satList.append(nimmanager.getSatListForNim(slot.slot))
				self.scan_satselection.append(getConfigSatlist(self.orbital_position, self.satList[slot.slot]))
			else:
				self.satList.append(None)
开发者ID:OpenSH4,项目名称:enigma2,代码行数:35,代码来源:plugin.py

示例3: __init__

	def __init__(self, session):
		self.initcomplete = False
		service = session and session.nav.getCurrentService()
		feinfo = service and service.frontendInfo()
		self.frontendData = feinfo and feinfo.getAll(True)
		del feinfo
		del service

		self.typeOfTuningEntry = None
		self.systemEntry = None
		self.satfinderTunerEntry = None
		self.satEntry = None
		self.typeOfInputEntry = None

		ScanSetup.__init__(self, session)
		self.setTitle(_("Satfinder"))
		self["introduction"].setText(_("Press OK to scan"))
		self["Frontend"] = FrontendStatus(frontend_source = lambda : self.frontend, update_interval = 100)

		self["actions"] = ActionMap(["SetupActions", "ColorActions"],
		{
			"save": self.keyGoScan,
			"ok": self.keyGoScan,
			"cancel": self.keyCancel,
		}, -3)

		self.initcomplete = True
		self.session.postScanService = self.session.nav.getCurrentlyPlayingServiceOrGroup()
		self.onClose.append(self.__onClose)
		self.onShow.append(self.prepareFrontend)
开发者ID:gasan36,项目名称:enigma2-openpli-fulan,代码行数:30,代码来源:plugin.py

示例4: __init__

	def __init__(self, session, feid):
		self.initcomplete = False
		self.feid = feid
		self.oldref = None
		self.frontendData = None
		service = session and session.nav.getCurrentService()
		feinfo = service and service.frontendInfo()
		self.frontendData = feinfo and feinfo.getAll(True)
		del feinfo
		del service

		ScanSetup.__init__(self, session)
		self.setTitle(_("Satfinder"))

		self["introduction"].setText(_("Press OK to scan"))
		self["Frontend"] = FrontendStatus(frontend_source = lambda : self.frontend, update_interval = 100)

		self["actions"] = ActionMap(["SetupActions"],
		{
			"save": self.keyGoScan,
			"ok": self.keyGoScan,
			"cancel": self.keyCancel,
		}, -3)

		self.initcomplete = True
		self.oldref = self.session.nav.getCurrentlyPlayingServiceReference()
		self.onClose.append(self.__onClose)
		self.onShow.append(self.__onShow)
开发者ID:drgogeta86,项目名称:enigma2,代码行数:28,代码来源:plugin.py

示例5: __init__

	def __init__(self, session, feid):
		self.initcomplete = False
		self.feid = feid
		self.oldref = None
		self.frontendData = None
		service = session and session.nav.getCurrentService()
		feinfo = service and service.frontendInfo()
		self.frontendData = feinfo and feinfo.getAll(True)
		del feinfo
		del service

		if not self.openFrontend():
			self.oldref = session.nav.getCurrentlyPlayingServiceReference()
			session.nav.stopService() # try to disable foreground service
			if not self.openFrontend():
				if session.pipshown: # try to disable pip
					session.pipshown = False
					del session.pip
					if not self.openFrontend():
						self.frontend = None # in normal case this should not happen

		ScanSetup.__init__(self, session)
		Screen.setTitle(self, _("Satfinder"))
		self.tuner = Tuner(self.frontend)
		self["introduction"].setText("")
		self["Frontend"] = FrontendStatus(frontend_source = lambda : self.frontend, update_interval = 100)
		self.initcomplete = True
		self.onClose.append(self.__onClose)
开发者ID:kolombek,项目名称:enigma2,代码行数:28,代码来源:plugin.py

示例6: createConfig

	def createConfig(self, foo):
		self.tuning_type = ConfigSelection(default = "predefined_transponder", choices = [("single_transponder", _("User defined transponder")), ("predefined_transponder", _("Predefined transponder"))])
		self.orbital_position = 192
		if self.frontendData and self.frontendData.has_key('orbital_position'):
			self.orbital_position = self.frontendData['orbital_position']
		ScanSetup.createConfig(self, self.frontendData)

		for x in (self.scan_sat.frequency,
			self.scan_sat.inversion, self.scan_sat.symbolrate,
			self.scan_sat.polarization, self.scan_sat.fec, self.scan_sat.pilot,
			self.scan_sat.fec_s2, self.scan_sat.fec, self.scan_sat.modulation,
			self.scan_sat.rolloff, self.scan_sat.system,
			self.scan_ter.channel, self.scan_ter.frequency, self.scan_ter.inversion,
			self.scan_ter.bandwidth, self.scan_ter.fechigh, self.scan_ter.feclow,
			self.scan_ter.modulation, self.scan_ter.transmission,
			self.scan_ter.guard, self.scan_ter.hierarchy, self.scan_ter.plp_id,
			self.scan_cab.frequency, self.scan_cab.inversion, self.scan_cab.symbolrate,
			self.scan_cab.modulation, self.scan_cab.fec):
			x.addNotifier(self.retune, initial_call = False)

		satfinder_nim_list = []
		for n in nimmanager.nim_slots:
			if not (n.isCompatible("DVB-S") or n.isCompatible("DVB-T") or n.isCompatible("DVB-C")):
				continue
			if n.config_mode  in ("loopthrough", "satposdepends", "nothing"):
				continue
			if n.isCompatible("DVB-S") and len(nimmanager.getSatListForNim(n.slot)) < 1:
				continue
			if n.isCompatible("DVB-S") and n.isFBCTuner() and not n.isFBCRoot():
				continue
			satfinder_nim_list.append((str(n.slot), n.friendly_full_description))
		self.satfinder_scan_nims = ConfigSelection(choices = satfinder_nim_list)
		if self.frontendData is not None and len(satfinder_nim_list) > 0: # open the plugin with the currently active NIM as default
			active_nim = self.frontendData.get("tuner_number", int(satfinder_nim_list[0][0]))
			if not nimmanager.nim_slots[active_nim].isFBCLink():
				self.satfinder_scan_nims.setValue(str(active_nim))

		self.feid = int(self.satfinder_scan_nims.value)

		self.satList = []
		self.scan_satselection = []
		for slot in nimmanager.nim_slots:
			if slot.isCompatible("DVB-S"):
				self.satList.append(nimmanager.getSatListForNim(slot.slot))
				self.scan_satselection.append(getConfigSatlist(self.orbital_position, self.satList[slot.slot]))
			else:
				self.satList.append(None)

		if self.frontendData:
			ttype = self.frontendData.get("tuner_type", "UNKNOWN")
			if ttype == "DVB-S" and self.predefinedTranspondersList(self.getSelectedSatIndex(self.feid)) is None and len(nimmanager.getTransponders(self.getSelectedSatIndex(self.feid))) > 0:
				self.tuning_type.value = "single_transponder"
			elif ttype == "DVB-T" and self.predefinedTerrTranspondersList() is None and len(nimmanager.getTranspondersTerrestrial(nimmanager.getTerrestrialDescription(self.feid))) > 0:
				self.tuning_type.value = "single_transponder"
			elif ttype == "DVB-C" and self.predefinedCabTranspondersList() is None and len(nimmanager.getTranspondersCable(self.feid)) > 0:
				self.tuning_type.value = "single_transponder"
开发者ID:Huevos,项目名称:enigma2,代码行数:56,代码来源:plugin.py

示例7: __init__

	def __init__(self, session, args = None):
		ScanSetup.__init__(self, session)
		# backup lamedb
		confdir = resolveFilename(SCOPE_CONFIG)
		copyfile(confdir + "/lamedb", confdir + "/lamedb.backup")
		self.scan_type.value = "multisat"
		self.createSetup()
		self.scanIndex = 0
		self.selectSat(0)
		self.onFirstExecBegin.append(self.runScan)
开发者ID:fairbird,项目名称:OpenPLI-BlackHole,代码行数:10,代码来源:plugin.py

示例8: newConfig

	def newConfig(self):
		cur = self["config"].getCurrent()
		if cur is None:
			pass
		elif cur == self.satEntry:
			self.updateSats()
			self.createSetup()
		else:
			ScanSetup.newConfig(self)
		if self.systemEntry and cur == self.systemEntry or \
			cur == self.tuning_type:
			self.retune(None)
开发者ID:OpenDMM,项目名称:enigma2,代码行数:12,代码来源:plugin.py

示例9: newConfig

	def newConfig(self):
		ScanSetup.newConfig(self)
		cur = self["config"].getCurrent()
		print"cur ", cur
		if cur == self.tunerEntry:
			self.feid = int(self.scan_nims.value)
			self.createSetup()
			self.prepareFrontend()
			if self.frontend == None:
				msg = _("Tuner not available.")
				if self.session.nav.RecordTimer.isRecording():
					msg += _("\nRecording in progress.")
				self.session.open(MessageBox, msg, MessageBox.TYPE_ERROR)
		self.retune()
开发者ID:idrogeno,项目名称:FusionOE,代码行数:14,代码来源:plugin.py

示例10: createConfig

	def createConfig(self, foo):
		self.tuning_transponder = None
		self.tuning_type = ConfigSelection(choices = [("manual_transponder", _("Manual transponder")), ("predefined_transponder", _("Predefined transponder"))])
		self.tuning_sat = getConfigSatlist(192, nimmanager.getSatListForNim(self.feid))
		ScanSetup.createConfig(self, None)
		
		self.updateSats()

		for x in (self.tuning_type, self.tuning_sat, self.scan_sat.frequency,
			self.scan_sat.inversion, self.scan_sat.symbolrate,
			self.scan_sat.polarization, self.scan_sat.fec, self.scan_sat.pilot,
			self.scan_sat.fec_s2, self.scan_sat.fec, self.scan_sat.modulation,
			self.scan_sat.rolloff, self.scan_sat.system):
			x.addNotifier(self.retune, initial_call = False)
开发者ID:4doe,项目名称:enigma2-old,代码行数:14,代码来源:plugin.py

示例11: newConfig

	def newConfig(self):
#		self.transponder = None
		cur = self["config"].getCurrent()
		print"cur ", cur

		if cur == self.tunerEntry:
			self.feid = int(self.scan_nims.value)
			self.prepareFrontend()
			if self.frontend == None and self.session.nav.RecordTimer.isRecording():
				slot = nimmanager.nim_slots[self.feid]
				msg = _("%s not available.") % slot.getSlotName()
				msg += _("\nRecording in progress.")
				self.session.open(MessageBox, msg, MessageBox.TYPE_ERROR)
		else:
			ScanSetup.newConfig(self)
		if cur[1].value == "single_transponder":
			self.retune()
开发者ID:Open-Plus,项目名称:opgui,代码行数:17,代码来源:plugin.py

示例12: __init__

	def __init__(self, session):
		self.initcomplete = False
		service = session and session.nav.getCurrentService()
		feinfo = service and service.frontendInfo()
		self.frontendData = feinfo and feinfo.getAll(True)
		del feinfo
		del service


		self.preDefTransponders = None
#		self.TerrestrialTransponders = None
		self.CableTransponders = None
		self.typeOfTuningEntry = None
#		self.systemEntry = None
#		self.tunerEntry = None
		self.satEntry = None
#		self.typeOfInputEntry = None
		self.frequencyEntry = None
		self.polarizationEntry = None
		self.symbolrateEntry = None
		self.inversionEntry = None
		self.rolloffEntry = None
		self.pilotEntry = None
#		self.modulationEntry = None
		self.fecEntry = None
		self.transponder = None
#		self.multiType = None

		ScanSetup.__init__(self, session)
		self.setTitle(_("Signal Finder"))
		self["introduction"].setText(_("Press OK to scan"))
		self["Frontend"] = FrontendStatus(frontend_source = lambda : self.frontend, update_interval = 100)

		self["actions"] = ActionMap(["SetupActions", "ColorActions"],
		{
			"save": self.keyGoScan,
			"ok": self.keyGoScan,
			"cancel": self.keyCancel,
		}, -3)

		self.initcomplete = True
		self.session.postScanService = self.session.nav.getCurrentlyPlayingServiceOrGroup()
		self.onClose.append(self.__onClose)
		self.onShow.append(self.prepareFrontend)
开发者ID:idrogeno,项目名称:FusionOE,代码行数:44,代码来源:plugin.py

示例13: createConfig

	def createConfig(self, foo):
		global tuning
		if not tuning:
			tuning = ConfigSubsection()
			tuning.type = ConfigSelection(
				default = "manual_transponder",
				choices = { "manual_transponder" : _("Manual transponder"),
							"predefined_transponder" : _("Predefined transponder") } )
			tuning.sat = ConfigSatlist(list=nimmanager.getRotorSatListForNim(self.feid))
			tuning.sat.addNotifier(self.tuningSatChanged)
			self.updateTransponders()
		orb_pos = self.fe_data.get("orbital_position", None)
		if orb_pos is not None:
			for x in nimmanager.getRotorSatListForNim(self.feid):
				opos = str(orb_pos)
				if x[0] == orb_pos and tuning.sat.value != opos:
					tuning.sat.value = opos
			del self.fe_data["orbital_position"]
		ScanSetup.createConfig(self, self.fe_data)
开发者ID:popazerty,项目名称:12,代码行数:19,代码来源:plugin.py

示例14: __init__

 def __init__(self, session):
     self.initcomplete = False
     self.frontendData = None
     service = session and session.nav.getCurrentService()
     feinfo = service and service.frontendInfo()
     self.frontendData = feinfo and feinfo.getAll(True)
     del feinfo
     del service
     ScanSetup.__init__(self, session)
     self.setTitle(_('Satfinder'))
     self['introduction'].setText(_('Press OK to scan'))
     self['Frontend'] = FrontendStatus(frontend_source=lambda : self.frontend, update_interval=100)
     self['actions'] = ActionMap(['SetupActions'], {'save': self.keyGoScan,
      'ok': self.keyGoScan,
      'cancel': self.keyCancel}, -3)
     self.initcomplete = True
     self.session.postScanService = self.session.nav.getCurrentlyPlayingServiceOrGroup()
     self.onClose.append(self.__onClose)
     self.onShow.append(self.prepareFrontend)
开发者ID:kingvuplus,项目名称:ZDE-gui,代码行数:19,代码来源:plugin.py

示例15: newConfig

	def newConfig(self):
#		self.transponder = None
		cur = self["config"].getCurrent()
		print"cur ", cur

		if cur == self.tunerEntry:
			self.feid = int(self.scan_nims.value)
			self.prepareFrontend()
			if self.frontend == None and self.session.nav.RecordTimer.isRecording():
				slot = nimmanager.nim_slots[self.feid]
				msg = _("%s not available.") % slot.getSlotName()
				msg += _("\nRecording in progress.")
				self.session.open(MessageBox, msg, MessageBox.TYPE_ERROR)
		elif cur == self.is_id_boolEntry:
			if self.is_id_boolEntry[1].value:
				self.scan_sat.is_id.value = 0 if self.is_id_memory < 0 else self.is_id_memory
				self.scan_sat.pls_mode.value = self.pls_mode_memory
				self.scan_sat.pls_code.value = self.pls_code_memory
			else:
				self.is_id_memory = self.scan_sat.is_id.value
				self.pls_mode_memory = self.scan_sat.pls_mode.value
				self.pls_code_memory = self.scan_sat.pls_code.value
				self.scan_sat.is_id.value = eDVBFrontendParametersSatellite.No_Stream_Id_Filter
				self.scan_sat.pls_mode.value = eDVBFrontendParametersSatellite.PLS_Gold
				self.scan_sat.pls_code.value = eDVBFrontendParametersSatellite.PLS_Default_Gold_Code
			self.createSetup()
			self.retune()
		elif cur == self.t2mi_plp_id_boolEntry:
			if self.t2mi_plp_id_boolEntry[1].value:
				self.scan_sat.t2mi_plp_id.value = 0 if self.t2mi_plp_id_memory < 0 else self.t2mi_plp_id_memory
				self.scan_sat.t2mi_pid.value = self.t2mi_pid_memory
			else:
				self.t2mi_plp_id_memory = self.scan_sat.t2mi_plp_id.value
				self.t2mi_pid_memory = self.scan_sat.t2mi_pid.value
				self.scan_sat.t2mi_plp_id.value = eDVBFrontendParametersSatellite.No_T2MI_PLP_Id
				self.scan_sat.t2mi_pid.value = eDVBFrontendParametersSatellite.T2MI_Default_Pid
			self.createSetup()
			self.retune()
		else:
			ScanSetup.newConfig(self)
		if cur[1].value == "single_transponder":
			self.retune()
开发者ID:openhdf,项目名称:enigma2,代码行数:42,代码来源:plugin.py


注:本文中的Screens.ScanSetup.ScanSetup类示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。