aboutsummaryrefslogtreecommitdiff
path: root/lib/python/Components/TunerInfo.py
diff options
context:
space:
mode:
authorStefan Pluecken <stefan.pluecken@multimedia-labs.de>2006-04-04 11:02:10 +0000
committerStefan Pluecken <stefan.pluecken@multimedia-labs.de>2006-04-04 11:02:10 +0000
commit497cdf03ef35886b452d366899988d041a7a533c (patch)
treec9b2714f94d33dcd5235c2b7328ab9a06778cb10 /lib/python/Components/TunerInfo.py
parent5cd11d2e469c17ebafb6b995076970f2a2ab82d0 (diff)
downloadenigma2-497cdf03ef35886b452d366899988d041a7a533c.tar.gz
enigma2-497cdf03ef35886b452d366899988d041a7a533c.zip
some work on the positioner setup plugin
Diffstat (limited to 'lib/python/Components/TunerInfo.py')
-rw-r--r--lib/python/Components/TunerInfo.py13
1 files changed, 11 insertions, 2 deletions
diff --git a/lib/python/Components/TunerInfo.py b/lib/python/Components/TunerInfo.py
index e22ce468..f39babf2 100644
--- a/lib/python/Components/TunerInfo.py
+++ b/lib/python/Components/TunerInfo.py
@@ -11,6 +11,8 @@ class TunerInfo(GUIComponent):
SNR_BAR = 3
AGC_BAR = 4
BER_BAR = 5
+ LOCK_STATE = 6
+ SYNC_STATE = 7
def __init__(self, type, servicefkt):
GUIComponent.__init__(self)
self.instance = None
@@ -50,6 +52,8 @@ class TunerInfo(GUIComponent):
value = feinfo.getFrontendInfo(iFrontendStatusInformation.signalQuality) * 100 / 65536
elif self.type == self.BER_VALUE or self.type == self.BER_BAR:
value = feinfo.getFrontendInfo(iFrontendStatusInformation.bitErrorRate)
+ elif self.type == self.LOCK_STATE:
+ value = feinfo.getFrontendInfo(iFrontendStatusInformation.LockState)
if self.type == self.SNR_PERCENTAGE or self.type == self.AGC_PERCENTAGE:
self.setText("%d%%" % (value))
@@ -59,9 +63,14 @@ class TunerInfo(GUIComponent):
self.setValue(value)
elif self.type == self.BER_BAR:
self.setValue(self.calc(value))
-
+ elif self.type == self.LOCK_STATE:
+ if value == 1:
+ self.setText(_("locked"))
+ else:
+ self.setText(_("not locked"))
+
def createWidget(self, parent):
- if self.SNR_PERCENTAGE <= self.type <= self.BER_VALUE:
+ if self.SNR_PERCENTAGE <= self.type <= self.BER_VALUE or self.type == self.LOCK_STATE:
return eLabel(parent)
elif self.SNR_BAR <= self.type <= self.BER_BAR:
self.g = eSlider(parent)