Eurocardsharing

Go Back   Eurocardsharing > Sharing receivers > VDR and Kaffeine

VDR and Kaffeine Discussion, Cardsharing between multiple tunercards at Sharing receivers forum; >There is no simple way of doing this. However, it is perfectly possible to get it up and running. I ...

Reply
 
LinkBack Thread Tools Display Modes
multiple streams using sasc-ng and cccam
Old
  (#11)
djwoef
Junior Member
 
djwoef's Avatar
 
Offline
Posts: 3

Level: 1 [♥ Bé-Yêu ♥]
Life: 0 / 2
Magic: 1 / 73
Experience: 10%

Thanks: 0
Thanked 0 Times in 0 Posts
Join Date: Dec 2008
multiple streams using sasc-ng and cccam - 29-December-2008, 02:39

Quote:
>There is no simple way of doing this. However, it is perfectly possible to get it up and running.

I have mythtv with 3 tuners (dvbs).
All sharing one card in a Phoenix Cardreader.

The problem is that sasc is talking to cccam directly via the socket. Thus you
can not access that for multiple streams at once.
Hello Sas, Sis and others,

Came also across this problem and I wonder how it can be solved. Cant find a solution anywhere. I have 2 tuners in my mythtv box, one dvb-t and one dvb-s handled by sasc-ng with double -j option. I have now the problem that the first device I access in mythtv is properly decoding the channels and when switching over to the second is always failing until I restart the backend server and access the other device first.
It fails with the following errors in the logging of sasc-ng

CCcam probably has crashed or been killed...
FAILED ECM FOR CARD 0 !!!!!!!!!!!!!!!!!!
client CCcam (127.0.0.1:9000) ECM failed (3701 ms)
cc-loop
now trying client CCcam (127.0.0.1:9000)
Processing ECM.... for card 0
Writing capmt for card 0 3
CCcam probably has crashed or been killed...
Writing capmt for card 0 3
Opened camd.socket..... ccamd_fd = 12


Sis, the way you descibe this it seems that the combination of cccam and sasc-ng does not support multiple streams. This seems weird since sasc-ng supports multiple interfaces. You can for instance give option -j 0:2 -j 1:3 so it handles 2 interfaces at the same time but cccam can't handle this so this option is useless while using with cccam? Does your solution require also a second instance of sasc-ng? In case no, how do you couple your sasc-ng to the other multiple instances of cccam? Do you have multiple lines for cccam in your cardclient.conf and how do they look like?

Hope to hear from you.

Regards

Woef

Last edited by djwoef; 29-December-2008 at 02:44.. Reason: Automerged Doublepost
   
Reply With Quote
Old
  (#12)
sis3970
Member
 
sis3970's Avatar
 
Offline
Posts: 39

Level: 5 [♥ Bé-Yêu ♥♥ Bé-Yêu ♥♥ Bé-Yêu ♥]
Life: 0 / 100
Magic: 13 / 2857
Experience: 2%

Thanks: 4
Thanked 4 Times in 4 Posts
Join Date: Aug 2008
Age: 37
30-December-2008, 11:22

@djwoef

Only one instance of sasc is needed. Sasc can indeed handle multiple streams. The problem is something else.

Sasc can ONLY talk to cccam through the camd.socket. This is a direct connection on port 9000, so only one connection per socket. (remeber, sasc was not designed for cccam. this is a hack)

Workaround is to run another camd.socket and thus another cccam server. This can only be done in chroot.

The connection from sasc to the two cccam's will be done by a %d variable:
ie. cccam:127.0.0.1:9000:1/0000/0000:/var/emu/chroot%d/tmp/camd.socket

In this case sasc will decode card 0 via the chroot0 server and card 1 via the chroot1 server.

All you need to do after this, is to connect your two chroot servers to a master cccam.

Chroot guide:


1. install dchroot:
Code:
apt-get install dchroot
2. Directories aanmaken:
Code:
mkdir /var/emu/
2a. Per DVB tuner een chroot dir aanmaken. Dus voor 2 tuners maak je chroot0 en chroot1
Code:
mkdir /var/emu/chroot0
	mkdir /var/emu/chroot1
3. chroot script:
Code:
cd /var/emu
	nano cpchroot.sh
3a. Hetvolgende moet in cpchroot.sh worden geplakt:

Code:
mkdir lib
		mkdir etc
		cp /etc/fstab etc/fstab                                                    
		cp /etc/resolv.conf etc/resolv.conf                                              
		cp /etc/sudoers etc/sudoers                                                  
		cp /etc/passwd  etc/passwd                                                   
		cp /etc/group   etc/group                                                    
		cp /etc/hosts   etc/hosts                                                    
		cp /etc/shadow  etc/shadow                                                   
		mkdir tmp
		mkdir dev
		mkdir bin
		mkdir var
		mkdir usr
		mkdir var/keys
		mkdir var/emu
		mkdir var/etc
		mkdir var/log
		mkdir proc
		cat /proc/cpuinfo > proc/cpuinfo
4. Script uitvoeren: Let op! -> Script moet je uitvoeren vanuit de chroot! Dit doe je voor elke chroot die je hebt gemaakt in stap 2a.

Code:
cd /var/emu/chroot0/
	sh ../cpchroot.sh

	cd /var/emu/chroot1/
	sh ../cpchroot.sh
5. Directories binden: Dit doe je voor elke chroot die je hebt gemaakt in stap 2a.

Code:
mount --bind /dev /var/emu/chroot0/dev
	mount --bind /lib /var/emu/chroot0/lib
	mount --bind /bin /var/emu/chroot0/bin
	mount --bind /usr /var/emu/chroot0/usr
	
	mount --bind /dev /var/emu/chroot1/dev
	mount --bind /lib /var/emu/chroot1/lib
	mount --bind /bin /var/emu/chroot1/bin
	mount --bind /usr /var/emu/chroot1/usr
6. Test chroot: Om uit de chroot te gaan -> CTRL+D
Code:
cd /var/emu/chroot0/
	chroot .
7. Installeer CCcam: Dit doe je voor elke chroot die je hebt gemaakt in stap 2a.
Installeer CCcam in /var/emu/chroot0/var/emu
Plaats de CCcam.cfg in /var/emu/chroot0/var/etc

Installeer CCcam in /var/emu/chroot1/var/emu
Plaats de CCcam.cfg in /var/emu/chroot1/var/etc

8. CCcam in Master/Slave zetten
Je kan slechts n CCcam server laten connecteren naar je cardreader.
Dus je zet CCcam in chroot0 in als Master en connecteert deze met jouw shares en cardreader(s)
CCcam in chroot1 stel je in als client voor de master in chroot0. LET OP-> WIjzig de poorten van de slave server. vb 12010 en 16011.

9. Automatiseren
je moet volgende stappen laden tijdens het opstarten. (nano /etc/rc.local)

Code:
# stap 5:
	mount --bind /dev /var/emu/chroot0/dev
	mount --bind /lib /var/emu/chroot0/lib
	mount --bind /bin /var/emu/chroot0/bin
	mount --bind /usr /var/emu/chroot0/usr
	
	mount --bind /dev /var/emu/chroot1/dev
	mount --bind /lib /var/emu/chroot1/lib
	mount --bind /bin /var/emu/chroot1/bin
	mount --bind /usr /var/emu/chroot1/usr
	sleep 2
	
	# start CCcam servers
	chroot /var/emu/chroot0 /var/emu/run.sh &
	chroot /var/emu/chroot1 /var/emu/run.sh &
	sleep 5
[/quote]
   
Reply With Quote
Sponsored Links
Re: Cardsharing between multiple tunercards
Old
  (#13)
djwoef
Junior Member
 
djwoef's Avatar
 
Offline
Posts: 3

Level: 1 [♥ Bé-Yêu ♥]
Life: 0 / 2
Magic: 1 / 73
Experience: 10%

Thanks: 0
Thanked 0 Times in 0 Posts
Join Date: Dec 2008
Re: Cardsharing between multiple tunercards - 30-December-2008, 15:10

Hello SIS,

Thank you very much for your reply! This is just the answer I was waiting 4!
I will continue with your solution. Are you sure it will work with only one instance of sasc-ng even you are decoding seca and conax at the same time?

I tried yesterday with 2 instances of cccam(not chrooted) and 2 instances of sasc-ng but that didn't work either. The basic problem lies in the fact that although in de cccam configuration the location /tmp/camd.socket can be changed to something else this doesn't work. It will never communicate on something else than /tmp/camd.socket. That is why probably you need to chroot cccam right? :-)

Is it an option to use 2 instances of sasc-ng (one for dvb-t and one for dvb-s), one chrooted cccam and one master ccam?

After all this I will create a good howto which covers it all. The information one needs is too much spread over the internet now.

Thanks again.

Woef
   
Reply With Quote
Old
  (#14)
nevermind
Junior Member
 
nevermind's Avatar
 
Offline
Posts: 4

Level: 1 [♥ Bé-Yêu ♥]
Life: 0 / 5
Magic: 1 / 148
Experience: 21%

Thanks: 0
Thanked 0 Times in 0 Posts
Join Date: Jan 2009
Age: 38
23-January-2009, 14:46

Hello sis3970,
thanks for tutorial :)

I try to configure my two dvbs cards (FF s2300 & skystar2)
I have setup two version of cccam chroots. I use vdr-sc + newcamd + cccam. I don't use sasc-ng. (I must use it ?)

1) master chrooted CCcam
2) slave chrooted CCcam

