Comments (4)
Hi. All Yeelights become devices of type light
.
In addition some lights can have an undocumented capability called color:rgb
which has a setRGB
method that takes a color in hex-format or as an object with the properties red
, green
, blue
with values between 0 and 255. The code for the color bulb can be found in the file yeelight.color.js
.
This is experimental and will probably change in the next few releases as I haven't had time to add proper support for all Yeelight features yet, for example #30 is an issue about adding support for hue and saturation.
from miio.
Ok. I know that.
I don't have any yeelight device,i want to know is these methods in this document ·https://www.yeelight.com/download/Yeelight_Inter-Operation_Spec.pdf· whether could be called in miio project?
if can, can i add method directly.
i have a project with mijia,https://github.com/rench/homebridge-smarthome/blob/master/kit/mijia/yeelight.js
, i use some method to covert hsv
to rgb
. i think it work correctly. but some other method can't be invoke like set_mode,set_ct methods in pdf document.
from miio.
The ambition is to support most of that in the end, but everything is not supported yet. And those that are supported may be named differently, an example would be set_ct
which is available if a light has the capability color:temperature
in which case the method setColorTemperature
is available.
And if something is missing you can always call any method on the device directly with call, which is how all the upper-level methods such as setRGB
and setPower
are implemented anyways. It's possible to do something like this device.call('set_power', [ 'off' ])
, but then you are communicating directly with the device and other implemented behaviour for the device might break.
from miio.
Ok, I see.
Some lighting equipment does not support the property, if I call the method certainly does not take effect. Because I do not have Yeelight's device, do not know if you can call the advanced method directly.
Since I saw Yeelight's PDF document, I thought that only way through the way that SSDP was called.
Do you use miio's command line to set some other properties of Yeelight, such as start_cf, because I do not know if the method of the PDF document is the same method name in the MIIO protocol.
from miio.
Related Issues (20)
- Not enough non-option arguments: got 0, need at least 1 error Command failed with exit code 1.
- Xiaomi Air Monitor cgllc.airm.cgdn1
- yeelight strip plus is supported?
- Can’t find Hub / Temperature-Sensors
- yeelink.light.color5 HOT 1
- Mi Smart LED Bulb (B22) - Support
- yeelink.light.mono6 HOT 1
- [add device request] yeelink.light.ceilb
- [add device request] yeelink.light.colorb
- -Bash: miio: command not found HOT 1
- doesn't work on Firmware version: 3.2.10
- Cannot connect to light after configuring wireless network HOT 1
- yeelink.light.bslamp2 HOT 2
- Create device with lib version >= 0.15.0
- Which devices can get tokens by "miio discover" or "mirobo discover --handshake 1"?
- Does this packge still getting maintained?
- Roborock S6 - 3.5.8._2902 - unsupported device
- colorTemperature2rgbUsingTH is not defined
- Device support [Vacum mop 2 ultra]
- Error connecting to device: Error: Call to device timed out
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from miio.