1
0
mirror of https://github.com/rofafor/vdr-plugin-satip.git synced 2023-10-10 11:37:42 +00:00

59 Commits

Author SHA1 Message Date
Rolf Ahrenberg
c07d921193 Silence "misleading-indentation" warning. 2018-03-14 23:23:27 +02:00
Rolf Ahrenberg
d333bcebb7 Remove speed limit. 2018-02-13 17:24:09 +02:00
Rolf Ahrenberg
0ce8ae7206 Avoid closing RTP/RTCP ports. 2018-02-06 22:55:52 +02:00
Rolf Ahrenberg
2c6c6ea5fd Fixed transport media change for RTCP. 2018-02-06 22:36:59 +02:00
Rolf Ahrenberg
28cc3cae63 Strip off the constructor delegation after all to broaden compiler compability. 2017-11-19 15:25:31 +02:00
Rolf Ahrenberg
0abccf2370 Merge pull request #46 from srehm/vdr-2.2.x
Configurable RTP receive buffer size
2017-11-19 14:59:50 +02:00
Stefan Rehm
f303298923 Added command line parameter to make the RTP receive bufferr size configurable. 2017-11-19 13:49:59 +01:00
Rolf Ahrenberg
f3fe1e9a13 Serialize channel switching to prevent device allocation failures. 2017-11-18 12:25:33 +02:00
Alexander Pipelka
364b4fbec7 Ignore handlers without any data. 2017-10-04 21:55:07 +03:00
Rolf Ahrenberg
b004793ef3 Cleanup section filter code. 2017-10-01 22:39:23 +03:00
Alexander Pipelka
ae403212f7 Moved send loop one level down. 2017-10-01 22:39:12 +03:00
Alexander Pipelka
09941322b1 Changed include header. 2017-10-01 22:39:03 +03:00
Alexander Pipelka
3713d1a1fa Use error() to display error messages. 2017-10-01 22:38:54 +03:00
Alexander Pipelka
2355dad37b Defined section filter send timeout. 2017-10-01 22:38:46 +03:00
Alexander Pipelka
de6c0e1f89 Minor coding-style fix. 2017-10-01 22:38:38 +03:00
Alexander Pipelka
bbd7f2da51 Removed dead sleep code (comment) in cSatipSectionFilterHandler::Action(). 2017-10-01 22:38:21 +03:00
Alexander Pipelka
e11396e84d Added transfer timeout for sectionfilter data. 2017-10-01 22:38:14 +03:00
Alexander Pipelka
dfb050c297 Fixed memory leak in cSatipSectionFilter. 2017-10-01 18:31:39 +03:00
Rolf Ahrenberg
ee88aadf60 Updated version number. 2017-08-15 09:17:11 +03:00
Sascha Kuehndel (InuSasha)
e405a31f48 fix gcc7 compiling 2017-08-15 09:11:02 +03:00
Rolf Ahrenberg
1a254029d5 Fix info messages. 2017-08-15 09:10:49 +03:00
Rolf Ahrenberg
87f9555290 Refactor the server detection script. 2017-08-15 09:10:28 +03:00
Rolf Ahrenberg
b21398938b Add a server detection script. 2017-08-15 09:10:16 +03:00
Rolf Ahrenberg
fb6282b44f Add support for interface binding via a defined source address. 2017-08-15 09:09:48 +03:00
Rolf Ahrenberg
01533ef6be Update quirks for FRITZ!WLAN Repeater DVB-C and FRITZ!Box 6490 Cable devices. 2017-08-15 09:09:16 +03:00
Tomasz Maciej Nowak
1ca7cae7e4 Add polish language 2017-08-15 09:04:52 +03:00
kavanu
974c26bdd6 added name of "KATHREIN SatIP Server" 2017-05-20 14:17:11 +03:00
Rolf Ahrenberg
ed99cfba79 Remove non-compatible RTP-over-TCP devices. 2017-02-25 14:05:32 +02:00
Frank Neumann
5b01fa34aa Update Catalan and Espanol translations. 2017-02-11 19:33:13 +02:00
Rolf Ahrenberg
0bad1c1702 Add musl-libc compatibility. 2017-01-05 17:28:28 +02:00
Rolf Ahrenberg
6573c38fb6 Updated HISTORY. 2016-12-18 17:28:41 +02:00
Rolf Ahrenberg
581ac4966d Prefer section pids. 2016-12-16 08:18:41 +02:00
Rolf Ahrenberg
99e366b261 Add a preliminary RTP-over-TCP support. 2016-12-15 23:48:22 +02:00
Frank Neumann
3b89dd4b01 Update German translations. 2016-12-15 08:11:34 +02:00
Rolf Ahrenberg
ee6ac0d48a Add a preliminary multicast support. 2016-12-14 00:39:22 +02:00
Rolf Ahrenberg
e6c9776ec9 Add a new ForcePilot quirk. 2016-11-10 16:54:12 +02:00
Rolf Ahrenberg
7aef2a3dff Update README. 2016-11-10 16:52:08 +02:00
Rolf Ahrenberg
61b56db909 Add command-line support for setting server quirks. 2016-10-09 18:55:12 +03:00
Rolf Ahrenberg
4c45787541 Add preliminary support for DVBViewer CI. 2016-09-11 13:13:24 +03:00
Rolf Ahrenberg
f65dca2910 Handle Out-of-Range responses as a normal operation. 2016-09-11 13:12:59 +03:00
Rolf Ahrenberg
db0c18ba33 Check source validity also in server assign (Thanks to Patrick Boettcher). 2016-07-31 12:02:31 +03:00
Rolf Ahrenberg
0f9e0014df Add support for source filtering. 2016-07-30 13:43:57 +03:00
Rolf Ahrenberg
6bb7fb511b Fix command-line examples to match defined quirks. 2016-07-23 17:38:28 +03:00
Rolf Ahrenberg
7815821824 Fix active device check. 2016-06-23 15:38:36 +03:00
Rolf Ahrenberg
bc481bcc4d Add support for activating/deactivating server on-the-fly. 2016-06-22 22:49:46 +03:00
Rolf Ahrenberg
7289da9f41 Add support for RTP-over-TCP. 2016-06-21 23:03:39 +03:00
Rolf Ahrenberg
d5e0106d8e Change EINTR handling in poller. 2016-06-05 14:20:50 +03:00
Rolf Ahrenberg
fe532e2248 Use 2MB ringbuffer per device. 2016-05-12 23:48:01 +03:00
Rolf Ahrenberg
b5483b9d77 Set SO_REUSEPORT only if it's defined. 2016-05-07 21:45:28 +03:00
Rolf Ahrenberg
fd23b0483a Re-enable to reuse address for msearch protocol. 2016-04-11 23:06:03 +03:00
Rolf Ahrenberg
18c9b79533 Reset device name when the device is idling. 2016-03-19 20:37:21 +02:00
Rolf Ahrenberg
e4f560c66e Fix statistics output a bit more. 2016-02-28 18:24:29 +02:00
Rolf Ahrenberg
57ea119d03 Fix statistics output. 2016-02-28 15:36:12 +02:00
Rolf Ahrenberg
ae8298d19a Added support for X-SATIP-RTSP-Port header. 2016-02-27 17:32:27 +02:00
Tobias Grimm
b755dbf318 C++11 requires a mandatory space when concatenating string literals 2016-01-30 21:52:12 +02:00
Rolf Ahrenberg
8f12ce6f55 Add a missing device name update. 2016-01-30 21:51:49 +02:00
chriszero
9d5f7cc703 Make it possible to specify the rtp and rtcp ports
this makes it possible to use the satip through a
NAT (e.g. a docker bridged network)
2016-01-08 20:26:02 +02:00
Rolf Ahrenberg
c1a881ba94 Reorder also terrestrial and cable query parameters as introduced in the satip specification 1.2.2, although the ordering shouldn't matter according to it. 2016-01-08 20:25:44 +02:00
Tobias Grimm
165fd5b14a Reorderd the transponder URL parameter in a way the Panasonic CXW804 expects them
(src/freq/pol/ro/msys/mtype/plts/sr/fec)

