Script to turn on/off hyperion gives error - Printable Version +- Kodi Community Forum (https://forum.kodi.tv) +-- Forum: Support (https://forum.kodi.tv/forumdisplay.php?fid=33) +--- Forum: General Support (https://forum.kodi.tv/forumdisplay.php?fid=111) +---- Forum: Raspberry Pi (https://forum.kodi.tv/forumdisplay.php?fid=166) +---- Thread: Script to turn on/off hyperion gives error (/showthread.php?tid=192905) |
Script to turn on/off hyperion gives error - stewiegriffin - 2014-04-22 Hello, I used to use raspbmc with hyperion and the following script to enable/disable hyperion with my usb remote: Code: import subprocess Now im using Openelec and installed hyperion, which works, but the script gives me back an error. I checked the log and this is what it shows: Code: 20:44:08 T:2732581984 ERROR: EXCEPTION Thrown (PythonToCppException) : -->Python callback/script returned the following error<-- Now it seems that it can find a file and from the script is probably initctl and i have searched for that file/directory so i could change the path on the script but i can't find it =/ Anyone knows how to fix this error or what change can i try to make on the script to make this work? Thank you![/quote] RE: Script to turn on/off hyperion gives error - Milhouse - 2014-04-23 OpenELEC doesn't use /sbin/initctl (it uses systemd). Also, because of the read-only file system used by OpenELEC, hyperion has to install it's own startup script in /storage/hyperion/bin/hyperiond.sh which is (normally) called from /storage/.config/autostart.sh. Not sure if you've followed this procedure, but it appears that in OpenELEC there is no concept of stopping/starting Hyperion - it's always started from the very outset. Maybe you can implement you're own method of stopping/starting Hyperion, that looks straight forward enough. RE: Script to turn on/off hyperion gives error - stewiegriffin - 2014-04-23 Thank you for the reply and explanation! I followed the instructions on the hyperion github page and it was basicly just a command that does all the work. I will look into having a way to start-stop hyperion, and also to control the lights because the app doesn't seem to be working with openelec =/ I dont really know about code/scripts ( unfortunately), but if i end up finding a solution i will share it here to anyone that might need it also RE: Script to turn on/off hyperion gives error - Flaq69 - 2015-04-28 # Milhouse Hallo, thx for all your support and help in this forum ! I am trying to get the guide to work in order to turn on/off Hyperion on Openelec: how-to-enabledisable-hyperion-on-openelec-with-remote Maybe you can help looking/debug this guide ? I am currently using the latest build #0427 : RPI2 I have followed the guide and have also changed the path from: <blue>XBMC.System.Exec("/storage/hyperion/hyperionswitch.sh")/blue> to <blue>XBMC.System.Exec("/storage/hyperion/hyperionswitch.sh")</blue> but it does not work for me do you have any suggestions ? I am trying to upload the log file but i have a problem with the file. I will upload asap. I am so happy for using your builds of Openelec hence it would be great if we could use this feature All regards F RE: Script to turn on/off hyperion gives error - KenV99 - 2015-08-05 I know this thread is months old, but since I was looking for this solution and then rolled my own, I figured I'd post it here in case others searched and ended up here as I did. On OpenELEC, place the following python script (which I'll call 'hyperion_switch.py' below) somewhere that Kodi can access it: Code: #!/usr/bin/python Then place the following or something similar in a file called keyboard.xml in /storage/.kodi/userdata/keymaps (replace $PATH_TO_SCRIPT with the path that you placed the .py file in above): Code: <?xml version="1.0" encoding="UTF-8" standalone="yes"?> Here, I am using alt-ctrl-a and alt-ctrl-b but you can use whatever keypresses you want (refer to the wiki: Keymap (wiki)) RE: Script to turn on/off hyperion gives error - b0br0ff - 2016-01-16 I guess this way is more simple ... Code: #!/bin/bash |