Comments (9)
I tried to find my way through the code and got stuck in several places.
Still I managed to add some syslog to the code to see what is going on with the constant PID changes.
I added the lines error("addpids: %s", *addPidsM.ListPids());
and error("delpids: %s", *delPidsM.ListPids());
here and here to start figuring out what is happening.
I then switched to this channel:
BBC World News Europe HD;SES ASTRA:11229:VC23M5O20P0S1:S19.2E:22000:2091=27:0;2092=@106:0:0:5001:1:1002:0
with only one device configured for the satip plugin.
I waited 10 minutes after switching to the channel and before I had the the last 5 minutes of logs written to a file via:
journalctl -u vdr.service --since "5 minutes ago"> /tmp/vdr-5m.log
Looking into the file and counting the lines containing addpids:
and delpids:
I got this:
awk '{ print substr($0, index($0,$7)) }' /tmp/vdr-5m.log|grep SATIP-ERROR|grep pids:|sort|uniq -c
81 SATIP-ERROR: addpids: 212
82 SATIP-ERROR: addpids: 3100
81 SATIP-ERROR: addpids: 5071
81 SATIP-ERROR: addpids: 96
81 SATIP-ERROR: addpids: 97
81 SATIP-ERROR: delpids: 212
82 SATIP-ERROR: delpids: 3100
81 SATIP-ERROR: delpids: 5071
81 SATIP-ERROR: delpids: 96
81 SATIP-ERROR: delpids: 97
In those 5 minutes, 406 times non-existing, PIDS were added and removed again(812 total). This causes a PID change being sent to the box every 0.37 seconds on average.
Where do those PID numbers come from? None of them seem to exist on this transponder.
Any help is greatly appreciated.
from vdr-plugin-satip.
I managed to find above mystery numbers:
Enabling debug output in pat.c of vdr itself, delivered this in the log:
Mai 23 18:34:01 server vdr[29960]: [29978] PAT 211229 -1 -> 7
Mai 23 18:34:01 server vdr[29960]: [29978] PMT pid 0 212 SID 5001
Mai 23 18:34:01 server vdr[29960]: [29978] sid = 5001 pmtIndex = 0
Mai 23 18:34:01 server vdr[29960]: [29978] PMT pid 1 96 SID 5010
Mai 23 18:34:01 server vdr[29960]: [29978] PMT pid 2 97 SID 5011
Mai 23 18:34:01 server vdr[29960]: [29978] PMT pid 3 5071 SID 5021
Mai 23 18:34:01 server vdr[29960]: [29978] PMT pid 4 3100 SID 5031
Now I "only" need to figure out if/why/where this got mixed up.
from vdr-plugin-satip.
VDR is autodetecting all the pids found in the stream and scanning them to find out new channels, transponders, epg data, etc. You can disable most of these by disabling required section filters in the plugin's setup menu, but this is how the VDR works and I don't recommend it unless some transponder is providing invalid data.
Pid updates have been limited to 250ms: https://github.com/rofafor/vdr-plugin-satip/blob/master/tuner.h#L87
from vdr-plugin-satip.
If I am not completely mistaken, then the SatIP-box does not know what to do with those IDs(212,96,97,507 & 3100). And how could it do something when they are deleted right after adding them?
Upon tuning to a new channel the vdr-plugin-satip requests a TS via SETUP command. This SETUP contains the IDs from the channels.conf. This should be everything the SatIP-box needs to know, in order to send the correct stream to VDR. If the stream-IDs change, then this must be communicated to the SatIP Box in order to be able to receive it. I believe this is the reason the addpids and delpids parameter exist. But the stream's IDs do not change here, they remain the same.
What happens here is different. As soon as VDR starts receiving the requested stream, it starts decoding the PMT. Then the vdr-plugin-satip plugin starts to send those decoded IDs to the SatIP Box via addpids
and delpids
(continuesly). If I understood things correctly then those IDs from the PMT must not be used here. (I'm confused by the naming here. There are SIDs and PIDs. I don't really know which is which. According to the debug log from pat.c, the SIDs are the values from the channels.conf, where the "mystery"-IDs are the PIDs.)
What also caught my attention, is the fact that the addition/deletion of above PIDs appears to correlate with each call to
bool cPatFilter::PmtVersionChanged(int PmtPid, int Sid, int Version, bool SetNewVersion)
in VDR's pat.c.
Something seems odd here and I'd like to figure out where these IDs come from and how to avoid adding and deleting them over and over again. But my C-knowledge is weak, and so is my understanding of VDR's internals.
My Google-foo doesn't seem to be strong enough, so any help is greatly appreciated.
from vdr-plugin-satip.
Your channels.conf contains a snapshot of pids and stream related ids. Pids are dynamic and they might change even during an event, e.g. subtitling pids are usually such ones. Now, VDR is inspecting all the time the stream detecting any changes in it and updating channels according to them - these add/del pids is business as usual. Take a look at the cPatFilter::SwitchToNextPmtPid()
in VDR's pat.c. You need to remember that you're tuning into transponder containing usually multiple channels instead of one you're looking at on your monitor.
from vdr-plugin-satip.
Disabling all the section filters in plugin's setup menu should stop the add/delpids looping as the core VDR shouldn't have nothing to parse anymore. Make sure to keep your channels.conf up to date manually afterwards.
from vdr-plugin-satip.
First of all thank you for taking the time to guide me trough this.
I'm not eager to disable the section filters. I'd like to know where the IDs come from and how to not send them to the box.
Please take a look at the pat.c debug above. It contains 5 SIDs. Those are the service-IDs for all channels on this transponder.
SID:
5001 == BBC World News Europe HD
5010 == INSIGHT TV HD
5011 == INSIGHT TV HD INT
5021 == NHK WORLD-JPN
5031 == Al Jazeera English HD
The PIDs that are constantly added and deleted are the IDs two columns before SIDs. The column containing: 212, 96, 97, 507, 3100.
I'm quite certain that they are not related to the IDs that are ment to be sent in the SETUP- or PLAY-request to the SatIP box.
What we need to send to the box (to receive "BBC World News Europe HD") are the video, audio and teletext PIDs for stream ID 5001 and transponder ID 1002. The rest must not be sent to the SatIP box.
from vdr-plugin-satip.
The plugin just implements VDR's SetPid()
interface. If VDR asks for pid 5071, the plugin delivers it back to VDR :
https://github.com/rofafor/vdr-plugin-satip/blob/master/device.h#L92
http://git.tvdr.de/?p=vdr.git;a=blob;f=device.h;h=63eef603b17b070ba8cc538ca6e8ffb19057a3e6;hb=c40fb4b4aa1f594fa94d89673d0a537bac3ec91d#l414
Now , take a look at your logs of the following altering pids (source: https://www.satindex.de/frequenz/11229/):
- 212, that's the PMT of SID 5001
- 96, that's the PMT pid of SID 5010
- 97, that's the PMT pid of SID 5011
- 5071, that's the PMT pid of SID 5021
- 3100, that's the PMT pid of SID 5031
This looks totally normal to me as VDR is just scanning through PMT pids as it should.
from vdr-plugin-satip.
The issue seems to be in VDR itself.
I got in touch with VDR's maintainer. Uncommenting 2 lines in pat.c (as a hot fix) eliminates the problem of PIDs popping in and out. But it needs some more looking into.
from vdr-plugin-satip.
Related Issues (20)
- channel switching issue HOT 66
- ClearQAM/ATSC support? HOT 3
- ERROR: SATIP poller thread HOT 5
- channel retune issue HOT 20
- missing quirk for Inverto IDL-400s HOT 4
- Reoccuring RTP errors with Octopus NET S2 V1.1.5/1.1.6 HOT 43
- Plugin uses all available tuners of AVM Fritz! box when using wirbelscan
- vdr-2.5.1 crash HOT 1
- New release? HOT 4
- question about your website HOT 1
- Glitches when switching channels HOT 6
- create satip.h HOT 4
- README/log improvements: list names of supported devices ("description"), quirks, ... HOT 2
- Plugin does not start fresh connection after Curl timeout HOT 2
- Returncode 404 from minisatip is not handled HOT 6
- Session times out on EXIP418 when timeout is equal to eMinKeepAliveIntervalMs HOT 9
- 250ms delay between commands is missing sometimes HOT 1
- plugin reports signal strength in dBm wrong to vdr, if server reports zero signal strength HOT 8
- octopus: "RTSP/1.0 455 Method Not Valid in This State" followed by vdr crash
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from vdr-plugin-satip.