How to address the yeelight bulb via a script?

Hi everyone,
i’m searching for a possibility to address the RGBW Yeelight Bulb with a script.
My plan to address the bulb with a specified & predefined color and brightness without using the yeelight app or something similar. Straight from a PC or raspberry console/terminal or as a normal script.

My setup:

Raspberry PI 3 with Homebridge
7x Yeelight RGBW bulbs
Yeelight 3.0 beta and Apple Home for bulb control

So, is there any way to control the bulb via a script? If so, how’s the code?


IP-Adress 123.456.123.456
Brightness: 30


I’m sorry… I didn’t find the pdf through my search with the mobile phone.

Do you have an example file which is JSON-formatted?

Grant your device ip address is 123.456.123.456, you can use telnet to control it:

telnet 123.456.123.456 55443
Trying 123.456.123.456…
Connected to 123.456.123.456.
Escape character is ‘^]’.

 // Command : powe on/off

 // Command :  change bright
 {"id":1,"method":"set_bright","params":[%value, "smooth", 200]}

 // Command : change color temperature
{"id":1,"method":"set_ct_abx","params":[%value, "smooth", 500]}

You can have a try, good luck!

Hello. I have a .php program that does what you are looking for. I run it on CentOS 6, I think I tried it on the “pi” and it was ok. I would be happy to share but I don’t think I can post a link on this forum. Ideas?

Unfortunately i didn#t find any time to get more into it… working :sleepy:
But i will grab up the info of @dingyichen and try to realise some tasker scripting.

I think it’s okay to post links here @WWBoxer