Jump to content


Photo

Libusb support added to oscam-experimental


  • Please log in to reply
77 replies to this topic

Re: Libusb support added to oscam-experimental #61 spock

  • Senior Member
  • 214 posts

+1
Neutral

Posted 27 June 2012 - 11:38

Is it possible to get a new build up for the ultimo to test this commit today or shall I wait till tomorrow?

Edited by spock, 27 June 2012 - 11:38.


Re: Libusb support added to oscam-experimental #62 pieterg

  • PLi® Core member
  • 32,766 posts

+245
Excellent

Posted 27 June 2012 - 11:41

starting a build now...

Re: Libusb support added to oscam-experimental #63 christophecvr

  • Senior Member
  • 3,131 posts

+140
Excellent

Posted 27 June 2012 - 12:20

DEVTMPFS was missing in vuplus kernels.
That would probably fix coldplugging.
I'm wondering about hotplugging though (for your dm8000 as well), we might need to add a custom mdev rule to create /dev/bus/usb nodes for hotplug events.


Hotplug seems ok on dm. I think the hotplug just places the innode into the /dev/bus/busid if this maps are present. If not I gues it just will create an inode under /dev/... can't check this.
maybe now witgh DEVTMPFS it will create those maps. I hope. If not Perhaps adding an usbdevloc compat package which runs a script on startup and create softlinks to the location off device node used in vu could be an option. ? however I think it will be solved with DEVTMPFS

Re: Libusb support added to oscam-experimental #64 christophecvr

  • Senior Member
  • 3,131 posts

+140
Excellent

Posted 27 June 2012 - 13:27

Just performed a build with latest pieterg changes.

If You wish you can try it out. By reflashing box with this build :

Do not use software update before nightly builds ar done. Installings off addons is ok, as long you do not update.

http://users.telenet...uultimo_usb.zip

Re: Libusb support added to oscam-experimental #65 spock

  • Senior Member
  • 214 posts

+1
Neutral

Posted 27 June 2012 - 13:51

Success!

root@vuultimo:/dev# list_smargo
Looking for smartreader with an out endpoint = 0x82 :
bus 003, device 002 : 0403:6001 Smartreader (Device=003:002 EndPoint=0x82 insert in oscam.server 'Device = Serial:Reader 152')

2012/06/27 16:27:23 770005A0 r Using 0x82 as endpoint for smartreader hardware detection
2012/06/27 16:27:23 77001EA0 c plain dvbapi-client granted (dvbapi, au=auto (5 reader))
2012/06/27 16:27:23 77001EA0 c dvbapi: 0 entries read from oscam.dvbapi
2012/06/27 16:27:23 770005A0 r Found reader with serial Reader 152 at 003:002
2012/06/27 16:27:23 770005A0 r Found smartreader device Serial:Reader 152
2012/06/27 16:27:23 770005A0 r reader smargo initialized (device=Serial:Reader 152, detect=cd, mhz=480, cardmhz=480)
2012/06/27 16:27:24 770005A0 r smargo [smartreader] smargo card detected
2012/06/27 16:27:27 770005A0 r smargo [smartreader] ATR: 3F 77 18 00 00 C2 7A 42 02 68 90 00
2012/06/27 16:27:28 770005A0 r Reader smargo: Maximum frequency for this card is formally 5 Mhz, clocking it to 4.80 Mhz
2012/06/27 16:27:29 770005A0 r smargo [smartreader] using ecm #608 for long viaccess ecm
2012/06/27 16:27:29 770005A0 r smargo [smartreader] type: Viaccess (standard atr), caid: 0500, serial: 11111

Many thanks to you both :)

Edited by spock, 27 June 2012 - 13:52.


Re: Libusb support added to oscam-experimental #66 christophecvr

  • Senior Member
  • 3,131 posts

+140
Excellent

Posted 27 June 2012 - 14:48

