I can confirm that with some cam's and or softcam configs the start and stop from out off pli's softcam manager does not work (ALWAYS) ok mostly well.
I used to have a softcam oscam setting on dm8000 with smartreader V1 and one pcsc (omnikey 3021 reader) Those both always worked better then the internal sci off dm8000.
(now I do not have card's anymore on my box self butt on a central pc)
In those days and only with the both readers, I had regularly failures upon starting stopping changing restarting softcam trough pli's softcam manager.
Using telnet and then ~# sh /etc/init.d/softcam restart (or stop and then start) did always worked fine.
But after I just once stopped the cam (and or restarted) trough the pli's software manager it went wrong.
The cam seemed to work but nothing worked at the same time. even with stopping trough telnet id did not stopped.
I then noticed that in despit the fact that I stopped the cam there where still aktif pids.
Those I could kill by using the command
~# killall -9 <name off softcam binary self>
Then It was ok and I could restart .
Trough telnet OK Trough softcam manager just same sometimes ok others not.
Yes that was pretty weird (increasing the stop times into the start script did not helped).
I then proceed checking the python plugin and start experimenting.
The whole stuff could be stabilized by : changing some lines into the python plugin of pli self.
How it is now :
def restart(self, what):
self.what = what
if "s" in what:
if "c" in what:
msg = _("Please wait, restarting softcam and cardserver.")
else:
msg = _("Please wait, restarting softcam.")
elif "c" in what:
msg = _("Please wait, restarting cardserver.")
self.mbox = self.session.open(MessageBox, msg, MessageBox.TYPE_INFO)
self.activityTimer = eTimer()
self.activityTimer.timeout.get().append(self.doStop)
self.activityTimer.start(100, False)
def doStop(self):
self.activityTimer.stop()
if "c" in self.what:
self.cardserver.command('stop')
if "s" in self.what:
self.softcam.command('stop')
self.oldref = self.session.nav.getCurrentlyPlayingServiceReference()
self.session.nav.stopService()
# Delay a second to give 'em a chance to stop
self.activityTimer = eTimer()
self.activityTimer.timeout.get().append(self.doStart)
self.activityTimer.start(1000, False)
With two small changes into the python file line 112 from 100 ms to 300 ms and line 125 from 1000 to 2000
All problems where solved
def restart(self, what):
self.what = what
if "s" in what:
if "c" in what:
msg = _("Please wait, restarting softcam and cardserver.")
else:
msg = _("Please wait, restarting softcam.")
elif "c" in what:
msg = _("Please wait, restarting cardserver.")
self.mbox = self.session.open(MessageBox, msg, MessageBox.TYPE_INFO)
self.activityTimer = eTimer()
self.activityTimer.timeout.get().append(self.doStop)
self.activityTimer.start(300, False)
def doStop(self):
self.activityTimer.stop()
if "c" in self.what:
self.cardserver.command('stop')
if "s" in self.what:
self.softcam.command('stop')
self.oldref = self.session.nav.getCurrentlyPlayingServiceReference()
self.session.nav.stopService()
# Delay a second to give 'em a chance to stop
self.activityTimer = eTimer()
self.activityTimer.timeout.get().append(self.doStart)
self.activityTimer.start(2000, False)
This already I passed long time ago to openpli but it was just ignored.
Then my softcam oscam those days started ok with a smartreader v1
When I used two readers if one off them was a pcsc I also just needed to add to the cam's startscript file a sleep off 2 seconds.
When those changes where done al was ok.
startscrit how it is (only the start part)
#!/bin/sh
case "$1" in
start)
ulimit -s 1024
exec start-stop-daemon -S -x /usr/bin/CCcam
;;
And how it always was ok with two readers and using the (modified) python softcam manager off pli
#!/bin/sh
case "$1" in
start)
sleep 2
ulimit -s 1024
exec start-stop-daemon -S -x /usr/bin/CCcam
;;