Beiträge von milhouse

    Sorry for the delayed reply. Travelling this week.


    You should not need to change the IP addresss 0.0.0.0. That just lets it accept on any network connect. If you had multiple, you could specift which address it should listen on. Port doesn't matter - you should be able to set any non-conflicting port for it to listen on (the 8080 in my code snippet). Obviosuly, you'd change the URLs to the same port.


    Set up port forwarding on your router for that port so an external call to your (external) IP address would go to your pi.


    Most ISPs don't actually change your IP address very often - my usually lasts for months without change. But if it's a problem look into a dynamic dns service so you could call by address instead of IP.

    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

    Well, I tried one more thing. The Meanwell power supply I am using is a 5v, 320W supply. It's also somewhat adjustable, 4.5V-5.5V per spec. First, I tried turning it up all the way to try and overcome the voltage drop. That actually made things a little worse. Then I turned the voltage (almost) all the way down. That resolved all the flickering. I may have lost a bit of brightness, but colors are still consistent. I'll take it.


    I'll give it a week or so to confirm that it's stable, then I've got some serious ladder work to do.

    I've been slowly working on this project. Starting with a portion of the lights I can reach "easily" with my 28 foot ladder. (Will have to rent a 40 ladder for the high parts!).


    Still trying to get this 137 LED proof of concept working reliably. Right now I go from the Pi to a level shifter to the light strips. I am using the same wire lengths I will be using to get all the way to the "real" start when the lights are complete. Probably about 40 feet of wire for the data/clock lines and the 5v / ground.


    When I used shorter wires (~15 feet) for testing, things were perfect. With the longer full length wires it works great for lower demand (e.g. color blob effects where all the lights aren't lit up) but gives flickering for more intensity, such as a warm white or bright white.


    Best guess, is this

    • an insufficient voltage issue on the power lines that I could resolve by using a 12v power supply + buck transformers to reduce to 5v at the strips (both ends) to ensure I overcome the voltage drop?
    • Or is this likely a data/clock issue where the wiring is just too long? I have seen some reference to using a resistor for long data lines, but not sure exactly what I'd need to do. Of course, there's the DMX boards from Akriss' fastled user group that has another option.


    Thanks in advance for any help. Big difference between getting this stuff to work behind a TV and getting it to work on long wiring runs...


    milhouse

    Your diagram didn't appear in your post, but I think you want the pi on the same power supply as the LEDs. Need to share a ground. Usually this results in things like flickering of the LEDs - haven't seen this is relation to a buzzing from the power supply.

    Haven't seen any posts around this, and wanted to float this idea out to see if I am off my rocker or if this could work.


    Here's what I want to do in the next couple of months:
    *string LED strips across the whole front of the house. Best guess is 5 x 5m strips. Thinking 36 leds/meter so I don't have TOO many LEDs. 60/m would be overkill on the exterior. That's still 900 independently controllable LEDs. APA102c.
    *to manage the power, power two strips (both ends of each) from one power supply, and another power supply on the other three strips (again, powering from both ends of all strips). The idea of two power supplies is to limit the length of the power lines.
    *Connect at one end to an RPi3 running Hyperion. I intend to configure it to have 0 lights on the bottom, left, and right, and 900 on the top. Obviously the point isn't for ambilight like around a tv, but just Hyperion effects or solid color.


    I've got some experience here - 2 Hyperion setups around TVs through Mediaportal, so I think I know what I am getting in to. But what I really want to know is:
    *Can I run the data / clock from the Pi through a string this long?
    *Would Hyperion work with just a "top" defined (again, for effects only)
    *Is my plan reasonably sound, or is this just too much to do for one run and ought to be split up into independent sets? I'd really like to be able to do, say, the knight rider effect all the way across the house and not just a segment.


    Any input would great great before I bite this project off!


    Milhouse