This only applies to DVB-S. DVB-C and DVB-T might need further tweaking.
It's actually a bug of the Panasonic TV to expect the transponder parameters in
a specific order in the query string, but for now this seems to be the most
pragmatic workaround.
2016-01-08 20:25:04 +02:00
12 changed files with 70 additions and 144 deletions

42
HISTORY
View File

@@ -165,45 +165,3 @@ VDR Plugin 'satip' Revision History
- Added support for FRITZ!Box 6490 Cable (Thanks to 9000h).
- Updated FRITZ!WLAN Repeater DVB-C detection for the latest firmware (Thanks to 9000h).
- Added GCC7 compatibility (Thanks to Sascha Kuehndel).
===================================
VDR Plugin 'satip' Revision History
===================================
2016-12-18: Version 2.3.0
- Updated for vdr-2.3.1.
- Updated German translation (Thanks to Frank Neumann).
- Fixed Panasonic CXW804 support (Thanks to Tobias Grimm).
- Fixed C++11 support (Thanks to Tobias Grimm).
- Fixed server assigment with source validation (Thanks to Patrick Boettcher).
- Added configurable RTP/RTCP ports (Thanks to chriszero).
- Added support for X-SATIP-RTSP-Port header.
- Added multicast and RTP-over-TCP support.
- Added support for activating/deactivating server on-the-fly.
- Extended command-line parameters for setting server quirks.
2017-08-15: Version 2.3.1
- Updated for vdr-2.3.7 (Thanks to Klaus Schmidinger).
- Added Polish translation (Thanks to Tomasz Nowak).
- Updated Catalan and Spanish translations (Thanks to Gabriel Bonich).
- Added support for KATHREIN SatIP Server (Thanks to kavanu).
- Added support for FRITZ!Box 6490 Cable (Thanks to 9000h).
- Updated FRITZ!WLAN Repeater DVB-C detection for the latest firmware (Thanks to 9000h).
- Added GCC7 compatibility (Thanks to Sascha Kuehndel).
===================================
VDR Plugin 'satip' Revision History
===================================
2018-04-15: Version 2.4.0
- Updated for vdr-2.4.0.
- Removed speed limit.
- Fixed transport media changes.
- Fixed memory leak in cSatipSectionFilter (Thanks to Alexander Pipelka).
- Added more robust section filter handling (Thanks to Alexander Pipelka).
- Added a command line parameter for the RTP receive buffer size (Thanks to Stefan Rehm).