and

1) master CCcam
2) slave chrooted CCcam
3) slave chrooted CCcam

cardclient.conf :
Code:
cccam:127.0.0.1:9000:0/0000/0000:/var/emu/chroot%d/tmp/camd.socket
In both of configuration the Cccam seems to work. But when I try to use both dvbs I have this error in CCcam slave:

Code:
13:37:31.558 CCcam: remote ecm -> 127.0.0.1:5631 0x919(0x000)
13:37:31.558 CCcam: remote ecm <- 127.0.0.1:5631 failure from cache
13:37:31.558 CCcam: cam[0] ecm even nok caid:0x919 id:0x0 pid:0x645 S*Y I****a (13E)
sc log:

Code:
Jan 23 14:43:28 [cardclient.cccam] 0: FAILED ECM !
Jan 23 14:43:28 [cardclient.core] client cccam (127.0.0.1:9000) ECM failed (4007 ms)
Jan 23 14:43:28 [cardclient.core] cc-loop
Jan 23 14:43:28 [core.ecm] 0.0: lost sync (period 10005, elapsed 23685)
Jan 23 14:43:28 [core.net] socket: select timed out (2 secs)
Jan 23 14:43:29 [cardclient.cccam] 1: FAILED ECM !
Jan 23 14:43:29 [cardclient.core] client cccam (127.0.0.1:9000) ECM failed (5685 ms)
Jan 23 14:43:29 [cardclient.core] cc-loop
Jan 23 14:43:29 [core.ecm] 1.1: lost sync (period 5000, elapsed 15415)
Jan 23 14:43:29 [cardclient.cccam] sending capmts 
Jan 23 14:43:29 [cardclient.cccam] 0: opened camd socket
Jan 23 14:43:30 [core.net] socket: select timed out (2 secs)
please help me! :)
   
