Code Monkey home page Code Monkey logo

Comments (2)

glenndehaan avatar glenndehaan commented on May 18, 2024

Yeah so I did some testing with my lights and the output of my bulbs is as follows:

{
  "9001": "Ceiling 1",
  "9002": 1518962113,
  "9020": 1583058020,
  "9003": 65537,
  "9054": 0,
  "9019": 1,
  "3": {
    "0": "IKEA of Sweden",
    "1": "TRADFRI bulb E27 CWS opal 600lm",
    "2": "",
    "3": "1.3.009",
    "6": 1
  },
  "5750": 2,
  "3311": [
    {
      "5850": 1,
      "5851": 203,
      "5708": 42596,
      "5707": 5427,
      "5709": 30015,
      "5710": 26870,
      "5706": "f1e0b5",
      "9003": 0
    }
  ]
}
{
  "9001": "TV Light",
  "9002": 1519564265,
  "9020": 1583058045,
  "9003": 65544,
  "9054": 0,
  "9019": 1,
  "3": {
    "0": "IKEA of Sweden",
    "1": "TRADFRI bulb E27 WS opal 980lm",
    "2": "",
    "3": "2.3.007",
    "6": 1
  },
  "5750": 2,
  "3311": [
    {
      "5850": 1,
      "5851": 25,
      "5717": 0,
      "5711": 454,
      "5709": 33008,
      "5710": 27213,
      "5706": "efd275",
      "9003": 0
    }
  ]
}
{
  "9001": "Bed Front",
  "9002": 1534071987,
  "9020": 1582999678,
  "9003": 65546,
  "9054": 0,
  "9019": 1,
  "3": {
    "0": "IKEA of Sweden",
    "1": "TRADFRI bulb GU10 W 400lm",
    "2": "",
    "3": "1.2.214",
    "6": 1
  },
  "5750": 2,
  "3311": [
    {
      "5850": 1,
      "5851": 203,
      "9003": 0
    }
  ]
}

From this I could take the following:

  1. You are able to check if a light is just only dimmable by checking the 3311 output. Since this is missing the RGB values.
  2. If you want to check if a light is RGB capable or just Cold / Warm capable. Well.... I can't find it. The only thing that I discovered is that when using the 'default' colors in the app the RGB bulbs will never use the colors described here: https://github.com/glenndehaan/ikea-tradfri-coap-docs#cold--warm-bulbs

So you could check if a bulb is using those colors by reading out the 5706 hex value. In the example output above all lights where set to the 'Glow' color provided by IKEA. But as you can see the RGB bulb won't choose that hex value.

Now I know that this method also feels hacky. And if I was making an implementation I would just go for a regex of the item name.

from ikea-tradfri-coap-docs.

Joey-1970 avatar Joey-1970 commented on May 18, 2024

Thank you very much!
Your data help me, to configure devices I don't have.

Joachim

from ikea-tradfri-coap-docs.

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.