View File

@@ -88,15 +88,14 @@ all: $(SOFILE) i18n
### Implicit rules:
%.o: %.c
@echo CC $@
$(Q)$(CXX) $(CXXFLAGS) -c $(DEFINES) $(INCLUDES) -o $@ $<
$(CXX) $(CXXFLAGS) -c $(DEFINES) $(INCLUDES) -o $@ $<
### Dependencies:
MAKEDEP = $(CXX) -MM -MG
DEPFILE = .dependencies
$(DEPFILE): Makefile
$(Q)$(MAKEDEP) $(CXXFLAGS) $(DEFINES) $(INCLUDES) $(OBJS:%.o=%.c) > $@
@$(MAKEDEP) $(CXXFLAGS) $(DEFINES) $(INCLUDES) $(OBJS:%.o=%.c) > $@
-include $(DEPFILE)
@@ -109,21 +108,17 @@ I18Nmsgs = $(addprefix $(DESTDIR)$(LOCDIR)/, $(addsuffix /LC_MESSAGES/vdr-$(PLU
I18Npot = $(PODIR)/$(PLUGIN).pot
%.mo: %.po
@echo MO $@
$(Q)msgfmt -c -o $@ $<
msgfmt -c -o $@ $<
$(I18Npot): $(wildcard *.c)
@echo GT $@
$(Q)xgettext -C -cTRANSLATORS --no-wrap --no-location -k -ktr -ktrNOOP --package-name=vdr-$(PLUGIN) --package-version=$(VERSION) --msgid-bugs-address='<see README>' -o $@ `ls $^`
xgettext -C -cTRANSLATORS --no-wrap --no-location -k -ktr -ktrNOOP --package-name=vdr-$(PLUGIN) --package-version=$(VERSION) --msgid-bugs-address='<see README>' -o $@ `ls $^`
%.po: $(I18Npot)
@echo PO $@
$(Q)msgmerge -U --no-wrap --no-location --backup=none -q -N $@ $<
msgmerge -U --no-wrap --no-location --backup=none -q -N $@ $<
@touch $@
$(I18Nmsgs): $(DESTDIR)$(LOCDIR)/%/LC_MESSAGES/vdr-$(PLUGIN).mo: $(PODIR)/%.mo
@echo IN $@
$(Q)install -D -m644 $< $@
install -D -m644 $< $@
.PHONY: i18n
i18n: $(I18Nmo) $(I18Npot)
@@ -133,13 +128,11 @@ install-i18n: $(I18Nmsgs)
### Targets:
$(SOFILE): $(OBJS)
@echo LD $@
$(Q)$(CXX) $(CXXFLAGS) $(LDFLAGS) -shared $(OBJS) $(LIBS) -o $@
$(Q)$(STRIP) $@
$(CXX) $(CXXFLAGS) $(LDFLAGS) -shared $(OBJS) $(LIBS) -o $@
@$(STRIP) $@
install-lib: $(SOFILE)
@echo IN $(DESTDIR)$(LIBDIR)/$^.$(APIVERSION)
$(Q)install -D $^ $(DESTDIR)$(LIBDIR)/$^.$(APIVERSION)
install -D $^ $(DESTDIR)$(LIBDIR)/$^.$(APIVERSION)
install-conf:
@mkdir -p $(DESTDIR)$(CFGDIR)/plugins/$(PLUGIN)
@@ -160,4 +153,4 @@ clean:
.PHONY: cppcheck
cppcheck:
$(Q)cppcheck --language=c++ --enable=all -v -f $(OBJS:%.o=%.c)
@cppcheck --language=c++ --enable=all -v -f $(OBJS:%.o=%.c)

View File

@@ -19,9 +19,8 @@ cMutex cSatipDevice::mutexS = cMutex();
cSatipDevice::cSatipDevice(unsigned int indexP)
: deviceIndexM(indexP),
bytesDeliveredM(0),
isPacketDeliveredM(false),
isOpenDvrM(false),
checkTsBufferM(false),
deviceNameM(*cString::sprintf("%s %d", *DeviceType(), deviceIndexM)),
channelM(),
createdM(0),
@@ -108,8 +107,12 @@ cString cSatipDevice::GetSatipStatus(void)
bool live = (device == cDevice::ActualDevice());
bool lock = device->HasLock();
const cChannel *channel = device->GetCurrentlyTunedTransponder();
#if defined(APIVERSNUM) && APIVERSNUM >= 20301
LOCK_TIMERS_READ;
for (const cTimer *timer = Timers->First(); timer; timer = Timers->Next(timer)) {
#else
for (cTimer *timer = Timers.First(); timer; timer = Timers.Next(timer)) {
#endif
if (timer->Recording()) {
cRecordControl *control = cRecordControls::GetRecordControl(timer);
if (control && control->Device() == device)
@@ -138,14 +141,20 @@ cString cSatipDevice::GetSatipStatus(void)
cString cSatipDevice::GetGeneralInformation(void)
{
debug16("%s [device %u]", __PRETTY_FUNCTION__, deviceIndexM);
#if defined(APIVERSNUM) && APIVERSNUM >= 20301
LOCK_CHANNELS_READ;
#endif
return cString::sprintf("SAT>IP device: %d\nCardIndex: %d\nStream: %s\nSignal: %s\nStream bitrate: %s\n%sChannel: %s\n",
deviceIndexM, CardIndex(),
pTunerM ? *pTunerM->GetInformation() : "",
pTunerM ? *pTunerM->GetSignalStatus() : "",
pTunerM ? *pTunerM->GetTunerStatistic() : "",
*GetBufferStatistic(),
#if defined(APIVERSNUM) && APIVERSNUM >= 20301
*Channels->GetByNumber(cDevice::CurrentChannel())->ToText());
#else
*Channels.GetByNumber(cDevice::CurrentChannel())->ToText());
#endif
}
cString cSatipDevice::GetPidsInformation(void)
@@ -216,21 +225,6 @@ bool cSatipDevice::AvoidRecording(void) const
return SatipConfig.IsOperatingModeLow();
}
bool cSatipDevice::SignalStats(int &Valid, double *Strength, double *Cnr, double *BerPre, double *BerPost, double *Per, int *Status) const
{
debug16("%s [device %u]", __PRETTY_FUNCTION__, deviceIndexM);
Valid = DTV_STAT_VALID_NONE;
if (Strength && pTunerM) {
*Strength = pTunerM->SignalStrengthDBm();
Valid |= DTV_STAT_VALID_STRENGTH;
}
if (Status) {
*Status = HasLock() ? (DTV_STAT_HAS_SIGNAL | DTV_STAT_HAS_CARRIER | DTV_STAT_HAS_VITERBI | DTV_STAT_HAS_SYNC | DTV_STAT_HAS_LOCK) : DTV_STAT_HAS_NONE;
Valid |= DTV_STAT_VALID_STATUS;
}
return Valid != DTV_STAT_VALID_NONE;
}
int cSatipDevice::SignalStrength(void) const
{
debug16("%s [device %u]", __PRETTY_FUNCTION__, deviceIndexM);
@@ -425,7 +419,7 @@ void cSatipDevice::CloseFilter(int handleP)
bool cSatipDevice::OpenDvr(void)
{
debug9("%s [device %u]", __PRETTY_FUNCTION__, deviceIndexM);
bytesDeliveredM = 0;
isPacketDeliveredM = false;
tsBufferM->Clear();
if (pTunerM)
pTunerM->Open();
@@ -511,17 +505,13 @@ bool cSatipDevice::IsIdle(void)
return !Receiving();
}
uchar *cSatipDevice::GetData(int *availableP, bool checkTsBuffer)
uchar *cSatipDevice::GetData(int *availableP)
{
debug16("%s [device %u]", __PRETTY_FUNCTION__, deviceIndexM);
if (isOpenDvrM && tsBufferM) {
int count = 0;
if (bytesDeliveredM) {
tsBufferM->Del(bytesDeliveredM);
bytesDeliveredM = 0;
}
if (checkTsBuffer && tsBufferM->Available() < TS_SIZE)
return NULL;
if (isPacketDeliveredM)
SkipData(TS_SIZE);
uchar *p = tsBufferM->Get(count);
if (p && count >= TS_SIZE) {
if (*p != TS_SYNC_BYTE) {
@@ -535,7 +525,7 @@ uchar *cSatipDevice::GetData(int *availableP, bool checkTsBuffer)
info("Skipped %d bytes to sync on TS packet", count);
return NULL;
}
bytesDeliveredM = TS_SIZE;
isPacketDeliveredM = true;
if (availableP)
*availableP = count;
// Update pid statistics
@@ -549,7 +539,8 @@ uchar *cSatipDevice::GetData(int *availableP, bool checkTsBuffer)
void cSatipDevice::SkipData(int countP)
{
debug16("%s [device %u]", __PRETTY_FUNCTION__, deviceIndexM);
bytesDeliveredM = countP;
tsBufferM->Del(countP);
isPacketDeliveredM = false;
// Update buffer statistics
AddBufferStatistic(countP, tsBufferM->Available());
}
@@ -563,12 +554,11 @@ bool cSatipDevice::GetTSPacket(uchar *&dataP)
if (cCamSlot *cs = CamSlot()) {
if (cs->WantsTsData()) {
int available;
dataP = GetData(&available, checkTsBufferM);
if (!dataP)
available = 0;
dataP = cs->Decrypt(dataP, available);
SkipData(available);
checkTsBufferM = dataP != NULL;
dataP = GetData(&available);
if (dataP) {
dataP = cs->Decrypt(dataP, available);
SkipData(available);
}
return true;
}
}

View File

@@ -32,9 +32,8 @@ private:
eTuningTimeoutMs = 1000 // in milliseconds
};
unsigned int deviceIndexM;
int bytesDeliveredM;
bool isPacketDeliveredM;
bool isOpenDvrM;
bool checkTsBufferM;
cString deviceNameM;
cChannel channelM;
cRingBufferLinear *tsBufferM;
@@ -65,7 +64,6 @@ public:
virtual cString DeviceType(void) const;
virtual cString DeviceName(void) const;
virtual bool AvoidRecording(void) const;
virtual bool SignalStats(int &Valid, double *Strength = NULL, double *Cnr = NULL, double *BerPre = NULL, double *BerPost = NULL, double *Per = NULL, int *Status = NULL) const;
virtual int SignalStrength(void) const;
virtual int SignalQuality(void) const;
@@ -85,7 +83,7 @@ protected:
// for recording
private:
uchar *GetData(int *availableP = NULL, bool checkTsBuffer = false);
uchar *GetData(int *availableP = NULL);
void SkipData(int countP);
protected:
@@ -101,7 +99,7 @@ public:
// for transponder lock
public:
virtual bool HasLock(int timeoutMsP = 0) const;
virtual bool HasLock(int timeoutMsP) const;
// for common interface
public:

View File

@@ -1,14 +1,14 @@
# VDR plugin language source file.
# Copyright (C) 2007-2018 Rolf Ahrenberg
# Copyright (C) 2007-2017 Rolf Ahrenberg
# This file is distributed under the same license as the satip package.
# Gabriel Bonich, 2014-2017
#
msgid ""
msgstr ""
"Project-Id-Version: vdr-satip 2.4.0\n"
"Project-Id-Version: vdr-satip 2.2.5\n"
"Report-Msgid-Bugs-To: <see README>\n"
"POT-Creation-Date: 2018-04-15 04:15+0300+0300\n"
"PO-Revision-Date: 2018-04-15 04:15+0300+0300\n"
"POT-Creation-Date: 2017-08-15 08:15+0300\n"
"PO-Revision-Date: 2017-08-15 08:15+0300\n"
"Last-Translator: Gabriel Bonich <gbonich@gmail.com>\n"
"Language-Team: Catalan <vdr@linuxtv.org>\n"
"Language: ca\n"

View File

@@ -1,14 +1,14 @@
# VDR plugin language source file.
# Copyright (C) 2007-2018 Rolf Ahrenberg
# Copyright (C) 2007-2017 Rolf Ahrenberg
# This file is distributed under the same license as the satip package.
# Frank Neumann, 2014-2017
#
msgid ""
msgstr ""
"Project-Id-Version: vdr-satip 2.4.0\n"
"Project-Id-Version: vdr-satip 2.2.5\n"
"Report-Msgid-Bugs-To: <see README>\n"
"POT-Creation-Date: 2018-04-15 04:15+0300+0300\n"
"PO-Revision-Date: 2018-04-15 04:15+0300+0300\n"
"POT-Creation-Date: 2017-08-15 08:15+0300\n"
"PO-Revision-Date: 2017-08-15 08:15+0300\n"
"Last-Translator: Frank Neumann <fnu@yavdr.org>\n"
"Language-Team: German <vdr@linuxtv.org>\n"
"Language: de\n"

View File

@@ -1,14 +1,14 @@
# VDR plugin language source file.
# Copyright (C) 2007-2018 Rolf Ahrenberg
# Copyright (C) 2007-2017 Rolf Ahrenberg
# This file is distributed under the same license as the satip package.
# Gabriel Bonich, 2014-2017
#
msgid ""
msgstr ""
"Project-Id-Version: vdr-satip 2.4.0\n"
"Project-Id-Version: vdr-satip 2.2.5\n"
"Report-Msgid-Bugs-To: <see README>\n"
"POT-Creation-Date: 2018-04-15 04:15+0300+0300\n"
"PO-Revision-Date: 2018-04-15 04:15+0300+0300\n"
"POT-Creation-Date: 2017-08-15 08:15+0300\n"
"PO-Revision-Date: 2017-08-15 08:15+0300\n"
"Last-Translator: Gabriel Bonich <gbonich@gmail.com>\n"
"Language-Team: Spanish <vdr@linuxtv.org>\n"
"Language: es\n"

View File

@@ -1,14 +1,14 @@
# VDR plugin language source file.
# Copyright (C) 2007-2018 Rolf Ahrenberg
# Copyright (C) 2007-2017 Rolf Ahrenberg
# This file is distributed under the same license as the satip package.
# Rolf Ahrenberg, 2015-2017
#
msgid ""
msgstr ""
"Project-Id-Version: vdr-satip 2.4.0\n"
"Project-Id-Version: vdr-satip 2.2.5\n"
"Report-Msgid-Bugs-To: <see README>\n"
"POT-Creation-Date: 2018-04-15 04:15+0300+0300\n"
"PO-Revision-Date: 2018-04-15 04:15+0300+0300\n"
"POT-Creation-Date: 2017-08-15 08:15+0300\n"
"PO-Revision-Date: 2017-08-15 08:15+0300\n"
"Last-Translator: Rolf Ahrenberg\n"
"Language-Team: Finnish <vdr@linuxtv.org>\n"
"Language: fi\n"

View File

@@ -1,14 +1,14 @@
# VDR plugin language source file.
# Copyright (C) 2007-2018 Rolf Ahrenberg
# Copyright (C) 2007-2017 Rolf Ahrenberg
# This file is distributed under the same license as the vdr-satip package.
# Tomasz Maciej Nowak, 2017
#
msgid ""
msgstr ""
"Project-Id-Version: vdr-satip 2.4.0\n"
"Project-Id-Version: vdr-satip 2.2.5\n"
"Report-Msgid-Bugs-To: <see README>\n"
"POT-Creation-Date: 2018-04-15 04:15+0300+0300\n"
"PO-Revision-Date: 2018-04-15 04:15+0300+0300\n"
"POT-Creation-Date: 2017-08-15 08:15+0300\n"
"PO-Revision-Date: 2017-08-15 08:15+0300\n"
"Last-Translator: Tomasz Maciej Nowak <tomek_n@o2.pl>\n"
"Language-Team: Polish <vdr@linuxtv.org>\n"
"Language: pl_PL\n"

View File

@@ -20,15 +20,15 @@
#warning "CURL version >= 7.36.0 is recommended"
#endif
#if defined(APIVERSNUM) && APIVERSNUM < 20400
#error "VDR-2.4.0 API version or greater is required!"
#if defined(APIVERSNUM) && APIVERSNUM < 20200
#error "VDR-2.2.0 API version or greater is required!"
#endif
#ifndef GITVERSION
#define GITVERSION ""
#endif
const char VERSION[] = "2.4.0" GITVERSION;
const char VERSION[] = "2.2.5" GITVERSION;
static const char DESCRIPTION[] = trNOOP("SAT>IP Devices");
class cPluginSatip : public cPlugin {

12
tuner.c
View File

@@ -40,7 +40,6 @@ cSatipTuner::cSatipTuner(cSatipDeviceIf &deviceP, unsigned int packetLenP)
externalStateM(),
timeoutM(eMinKeepAliveIntervalMs),
hasLockM(false),
signalStrengthDBmM(0.0),
signalStrengthM(-1),
signalQualityM(-1),
frontendIdM(-1),
@@ -136,7 +135,6 @@ void cSatipTuner::Action(void)
// Quirk for devices without valid reception data
if (currentServerM.IsQuirk(cSatipServer::eSatipQuirkForceLock)) {
hasLockM = true;
signalStrengthDBmM = eDefaultSignalStrengthDBm;
signalStrengthM = eDefaultSignalStrength;
signalQualityM = eDefaultSignalQuality;
}
@@ -266,7 +264,6 @@ bool cSatipTuner::Disconnect(void)
// Reset signal parameters
hasLockM = false;
signalStrengthDBmM = 0.0;
signalStrengthM = -1;
signalQualityM = -1;
frontendIdM = -1;
@@ -336,9 +333,8 @@ void cSatipTuner::ProcessApplicationData(u_char *bufferP, int lengthP)
// No signal corresponds to 0
c = strstr(c, ",");
value = min(atoi(++c), 255);
signalStrengthDBmM = (value >= 0) ? 40.0 * (value - 32) / 192.0 - 65.0 : 0.0;
// Scale value to 0-100
signalStrengthM = (value >= 0) ? value * 100 / 255 : -1;
signalStrengthM = (value >= 0) ? (value * 100 / 255) : -1;
// lock:
// lock Set to one of the following values:
@@ -674,12 +670,6 @@ int cSatipTuner::SignalStrength(void)
return signalStrengthM;
}
double cSatipTuner::SignalStrengthDBm(void)
{
debug16("%s [device %d]", __PRETTY_FUNCTION__, deviceIdM);
return signalStrengthDBmM;
}
int cSatipTuner::SignalQuality(void)
{
debug16("%s [device %d]", __PRETTY_FUNCTION__, deviceIdM);

23
tuner.h
View File

@@ -78,17 +78,16 @@ class cSatipTuner : public cThread, public cSatipTunerStatistics, public cSatipT
{
private:
enum {
eDummyPid = 100,
eDefaultSignalStrengthDBm = -25,
eDefaultSignalStrength = 224,
eDefaultSignalQuality = 15,
eSleepTimeoutMs = 250, // in milliseconds
eStatusUpdateTimeoutMs = 1000, // in milliseconds
ePidUpdateIntervalMs = 250, // in milliseconds
eConnectTimeoutMs = 5000, // in milliseconds
eIdleCheckTimeoutMs = 15000, // in milliseconds
eTuningTimeoutMs = 20000, // in milliseconds
eMinKeepAliveIntervalMs = 30000 // in milliseconds
eDummyPid = 100,
eDefaultSignalStrength = 15,
eDefaultSignalQuality = 224,
eSleepTimeoutMs = 250, // in milliseconds
eStatusUpdateTimeoutMs = 1000, // in milliseconds
ePidUpdateIntervalMs = 250, // in milliseconds
eConnectTimeoutMs = 5000, // in milliseconds
eIdleCheckTimeoutMs = 15000, // in milliseconds
eTuningTimeoutMs = 20000, // in milliseconds
eMinKeepAliveIntervalMs = 30000 // in milliseconds
};
enum eTunerState { tsIdle, tsRelease, tsSet, tsTuned, tsLocked };
enum eStateMode { smInternal, smExternal };
@@ -116,7 +115,6 @@ private:
cVector<eTunerState> externalStateM;
int timeoutM;
bool hasLockM;
double signalStrengthDBmM;
int signalStrengthM;
int signalQualityM;
int frontendIdM;
@@ -151,7 +149,6 @@ public:
bool Close(void);
int FrontendId(void);
int SignalStrength(void);
double SignalStrengthDBm(void);
int SignalQuality(void);
bool HasLock(void);
cString GetSignalStatus(void);