Code Monkey home page Code Monkey logo

Comments (1)

Foddy avatar Foddy commented on May 28, 2024

Hi lespatots!
Thank you for this nice feedback and sorry for my late response!

Setting "on" to "false" should work as expected now with v1.3.1. I also added a brightness setting validation (can't understand why I didn't before…) and lights / groups are now turning off if the setting is "0". You were right, for some reasons Philips' API is not turning off the lights if the brightness setting is 0.

The saturation setting is something that I totally missed from the API docs – but now obviously added with the update ;)!

With the improved input "algorithm" in v1.3.1 all nodes are now working "additive". You also don't have to pass in the "msg.payload.on" parameter anymore and all future commands are simply updating the light / group / sensors. I added this info in the features section in the README file with a simple sentence. You're totally free to contribute if you have some improvements for the README of even the actual code :)!

I decided to use own customized parameters for HueMagic because of three reasons:

  1. You also mentioned it. They are cryptic in some cases and not easy to remember (often).
  2. If they were all identical then users would probably think, that they also work the same. With Philips Hue API for example you have to pass in a value between 0 and 254 to set the brightness level of a light bulb. In HueMagic this setting is a more convenient "percent" parameter which makes things easier for users – I guess (I hope).
  3. With customized parameter names HueMagic is able to keep it's nodes and API "alive" with internal recalculations and without having the user to manually update all the nodes, just because Philips changed / removed / unnamed some parameters in their API.

I am closing this issue for now. Feel free to answer back if you don't agree with my last arguments πŸ‘ !

from node-red-contrib-huemagic.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    πŸ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo 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.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❀️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.