Nice to know. Now it will be ok for everyone with vu box as from tommorow after nightly builds are done and they update box.

Re: Libusb support added to oscam-experimental #67 spock

  • Senior Member
  • 214 posts

+1
Neutral

Posted 27 June 2012 - 16:14

wrong post, disregard this.

thanks again btw. :)

Edited by spock, 27 June 2012 - 16:15.


Re: Libusb support added to oscam-experimental #68 christophecvr

  • Senior Member
  • 3,131 posts

+140
Excellent

Posted 28 June 2012 - 10:15

@pieterg,

I discoverd that there is a problem with usb serial devices on dm8000.

ftdi_sio does not load anymore. Even after installing usbserial. If I do modprobe ftdi_sio it does load. But after boot the ftdi_sio does not load anymore.
We always have to do this manually. does will affect so what every cam using smargo or any ftdi based cardreader. (except oscam for smargo using smartreader protocol).
When usb serial is installed ftdi_sio must load automatically at boot time.

Re: Libusb support added to oscam-experimental #69 pieterg

  • PLi® Core member
  • 32,766 posts

+245
Excellent

Posted 28 June 2012 - 10:42

which files do you have in /etc/modules-load.d ?
Is there an fdti-sio entry?

Re: Libusb support added to oscam-experimental #70 christophecvr

  • Senior Member
  • 3,131 posts

+140
Excellent

Posted 28 June 2012 - 11:39

No there wasn't. But now I put one in ftdi_sio.conf with ftdi_sio.

runned update-modules, now its' ok. Somehow it seems to be an installation problem.

Re: Libusb support added to oscam-experimental #71 christophecvr

  • Senior Member
  • 3,131 posts

+140
Excellent

Posted 28 June 2012 - 12:22

@pieterg,

Also there is another problem with oscam this does only appear when using the restart function trough softcam menu.

I did a lot of test's ,

What's happening. With smargo support.

1) If I change the came to none, wait until started then select back oscam-experimental.
Start perfect smargo intiated at first attempt.
After boot smargo intiated at first attempt

2) If I select Softcam Herstarten
It stops that's ok
When it start's, It is never able to intitate smargo at first attempt, smargo only initiate at second attempt this takes place 1 minute after start.

I tried to investigate trough telnet.
When stopping oscam with sh softcams.oscam-experimental stop
stop ok
When starting with sh softcams.oscam-experimental start
start ok smargo intiated at first attempt.

I modified temporarely the start script to use the restart or reload command (which does not work on the standard one)

When performing sh softcams.oscam-experimental restart or reload ,
does stop ok restart ok smargo initiated at the first attempt.

When I do this trough softcam herstarten, oscam does stop does restart, but smargo does not intiate at first attempt.

Whatever we do it seems that when using Softcam Herstarten it does not kill all running pids or so ???

I modified the script working old ways whitout start-stop-deamon . problem remains.
What can be done to really kill oscam and restart correctly ?

