Open shanness opened 6 years ago
The only thing I can think of is that the MariusRumpf/node-lifx
(base communication library) have added support for the Mini Color but they haven't published it to npm yet
You could go to the node-red installation folder and change the dependency in the package.json
file for this project to
"node-lifx": "git://github.com/MariusRumpf/node-lifx.git#ffd9df0"
Ahh, thanks, looks like you are right, the npm version (0.8.0) is 2 years old and about 11 months before the mini colour was fixed.
Thanks for the code change, helpful.
I had to do basically this to get it to pick up that version
cd ~/.node-red
rm -rf node_modules/node-lifx
npm install git://github.com/MariusRumpf/node-lifx.git#ffd9df0
(as well as your change, which I couldn't get to force the install, but I'm a bit of a node newbie, so might be me, just thought it might help others.).
I've tripped on this same issue when trying to change the color of my LIFX Mini Color using these nodes. The commit is still not included (Jan 2019) in the node-lifx release npm package. Bummer - I've switched to the node-red-contrib-lifx-api nodes
@jdomeij is right—the problem is actually with the node-lifx dependency. This is actually the same issue as we discussed in this issue thread:
https://github.com/jdomeij/node-red-contrib-node-lifx/issues/16
The fix is actually pretty easy, though. You just have to get an updated products.json file from LIFX’s GitHub and replace it in the node-lifx package on your machine. My post goes into a little more detail at the link above and includes a side conversation with another user, @ristomatti, who’s forked this repository and added a custom dependency that fixes this.
Take a look at that other issue for more info, but if you have trouble implementing the solution, let me know. I can definitely get into the details. I also may have to follow ristomatti’s lead and just fork the package with an updated LIFX dependency. 😉
In case someone ends up reading this thread, my fork has since been changed to use lifx-lan-client (a fork of node-lifx which I'm also helping to maintain). So a simple fix to this is to install github:ristomatti/node-red-contrib-node-lifx
instead of node-lifx-contrib-node-lifx
.
Maybe we'll fork this package under the same GitHub organization created for lifx-lan-client at some point.
Thanks for the tip. I'll take a look at your fork.
Hey,
I'm using this :-
{on : true,hex: "#FF0000", brightness: 100};
And it's working for my two Color 1000 lights, but not my Mini Color. The python lifxlan module is working though when I run
lifx.set_color_all_lights(RED, rapid=True)
Not sure what the issue is, but thought I should let you know in case you do.