add possibility to change delay after diseqc reset command and delay after diseqc...
authorghost <andreas.monzner@multimedia-labs.de>
Thu, 13 Nov 2008 12:32:15 +0000 (13:32 +0100)
committerghost <andreas.monzner@multimedia-labs.de>
Thu, 13 Nov 2008 12:32:15 +0000 (13:32 +0100)
lib/dvb/sec.cpp
lib/dvb/sec.h
lib/python/Components/NimManager.py
lib/python/Plugins/SystemPlugins/SatelliteEquipmentControl/plugin.py

index 2a6016e..2b7f717 100644 (file)
@@ -637,11 +637,11 @@ RESULT eDVBSatelliteEquipmentControl::prepare(iDVBFrontend &frontend, FRONTENDPA
                                                        diseqc.data[2] = 0;
                                                        // diseqc reset
                                                        sec_sequence.push_back( eSecCommand(eSecCommand::SEND_DISEQC, diseqc) );
-                                                       sec_sequence.push_back( eSecCommand(eSecCommand::SLEEP, 50) );
+                                                       sec_sequence.push_back( eSecCommand(eSecCommand::SLEEP, m_params[DELAY_AFTER_DISEQC_RESET_CMD]) );
                                                        diseqc.data[2] = 3;
                                                        // diseqc peripherial powersupply on
                                                        sec_sequence.push_back( eSecCommand(eSecCommand::SEND_DISEQC, diseqc) );
-                                                       sec_sequence.push_back( eSecCommand(eSecCommand::SLEEP, 150) );
+                                                       sec_sequence.push_back( eSecCommand(eSecCommand::SLEEP, m_params[DELAY_AFTER_DISEQC_PERIPHERIAL_POWERON_CMD]) );
                                                }
 
                                                for (int seq_repeat = 0; seq_repeat < (di_param.m_seq_repeat?2:1); ++seq_repeat)
index 42e53eb..e68ed16 100644 (file)
@@ -267,6 +267,8 @@ public:
                MOTOR_COMMAND_RETRIES, // max transmit tries of rotor command when the rotor dont start turning (with power measurement)
                MOTOR_RUNNING_TIMEOUT, // max motor running time before timeout
                DELAY_AFTER_VOLTAGE_CHANGE_BEFORE_SWITCH_CMDS, // delay after change voltage before transmit toneburst/diseqc
+               DELAY_AFTER_DISEQC_RESET_CMD,
+               DELAY_AFTER_DISEQC_PERIPHERIAL_POWERON_CMD,
                MAX_PARAMS
        };
 private:
index 7060168..f4e9108 100644 (file)
@@ -858,6 +858,14 @@ def InitSecParams():
        x.addNotifier(lambda configElement: secClass.setParam(secClass.MOTOR_COMMAND_RETRIES, configElement.value))
        config.sec.motor_command_retries = x
 
+       x = ConfigInteger(default=50, limits = (0, 9999))
+       x.addNotifier(lambda configElement: secClass.setParam(secClass.DELAY_AFTER_DISEQC_RESET_CMD, configElement.value))
+       config.sec.delay_after_diseqc_reset_cmd = x
+
+       x = ConfigInteger(default=150, limits = (0, 9999))
+       x.addNotifier(lambda configElement: secClass.setParam(secClass.DELAY_AFTER_DISEQC_PERIPHERIAL_POWERON_CMD, configElement.value))
+       config.sec.delay_after_diseqc_peripherial_poweron_cmd = x
+
 # TODO add support for satpos depending nims to advanced nim configuration
 # so a second/third/fourth cable from a motorized lnb can used behind a
 # diseqc 1.0 / diseqc 1.1 / toneburst switch
index 7b3d08f..ec223d3 100644 (file)
@@ -23,6 +23,8 @@ class SecParameterSetup(Screen, ConfigListScreen):
 
                Screen.__init__(self, session)
                list = [
+                       ("Delay after diseqc reset command", config.sec.delay_after_diseqc_reset_cmd),
+                       ("Delay after diseqc peripherial poweron command", config.sec.delay_after_diseqc_peripherial_poweron_cmd),
                        ("Delay after continuous tone change", config.sec.delay_after_continuous_tone_change),
                        ("Delay after last voltage change", config.sec.delay_after_final_voltage_change),
                        ("Delay between diseqc commands", config.sec.delay_between_diseqc_repeats),