FernetMenta / vdr-plugin-vnsiserver

VDR plugin to handle XBMC clients.
GNU General Public License v2.0
16 stars 33 forks source link

cParser::AddPESPacket Buffer size to small #55

Closed Karl-opec closed 8 years ago

Karl-opec commented 8 years ago

I found following Messages after each channel switch in my logs:

VNSI-Error: cParser::AddPESPacket - max buffer size reached

I increased in the code the plain Number: 1000000 to 5000000

[code] if (m_PesBufferPtr + size >= m_PesBufferSize) { if (m_PesBufferPtr + size >= 1000000) { ERRORLOG("cParser::AddPESPacket - max buffer size reached, pid: %d", m_pID); Reset(); return false; } [/code]

and these Messages are gone.

I don't really understand the code but with this change the short picture disturbance after channel switch is gone.

Perhaps other methods defining the size address the issue better. FernetMenta might have a look.

FernetMenta commented 8 years ago

is it all channels or just particular ones? Where are you located? I am wondering why others like myself do not observe this issue.

Karl-opec commented 8 years ago

Channel which are scrambled show this during switching: [code] 2016-06-09T12:19:03.316630+02:00 vnas vdr: [24779] VNSI: Successfully found following device: 0x126c840 (1) for receiving 2016-06-09T12:19:03.316794+02:00 vnas vdr: [24779] VNSI: activate live receiver: 1, pmt change: 1 2016-06-09T12:19:03.366625+02:00 vnas vdr: [24779] VNSI: Successfully switched to channel 31 - SyFy HD 2016-06-09T12:19:03.366771+02:00 vnas vdr: [24779] VNSI: Started streaming of channel SyFy HD (timeout 10 seconds) 2016-06-09T12:19:03.918067+02:00 vnas vdr: [25044] VNSI: Created stream for pid=543 and type=8 2016-06-09T12:19:03.918249+02:00 vnas vdr: [25044] VNSI: Created stream for pid=544 and type=1 2016-06-09T12:19:03.918368+02:00 vnas vdr: [25044] VNSI: Created stream for pid=545 and type=1 2016-06-09T12:19:05.463999+02:00 vnas vdr: [25044] VNSI-Error: cParser::AddPESPacket - max buffer size reached, pid: 543 2016-06-09T12:19:05.901885+02:00 vnas vdr: [24005] VNSI: re-tune to channel SyFy HD [/code]

FernetMenta commented 8 years ago

I'll have a closer look at this this weekend

FernetMenta commented 8 years ago

you multiplied max buffer size with a factor of 5. did you try a factor of 2?

Karl-opec commented 8 years ago

With 2000000 after the first switch to a scrambled channel the VNSI-Error: cParser::AddPESPacket messages is still gone, but in the kodi gui a pop up window with message "channel is scrambled" is shown. But the descrambled stream is show.

ivanmara555 commented 8 years ago

I have the same problem with message: VNSI-Error: cParser::AddPESPacket - max buffer size reached in log file after switching every DVB-S2 (mpeg4, h.264) encrypted channel on Eutelsat 36 satellite. In the Kodi gui a pop up window with message "Channel is scrambled" is shown. Accordingly, I can not watch these channels. But DVB-S encrypted channels working good. It's not hardware or firmware problem because on the same system xvdr plugin (xvdr + vdr + oscam) working excellent. Problem only with vnsi + vdr + oscam.

AndreyPavlenko commented 8 years ago

I'm getting the same error occasionally. In general it works, but sometimes this error occurs and the playback brakes until restarted.

FernetMenta commented 8 years ago

are you running v1.5 from master branch?

AndreyPavlenko commented 8 years ago

Yes. I use the plugin from this ppa - https://launchpad.net/~aap/+archive/ubuntu/vdr/+packages?field.name_filter=&field.status_filter=published&field.series_filter=xenial.

FernetMenta commented 8 years ago

could you please test with current master? there is a new setting that allows you to disable vdr's scramble timeout.

AndreyPavlenko commented 8 years ago

The package is built from 51a0882. As I see, this is the current master.

AndreyPavlenko commented 8 years ago

Do you mean this one - vnsiserver.DisableScrambleTimeout = 1?

FernetMenta commented 8 years ago

yes, easiest method to change it is by using VDR ui available via client specific settings in Kodi. When using the UI, you can't make typos.

AndreyPavlenko commented 8 years ago

Thanks, I've changed this setting and will let you know if the error occurs. Btw, I've just noticed another issue. I've created a few groups in channels.conf. I can see these new groups in streamdev but not in vnsi. I've reset pvr and restarted kodi a few times but the groups have not appeared, I've only the provider names instead of my groups. Does vnsi preserve the vdr groups?

FernetMenta commented 8 years ago

@AndreyPavlenko please open a new thread for a new topic next time.

Does vnsi preserve the vdr groups?

Yes it does, provided you have set Kodi PVR to sync backend channels groups (PVR setting).

AndreyPavlenko commented 8 years ago

Seems I've understood where the issue is.

My new groups contain duplicates. Here is a short example:

:~HTB+~ EUROSPORT 1 HD;HTB+:12207:vC34M5O35S1:S36.0E:27500:301=27:401=rus@4,421=eng@4:0:500:26001:112:9:0

:Sport EUROSPORT 1 HD;HTB+:12207:vC34M5O35S1:S36.0E:27500:301=27:401=rus@4,421=eng@4:0:500:26001:112:9:1

The first group is the provider name and it contains all channels of this provider. The second group contains only the sport channels from the first group. But, these channels have a different RID - https://linuxtv.org/vdrwiki/index.php/Syntax_of_channels.conf#RID. In terms of vdr these are not duplicates, but vnsi, seems, consider these channels as duplicates and ignores them.

FernetMenta commented 8 years ago

@AndreyPavlenko please stay focused on the original topic. Open a new issue for new topics.

AndreyPavlenko commented 8 years ago

Sure. I just wanted to clarify if it should work. I'll open a new issue.

FernetMenta commented 8 years ago

should be solved by linked issue