git.cweiske.de
/
enigma2.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Merge branch 'master' of git.opendreambox.org:/git/enigma2
[enigma2.git]
/
lib
/
python
/
Screens
/
ServiceInfo.py
diff --git
a/lib/python/Screens/ServiceInfo.py
b/lib/python/Screens/ServiceInfo.py
index 7bd8aa9821dbae3e1cfe1694c3011aee1ad2ee0a..4606f883f4950175133a4eaa2340775f5ab7d47e 100644
(file)
--- a/
lib/python/Screens/ServiceInfo.py
+++ b/
lib/python/Screens/ServiceInfo.py
@@
-14,6
+14,9
@@
TYPE_VALUE_DEC = 2
TYPE_VALUE_HEX_DEC = 3
TYPE_SLIDER = 4
TYPE_VALUE_HEX_DEC = 3
TYPE_SLIDER = 4
+def to_unsigned(x):
+ return x & 0xFFFFFFFF
+
def ServiceInfoListEntry(a, b, valueType=TYPE_TEXT, param=4):
res = [ ]
def ServiceInfoListEntry(a, b, valueType=TYPE_TEXT, param=4):
res = [ ]
@@
-23,11
+26,11
@@
def ServiceInfoListEntry(a, b, valueType=TYPE_TEXT, param=4):
print "b:", b
if type(b) is not str:
if valueType == TYPE_VALUE_HEX:
print "b:", b
if type(b) is not str:
if valueType == TYPE_VALUE_HEX:
- b = ("0x%0" + str(param) + "x") %
b
+ b = ("0x%0" + str(param) + "x") %
to_unsigned(b)
elif valueType == TYPE_VALUE_DEC:
b = str(b)
elif valueType == TYPE_VALUE_HEX_DEC:
elif valueType == TYPE_VALUE_DEC:
b = str(b)
elif valueType == TYPE_VALUE_HEX_DEC:
- b = ("0x%0" + str(param) + "x (%dd)") % (
b
, b)
+ b = ("0x%0" + str(param) + "x (%dd)") % (
to_unsigned(b)
, b)
else:
b = str(b)
else:
b = str(b)
@@
-129,16
+132,17
@@
class ServiceInfo(Screen):
else:
if self.transponder_info:
conv = { "type" : _("Transponder Type"),
else:
if self.transponder_info:
conv = { "type" : _("Transponder Type"),
+ "system" : _("System"),
+ "modulation" : _("Modulation"),
+ "orbital position" : _("Orbital Position"),
"frequency" : _("Frequency"),
"symbolrate" : _("Symbolrate"),
"frequency" : _("Frequency"),
"symbolrate" : _("Symbolrate"),
- "orbital position" : _("Orbital Position"),
- "inversion" : _("Inversion"),
- "fec inner" : _("FEC"),
- "modulation" : _("Modulation"),
+ "bandwidth" : _("Bandwidth"),
"polarization" : _("Polarization"),
"polarization" : _("Polarization"),
+ "inversion" : _("Inversion"),
+ "pilot" : _("Pilot"),
"roll off" : _("Rolloff"),
"roll off" : _("Rolloff"),
- "system" : _("System"),
- "bandwidth" : _("Bandwidth"),
+ "fec inner" : _("FEC"),
"code rate lp" : _("Coderate LP"),
"code rate hp" : _("Coderate HP"),
"constellation" : _("Constellation"),
"code rate lp" : _("Coderate LP"),
"code rate hp" : _("Coderate HP"),
"constellation" : _("Constellation"),
@@
-187,7
+191,9
@@
class ServiceInfo(Screen):
("Symbolrate", frontendData["symbol_rate"], TYPE_VALUE_DEC),
("Polarization", frontendData["polarization"], TYPE_TEXT),
("Inversion", frontendData["inversion"], TYPE_TEXT),
("Symbolrate", frontendData["symbol_rate"], TYPE_VALUE_DEC),
("Polarization", frontendData["polarization"], TYPE_TEXT),
("Inversion", frontendData["inversion"], TYPE_TEXT),
- ("FEC inner", frontendData["fec_inner"], TYPE_TEXT))
+ ("FEC inner", frontendData["fec_inner"], TYPE_TEXT),
+ ("Pilot", frontendData.get("pilot", None), TYPE_TEXT),
+ ("Rolloff", frontendData.get("rolloff", None), TYPE_TEXT))
elif frontendData["tuner_type"] == "DVB-C":
return (("NIM", ['A', 'B', 'C', 'D'][frontendData["tuner_number"]], TYPE_TEXT),
("Type", frontendData["tuner_type"], TYPE_TEXT),
elif frontendData["tuner_type"] == "DVB-C":
return (("NIM", ['A', 'B', 'C', 'D'][frontendData["tuner_number"]], TYPE_TEXT),
("Type", frontendData["tuner_type"], TYPE_TEXT),
@@
-214,6
+220,8
@@
class ServiceInfo(Screen):
tlist = [ ]
for item in Labels:
tlist = [ ]
for item in Labels:
+ if item[1] is None:
+ continue;
value = item[1]
if len(item) < 4:
tlist.append(ServiceInfoListEntry(item[0]+":", value, item[2]))
value = item[1]
if len(item) < 4:
tlist.append(ServiceInfoListEntry(item[0]+":", value, item[2]))