Just another blog
Posts tagged zapscript
Dreambox standby channel script
Aug 20th
My dreambox 800hd combined with a Multitenne dish can’t wake up on a HD channel, will give a “Tune failed” message.
So every time I had to switch to a SD channel and switch back to the HD channel to get an image.
I created a little script that can do the switch for you, I use the BVN channel as standby channel so if the box wakes up i BVN is on. You can set your own startup channel in three steps as described in the script.
- Put zapscript.sh on your dreambox somewhere (i.e. your root home dir)
- Enter “chmod 755 zapscript.sh”
- Start script “./zapscript.sh”
- Optional but recommended add to startup: enter “ln -s /home/root/zapscript.sh /etc/rcS.d/S80zapscript.sh” the script will run if the box get booted after a power down or reboot.
download zapscript.sh
Source:
#!/bin/sh # # Set default channel in standby mode # To select your default channel: # 1. navigate to http://dreamboxip/web/getservices and select your bouquet reference value and copy it # 2. navigate to http://dreamboxip/web/getservices?sRef=YOURBOUQUET # Something like: 1:7:1:0:0:0:0:0:0:0:FROM%20BOUQUET%20%22userbouquet.dbe17.tv%22%20ORDER%20BY%20bouquet # 3. copy your channel reference to use as your standby channel # # Used source for dreambox web interface: http://dream.reichholf.net/wiki/Enigma2:WebInterface # STANDBYCHANNEL="1:0:1:FB0:451:35:C00000:0:0:0:" LASTCHANNEL=0 LINE="------------------------------------------------------" echo $LINE echo "Standby channel script running" echo $LINE sleep 300 while [ 1 ] do CHANNEL=`wget -O- -q http://localhost/web/about | grep "servicename" | sed 's/.*\(.*\)<\/e2servicename.*/\1/'` if [ "$CHANNEL" = "" ]; then if [ "$LASTCHANNEL" != "BVN" ]; then echo "TV standby, set channel to bvn and go back to standby." `wget -O- -q http://localhost/web/powerstate?newstate=0 >> /dev/null` echo "power on" sleep 10 `wget -O- -q http://localhost/web/zap?sRef=$STANDBYCHANNEL >> /dev/null` echo "channel changed" sleep 5 `wget -O- -q http://localhost/web/powerstate?newstate=0 >> /dev/null` echo "goto standby" LASTCHANNEL="BVN" else echo "TV channel already set to BVN, do nothing" fi else echo "TV channel: $CHANNEL" LASTCHANNEL=$CHANNEL fi echo $LINE sleep 300 done exit 0