The tempo modified script is now :
#!/bin/sh
remove_tmp () {
  rm -rf /tmp/.oscam /media/cf/oscam/* /tmp/.listen.camd.socket /tmp/camd.socket
}
case "$1" in
start)
remove_tmp
sleep 2
ulimit -s 512
/usr/bin/oscam-experimental -b -r 2 -c /etc/tuxbox/config/oscam-experimental &
;;
stop)
/usr/bin/oscam-experimental &
sleep 2
killall -9 oscam-experimental 2>/dev/null &
remove_tmp
sleep 3
  ;;
restart|reload)
killall -9 oscam-experimental 2>/dev/null &
sleep 5
sleep 2
ulimit -s 512
/usr/bin/oscam-experimental -b -r 2 -c /etc/tuxbox/config/oscam-experimental &
;;
version)
echo "1.20"
;;
info)
echo "oscam-experimental"
;;
*)
echo "Usage: $0 start|stop|restart"
exit 1
;;
esac
exit 0

Ok I removed the start stop deamon now, why does it still not work's ? manually start stop or restart using script does work very well

Re: Libusb support added to oscam-experimental #72 christophecvr

  • Senior Member
  • 3,131 posts

+140
Excellent

Posted 28 June 2012 - 12:32

sorry I did find the error on stop function it started as well .

Now whit script modified like this it work's I just removed the
/usr/bin/oscam-experimental &
on stop line

Re: Libusb support added to oscam-experimental #73 christophecvr

  • Senior Member
  • 3,131 posts

+140
Excellent

Posted 28 June 2012 - 16:12

After much more testing , it's not the start script itself. unfortunately.

the problem is situated into the Softcams.py file. Somehow sometimes (mostly) it does cause a runtime error during oscam start. Lucky oscam itself does intercept this error by reiniting readers a second time after one minute.
One minute however is very very long. something needs to be changed into the softcams i think into Sc.py but i tried a couple of things whitout succes. Unfortunately i'm not familiar with python.

Re: Libusb support added to oscam-experimental #74 christophecvr

  • Senior Member
  • 3,131 posts

+140
Excellent

Posted 29 June 2012 - 17:47

ter info

To start or restart oscam with smargo readers on dm8000 and smartreader protocol,
Whitout having to wait an extra minute before it works correctly is to use modified oscam start script.
For boot time or manual start the openpli script is ok. For restarting or starting coming from other or no cam with softcam utility this script modification is needed.
The start stop deamon causes run time error when used from out of python.

#!/bin/sh
case "$1" in
start)
sleep 1
ulimit -s 512
sleep 2
/usr/bin/oscam-experimental -b -r 2 -c /etc/tuxbox/config/oscam-experimental
sleep 1
;;
stop)
sleep 1
killall -9 oscam-experimental
sleep 1
killall -9 oscam-experimental 2>/dev/null
sleep 1
rm -rf /tmp/.oscam /media/cf/oscam/*
sleep 1
;;
restart|reload)
$0 stop
sleep 2
$0 start
;;
version)
echo "1.20"
;;
info)
echo "oscam-experimental"
;;
*)
echo "Usage: $0 start|stop|restart"
exit 1
;;
esac
exit 0


Re: Libusb support added to oscam-experimental #75 spock

  • Senior Member
  • 214 posts

+1
Neutral

Posted 3 July 2012 - 01:19

Sorry for a little bit OT here, but I'm trying to build enigma2-plugin-softcams-oscam-experimental for OpenPLi 3.0 on VU+ Ultimo, and I keep getting a weird error that I just can't seem to figure out.

It seems to think it fails to fetch the code from SVN, but the SVN is up, and the code actually is downloaded to ~/openpli/openpli-oe-core/sources/svn/oscam.to/svn/oscam/trunk

I had no problem building the vuultimo image, and it seems to be working. But many plugins seems to have failed to build.


johan@virtual-einstein:~/openpli/openpli-oe-core/build-vuultimo$ source env.source
johan@virtual-einstein:~/openpli/openpli-oe-core/build-vuultimo$ bitbake enigma2-plugin-softcams-oscam-experimental
Loading cache: 100% |#############################################################| ETA:  00:00:00
Loaded 1753 entries from dependency cache.
Parsing recipes: 100% |###########################################################| Time: 00:00:17
Parsing of 1459 .bb files complete (1390 cached, 69 parsed). 1821 targets, 175 skipped, 0 masked, 0 errors.
OE Build Configuration:
BB_VERSION	    = "1.15.2"
TARGET_ARCH	   = "mipsel"
TARGET_OS		 = "linux"
MACHINE		   = "vuultimo"
DISTRO		    = "openpli"
DISTRO_VERSION    = "3.0"
TUNE_FEATURES	 = "o32 fpu-hard mips32"
TARGET_FPU	    = ""
meta-oe		   = "(nobranch):99f12509d090ad3dcfdca693b4c8765482d16621"
meta			  = "(nobranch):962a96fb25c4d09509e3f05ec6f7c9bfee0f53dd"
meta-openpli	  = "master:fd419d3e7b2c986c28ed08d97811cc1b73cc4af7"
NOTE: Resolving any missing task queue dependencies
NOTE: Preparing runqueue
NOTE: Executing SetScene Tasks
NOTE: Executing RunQueue Tasks
NOTE: Running task 1011 of 1064 (ID: 109, /home/johan/openpli/openpli-oe-core/meta-openpli/recipes-openpli/enigma2-softcams/oscam-experimental.bb, do_fetch)
NOTE: Running task 1033 of 1064 (ID: 131, /home/johan/openpli/openpli-oe-core/meta-openpli/recipes-openpli/enigma2-softcams/softcam-support.bb, do_package_write_ipk)
NOTE: Running task 1042 of 1064 (ID: 9, /home/johan/openpli/openpli-oe-core/meta-openpli/recipes-openpli/enigma2-softcams/enigma2-plugin-softcams-oscam-experimental.bb, do_package)
NOTE: Running task 1043 of 1064 (ID: 3, /home/johan/openpli/openpli-oe-core/meta-openpli/recipes-openpli/enigma2-softcams/enigma2-plugin-softcams-oscam-experimental.bb, do_populate_sysroot)
NOTE: package oscam-experimental-svn7128-r3: task do_fetch: Started
NOTE: package softcam-support-1.0-r1: task do_package_write_ipk: Started
NOTE: package enigma2-plugin-softcams-oscam-experimental-1.20-r4.1: task do_package: Started
NOTE: package enigma2-plugin-softcams-oscam-experimental-1.20-r4.1: task do_populate_sysroot: Started
NOTE: package enigma2-plugin-softcams-oscam-experimental-1.20-r4.1: task do_populate_sysroot: Succeeded
NOTE: package softcam-support-1.0-r1: task do_package_write_ipk: Succeeded
NOTE: Running noexec task 1044 of 1064 (ID: 127, /home/johan/openpli/openpli-oe-core/meta-openpli/recipes-openpli/enigma2-softcams/softcam-support.bb, do_package_write)
NOTE: Running noexec task 1045 of 1064 (ID: 124, /home/johan/openpli/openpli-oe-core/meta-openpli/recipes-openpli/enigma2-softcams/softcam-support.bb, do_build)
NOTE: Running task 1046 of 1064 (ID: 129, /home/johan/openpli/openpli-oe-core/meta-openpli/recipes-openpli/enigma2-softcams/softcam-support.bb, do_rm_work)
NOTE: package softcam-support-1.0-r1: task do_rm_work: Started
NOTE: package softcam-support-1.0-r1: task do_rm_work: Succeeded
NOTE: package enigma2-plugin-softcams-oscam-experimental-1.20-r4.1: task do_package: Succeeded
WARNING: Failed to fetch URL svn://oscam.to/svn/oscam;module=trunk;proto=http;scmdata=keep
ERROR: Fetcher failure: Fetch command export HOME="/home/johan"; export SSH_AUTH_SOCK="/tmp/keyring-vuk71M/ssh"; export GIT_CONFIG="/home/johan/openpli/openpli-oe-core/build-vuultimo/tmp/sysroots/x86_64-linux/etc/gitconfig"; export PATH="/home/johan/openpli/openpli-oe-core/build-vuultimo/tmp/sysroots/x86_64-linux/usr/bin/mips32el-oe-linux:/home/johan/openpli/openpli-oe-core/build-vuultimo/tmp/sysroots/vuultimo/usr/bin/crossscripts:/home/johan/openpli/openpli-oe-core/build-vuultimo/tmp/sysroots/x86_64-linux/usr/sbin:/home/johan/openpli/openpli-oe-core/build-vuultimo/tmp/sysroots/x86_64-linux/usr/bin:/home/johan/openpli/openpli-oe-core/build-vuultimo/tmp/sysroots/x86_64-linux/sbin:/home/johan/openpli/openpli-oe-core/build-vuultimo/tmp/sysroots/x86_64-linux//bin:/home/johan/openpli/openpli-oe-core/openembedded-core/scripts:/home/johan/openpli/openpli-oe-core/bitbake/bin:/home/johan/openpli/openpli-oe-core/openembedded-core/scripts:/home/johan/openpli/openpli-oe-core/bitbake/bin:/home/johan/openpli/openpli-oe-core/openembedded-core/scripts:/home/johan/openpli/openpli-oe-core/bitbake/bin:/home/johan/openpli/openpli-oe-core/openembedded-core/scripts:/home/johan/openpli/openpli-oe-core/bitbake/bin:/home/johan/openpli/openpli-oe-core/openembedded-core/scripts:/home/johan/openpli/openpli-oe-core/bitbake/bin:/usr/lib/lightdm/lightdm:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/home/johan/openpli/openpli-oe-core/openembedded-core/scripts"; /usr/bin/env svn update -r 7128 could not be run:
None
ERROR: Function failed: Fetcher failure for URL: 'svn://oscam.to/svn/oscam;module=trunk;proto=http;scmdata=keep'. Unable to fetch URL from any source.
ERROR: Logfile of failure stored in: /home/johan/openpli/openpli-oe-core/build-vuultimo/tmp/work/mips32el-oe-linux/oscam-experimental-svn7128-r3/temp/log.do_fetch.18607
NOTE: package oscam-experimental-svn7128-r3: task do_fetch: Failed
ERROR: Task 109 (/home/johan/openpli/openpli-oe-core/meta-openpli/recipes-openpli/enigma2-softcams/oscam-experimental.bb, do_fetch) failed with exit code '1'
NOTE: Tasks Summary: Attempted 1046 tasks of which 1039 didn't need to be rerun and 1 failed.
Summary: 1 task failed:
  /home/johan/openpli/openpli-oe-core/meta-openpli/recipes-openpli/enigma2-softcams/oscam-experimental.bb, do_fetch
Summary: There was 1 WARNING message shown.
Summary: There were 2 ERROR messages shown, returning a non-zero exit code.
johan@virtual-einstein:~/openpli/openpli-oe-core/build-vuultimo$

Got any clue what this is about? The machine I'm building on is a virtual ubuntu 12.04 64-bit. Followed the guides and installed all necessary packages to build the image.

Re: Libusb support added to oscam-experimental #76 christophecvr

  • Senior Member
  • 3,131 posts

+140
Excellent

Posted 3 July 2012 - 09:35

Hello Yes I do have the same problem, Curiousely only when I build for vu ultimo. Not when I build for dm8000.

For oscam there is a work around, Just change the download link in file located in directory.

~/openpli30vuul/openpli-oe-core/meta-openpli/recipes-openpli/enigma2-softcams

called oscam-experimental.bb

the line 4

from
URI = "svn://oscam.to/svn/oscam;module=trunk;proto=http;scmdata=keep"

into
URI = "svn://streamboard.gmc.to/svn/oscam;module=trunk;proto=http;scmdata=keep"

Then it work's

Re: Libusb support added to oscam-experimental #77 spock

  • Senior Member
  • 214 posts

+1
Neutral

Posted 3 July 2012 - 10:52

That worked, thanks!

Re: Libusb support added to oscam-experimental #78 christophecvr

  • Senior Member
  • 3,131 posts

+140
Excellent

Posted 3 July 2012 - 13:11

@pieterg

Do you have any idea why the oscam link into experimental.bb file oscam.to does work perfectly well in dm8000 build but not in vu build.


1 user(s) are reading this topic

0 members, 1 guests, 0 anonymous users