Custom RGB Light Plugin

Post Reply
miroslavpetrov
Posts: 14
Joined: Wednesday 03 February 2016 14:35
Target OS: Raspberry Pi
Domoticz version:
Contact:

Custom RGB Light Plugin

Post by miroslavpetrov » Saturday 09 September 2017 9:01

Hello everyone!
I bought few RGB Light bulbs that are based on ESP8266. The come with nice firmware which enables them to be controlled with HTTP requests.
I want to make a domoticz plugin for those(python preferably). Can you give me some guidance on how to begin. I was thinking of rewriting the plugin for Yeelight but I cannot find where the plugins are stored in domoticz.
Domoticz on Raspberry Pi 3 with HomeBridge.
RFXCOM, Xiaomi Smart Home, Broadlink RM3, Shelly Smart Bulbs, EasyESP custom sensors.

deennoo
Posts: 900
Joined: Wednesday 10 December 2014 14:06
Target OS: Linux
Domoticz version: beta
Location: Bordeaux France
Contact:

Re: Custom RGB Light Plugin

Post by deennoo » Thursday 21 September 2017 19:20

miroslavpetrov wrote:Hello everyone!
I bought few RGB Light bulbs that are based on ESP8266. The come with nice firmware which enables them to be controlled with HTTP requests.
I want to make a domoticz plugin for those(python preferably). Can you give me some guidance on how to begin. I was thinking of rewriting the plugin for Yeelight but I cannot find where the plugins are stored in domoticz.
YeeLight isn't à plugin, that à part of domoticz (github source code), and it works great for me and other, with some lua script, we can drive every thing (white temp, scène, colorflow)

What is your esp8266 modules ?
Domoticz stable 3.5877 for real & Domoticz beta for test
Rfxtrxe / RFLink / Milight / Yeelight / ESP8266 / MQTT / BLE
http://domo-attitude.fr

miroslavpetrov
Posts: 14
Joined: Wednesday 03 February 2016 14:35
Target OS: Raspberry Pi
Domoticz version:
Contact:

Re: Custom RGB Light Plugin

Post by miroslavpetrov » Friday 22 September 2017 16:41

It is Shelly RGB bulb. Its firmware is based on mangoose OS. Here is an example http request:

http://192.168.1.20/color/0?turn=on&red ... 55&white=0

Can you give me some guidance how to begin with writing a LUA script or a python plugin in order to use domoticz's color picker?
Domoticz on Raspberry Pi 3 with HomeBridge.
RFXCOM, Xiaomi Smart Home, Broadlink RM3, Shelly Smart Bulbs, EasyESP custom sensors.

deennoo
Posts: 900
Joined: Wednesday 10 December 2014 14:06
Target OS: Linux
Domoticz version: beta
Location: Bordeaux France
Contact:

Re: Custom RGB Light Plugin

Post by deennoo » Friday 22 September 2017 18:06

Colorpicker isn't on rgb but hsv, you have to use à translator if you want to use it.

On Lua you Can parse thé json value : https://www.domoticz.com/wiki/Domoticz_ ... fic_device

Another simple solution already used for hyperion plugin, or playbulb one's is to create 4. Dimmer :
Red
Green
Blue
white : if existe on your bulb
Domoticz stable 3.5877 for real & Domoticz beta for test
Rfxtrxe / RFLink / Milight / Yeelight / ESP8266 / MQTT / BLE
http://domo-attitude.fr

Post Reply

Who is online

Users browsing this forum: No registered users and 6 guests