mirror of
https://github.com/rofafor/vdr-plugin-satip.git
synced 2023-10-10 13:37:42 +02:00
Updated the server info message to show used quirks.
This commit is contained in:
parent
73ed299ed9
commit
3e4b1c0383
@ -242,7 +242,7 @@ void cSatipDiscover::AddServer(const char *addrP, const char *modelP, const char
|
|||||||
cString desc = cString::sprintf("%s #%d", !isempty(descP) ? descP : "MyBrokenHardware", n++);
|
cString desc = cString::sprintf("%s #%d", !isempty(descP) ? descP : "MyBrokenHardware", n++);
|
||||||
cSatipServer *tmp = new cSatipServer(addrP, r, desc);
|
cSatipServer *tmp = new cSatipServer(addrP, r, desc);
|
||||||
if (!serversM.Update(tmp)) {
|
if (!serversM.Update(tmp)) {
|
||||||
info("Adding server '%s|%s|%s'%s%s", tmp->Address(), tmp->Model(), tmp->Description(), tmp->HasCI() ? " providing CI" : "", tmp->HasQuirk() ? " (malfunctioning firmware!)" : "");
|
info("Adding server '%s|%s|%s' CI: %s Quirks: %s", tmp->Address(), tmp->Model(), tmp->Description(), tmp->HasCI() ? "yes" : "no", tmp->HasQuirk() ? tmp->Quirks() : "none");
|
||||||
serversM.Add(tmp);
|
serversM.Add(tmp);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
@ -254,7 +254,7 @@ void cSatipDiscover::AddServer(const char *addrP, const char *modelP, const char
|
|||||||
else {
|
else {
|
||||||
cSatipServer *tmp = new cSatipServer(addrP, modelP, descP);
|
cSatipServer *tmp = new cSatipServer(addrP, modelP, descP);
|
||||||
if (!serversM.Update(tmp)) {
|
if (!serversM.Update(tmp)) {
|
||||||
info("Adding server '%s|%s|%s'%s%s", tmp->Address(), tmp->Model(), tmp->Description(), tmp->HasCI() ? " providing CI" : "", tmp->HasQuirk() ? " (malfunctioning firmware!)" : "");
|
info("Adding server '%s|%s|%s' CI: %s Quirks: %s", tmp->Address(), tmp->Model(), tmp->Description(), tmp->HasCI() ? "yes" : "no", tmp->HasQuirk() ? tmp->Quirks() : "none");
|
||||||
serversM.Add(tmp);
|
serversM.Add(tmp);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
|
16
server.c
16
server.c
@ -72,29 +72,37 @@ cSatipServer::cSatipServer(const char *addressP, const char *modelP, const char
|
|||||||
: addressM((addressP && *addressP) ? addressP : "0.0.0.0"),
|
: addressM((addressP && *addressP) ? addressP : "0.0.0.0"),
|
||||||
modelM((modelP && *modelP) ? modelP : "DVBS-1"),
|
modelM((modelP && *modelP) ? modelP : "DVBS-1"),
|
||||||
descriptionM(!isempty(descriptionP) ? descriptionP : "MyBrokenHardware"),
|
descriptionM(!isempty(descriptionP) ? descriptionP : "MyBrokenHardware"),
|
||||||
|
quirksM(""),
|
||||||
quirkM(eSatipQuirkNone),
|
quirkM(eSatipQuirkNone),
|
||||||
hasCiM(false),
|
hasCiM(false),
|
||||||
createdM(time(NULL)),
|
createdM(time(NULL)),
|
||||||
lastSeenM(0)
|
lastSeenM(0)
|
||||||
{
|
{
|
||||||
if (!SatipConfig.GetDisableServerQuirks()) {
|
if (!SatipConfig.GetDisableServerQuirks()) {
|
||||||
debug3("%s quirks=%s", __PRETTY_FUNCTION__, *descriptionM);
|
|
||||||
// These devices contain a session id bug:
|
// These devices contain a session id bug:
|
||||||
// Inverto Airscreen Server IDL 400 ?
|
// Inverto Airscreen Server IDL 400 ?
|
||||||
// Elgato EyeTV Netstream 4Sat ?
|
// Elgato EyeTV Netstream 4Sat ?
|
||||||
if (strstr(*descriptionM, "GSSBOX") || // Grundig Sat Systems GSS.box DSI 400
|
if (strstr(*descriptionM, "GSSBOX") || // Grundig Sat Systems GSS.box DSI 400
|
||||||
strstr(*descriptionM, "DIGIBIT") || // Telestar Digibit R1
|
strstr(*descriptionM, "DIGIBIT") || // Telestar Digibit R1
|
||||||
strstr(*descriptionM, "Triax SatIP Converter") // Triax TSS 400
|
strstr(*descriptionM, "Triax SatIP Converter") // Triax TSS 400
|
||||||
)
|
) {
|
||||||
quirkM |= eSatipQuirkSessionId;
|
quirkM |= eSatipQuirkSessionId;
|
||||||
|
quirksM = cString::sprintf("%s%sSessionId", *quirksM, isempty(*quirksM) ? "" : ",");
|
||||||
|
}
|
||||||
// These devices contain a play (add/delpids) parameter bug:
|
// These devices contain a play (add/delpids) parameter bug:
|
||||||
if (strstr(*descriptionM, "fritzdvbc")) // Fritz!WLAN Repeater DVB-C
|
if (strstr(*descriptionM, "fritzdvbc") // Fritz!WLAN Repeater DVB-C
|
||||||
|
) {
|
||||||
quirkM |= eSatipQuirkPlayPids;
|
quirkM |= eSatipQuirkPlayPids;
|
||||||
|
quirksM = cString::sprintf("%s%sPlayPids", *quirksM, isempty(*quirksM) ? "" : ",");
|
||||||
|
}
|
||||||
// These devices contain a frontend locking bug:
|
// These devices contain a frontend locking bug:
|
||||||
if (strstr(*descriptionM, "fritzdvbc") || // Fritz!WLAN Repeater DVB-C
|
if (strstr(*descriptionM, "fritzdvbc") || // Fritz!WLAN Repeater DVB-C
|
||||||
strstr(*descriptionM, "Triax SatIP Converter") // Triax TSS 400
|
strstr(*descriptionM, "Triax SatIP Converter") // Triax TSS 400
|
||||||
)
|
) {
|
||||||
quirkM |= eSatipQuirkForceLock;
|
quirkM |= eSatipQuirkForceLock;
|
||||||
|
quirksM = cString::sprintf("%s%sForceLock", *quirksM, isempty(*quirksM) ? "" : ",");
|
||||||
|
}
|
||||||
|
debug3("%s description=%s quirks=%s", __PRETTY_FUNCTION__, *descriptionM, *quirksM);
|
||||||
}
|
}
|
||||||
// These devices support the X_PMT protocol extension
|
// These devices support the X_PMT protocol extension
|
||||||
if (strstr(*descriptionM, "OctopusNet")) // Digital Devices OctopusNet
|
if (strstr(*descriptionM, "OctopusNet")) // Digital Devices OctopusNet
|
||||||
|
20
server.h
20
server.h
@ -54,6 +54,7 @@ private:
|
|||||||
cString addressM;
|
cString addressM;
|
||||||
cString modelM;
|
cString modelM;
|
||||||
cString descriptionM;
|
cString descriptionM;
|
||||||
|
cString quirksM;
|
||||||
cSatipFrontends frontendsM[eSatipFrontendCount];
|
cSatipFrontends frontendsM[eSatipFrontendCount];
|
||||||
int quirkM;
|
int quirkM;
|
||||||
bool hasCiM;
|
bool hasCiM;
|
||||||
@ -80,15 +81,16 @@ public:
|
|||||||
int GetModulesDVBT2(void);
|
int GetModulesDVBT2(void);
|
||||||
int GetModulesDVBC(void);
|
int GetModulesDVBC(void);
|
||||||
int GetModulesDVBC2(void);
|
int GetModulesDVBC2(void);
|
||||||
const char *Address() { return *addressM; }
|
const char *Address(void) { return *addressM; }
|
||||||
const char *Model(void) { return *modelM; }
|
const char *Model(void) { return *modelM; }
|
||||||
const char *Description() { return *descriptionM; }
|
const char *Description(void) { return *descriptionM; }
|
||||||
bool Quirk(int quirkP) { return ((quirkP & eSatipQuirkMask) & quirkM); }
|
const char *Quirks(void) { return *quirksM; }
|
||||||
bool HasQuirk(void) { return !!quirkM; }
|
bool Quirk(int quirkP) { return ((quirkP & eSatipQuirkMask) & quirkM); }
|
||||||
bool HasCI(void) { return hasCiM; }
|
bool HasQuirk(void) { return (quirkM != eSatipQuirkNone); }
|
||||||
void Update(void) { lastSeenM.Set(); }
|
bool HasCI(void) { return hasCiM; }
|
||||||
uint64_t LastSeen(void) { return lastSeenM.Elapsed(); }
|
void Update(void) { lastSeenM.Set(); }
|
||||||
time_t Created(void) { return createdM; }
|
uint64_t LastSeen(void) { return lastSeenM.Elapsed(); }
|
||||||
|
time_t Created(void) { return createdM; }
|
||||||
};
|
};
|
||||||
|
|
||||||
// --- cSatipServers ----------------------------------------------------------
|
// --- cSatipServers ----------------------------------------------------------
|
||||||
|
Loading…
Reference in New Issue
Block a user