Reply With Quote
Old
  (#15)
djwoef
Junior Member
 
djwoef's Avatar
 
Offline
Posts: 3

Level: 1 [♥ Bé-Yêu ♥]
Life: 0 / 2
Magic: 1 / 73
Experience: 10%

Thanks: 0
Thanked 0 Times in 0 Posts
Join Date: Dec 2008
24-January-2009, 15:47

Hello nevermind,

I used Sis's tutorial and I got it working exactly this way. Have you also changed and compiled the ca.c for the second instance and changed the port? That is very important otherwise it wont work.

The only change I did was that I used 2 instances of sasc-ng, otherwise I cant get it to work. Since I am using dvb-t, Conax and dvb-s Secam at the same time I guess sasc-ng gets kinda mixed up. Now I start 2 instances like:

#satelliet ding
/usr/local/bin/sasc-ng -D -j 0:2 --cam-budget --cam-dir /var/keys -l /var/log/sascng.log
#dvb-t ding, debuggen moet op andere poort vandaar extra -p
/usr/local/bin/sasc-ng -D -p 5457 -j 1:3 --cam-dir /var/keys2/ -l /var/log/sascng2.log


Which kind of dvb-s drivers do you use for your card? The 'new' s2api or the 'default' multiproto. This is also an issue since during configuration of sasc-ng you need to include the correct location of the dvb driver headers. Otherwise you can get into trouble, at least I did :-)

