Looked all over for a way to control Hyperion through a web call, primarily so I could control from WebCore in SmartThings. It can't send raw TCP. Could find anything, so rolled my own. Thought I'd share in case in helps anyone else.
1) Add a couple python modules on your Raspi that runs hyperion.
pip install bottle
pip install bottledaemon
2) The python script that runs the web server and add endpoints for color and effects:
from bottledaemon import daemon_run
from bottle import route, run, template
import subprocess
@route('/color/<colorid>')
def index(colorid):
subprocess.check_output(['/usr/bin/hyperion-remote', '--color', colorid])
return "done"
@route('/effect/<effectname>')
def index(effectname):
subprocess.check_output(['/usr/bin/hyperion-remote', '--effect', effectname])
return "done"
@route('/clearall')
def index():
subprocess.check_output(['/usr/bin/hyperion-remote', '--clearall'])
return "done"
if __name__ == "__main__":
daemon_run(host="0.0.0.0", port="8080")
3) Start the python script using nohup so you can close your connection and it keep running.
nohup /usr/bin/python /home/pi/Documents/hyperionweb.py start
4) make a standard http request to control.
http://192.168.2.71:8080/effect/Cold%20mood%20blobs
http://192.168.2.71:8080/color/ff0000
http://192.168.2.71:8080/clearall
Hopefully this is useful to someone. And hopefully I didn't overlook something completely obvious and do it the hard way.
milhouse