Some people that want to use a more recent version of there softcam (oscam for exemple) find it sometimes hard to change the version.
I have then slightly rewrote the softcam startup script to have clearly separated softcam exe and parameters, so the startup script can become more universal for any softcam.
Can perhaps be a best pratice to use this new softcam startup script method for all the current available softcam in the repository.
Here is the script:
#!/bin/sh # Define parameters here # start-exe = executable to launch # softcam_param = full command line parameters to pass to executable # softcam_version = For information only, version of the executable softcam_exe="/usr/bin/oscam-experimental" softcam_param="-b -r 2 -c /etc/tuxbox/config/oscam-experimental" softcam_version="1.20" remove_tmp () { [ -e /tmp/ecm.info ] && rm -rf /tmp/ecm.info [ -e /tmp/.oscam ] && rm -rf /tmp/.oscam [ -e /tmp/.console ] && rm -rf /tmp/.console [ -e /tmp/camd.socket ] && rm -rf /tmp/camd.socket } case "$1" in start) exec start-stop-daemon -S -x $softcam_exe -- $softcam_param ;; stop) exec start-stop-daemon -K -R 2 -x $softcam_exe & sleep 2 ps | grep $softcam_exe | grep -v grep > /dev/null if [ $? -eq 0 ] then killall -9 $softcam_exe 2>/dev/null fi sleep 2 remove_tmp ;; restart|reload) $0 stop sleep 1 $0 start ;; version) echo $softcam_version ;; info) echo "oscam" ;; values) echo "Command line started:" echo $softcam_exe $softcam_param ;; *) echo "Usage: $0 start|stop|restart|version|info|values" exit 1 ;; esac exit 0
Tested with different OScam version. I don't know if the info parameter is used somewhere in OpenPli so I leave it that way and add my own new options "values" that will display what the command line used to start the emu looks like.
Pr2