Regards

(24-January-2009 15:48)
Ohw damn,

Need to look better, I see you are not using sasc-ng so forget this message :-( Just fyi for others who do work with sasc-ng

Last edited by djwoef; 24-January-2009 at 15:50.. Reason: Automerged Doublepost
   
Reply With Quote
Old
  (#16)
nevermind
Junior Member
 
nevermind's Avatar
 
Offline
Posts: 4

Level: 1 [♥ Bé-Yêu ♥]
Life: 0 / 5
Magic: 1 / 148
Experience: 21%

Thanks: 0
Thanked 0 Times in 0 Posts
Join Date: Jan 2009
Age: 38
24-January-2009, 19:39

Hello djwoef,

thanks for reply :) ,

I resolved this problem :

Code:
13:37:31.558 CCcam: remote ecm <- 127.0.0.1:5631 failure from cache
by changing cardserver (newcs -> radegast)

The system works, but this error remains:

Code:
[core.net] socket: select timed out (2 secs)
I have changed the ca.c port 9000 to 9999 in the master CCcam.
But in both of slave CCcam the port remais 9000.

I tried this ca.c port config:

CCcam server port 9999
CCcam client port 9000
CCcam client port 9000

The server port in CCcam.cfg is:
CCcam server port 5555
CCcam client port 5556
CCcam client port 5557

Is this the correct configuration ?
   
Reply With Quote
Old
  (#17)
sis3970
Member
 
sis3970's Avatar
 
Offline
Posts: 39

Level: 5 [♥ Bé-Yêu ♥♥ Bé-Yêu ♥♥ Bé-Yêu ♥]
Life: 0 / 100
Magic: 13 / 2857
Experience: 2%

Thanks: 4
Thanked 4 Times in 4 Posts
Join Date: Aug 2008
Age: 37
28-January-2009, 16:43

That is correct. Do you still have issues with that configuration??
   
Reply With Quote
Old
  (#18)
nevermind79
Junior Member
 
nevermind79's Avatar
 
Offline
Posts: 1

Level: 1 [♥ Bé-Yêu ♥]
Life: 0 / 0
Magic: 0 / 0
Experience: 0%

Thanks: 0
Thanked 0 Times in 0 Posts
Join Date: Oct 2007
29-January-2009, 15:43

Quote:
Originally Posted by sis3970 View Post
That is correct. Do you still have issues with that configuration??
Yes I have this error :

Code:
[core.net] socket: select timed out (2 secs)
   
Reply With Quote
Old
  (#19)
xjust
Member
 
xjust's Avatar
 
Offline
Posts: 39

Level: 5 [♥ Bé-Yêu ♥♥ Bé-Yêu ♥♥ Bé-Yêu ♥]
Life: 0 / 100
Magic: 13 / 3214
Experience: 2%

Thanks: 10
Thanked 4 Times in 3 Posts
Join Date: May 2007
11-May-2009, 13:02

i have that error as well even tho the channels are decoded
any help getting rid of it ?
   
Reply With Quote
Old
  (#20)
gava
Junior Member
 
gava's Avatar
 
Offline
Posts: 1

Level: 1 [♥ Bé-Yêu ♥]
Life: 0 / 0
Magic: 0 / 0
Experience: 0%

Thanks: 0
Thanked 0 Times in 0 Posts
Join Date: Jun 2009
11-June-2009, 09:18

Hi All,

I've just recently read about this card sharing tech.. I've been using a mythtv box with my DVB-T cards for years now and love it. I want to put a dvb-s card's in my box to use with Austr... will this work?

i.e. Mythtv Backend with 3 x DVB-S cards share one card?

if so is there certain HW I should stick to?
   
Reply With Quote
Reply

Bookmarks

Tags
cardsharing, multiple, tuner


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are Off
Refbacks are Off

Forum Jump



ECS on RSS ECS on Twitter ECS on Facebook ECS on Youtube
Follow us on:

Powered by vBulletin
Copyright 2002 - 2010, Jelsoft Enterprises Ltd.
SEO by vBSEO ©2011, Crawlability, Inc.
Dreambox