From 7a9ba876b08412b2061e1d4c368b08836e6b64d0 Mon Sep 17 00:00:00 2001 From: brindosch Date: Sat, 30 Apr 2016 01:14:28 +0200 Subject: [PATCH 1/9] Update README.md Former-commit-id: a1bc04f01efe52cb87f85aa68e8f181c0e95900b --- README.md | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index e8ead57c..ec8af595 100644 --- a/README.md +++ b/README.md @@ -12,6 +12,9 @@ Hyperion is an opensource 'AmbiLight' implementation supported by many devices. * A scriptable effect engine. * Generic software architecture to support new devices and new algorithms easily. -More information can be found on the [wiki](wiki.hyperion-project.org) or the [Hyperion webpage/forum](www.hyperion-project.org). +More information can be found on the official Hyperion [Wiki](https://wiki.hyperion-project.org) + +If you need further support please open a topic at the our new forum! +[Hyperion webpage/forum](https://www.hyperion-project.org). The source is released under MIT-License (see http://opensource.org/licenses/MIT). From 4853d17563111af9173fcaad62545e8610663ef2 Mon Sep 17 00:00:00 2001 From: brindosch Date: Sat, 30 Apr 2016 17:00:29 +0200 Subject: [PATCH 2/9] maybe fix install.sh Former-commit-id: 2713fb28ddf70d6a22fd743ca931b2f120e03a8e --- bin/install_hyperion.sh | 1 + 1 file changed, 1 insertion(+) diff --git a/bin/install_hyperion.sh b/bin/install_hyperion.sh index b3452276..13b1f91b 100755 --- a/bin/install_hyperion.sh +++ b/bin/install_hyperion.sh @@ -206,6 +206,7 @@ elif [ $OS_OPENELEC -eq 1 ]; then #modify all old installs with a logfile output sed -i 's|/dev/null|/storage/logfiles/hyperion.log|g' /storage/.config/autostart.sh # only add to start script if hyperion is not present yet + touch /storage/.config/autostart.sh 2>/dev/null if [ `cat /storage/.config/autostart.sh 2>/dev/null | grep hyperiond | wc -l` -eq 0 ]; then echo '---> Adding Hyperion to OpenELEC autostart.sh' echo "/storage/hyperion/bin/hyperiond.sh /storage/.config/hyperion.config.json > /storage/logfiles/hyperion.log 2>&1 &" >> /storage/.config/autostart.sh From fdbb1673ebdbd4d333b13027756a60f0a0ed35ba Mon Sep 17 00:00:00 2001 From: brindosch Date: Sat, 30 Apr 2016 17:09:41 +0200 Subject: [PATCH 3/9] add logfiles dir for oe install Former-commit-id: d549732905e85d224921de574463f540d8d5d647 --- bin/install_hyperion.sh | 1 + 1 file changed, 1 insertion(+) diff --git a/bin/install_hyperion.sh b/bin/install_hyperion.sh index 13b1f91b..43ba9566 100755 --- a/bin/install_hyperion.sh +++ b/bin/install_hyperion.sh @@ -206,6 +206,7 @@ elif [ $OS_OPENELEC -eq 1 ]; then #modify all old installs with a logfile output sed -i 's|/dev/null|/storage/logfiles/hyperion.log|g' /storage/.config/autostart.sh # only add to start script if hyperion is not present yet + mkdir /storage/logfiles 2>/dev/null touch /storage/.config/autostart.sh 2>/dev/null if [ `cat /storage/.config/autostart.sh 2>/dev/null | grep hyperiond | wc -l` -eq 0 ]; then echo '---> Adding Hyperion to OpenELEC autostart.sh' From 89a8e6c6e5da6b1991b617806f2439178fbd587d Mon Sep 17 00:00:00 2001 From: brindosch Date: Wed, 4 May 2016 10:28:25 +0200 Subject: [PATCH 4/9] rasplex support Former-commit-id: 5dc6697124fe2e4fbfee6228db131bd574a921c6 --- bin/install_hyperion.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/bin/install_hyperion.sh b/bin/install_hyperion.sh index 43ba9566..f8dafb55 100755 --- a/bin/install_hyperion.sh +++ b/bin/install_hyperion.sh @@ -33,7 +33,7 @@ echo 'Created by brindosch - hyperion-project.org - the official Hyperion source echo '*******************************************************************************' # Find out if we are on OpenElec / OSMC / Raspbian -OS_OPENELEC=`grep -m1 -c OpenELEC /etc/issue` +OS_OPENELEC=`grep -m1 -c 'OpenELEC\|RasPlex' /etc/issue` OS_OSMC=`grep -m1 -c OSMC /etc/issue` OS_RASPBIAN=`grep -m1 -c 'Raspbian\|RetroPie' /etc/issue` From f4c07f6c83c1810d67134cef6107455fc2d937e2 Mon Sep 17 00:00:00 2001 From: brindosch Date: Wed, 4 May 2016 15:41:58 +0200 Subject: [PATCH 5/9] revert script changes Former-commit-id: 98b2d971b780ccae61cc01b9da1a339ed5799b19 --- bin/remove_hyperion.sh | 24 ++++++++++++------------ 1 file changed, 12 insertions(+), 12 deletions(-) diff --git a/bin/remove_hyperion.sh b/bin/remove_hyperion.sh index fafd0f99..7a828fd2 100644 --- a/bin/remove_hyperion.sh +++ b/bin/remove_hyperion.sh @@ -63,10 +63,10 @@ elif [ $USE_SERVICE -eq 1 ]; then /usr/sbin/service hyperion stop 2>/dev/null elif [ $USE_SYSTEMD -eq 1 ]; then service hyperion stop 2>/dev/null - while [ $SERVICEC -le 20 ]; do - service hyperion_fw$SERVICEC stop 2>/dev/null - ((SERVICEC++)) - done +# while [ $SERVICEC -le 20 ]; do +# service hyperion_fw$SERVICEC stop 2>/dev/null +# ((SERVICEC++)) +# done fi #reset count @@ -86,19 +86,19 @@ elif [ $USE_SYSTEMD -eq 1 ]; then # Delete and disable Hyperion systemd script echo '---> Delete and disable Hyperion systemd script' systemctl disable hyperion.service - while [ $SERVICEC -le 20 ]; do - systemctl -q disable hyperion_fw$SERVICEC.service 2>/dev/null - ((SERVICEC++)) - done +# while [ $SERVICEC -le 20 ]; do +# systemctl -q disable hyperion_fw$SERVICEC.service 2>/dev/null +# ((SERVICEC++)) +# done rm -v /etc/systemd/system/hyperion* 2>/dev/null elif [ $USE_SERVICE -eq 1 ]; then # Delete and disable Hyperion init.d script echo '---> Delete and disable Hyperion init.d script' update-rc.d -f hyperion remove - while [ $SERVICEC -le 20 ]; do - update-rc.d -f hyperion_fw$SERVICEC remove 2>/dev/null - ((SERVICEC++)) - done +# while [ $SERVICEC -le 20 ]; do +# update-rc.d -f hyperion_fw$SERVICEC remove 2>/dev/null +# ((SERVICEC++)) +# done rm /etc/init.d/hyperion* 2>/dev/null fi From d5e6a4cdaaa74a9e55133dc0bc068dfe91312ae4 Mon Sep 17 00:00:00 2001 From: brindosch Date: Wed, 4 May 2016 18:50:40 +0200 Subject: [PATCH 6/9] rasplex install Former-commit-id: 083c6e95432d6bd776eba3e70b23a7d1fd5d9d84 --- bin/install_hyperion.sh | 10 +++++++--- bin/remove_hyperion.sh | 4 ++-- 2 files changed, 9 insertions(+), 5 deletions(-) diff --git a/bin/install_hyperion.sh b/bin/install_hyperion.sh index f8dafb55..82bfa6fa 100755 --- a/bin/install_hyperion.sh +++ b/bin/install_hyperion.sh @@ -32,8 +32,9 @@ $WMESSAGE echo 'Created by brindosch - hyperion-project.org - the official Hyperion source.' echo '*******************************************************************************' -# Find out if we are on OpenElec / OSMC / Raspbian +# Find out if we are on OpenElec (Rasplex) / OSMC / Raspbian OS_OPENELEC=`grep -m1 -c 'OpenELEC\|RasPlex' /etc/issue` +OS_RASPLEX=`grep -m1 -c RasPlex /etc/issue` OS_OSMC=`grep -m1 -c OSMC /etc/issue` OS_RASPBIAN=`grep -m1 -c 'Raspbian\|RetroPie' /etc/issue` @@ -99,7 +100,7 @@ if [ $CPU_RPI -eq 1 ] && [ $OS_OPENELEC -ne 1 ]; then echo '---> Raspberry Pi found, but SPI is not ready, we write "dtparam=spi=on" to /boot/config.txt' sed -i '$a dtparam=spi=on' /boot/config.txt REBOOTMESSAGE="echo Please reboot your Raspberry Pi, we inserted dtparam=spi=on to /boot/config.txt" - fi + fi fi #Check, if dtparam=spi=on is in place (just for OPENELEC) @@ -128,7 +129,10 @@ if [ $BETA -eq 1 ]; then else HYPERION_ADDRESS=https://sourceforge.net/projects/hyperion-project/files/release fi # Select the appropriate release -if [ $CPU_RPI -eq 1 ] && [ $OS_OPENELEC -eq 1 ] && [ $RPI_1 -eq 1 ]; then +if [ $CPU_RPI -eq 1 ] && [ $OS_RASPLEX -eq 1 ]; then + HYPERION_RELEASE=$HYPERION_ADDRESS/hyperion_rpi_rasplex.tar.gz + OE_DEPENDECIES=$HYPERION_ADDRESS/hyperion.deps.openelec-rpi.tar.gz +elif [ $CPU_RPI -eq 1 ] && [ $OS_OPENELEC -eq 1 ] && [ $RPI_1 -eq 1 ]; then HYPERION_RELEASE=$HYPERION_ADDRESS/hyperion_rpi_oe.tar.gz OE_DEPENDECIES=$HYPERION_ADDRESS/hyperion.deps.openelec-rpi.tar.gz elif [ $CPU_RPI -eq 1 ] && [ $OS_OPENELEC -eq 1 ] && [ $RPI_2 -eq 1 ]; then diff --git a/bin/remove_hyperion.sh b/bin/remove_hyperion.sh index 7a828fd2..a8215c54 100644 --- a/bin/remove_hyperion.sh +++ b/bin/remove_hyperion.sh @@ -42,8 +42,8 @@ esac done echo "---> You entered \"$CONFIRM\". Remove Hyperion!" fi -# Find out if we are on OpenElec -OS_OPENELEC=`grep -m1 -c OpenELEC /etc/issue` +# Find out if we are on OpenElec or RasPlex +OS_OPENELEC=`grep -m1 -c 'OpenELEC\|RasPlex' /etc/issue` # check which init script we should use USE_SYSTEMD=`grep -m1 -c systemd /proc/1/comm` From f1c510bc8139381057b23e5c5362ca5972afaf33 Mon Sep 17 00:00:00 2001 From: brindosch Date: Thu, 5 May 2016 12:38:24 +0200 Subject: [PATCH 7/9] LibreELEC support added Former-commit-id: 8448696709ac57bb29f9e31d17125776e50ad2bb --- bin/install_hyperion.sh | 37 ++++++++++++++++++++++++++----------- 1 file changed, 26 insertions(+), 11 deletions(-) diff --git a/bin/install_hyperion.sh b/bin/install_hyperion.sh index 82bfa6fa..62d9edfa 100755 --- a/bin/install_hyperion.sh +++ b/bin/install_hyperion.sh @@ -23,7 +23,7 @@ fi #Set welcome message if [ $BETA -eq 1 ]; then WMESSAGE="echo This script will update Hyperion to the latest BETA" -else WMESSAGE="echo This script will install/update Hyperion ambilight" +else WMESSAGE="echo This script will install/update Hyperion Ambilight" fi #Welcome message @@ -33,7 +33,8 @@ echo 'Created by brindosch - hyperion-project.org - the official Hyperion source echo '*******************************************************************************' # Find out if we are on OpenElec (Rasplex) / OSMC / Raspbian -OS_OPENELEC=`grep -m1 -c 'OpenELEC\|RasPlex' /etc/issue` +OS_OPENELEC=`grep -m1 -c 'OpenELEC\|RasPlex\|LibreELEC' /etc/issue` +OS_LIBREELEC=`grep -m1 -c LibreELEC /etc/issue` OS_RASPLEX=`grep -m1 -c RasPlex /etc/issue` OS_OSMC=`grep -m1 -c OSMC /etc/issue` OS_RASPBIAN=`grep -m1 -c 'Raspbian\|RetroPie' /etc/issue` @@ -99,20 +100,25 @@ if [ $CPU_RPI -eq 1 ] && [ $OS_OPENELEC -ne 1 ]; then if [ $SPIOK -ne 1 ]; then echo '---> Raspberry Pi found, but SPI is not ready, we write "dtparam=spi=on" to /boot/config.txt' sed -i '$a dtparam=spi=on' /boot/config.txt - REBOOTMESSAGE="echo Please reboot your Raspberry Pi, we inserted dtparam=spi=on to /boot/config.txt" + if [ $HCInstall -ne 1 ]; then + REBOOTMESSAGE="echo Please reboot your Raspberry Pi, we inserted dtparam=spi=on to /boot/config.txt" + fi fi fi -#Check, if dtparam=spi=on is in place (just for OPENELEC) +#Check, if dtparam=spi=on is in place (just for OPENELEC/LibreELEC +) if [ $CPU_RPI -eq 1 ] && [ $OS_OPENELEC -eq 1 ]; then SPIOK=`grep '^\dtparam=spi=on' /flash/config.txt | wc -l` if [ $SPIOK -ne 1 ]; then mount -o remount,rw /flash - echo '---> Raspberry Pi with OpenELEC found, but SPI is not ready, we write "dtparam=spi=on" to /flash/config.txt' + echo '---> Raspberry Pi with OpenELEC/LibreELEC found, but SPI is not set, we write "dtparam=spi=on" to /flash/config.txt' sed -i '$a dtparam=spi=on' /flash/config.txt mount -o remount,ro /flash - REBOOTMESSAGE="echo Please reboot your OpenELEC, we inserted dtparam=spi=on to /flash/config.txt" - fi + if [ $HCInstall -ne 1 ]; then + REBOOTMESSAGE="echo Please reboot your OpenELEC/LibreELEC, we inserted dtparam=spi=on to /flash/config.txt" + fi + fi fi #Backup the .conf files, if present @@ -132,6 +138,15 @@ fi if [ $CPU_RPI -eq 1 ] && [ $OS_RASPLEX -eq 1 ]; then HYPERION_RELEASE=$HYPERION_ADDRESS/hyperion_rpi_rasplex.tar.gz OE_DEPENDECIES=$HYPERION_ADDRESS/hyperion.deps.openelec-rpi.tar.gz +elif [ $CPU_RPI -eq 1 ] && [ $OS_LIBREELEC -eq 1 ] && [ $RPI_1 -eq 1 ]; then + HYPERION_RELEASE=$HYPERION_ADDRESS/hyperion_rpi_le.tar.gz + OE_DEPENDECIES=$HYPERION_ADDRESS/hyperion.deps.openelec-rpi.tar.gz +elif [ $CPU_RPI -eq 1 ] && [ $OS_LIBREELEC -eq 1 ] && [ $RPI_2 -eq 1 ]; then + HYPERION_RELEASE=$HYPERION_ADDRESS/hyperion_rpi2_le.tar.gz + OE_DEPENDECIES=$HYPERION_ADDRESS/hyperion.deps.openelec-rpi.tar.gz +elif [ $CPU_RPI -eq 1 ] && [ $OS_LIBREELEC -eq 1 ] && [ $RPI_3 -eq 1 ]; then + HYPERION_RELEASE=$HYPERION_ADDRESS/hyperion_rpi3_le.tar.gz + OE_DEPENDECIES=$HYPERION_ADDRESS/hyperion.deps.openelec-rpi.tar.gz elif [ $CPU_RPI -eq 1 ] && [ $OS_OPENELEC -eq 1 ] && [ $RPI_1 -eq 1 ]; then HYPERION_RELEASE=$HYPERION_ADDRESS/hyperion_rpi_oe.tar.gz OE_DEPENDECIES=$HYPERION_ADDRESS/hyperion.deps.openelec-rpi.tar.gz @@ -171,9 +186,9 @@ fi echo '---> Downloading the appropriate Hyperion release' if [ $OS_OPENELEC -eq 1 ]; then # OpenELEC has a readonly file system. Use alternative location - echo '---> Downloading Hyperion OpenELEC release' + echo '---> Downloading Hyperion OpenELEC/LibreELEC release' curl -# -L --get $HYPERION_RELEASE | tar -C /storage -xz - echo '---> Downloading Hyperion OpenELEC dependencies' + echo '---> Downloading Hyperion OpenELEC/LibreELEC dependencies' curl -# -L --get $OE_DEPENDECIES | tar -C /storage/hyperion/bin -xz #set the executen bit (failsave) chmod +x -R /storage/hyperion/bin @@ -213,13 +228,13 @@ elif [ $OS_OPENELEC -eq 1 ]; then mkdir /storage/logfiles 2>/dev/null touch /storage/.config/autostart.sh 2>/dev/null if [ `cat /storage/.config/autostart.sh 2>/dev/null | grep hyperiond | wc -l` -eq 0 ]; then - echo '---> Adding Hyperion to OpenELEC autostart.sh' + echo '---> Adding Hyperion to OpenELEC/LibreELEC autostart.sh' echo "/storage/hyperion/bin/hyperiond.sh /storage/.config/hyperion.config.json > /storage/logfiles/hyperion.log 2>&1 &" >> /storage/.config/autostart.sh chmod +x /storage/.config/autostart.sh fi # only add hyperion-x11 to startup, if not found and x32x64 detected if [ $CPU_X32X64 -eq 1 ] && [ `cat /storage/.config/autostart.sh 2>/dev/null | grep hyperion-x11 | wc -l` -eq 0 ]; then - echo '---> Adding Hyperion-x11 to OpenELEC autostart.sh' + echo '---> Adding Hyperion-x11 to OpenELEC/LibreELEC autostart.sh' echo "DISPLAY=:0.0 LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/storage/hyperion/bin /storage/hyperion/bin/hyperion-x11 /storage/logfiles/hyperion.log 2>&1 &" >> /storage/.config/autostart.sh fi elif [ $USE_SYSTEMD -eq 1 ]; then From 2b077aad9486e4288357c77473753f93d1086e5f Mon Sep 17 00:00:00 2001 From: brindosch Date: Thu, 5 May 2016 12:42:34 +0200 Subject: [PATCH 8/9] typo fix Former-commit-id: 9525da45219ba48a8e45ac275182f17016b9f7b5 --- bin/install_hyperion.sh | 1 - 1 file changed, 1 deletion(-) diff --git a/bin/install_hyperion.sh b/bin/install_hyperion.sh index 62d9edfa..7b7a354d 100755 --- a/bin/install_hyperion.sh +++ b/bin/install_hyperion.sh @@ -107,7 +107,6 @@ if [ $CPU_RPI -eq 1 ] && [ $OS_OPENELEC -ne 1 ]; then fi #Check, if dtparam=spi=on is in place (just for OPENELEC/LibreELEC -) if [ $CPU_RPI -eq 1 ] && [ $OS_OPENELEC -eq 1 ]; then SPIOK=`grep '^\dtparam=spi=on' /flash/config.txt | wc -l` if [ $SPIOK -ne 1 ]; then From fdbbdd09cc992ca9da8395ca01dc7e7841291bb7 Mon Sep 17 00:00:00 2001 From: brindosch Date: Thu, 5 May 2016 12:55:11 +0200 Subject: [PATCH 9/9] prevent spam Former-commit-id: 3848e23575cb73e322652a9d2f2b677c64763f14 --- bin/install_hyperion.sh | 6 +++--- bin/remove_hyperion.sh | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/bin/install_hyperion.sh b/bin/install_hyperion.sh index 7b7a354d..c0b05212 100755 --- a/bin/install_hyperion.sh +++ b/bin/install_hyperion.sh @@ -98,7 +98,7 @@ fi if [ $CPU_RPI -eq 1 ] && [ $OS_OPENELEC -ne 1 ]; then SPIOK=`grep '^\dtparam=spi=on' /boot/config.txt | wc -l` if [ $SPIOK -ne 1 ]; then - echo '---> Raspberry Pi found, but SPI is not ready, we write "dtparam=spi=on" to /boot/config.txt' + echo '---> Raspberry Pi found, but SPI is not set, we write "dtparam=spi=on" to /boot/config.txt' sed -i '$a dtparam=spi=on' /boot/config.txt if [ $HCInstall -ne 1 ]; then REBOOTMESSAGE="echo Please reboot your Raspberry Pi, we inserted dtparam=spi=on to /boot/config.txt" @@ -111,7 +111,7 @@ if [ $CPU_RPI -eq 1 ] && [ $OS_OPENELEC -eq 1 ]; then SPIOK=`grep '^\dtparam=spi=on' /flash/config.txt | wc -l` if [ $SPIOK -ne 1 ]; then mount -o remount,rw /flash - echo '---> Raspberry Pi with OpenELEC/LibreELEC found, but SPI is not set, we write "dtparam=spi=on" to /flash/config.txt' + echo '---> RPi with OpenELEC/LibreELEC found, but SPI is not set, we write "dtparam=spi=on" to /flash/config.txt' sed -i '$a dtparam=spi=on' /flash/config.txt mount -o remount,ro /flash if [ $HCInstall -ne 1 ]; then @@ -222,7 +222,7 @@ if [ $USE_INITCTL -eq 1 ]; then initctl reload-configuration elif [ $OS_OPENELEC -eq 1 ]; then #modify all old installs with a logfile output - sed -i 's|/dev/null|/storage/logfiles/hyperion.log|g' /storage/.config/autostart.sh + sed -i 's|/dev/null|/storage/logfiles/hyperion.log|g' /storage/.config/autostart.sh 2>/dev/null # only add to start script if hyperion is not present yet mkdir /storage/logfiles 2>/dev/null touch /storage/.config/autostart.sh 2>/dev/null diff --git a/bin/remove_hyperion.sh b/bin/remove_hyperion.sh index a8215c54..c3034032 100644 --- a/bin/remove_hyperion.sh +++ b/bin/remove_hyperion.sh @@ -43,7 +43,7 @@ done echo "---> You entered \"$CONFIRM\". Remove Hyperion!" fi # Find out if we are on OpenElec or RasPlex -OS_OPENELEC=`grep -m1 -c 'OpenELEC\|RasPlex' /etc/issue` +OS_OPENELEC=`grep -m1 -c 'OpenELEC\|RasPlex\|LibreELEC' /etc/issue` # check which init script we should use USE_SYSTEMD=`grep -m1 -c systemd /proc/1/comm`