Jump to content
C4 Forums | Control4

Any way to change TCP action to a light?


Recommended Posts

I have some LED light strips in my kitchen that can be controlled by IP - they are compatible with the Magic Home phone app and flux_led.  I have written some python code that controls this that can be accessed via a web browser.  So when I get "http://192.168.1.104/cgi-bin/led_control?ip=192.168.1.211&command=toggle" it will toggle the lights.  I can access this web site in C4 thanks to the Chowmain Generic TCP driver.  Is there any way I can make this appear in C4 as a light?  Or would I essentially have to write my own driver to do that?

Link to comment
Share on other sites


might be able to use the Chowmain generic light or generic dimmer light driver, do the IR binding and fire the tcp commands based on the state? not really ideal because you are not getting to use feedback but i used it for my smartthings lamp outlets via IFTTT for a while before getting a vera hub. im sure making your own driver would be better but depends on how much time you want to throw at it

Link to comment
Share on other sites

You could try an "experience button". The icon could be changed to look like a light but it wouldnt actually be a light.  It could be programmed to turn on or off the led strip every time its pressed

Link to comment
Share on other sites

Problem with experience buttons is that they don't show under lights. (and there IS actually a light bulb experience button, for color changing LED that you could set to just use white and off)

Nicest solution is to get the Chowmain relay to light driver, use an empty controller relay so it keeps full track and program on light toggle to send the IP command.

Link to comment
Share on other sites

21 minutes ago, eddy.trochez said:

I have used Alan's driver as suggested by Sonic, and it would be perfect for what the OP wants to do. Light would appear in the Lighting Menu as a switch. 

Yep that would work just fine.

Link to comment
Share on other sites

8 hours ago, sonic30101 said:

Programing based on light state to fire the appropriate TCP commands. The c4 driver being ir or relay is irrelevant in the big picture, it will open/close the relay or fire the ir commands but that wont matter

the relay to light driver requires binding to a relay for it to change state.  the generic lighting driver just assumes that its changed states when it 'fires' ir.  no binding to infra red is required and no ir code is necessary.

Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.