diff options
| author | Andreas Monzner <andreas.monzner@multimedia-labs.de> | 2006-10-19 19:59:05 +0000 |
|---|---|---|
| committer | Andreas Monzner <andreas.monzner@multimedia-labs.de> | 2006-10-19 19:59:05 +0000 |
| commit | e128ab84e720068a36530a0dab1426f893697247 (patch) | |
| tree | 1993c062b9d6510e8dbc8dcd0d850d7d6b830e18 /lib | |
| parent | eb6aa32e811a52a604ff00eb8e84932e3c86e598 (diff) | |
| download | enigma2-e128ab84e720068a36530a0dab1426f893697247.tar.gz enigma2-e128ab84e720068a36530a0dab1426f893697247.zip | |
fix python part of ePythonConfig::getConfigQuery... so now default ac3 and 5V
on Terrestrial Tuner are working again
Diffstat (limited to 'lib')
| -rw-r--r-- | lib/dvb/frontend.cpp | 4 | ||||
| -rw-r--r-- | lib/dvb_ci/dvbci.cpp | 2 | ||||
| -rw-r--r-- | lib/python/Components/config.py | 17 |
3 files changed, 19 insertions, 4 deletions
diff --git a/lib/dvb/frontend.cpp b/lib/dvb/frontend.cpp index cfd2610d..3905a187 100644 --- a/lib/dvb/frontend.cpp +++ b/lib/dvb/frontend.cpp @@ -1782,10 +1782,10 @@ RESULT eDVBFrontend::tune(const iDVBFrontendParameters &where) std::string enable_5V; char configStr[255]; - snprintf(configStr, 255, "config.Nim%c.terrestrial_5V", 'A'+m_fe); + snprintf(configStr, 255, "config.Nims.%d.terrestrial_5V", m_fe); m_sec_sequence.push_back( eSecCommand(eSecCommand::START_TUNE_TIMEOUT) ); ePythonConfigQuery::getConfigValue(configStr, enable_5V); - if (enable_5V == "on") + if (enable_5V == "True") m_sec_sequence.push_back( eSecCommand(eSecCommand::SET_VOLTAGE, iDVBFrontend::voltage13) ); else m_sec_sequence.push_back( eSecCommand(eSecCommand::SET_VOLTAGE, iDVBFrontend::voltageOff) ); diff --git a/lib/dvb_ci/dvbci.cpp b/lib/dvb_ci/dvbci.cpp index d95f6832..b074342e 100644 --- a/lib/dvb_ci/dvbci.cpp +++ b/lib/dvb_ci/dvbci.cpp @@ -221,7 +221,7 @@ void eDVBCIInterfaces::ciRemoved(eDVBCISlot *slot) static bool canDescrambleMultipleServices(int slotid) { char configStr[255]; - snprintf(configStr, 255, "config.ci%d.canDescrambleMultipleServices", slotid); + snprintf(configStr, 255, "config.ci.%d.canDescrambleMultipleServices", slotid); std::string str; ePythonConfigQuery::getConfigValue(configStr, str); if ( str == "auto" ) diff --git a/lib/python/Components/config.py b/lib/python/Components/config.py index b7b3baa8..0fd6e732 100644 --- a/lib/python/Components/config.py +++ b/lib/python/Components/config.py @@ -832,8 +832,23 @@ class ConfigFile: config.save() config.saveToFile(self.CONFIG_FILE) + def __resolveValue(self, pickles, cmap): + if cmap.has_key(pickles[0]): + if len(pickles) > 1: + return self.__resolveValue(pickles[1:], cmap[pickles[0]].content.items) + else: + return str(cmap[pickles[0]].value) + return None + def getResolvedKey(self, key): - return None # FIXME + names = key.split('.') + if len(names) > 1: + if names[0] == "config": + ret=self.__resolveValue(names[1:], config.content.items) + if ret and len(ret): + return ret + print "getResolvedKey", key, "failed !! (Typo??)" + return "" def NoSave(element): element.disableSave() |
