}
}
eDebug("close frontend %d", m_fe);
+ setTone(iDVBFrontend::toneOff);
+ setVoltage(iDVBFrontend::voltageOff);
if (m_fd >= 0)
{
::close(m_fd);
delete m_sn;
m_sn=0;
- setTone(iDVBFrontend::toneOff);
- setVoltage(iDVBFrontend::voltageOff);
return 0;
}
eDebug("[SEC] error read lnbp (%m)");
if ( m_sec_sequence.current()->mode == eSecCommand::modeStatic )
{
- data[0] |= 0x90; // enable static current limiting
+ data[0] |= 0x80; // enable static current limiting
eDebug("[SEC] set static current limiting");
}
else
{
- data[0] &= ~0x90; // enable dynamic current limiting
+ data[0] &= ~0x80; // enable dynamic current limiting
eDebug("[SEC] set dynamic current limiting");
}
if(::write(fd, data, 1) != 1)
break;
case eSecCommand::IF_INPUTPOWER_DELTA_GOTO:
{
- int idleInputpower = m_idleInputpower[m_curVoltage == iDVBFrontend::voltage13 ? 0 : 1];
+ int idleInputpower = m_idleInputpower[ (m_curVoltage&1) ? 0 : 1];
eSecCommand::rotor &cmd = m_sec_sequence.current()->measure;
const char *txt = cmd.direction ? "running" : "stopped";
eDebug("[SEC] waiting for rotor %s %d, idle %d, delta %d",
#if HAVE_DVB_API_VERSION < 3
secVoltage vlt;
#else
+ bool increased=false;
fe_sec_voltage_t vlt;
#endif
-
m_curVoltage=voltage;
switch (voltage)
{
m_data[i]=-1;
vlt = SEC_VOLTAGE_OFF;
break;
+ case voltage13_5:
+#if HAVE_DVB_API_VERSION < 3
+ vlt = SEC_VOLTAGE_13_5;
+ break;
+#else
+ increased = true;
+#endif
case voltage13:
vlt = SEC_VOLTAGE_13;
break;
+ case voltage18_5:
+#if HAVE_DVB_API_VERSION < 3
+ vlt = SEC_VOLTAGE_18_5;
+ break;
+#else
+ increased = true;
+#endif
case voltage18:
vlt = SEC_VOLTAGE_18;
break;
#if HAVE_DVB_API_VERSION < 3
return ::ioctl(m_secfd, SEC_SET_VOLTAGE, vlt);
#else
+ if (::ioctl(m_fd, FE_ENABLE_HIGH_LNB_VOLTAGE, increased) < 0)
+ perror("FE_ENABLE_HIGH_LNB_VOLTAGE");
return ::ioctl(m_fd, FE_SET_VOLTAGE, vlt);
#endif
}