This is the forum archive of Homey. For more information about Homey, visit the Official Homey website.

The Homey Community has been moved to https://community.athom.com.

This forum is now read-only for archive purposes.
Closed

App to support Yeelight

124»

Comments

  • FloodnlFloodnl Member
    edited June 2017
    @Phuturist  Maybe a dumb question but checking the Yeelight options of the bulb i notice also a developer mode so you can control the app. You are aware of this?  or does this even needs to be on using your app? 

    (about to start installing the lights, just wondering if we could make it easyer for the nontechnical users that have Homey)





  • Floodnl said:
    @Phuturist  Maybe a dumb question but checking the Yeelight options of the bulb i notice also a developer mode so you can control the app. You are aware of this?  or does this even needs to be on using your app? 

    (about to start installing the lights, just wondering if we could make it easyer for the nontechnical users that have Homey)





    I actually noticed this as well yesterday (I was using the Mi Home app which does not have this option and the Yeelights are just a bonus in this app as I was actually making the app for the Mi Robot Vacuumcleaner mainly).

    I have investigated this and it should be possible for at least the Yeelights to be paired more easily. This will use another controlling mechanism than the other Mi Home devices which are part of this app, so the question comes to mind if the Yeelights should then get it's own app or if I try to integrate this other mechanism into this same app as well (as more apps are not good for mem usage anyway).
  • Phuturist said:
    Floodnl said:
    @Phuturist  Maybe a dumb question but checking the Yeelight options of the bulb i notice also a developer mode so you can control the app. You are aware of this?  or does this even needs to be on using your app? 

    (about to start installing the lights, just wondering if we could make it easyer for the nontechnical users that have Homey)





    I actually noticed this as well yesterday (I was using the Mi Home app which does not have this option and the Yeelights are just a bonus in this app as I was actually making the app for the Mi Robot Vacuumcleaner mainly).

    I have investigated this and it should be possible for at least the Yeelights to be paired more easily. This will use another controlling mechanism than the other Mi Home devices which are part of this app, so the question comes to mind if the Yeelights should then get it's own app or if I try to integrate this other mechanism into this same app as well (as more apps are not good for mem usage anyway).
    Btw just as fyi  the ip of my lamp was 192.168.13.1  so not the 192.168.8.1 just have tinkered a bit but at the moment unable to connect but i haven't looked into it to deep
  • RuudvBRuudvB Member
    edited June 2017
    Phuturist said:
    It's up in the app store, it's still beta but on/off, dim and color temperature should be working. But i'm sure there will be bugs, therefor it's beta and I hope to hear from you guys on what needs improvement. You can use the app topic or the github repo for submitting bugs.

    App store: https://apps.athom.com/app/com.xiaomi-miio
    Forum topic: https://forum.athom.com/discussion/3295/
    Github issues: https://github.com/jghaanstra/com.xiaomi-miio/issues
    Great work!

    Just installed your app and found the IP-addresses of the bulbs in my routers DHCP table. Now, finding the token.... pff, that is not so simple...

    @Floodnl did you already mannage to find your tokens?

    I put one of the bulbs in developer mode, just in case this should make any difference.


  • FloodnlFloodnl Member
    edited June 2017
    RuudvB said:
    Phuturist said:
    It's up in the app store, it's still beta but on/off, dim and color temperature should be working. But i'm sure there will be bugs, therefor it's beta and I hope to hear from you guys on what needs improvement. You can use the app topic or the github repo for submitting bugs.

    App store: https://apps.athom.com/app/com.xiaomi-miio
    Forum topic: https://forum.athom.com/discussion/3295/
    Github issues: https://github.com/jghaanstra/com.xiaomi-miio/issues
    Great work!

    Just installed your app and found the IP-addresses of the bulbs in my routers DHCP table. Now, finding the token.... pff, that is not so simple...

    @Floodnl did you already mannage to find your tokens?


    Yea it was easy (i did use my phone not his app as my pc has no WiFi The Android app is called: UDP Sender / Receiver  and has the icond that looks like:
     Cover art

    Now i have to get it connected to homey  this is how i setup the app





    Ps if anyone needs help doing this i am willing to chip in and make a step by step manual. 
    UDP.png 191.7K
  • Back on topic i give up for the moment i (sadly) do not have the time at the moment  but i keep getting that the session is invalid. 
  • Floodnl said:
    Back on topic i give up for the moment i (sadly) do not have the time at the moment  but i keep getting that the session is invalid. 
    Please post it as a bug on Github or in the support topic of the app with details if you believe it's a bug of the app. This info is a too little to work with ... :+1:

  • FloodnlFloodnl Member
    edited June 2017
    Phuturist said:
    Floodnl said:
    Back on topic i give up for the moment i (sadly) do not have the time at the moment  but i keep getting that the session is invalid. 
    Please post it as a bug on Github or in the support topic of the app with details if you believe it's a bug of the app. This info is a too little to work with ... :+1:

    Nope it works fine, it seems te been my mistake (i think) as soon as i left the lamp in a on (burning) state  i was able to add it without any issues!  now time to play and add in the other lights. i'll report tomorrow :)
  • RuudvBRuudvB Member





    Ps if anyone needs help doing this i am willing to chip in and make a step by step manual. 
    Thanks for this! I tried using the app, but I get an error stating that there was a problem to send/receive.
    I used the details from above, only changed the IP address to one of my Yeelights.

    What exactly does the message part do? How many fffff do I need to fill in?
    Help is appreciated :)
  • FloodnlFloodnl Member
    edited June 2017
    RuudvB said:





    Ps if anyone needs help doing this i am willing to chip in and make a step by step manual. 
    Thanks for this! I tried using the app, but I get an error stating that there was a problem to send/receive.
    I used the details from above, only changed the IP address to one of my Yeelights.

    What exactly does the message part do? How many fffff do I need to fill in?
    Help is appreciated :)
    Make sure you have it set on HEX and there are 56x f  in it  the code response you get you need to pick the last 32 characters

    And of course connect your phone to the wifi of your lamp in reset mode
  • anneanne Member
    The procedure is described in the Readme, including the HEX string: https://apps.athom.com/app/com.xiaomi-miio.

    • HEX: 21310020ffffffffffffffffffffffffffffffffffffffffffffffffffffffff

  • Hey I don't know if you are still looking for an app that controls Yeelight but maybe, this could work: 

    Yeti: https://play.google.com/store/apps/details?id=com.netbeast.yeti
    https://itunes.apple.com/us/app/yeti-smart-home/id1190638808?mt=8

  • Hey I don't know if you are still looking for an app that controls Yeelight but maybe, this could work: 

    Yeti: https://play.google.com/store/apps/details?id=com.netbeast.yeti
    https://itunes.apple.com/us/app/yeti-smart-home/id1190638808?mt=8

    Thanks for your tip, but there is a working homey app now: https://apps.athom.com/app/com.xiaomi-miio

  • My Yeelight led strip just arrived and I was kinda hoping it would just work via the Zigbee-protocol, but they have their own protocol. I switched on developer mode and I found the IP of the Led strip by looking at the DHCP table. The "Yealigh 3rd party control protocol" in the Yeelight app links to a developer image, so that was not very helpful. The Chrome app from https://www.yeelight.com/en_US/developer did not work for me but the windows app did. It's in Chinese but it did detect the led strip and I was able to control it via the app (on/off). I'm now downloading wireshark to see what they send to the led strip.
  • MarkV said:
    My Yeelight led strip just arrived and I was kinda hoping it would just work via the Zigbee-protocol, but they have their own protocol. I switched on developer mode and I found the IP of the Led strip by looking at the DHCP table. The "Yealigh 3rd party control protocol" in the Yeelight app links to a developer image, so that was not very helpful. The Chrome app from https://www.yeelight.com/en_US/developer did not work for me but the windows app did. It's in Chinese but it did detect the led strip and I was able to control it via the app (on/off). I'm now downloading wireshark to see what they send to the led strip.
    I plan to implement at least basic support for the Yeelight LED strip in the Xiaomi Mi Home app in the app store. I have started rewritting it for SDK 2 / Homey firmware 2.0.0. That will take some time (rather months than weeks), and it's hard to test anything since I dont own the device myself so there may be bugs in the beginning.

    If you have any programming knowledge I'd be more than happy to accept pull requests here: https://github.com/jghaanstra/com.xiaomi-miio
  • MarkVMarkV Member
    edited September 2017
    It's a long time since I've done this but...

    The windows app sends data to port 55443. Is sends multiple types of messages:
    SYN (Sync) 
    PSH (Push) and
    ACK (Acknowledged)
    FIN (Finished)

    The Push is the most relevant one, it goes over TCP :

    On

    {"id":0x000000000361970a,"method":"toggle","params":[]}
    {"id":0, "result":["ok"]}
    {"method":"props","params":{"power":"on"}}

    Off
    {"id":0x000000000361970a,"method":"toggle","params":[]}
    {"id":0, "result":["ok"]}
    {"method":"props","params":{"power":"off"}}


    I also found some other things that might be useful for the LED strip:

    https://www.domoticz.com/wiki/Yeelight.

    and

    https://github.com/octa22/org.openhab.binding.yeelight

  • I just got my first Yeelights and have them set up great with Homey app so far, so thanks.

    I'm actually replacing my Hue lights and one thing I can't seem to find is a way to do which is available on the Hue is set these to "Change Brightness Over Time" - is there such a way? I.e dim the lights to zero over a period of 15minutes?

    Thanks
  • I have 2 Yeelight bulbs as devices in Homey, but sometimes they do not respond. Sometimes only one of them responds. I have to go to the official Yeelight app and control them from there. There they do respond every time. Does this sound familiar? Is there a way to solve this?
  • vaderag said:
    I just got my first Yeelights and have them set up great with Homey app so far, so thanks.

    I'm actually replacing my Hue lights and one thing I can't seem to find is a way to do which is available on the Hue is set these to "Change Brightness Over Time" - is there such a way? I.e dim the lights to zero over a period of 15minutes?

    Thanks
    There is no such thing yet but feel free to submit it as a feature request in the repo here: https://github.com/jghaanstra/com.xiaomi-miio/issues May take some time to implement though as I'm struggling with the update to SDK2 of the Xiaomi Mi Home app.
    I have 2 Yeelight bulbs as devices in Homey, but sometimes they do not respond. Sometimes only one of them responds. I have to go to the official Yeelight app and control them from there. There they do respond every time. Does this sound familiar? Is there a way to solve this?
    Could be some buggy coding from my part. Will have to see how it works after the app is updated to SDK2 and troubleshoot from there.
  • Couple of quick questions...
    1) Is there a way to activate a scene that is saved to the Yeelight app from Homey?
    2) Is there a way to determine the # code of the current colour that the Yeelight is on? I see all the other values for Hue, Saturation etc in tags but don't see a way to get that...

    Reasoning - I have a tone that I've saved as a scene which is essentially a warm white - i'd like to ensure that whenever the light comes on it hits that tone initially. 

    Side note - I actually wish there was a way to save a new tone as your white entirely - I use them with Alexa and the white is too clinical and the 'warm white' that it defaults to is too orange... Also when I ask Alexa for Yellow oddly I get green...

    Thanks!
    P.S plan to test out the Beta app as soon as I get a bit of time - knee deep in decorating right now...
  • vaderag said:
    Couple of quick questions...
    1) Is there a way to activate a scene that is saved to the Yeelight app from Homey?
    2) Is there a way to determine the # code of the current colour that the Yeelight is on? I see all the other values for Hue, Saturation etc in tags but don't see a way to get that...

    Reasoning - I have a tone that I've saved as a scene which is essentially a warm white - i'd like to ensure that whenever the light comes on it hits that tone initially. 

    Side note - I actually wish there was a way to save a new tone as your white entirely - I use them with Alexa and the white is too clinical and the 'warm white' that it defaults to is too orange... Also when I ask Alexa for Yellow oddly I get green...

    Thanks!
    P.S plan to test out the Beta app as soon as I get a bit of time - knee deep in decorating right now...
    1) not sure, I don't believe I have seen it in the api documentation. The beta app allows you to create these scenes yourself though if you know what you are doing. But I'll look into it at a later time.
    2) that would require some custom coding I guess. What would you use it for?
    3) From the official app and now in the Homey beta app as well you can set a default for when the light goes on.
    4) I have no control over the built in Homey commands like default colors or Alexa for that matter.
  • Phuturist said:
    vaderag said:
    Couple of quick questions...
    1) Is there a way to activate a scene that is saved to the Yeelight app from Homey?
    2) Is there a way to determine the # code of the current colour that the Yeelight is on? I see all the other values for Hue, Saturation etc in tags but don't see a way to get that...

    Reasoning - I have a tone that I've saved as a scene which is essentially a warm white - i'd like to ensure that whenever the light comes on it hits that tone initially. 

    Side note - I actually wish there was a way to save a new tone as your white entirely - I use them with Alexa and the white is too clinical and the 'warm white' that it defaults to is too orange... Also when I ask Alexa for Yellow oddly I get green...

    Thanks!
    P.S plan to test out the Beta app as soon as I get a bit of time - knee deep in decorating right now...
    1) not sure, I don't believe I have seen it in the api documentation. The beta app allows you to create these scenes yourself though if you know what you are doing. But I'll look into it at a later time.
    2) that would require some custom coding I guess. What would you use it for?
    3) From the official app and now in the Homey beta app as well you can set a default for when the light goes on.
    4) I have no control over the built in Homey commands like default colors or Alexa for that matter.
    2) I wanted the # code of the colour to select the colour from the colour wheel correctly - i.e. i have the light set to a specific colour I selected in the app that I like. I want to set that colour in a flow, so I grab the # code for the colour to plug into the colour wheel in the flow and get the exact colour that it is on (rather than fumbling around trying to find the correct one)

    3) So I have, in theory, saved this in the official app, but it only seems to work on FULL power off, not just on an on/off command. I'll check out the Homey Beta App as soon as I can - sounds like adding some cool features :) This would probably suffer the same issue as above maybe as I guess I'll need a #code for the colour?

    4) Oh, I know - was purely mentioning it :)
  • New app crashes some times a day with below error message: 

                yeelightsid.socket.destroy();
                                    ^

    TypeError: Cannot read property 'destroy' of null
        at Socket.<anonymous> (/drivers/yeelights/device.js:122:33)
        at emitOne (events.js:120:20)
        at Socket.emit (events.js:210:7)
        at TCP.handle.close [as onclose] (net.js:545:12)
  • ncickc said:
    New app crashes some times a day with below error message: 

                yeelightsid.socket.destroy();
                                    ^

    TypeError: Cannot read property 'destroy' of null
        at Socket.<anonymous> (/drivers/yeelights/device.js:122:33)
        at emitOne (events.js:120:20)
        at Socket.emit (events.js:210:7)
        at TCP.handle.close [as onclose] (net.js:545:12)
     I'm away from home for some days, could you submit a bug in the repo at github so I can pick it up when I get home.
  • I'm not sure how to get the errors but I'm not in the beta yet and am getting a lot of crashes too...
  • Phuturist said:
    vaderag said:
    Couple of quick questions...
    1) Is there a way to activate a scene that is saved to the Yeelight app from Homey?
    2) Is there a way to determine the # code of the current colour that the Yeelight is on? I see all the other values for Hue, Saturation etc in tags but don't see a way to get that...

    Reasoning - I have a tone that I've saved as a scene which is essentially a warm white - i'd like to ensure that whenever the light comes on it hits that tone initially. 

    Side note - I actually wish there was a way to save a new tone as your white entirely - I use them with Alexa and the white is too clinical and the 'warm white' that it defaults to is too orange... Also when I ask Alexa for Yellow oddly I get green...

    Thanks!
    P.S plan to test out the Beta app as soon as I get a bit of time - knee deep in decorating right now...
    1) not sure, I don't believe I have seen it in the api documentation. The beta app allows you to create these scenes yourself though if you know what you are doing. But I'll look into it at a later time.
    2) that would require some custom coding I guess. What would you use it for?
    3) From the official app and now in the Homey beta app as well you can set a default for when the light goes on.
    4) I have no control over the built in Homey commands like default colors or Alexa for that matter.
    1) there is no api available to activate a scene saved in the Yeelight app, but if you know what you are doing you can recreate your scenes with the beta app within the Homey flows, either with the user friendly action cards or the custom command card for advanced users.
    2) the currently available tags are default functionality of Homey, I dont plan to extend this with RGB unless demand is high
    3) indeed the default state is only set on a full power cycle, in the next beta I'll introduce action cards that allow you to power on the Yeelight into a specific state (color or temperature and brightness). That should fit your needs.
This discussion has been closed.