-
Notifications
You must be signed in to change notification settings - Fork 198
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add Color or Raw Info #327
Comments
Can you treat your firefly like a philips hue bridge? When you use the hue passthru device option, the color is passed. Otherwise if the firefly does not use the hue api protocol we would have to build a connector. |
I have already built a connector for it, at least from the firefly side, the issue that I am having it I also use firefly to pull the groups from the hue bridge as well as creating virtual groups.. Firefly doesn't use the hue api so the passthru doesn't work for that.. What I have done so far is ha-bridge runs not connected to hue, and firefly takes any device that is a switch or light and automatically adds those into ha-bride enabling voice control on them via ha-bridge. |
This is the file that I am using for linking ha-bridge to firefly: |
I would have to add new variables to be replaced, like how the brightness value is handled, to have this happen. |
I feel like this would support many other projects as well. I would be willing to take a look at it and what what I can do.. Its been a while since I have done Java but I should be fine. Any chance you can point me at what files I would have to be working with? |
This will be partly within the HueMulator class. |
Take a look how ${intensity.percent} is handled. |
Also would like to see this feature. It would be great to do something like this: Thanks a lot! |
I've been doing this for a while many versions ago. I simply just edited the default bulb type for HA-Bridge as a Extended Color Light instead of just a Dimmable Light. When a HA-Bridge device gets called, it polls the device state of the HA-Bridge "bulb" and I pass the values I need on through. There was a short time when HA-Bridge didnt save extended characteristics like color, but that has long since been resolved many versions ago. I used simple curl and grep commands. Since it only polls as needed when device changes state, its instantaneos and seamless. |
That's great to hear! But where can I edit the default bulb type to Extended Color Light? Is it within the config files or on the GUI? Second question is how the variables are named to send the color to my RGB stripe within an udp call. |
Edit ha-bridge/src/main/java/com/bwssystems/HABridge/api/hue/DeviceResponse.java Near the end, just change Dimmable light to Extended Color Light and change the bulb model from LWB004 to LCT004 (or any other bulb type depending on your project) right below it. The rest just conforms to the hue api. Adjust the colors the same way. Pull the values using a scripts from http:https://ipaddress/api/username/lights/1 |
So, looking into RGB, the hue api uses CIE with just xy components don't have Z and don't have Y. Cannot get it to convert properly |
I love the HA bridge you made. looks really nice and lot of options. thanks. I was wondering how the color is going. can we expect the pull color out of the system soon? |
@bwssytems I was playing with a little custom Skill that allowed me to set colour by name. It isn't very polished but it does work as a concept. Whilst the Skill itself won't be much use to you, it does contain the functions to convert HEX to RGB to XY. They are in javascript but the calculations would be the same in whatever the language. |
It would help if I posted the link https://github.com/digiltd/alexa-hue-colour-control |
@digiltd Thanks, I'll take a look |
I only have the .JAR file for Ha-Bridge in my installation - (Raspberry Pi) - is there any way to make use of colour commands without somehow getting the source and somehow compiling it? |
Nope, you will have to wait until it is implemented. The link above is an example for me to do implement the color conversion calculation. |
Ah, right. Ok, ball is in your court – would be VERY good if you could implement simple colours… I realise you could make lots of objects with different name endings for colours but I can’t help thinking that is asking for trouble…
From: BWS Systems [mailto:[email protected]]
Sent: 26 June 2017 15:39
To: bwssytems/ha-bridge <[email protected]>
Cc: Peter Scargill <[email protected]>; Comment <[email protected]>
Subject: Re: [bwssytems/ha-bridge] Add Color or Raw Info (#327)
Nope, you will have to wait until it is implemented. The link above is an example for me to do implement the color conversion calculation.
—
You are receiving this because you commented.
Reply to this email directly, view it on GitHub <#327 (comment)> , or mute the thread <https://github.com/notifications/unsubscribe-auth/ABzUgzqsqvxmLFi6GBDHqUoaFUqLH5Zjks5sH7RwgaJpZM4LVXQr> .
|
I don't understand why you guys don't pull the lights state value for color. After changing bulb type with one with color values, you can simply pull the state which includes the hue value (documented in hue api). Use that value and translate however you want and have it executing along your other commands you use it for. |
So, suing the CIE color space uses we can do one for one as that is easy. If it needs to be translated, say to RGB, then that is different. Also, this is for fun and I am one person.... |
You’ve completely lost me on this… as far as I can tell I can say “turn light on”, “turn light off” and give it a value for brilliance…. (I am controlling a light via MQTT and have full control at that level over colour and brilliance - I just can’t seem to see anything remotely like the ability to SAY a colour and have it output something.
From: mysteryan [mailto:[email protected]]
Sent: 26 June 2017 19:21
To: bwssytems/ha-bridge <[email protected]>
Cc: Peter Scargill <[email protected]>; Comment <[email protected]>
Subject: Re: [bwssytems/ha-bridge] Add Color or Raw Info (#327)
I don't understand why you guys don't pull the lights state value for color. After changing bulb type with one with color values, you can simply pull the state which includes the hue value (documented in hue api). Use that value and translate however you want and have it executing along your other commands you use it for.
—
You are receiving this because you commented.
Reply to this email directly, view it on GitHub <#327 (comment)> , or mute the thread <https://github.com/notifications/unsubscribe-auth/ABzUg77v6WnPeS3ifZ-5DPmYXLJbwrsbks5sH-h2gaJpZM4LVXQr> .
|
I thought color intents were available via skill only. Hence why its available to Hue bridge v2 that has a skills and why the round Hue bridge v1 that doesnt have a skill can't do color requests. I know it bypasses the perks of local HA-Bridge, but a private skills that returns setColor, and setColorTemperature as available actions under discovery that pipes into your mqtt broker would satisfy your needs |
I changed the bulb type, model id and everything. My Echo now displays my HA-Bridge devices as color lights, like real Philips Hue color lights. |
I have not implemented a way to get the color info to pass on yet. |
@FloFoer would you please post the changes you made to at least get to the point you are at? I've also struggled with how Alexa is supposed to support colors (including such as warm white, cool white, etc.) natively now. |
I did the thing mysteryan said above: changed the information in DeviceResponse.java like so:
Took the information from my real hue color bulbs. Now after a echo discovery the ha-bridge devices are color lights. But no color voice commands possible. Even if i proxy one of my real bulbs with ha-bridge. @bwssytems I saw that you started implementing a CIE <> RGB conversion. So i thought you maybe already know why my echo keeps telling me color is not supported, because without the possibility to issue a color command to ha-bridge devices in the first place, the conversion would be very less useful. I started playing around a little with the code, i implemented a rudimentary "colorUrl" additional to on/off/dim in editdevice and adjusted the huemulator/app.js accordingly. When i now try to change the color with the hue app my colorUrl gets executed. For that the conversion would be very useful. So it would work with the hue app but not with alexa. Can it be that the echo still needs the hue skill for color commands and the ha-bridge doesn't work with the official skill? |
Sicne I have yet to really delve into this, I do not have any ideas on why Alexa will not communicate color yet. The ha-bridge does not have any interaction as a skill. It is based off of the Echo's ability to communicate locally with the hue bridge. |
@bwssytems I have exams currently, but afterwards i will definitely look deeper into the whole color and milight/limitless thing myself, and some other stuff i'm not 100% satisfied with. If i'll accomplish something interesting for others i would contribute it if wanted. |
Got a statement from the hue developer support:
Also here was said that it will not get implemented natively. So going that route color would unfortunately only be possible with alexa if we could connect the ha-bridge to a hue account like a real bridge which is unlikely i guess. Same goes for scenes. |
Thanks for looking into that. I am still going to implement it as the apps can change the color and if there is any custom use of the api. |
I have been working on a home automation system and I am loving ha-bridge! However there is one thing that I am missing. Color info.
This shows when I am use a Google home and tell it to set the lights to green or any other color. Ideally I would like it to be Google home -> ha-bridge -> Firefly (my system) -> hue
Within firefly I have hue color support and would like to take advantage of that.. it would be nice if ha-bridge could support passing of that info or have a check box per device for 'raw request' -> this would be a nice way to get any info that is passed that can be used without much development overhead -> this could get appended to the body in JSON format.
Thanks
The text was updated successfully, but these errors were encountered: