Git Product home page Git Product logo

Comments (14)

chrsmrtn- avatar chrsmrtn- commented on September 27, 2024

Found this error in the logs

{"Timestamp":"2024-02-14T20:01:41.1406488-07:00","Level":"Information","MessageTemplate":"Get LIFX Lights Initialized","Properties":{"SourceContext":"PresenceLight.Razor.Components.Pages.Lifx","Application":"PresenceLight"}}
{"Timestamp":"2024-02-14T20:01:41.5026759-07:00","Level":"Error","MessageTemplate":"Error Occurred Getting LIFX Lights","Exception":"System.NullReferenceException: Object reference not set to an instance of an object.\r\n at PresenceLight.Razor.Components.Pages.Lifx.CheckLIFX(String type)","Properties":{"SourceContext":"PresenceLight.Razor.Components.Pages.Lifx","Application":"PresenceLight"}}

from presencelight.

chrsmrtn- avatar chrsmrtn- commented on September 27, 2024

Error from nightly build:

{"Timestamp":"2024-02-14T20:38:23.9062263-07:00","Level":"Information","MessageTemplate":"Get LIFX Lights Initialized","Properties":{"SourceContext":"PresenceLight.Razor.Components.Pages.Lifx","Application":"PresenceLight"}}
{"Timestamp":"2024-02-14T20:38:24.2627032-07:00","Level":"Error","MessageTemplate":"Error Occurred Getting LIFX Lights","Exception":"System.NullReferenceException: Object reference not set to an instance of an object.\r\n at PresenceLight.Razor.Components.Pages.Lifx.CheckLIFX(String type) in D:\\a\\presencelight\\presencelight\\src\\PresenceLight.Razor\\Components\\Pages\\Lifx.razor:line 204","Properties":{"SourceContext":"PresenceLight.Razor.Components.Pages.Lifx","Application":"PresenceLight"}}

from presencelight.

chrsmrtn- avatar chrsmrtn- commented on September 27, 2024

My currently selected item id for LIFX

image

from presencelight.

chrsmrtn- avatar chrsmrtn- commented on September 27, 2024

Workaround to get things working is to use the LIFX api to get the ID of the light you want to use and then manually set the SelectedItemId in the settings to the appropriate encoded value. I don't have a workaround for the listing issue

from presencelight.

isaacrlevin avatar isaacrlevin commented on September 27, 2024

@chrsmrtn- what lights do you have? I wonder if certain lights operate on a different protocol than the ones I have tested with.

from presencelight.

chrsmrtn- avatar chrsmrtn- commented on September 27, 2024

LIFX beam and LIFX striplight (LIFX Z2). Neither of which are listed in the app. Those are the only two lights i own

from presencelight.

isaacrlevin avatar isaacrlevin commented on September 27, 2024

So lights or groups don't work?

from presencelight.

chrsmrtn- avatar chrsmrtn- commented on September 27, 2024

I'm unable to list lights

from presencelight.

isaacrlevin avatar isaacrlevin commented on September 27, 2024

@chrsmrtn- Can you do me a favor and return the JSON response you get from the LIFX Api?

from presencelight.

chrsmrtn- avatar chrsmrtn- commented on September 27, 2024

Sure, here ya go. I masked the IDs. The Guids are still formatted as guid and the other values all have the same number of characters. The original values were all alphanumeric

[
    {
        "id": "d00000000000",
        "uuid": "00000000-0000-0000-0000-000000000001",
        "label": "Office Door",
        "connected": false,
        "power": "off",
        "color": {
            "hue": 0,
            "saturation": 0,
            "kelvin": 3500
        },
        "brightness": 1,
        "effect": "OFF",
        "group": {
            "id": "00000000000000000000000000000001",
            "name": "Upstairs Hallway"
        },
        "location": {
            "id": "00000000000000000000000000000002",
            "name": "Home"
        },
        "product": {
            "name": "LIFX Z 2",
            "identifier": "lifx_z2",
            "company": "LIFX",
            "vendor_id": 1,
            "product_id": 32,
            "capabilities": {
                "has_color": true,
                "has_variable_color_temp": true,
                "has_ir": false,
                "has_hev": false,
                "has_chain": false,
                "has_matrix": false,
                "has_multizone": true,
                "min_kelvin": 2500,
                "max_kelvin": 9000
            }
        },
        "last_seen": "",
        "seconds_since_seen": 0
    },
    {
        "id": "d00000000001",
        "uuid": "00000000-0000-0000-0000-000000000002",
        "label": "Status Light",
        "connected": false,
        "power": "off",
        "color": {
            "hue": 0,
            "saturation": 0,
            "kelvin": 3500
        },
        "brightness": 1,
        "effect": "OFF",
        "group": {
            "id": "00000000000000000000000000000011",
            "name": "Desk"
        },
        "location": {
            "id": "00000000000000000000000000000022",
            "name": "Office"
        },
        "product": {
            "name": "LIFX Beam",
            "identifier": "lifx_beam",
            "company": "LIFX",
            "vendor_id": 1,
            "product_id": 119,
            "capabilities": {
                "has_color": true,
                "has_variable_color_temp": true,
                "has_ir": false,
                "has_hev": false,
                "has_chain": false,
                "has_matrix": false,
                "has_multizone": true,
                "min_kelvin": 1500,
                "max_kelvin": 9000
            }
        },
        "last_seen": "",
        "seconds_since_seen": 0
    }
]

from presencelight.

chrsmrtn- avatar chrsmrtn- commented on September 27, 2024

I'm also unable to list groups

from presencelight.

isaacrlevin avatar isaacrlevin commented on September 27, 2024

I think the issue is with the model of light you have. I have a LIFX Beam, and it shows up in PresenceLight. Here is what that light looks like, only difference I see from yours is the product_id

  {
    "id": "xxxxx",
    "uuid": "xxxx",
    "label": "Isaac Wakeup Light",
    "connected": true,
    "power": "on",
    "color": {
      "hue": 191.94,
      "saturation": 1,
      "kelvin": 3500
    },
    "brightness": 0.1,
    "zones": {
      "count": 21,
      "zones": [
        {
          "hue": 191.94,
          "saturation": 1,
          "brightness": 0.1,
          "kelvin": 3500,
          "zone": 0
        },
        {
          "hue": 191.94,
          "saturation": 1,
          "brightness": 0.1,
          "kelvin": 3500,
          "zone": 1
        },
        {
          "hue": 191.94,
          "saturation": 1,
          "brightness": 0.1,
          "kelvin": 3500,
          "zone": 2
        },
        {
          "hue": 191.94,
          "saturation": 1,
          "brightness": 0.1,
          "kelvin": 3500,
          "zone": 3
        },
        {
          "hue": 191.94,
          "saturation": 1,
          "brightness": 0.1,
          "kelvin": 3500,
          "zone": 4
        },
        {
          "hue": 191.94,
          "saturation": 1,
          "brightness": 0.1,
          "kelvin": 3500,
          "zone": 5
        },
        {
          "hue": 191.94,
          "saturation": 1,
          "brightness": 0.1,
          "kelvin": 3500,
          "zone": 6
        },
        {
          "hue": 191.94,
          "saturation": 1,
          "brightness": 0.1,
          "kelvin": 3500,
          "zone": 7
        },
        {
          "hue": 191.94,
          "saturation": 1,
          "brightness": 0.1,
          "kelvin": 3500,
          "zone": 8
        },
        {
          "hue": 191.94,
          "saturation": 1,
          "brightness": 0.1,
          "kelvin": 3500,
          "zone": 9
        },
        {
          "hue": 191.94,
          "saturation": 1,
          "brightness": 0.1,
          "kelvin": 3500,
          "zone": 10
        },
        {
          "hue": 191.94,
          "saturation": 1,
          "brightness": 0.1,
          "kelvin": 3500,
          "zone": 11
        },
        {
          "hue": 191.94,
          "saturation": 1,
          "brightness": 0.1,
          "kelvin": 3500,
          "zone": 12
        },
        {
          "hue": 191.94,
          "saturation": 1,
          "brightness": 0.1,
          "kelvin": 3500,
          "zone": 13
        },
        {
          "hue": 191.94,
          "saturation": 1,
          "brightness": 0.1,
          "kelvin": 3500,
          "zone": 14
        },
        {
          "hue": 191.94,
          "saturation": 1,
          "brightness": 0.1,
          "kelvin": 3500,
          "zone": 15
        },
        {
          "hue": 191.94,
          "saturation": 1,
          "brightness": 0.1,
          "kelvin": 3500,
          "zone": 16
        },
        {
          "hue": 191.94,
          "saturation": 1,
          "brightness": 0.1,
          "kelvin": 3500,
          "zone": 17
        },
        {
          "hue": 191.94,
          "saturation": 1,
          "brightness": 0.1,
          "kelvin": 3500,
          "zone": 18
        },
        {
          "hue": 191.94,
          "saturation": 1,
          "brightness": 0.1,
          "kelvin": 3500,
          "zone": 19
        },
        {
          "hue": 191.94,
          "saturation": 1,
          "brightness": 0.1,
          "kelvin": 3500,
          "zone": 20
        }
      ]
    },
    "effect": "OFF",
    "group": {
      "id": "xxxxxx",
      "name": "OK To Wake"
    },
    "location": {
      "id": "xxxxx",
      "name": "Home"
    },
    "product": {
      "name": "LIFX Beam",
      "identifier": "lifx_beam",
      "company": "LIFX",
      "vendor_id": 1,
      "product_id": 38,
      "capabilities": {
        "has_color": true,
        "has_variable_color_temp": true,
        "has_ir": false,
        "has_hev": false,
        "has_chain": false,
        "has_matrix": false,
        "has_multizone": true,
        "min_kelvin": 2500,
        "max_kelvin": 9000
      }
    },
    "last_seen": "2024-03-06T23:35:06Z",
    "seconds_since_seen": 0
  }

from presencelight.

chrsmrtn- avatar chrsmrtn- commented on September 27, 2024

So my model is causing the issue with being able to list my lights? But the light transitions work just fine if i manually set that light in the configuration

from presencelight.

isaacrlevin avatar isaacrlevin commented on September 27, 2024

@chrsmrtn- would you be willing to send me your LIFX token temporarily? I just want to see what that app does when it calls the API

from presencelight.

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.