New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Cwc/Capmt changes #416
Cwc/Capmt changes #416
Conversation
|
Great work! So ... to have a smooth transition plan I believe that any oscam dvbapi client which is using a TCP mode should create a similar check for some time. After this to have things clean we need to add htonl() htons() in the OSCam, and finally remove this workaround-checks in the clients. Otherwise we would have a tons of reports that it suddenly stopped working. |
|
The second capmt code update was pushed. Everything should be improved (and maybe broken). Note that I fould another issue in oscam which is reported in http://www.streamboard.tv/oscam/ticket/3758 . The code from ticked 3753 was already applied to oscam svn (revision 9754). EDIT: The patch from ticket 3758 was applied as oscam revision 9760. |
|
@manio : Thanks. I do also this endian conversion in cf9163b . But in your code - I would swap the bytes - perhaps using __bswap32() or own macro. htonl() will work only for the little endian system. If the vdr is running on the big endian system (versus a little endian server) - there is no byte swap in htonl(). |
|
@perexg |
- capmt code was a bit restructured again
|
I added another two commit to open/close the required PIDs on demand for both ECM and EMM sections. |
- also change the capmt locking (get most of job outside global lock)
|
@perexg Could you please post an example setup/configuration for oscam and tvheadend? Edit: Oops, I just saw thats its not yet merged to master. Nevertheless documentation is always good :-) Edit2: Okay okay, I think I got it :-) Edit3: Works great so far 👍 |
|
Rebased and merged to the master git tree. |
|
After try compilation after mereged: CC src/descrambler/ffdecsa/ffdecsa_mmx.o |
|
@PiterEL : Try latest master branch. I hope that the commit 6fc3a46 will fix this issue for you. |
|
@perexg I get a strange issue using CAMPT with mode 3 / IP: Recording scrambled SD channel works, recordings HD channels doesn't, streaming the same HD channel works fine. Full log (descrambling,cwc,campt) here https://drive.google.com/file/d/0B0-Pum1Hxr6eSkVJRHFPUnJ5VDQ/edit?usp=sharing (50 MB) |
|
@crarrie: It seems that oscam does not send keys for some situations. You may also check the oscam log with the 128 debug level. EDIT: It seems that the "fails" are also when there are 2 simultaneous sessions (dvr + streaming?). Not sure if it's related, but may be.. You may verify this by stream 2 different HD channels together. |
|
@perexg Confirmed: I opened 2 vlc instances A and B. One A i streamed a scrambled HD channel without problems. On B I started a second scrambled HD channel... but no luck! I tried another HD channel on VLC instance B but without luck. I stopped A and retried streaming with B, but no luck. I stopped B. I restarted A and it works. Log is at https://drive.google.com/file/d/0B0-Pum1Hxr6eVkNXNmJNNjVmRDQ/edit?usp=sharing EDIT1: after some minutes, A and B stopped, A starts working. EDIT2: does Tvheadend request for keys? It seems not in some cases (Only one request for Key in Oscam and then no more requests...) EDIT3: I get a campt message on unscrambled HD channels EDIT4: I switched now back to cwc, now I get following in oscam log: It seems sometimes to work on channels with one CAID (0500). If you need further infos/access just ask here (with correct username ;-)) |
|
@ckarrie: I'm a bit lost, please, provide logs for a simple case to verify. Run A for 60 seconds, then add B for next 60 seconds (assuming that B is not decoded) and shut down tvheadend. Also grab the oscam log for dvbapi simultaneously. For cwc - I need the tvheadend log. EDIT: But, please, try to cut only log for time you tried to decode the problematic channel. |
|
@perexg No more 50 MB Logs? Okay okay ;-) Stay tuned. |
|
@perexg Here we go: Note to Oscam: all real cards, no proxies! Case 1: campt, A= 1 scrambled HD channel, B= 1 unscrambled HD Channel
Case 2: campt, A= 1 scrambled HD channel (recording), B= 1 scrambled HD Channel, C= 1 scrambled HD Channel
Case 3: cwc, A= 1 scrambled HD channel, B= 1 unscrambled HD Channel
Case 4: cwc, A= 1 scrambled HD channel, B= 1 scrambled HD Channel
|
|
@perexg Wow cool, this fixed Case 2! I think all issues fixed :-) Thank you a lot. |
|
Just a note: I found another issue which affects the capmt 'mode 3' and 'mode 4' in oscam . The patch is in ticket # 3768 : http://www.streamboard.tv/oscam/ticket/3768 . EDIT: The patch is in oscam - r9765 . |
|
@perexg Hi perexg, Tvheadend just crashed with following "message":
Followed by Using version 3.9.920~ga78c1c7 |
|
@ckarrie : A fix is in the current git master tree. |
|
@perexg Thank you! I give it a try! |

Some changes are cleanups for the descramler.
A support for the TCP mode was added to the capmt client (mode 3). Also, another mode 4 was introduced (for the camd.socket) - required patches oscam with http://www.streamboard.tv/oscam/ticket/3753 . I think that I fixed also some errors for mode 2. The capmt code requires more updates:
Other parts of descrambler should be also improved: