Plugin: Yeelight

Although Yeelight support was promised by Vera some months ago, I got impatient and had a project that needed to get done, so I rolled by own. At this point, I probably will not release it officially (through the marketplace and AltAppStore), pending whatever the outcome of Vera’s efforts, but in the interim, if anyone else finds it useful, here it is.

Download releases from the Github repository, here:

Installation instructions are in the README file in the Github repo.

2019-01-05: Version 0.1, initial release. Set on/off, brightness, color temperature, RGB color, using Vera-standard Dimmable RGB Light service and device type. SSDP discovery of bulbs (requires that you first enable “LAN Control” on the bulb using the Yeelight mobile app).

There are so many of these lights available, makes me want to wait to see if prices come down substantially.
I recently bought a Magic light for a few bucks cheaper than this one that already has an add on with Vera. What made you choose this one?

[quote=“Jamr, post:2, topic:200363”]There are so many of these lights available, makes me want to wait to see if prices come down substantially.
I recently bought a Magic light for a few bucks cheaper than this one that already has an add on with Vera. What made you choose this one?[/quote]

Yeelight has some other interesting fixtures that I’m sourcing for a house. They all work on the same API. I’ve had one of their bulbs for a couple of years from an earlier eval. It turns out, the bulb is quite hardy, so I’m going to be using it in an outdoor fixture as both an illuminator and annunciator. They’re now part of Xiaomi, and the change in their product line since I bought the bulb is notable.

Thanks for the info and the add on. Love the simple design of it.

The UI is all Vera. I just rely on their standard RGB Dimmable Light type, service and UI. I figured that would have the best chance of working on the mobile apps.

Very nice! I believe we will be getting a handful of these at work coming soon. I will have to test this out! :slight_smile:

Nice work @rigpapa!

A fantastic start to things. Can’t wait to see how we can add this into the mix of things around here.

Fantastic work, really appreciate your efforts.

Do you have anything in the roadmap like activating colour flow or customised routines? I have a strobe function created in the Yeelight app that’s a really quick on / off loop and it would be great to control that via Vera!

As soon as I get Reactor 3.0 released and handle a few other smaller matters, I’ll be circling back to Yeelight and a related project. I’ll add this to my list.

1 Like

Any updates in the pipeline Sir?


I just upgraded from an early Yeelight plugin that I think I manually installed to the latest version from the Vera Marketplace. I re-added my RGB bulbs (2nd generation E26 bulbs) and now I can’t seem to get them to turn off in a scene.

As you can see in the image below the scene summary shows each light has an ‘off’ and a ‘pick a color’ action. The two Yeelight bulbs in this scene are the ‘front lamp’ and ‘rear lamp’. When I edited the scene from the mobile app I also sometimes got a ‘level 0’ action for a total of 3 actions per bulb.

I tried turning them on rather than off using this scene, and the on command works while the off command fails.

I have no problem turning the bulbs off when I access them via the ‘Devices’ page and toggle the on/off switch nor when I send a command via their API.

Any advice?


Can you go into the “Advanced Editor” in your screen (on the last page where you name the scene and save it) and post a screen shot of that. I’d like to see what it thinks it’s really doing.

Thanks for pointing me to the advanced editor - I’ve been using Vera for a long time and never even noticed it was there.

It looks like the issue is it wants to set power, level, then RGB. I’m guessing it’s actually turning off, then setting load level 0, then sending an RGB command that turns the light back on. I’m going to delete the power level and RGB commands in the advanced editor and will test.

OK. You can see in the advanced editor, the scene Vera has built turns the light off, and then sets the color. Setting the color turns the light on (just as setting brightness would for both color and non-color lights). Just delete those SetColorRGB actions and the scene should work fine.

hi Rigpapa, I’m a fan of your plugins. Reactor, DLT, VSwitch and Submaster (which i use in each room) are a great job for those who do not have programming experience and above all give a thousand more reasons to continue using ezlo-vera hub and remain in this community.
My bulbs are all zwave: Aeontec RGB, Zipato RGB, Domitech. I can control them with Reactor: on/off, brightness, color temperature, and RGB color but I like the idea to save and restore profiles on each bulb with gel colors.
Is there a workaround with non-wifi bulbs to control zwave or zigbee devices putting them in listed DeviceList and manage them with this plugin? and then to use ‘SetColor’ profile or RestoreColorProfile in Reactor --> activities?
Thanks in advance

This is how it is designed to work.

I just started with Yeelight… I used to Millight for quit a time with Vera and I’m using luup to control my lights with those…
luup.call_action(“urn:upnp-org:serviceId:SwitchPower1”,“SetTarget”,{ newTargetValue=“1” },device1)
luup.call_action(“urn:dcineco-com:serviceId:MiLightRGBW1”,“SetHue”,{newHue = 40},device1)
luup.call_action(“urn:upnp-org:serviceId:Dimming1”,“SetLoadLevelTarget”,{newLoadlevelTarget = 100},device1)

Now I’m trying to figure out if there is anyway to do the same thing with Yeeligth’s Plugin…

Thanks for your help…