Giter Club home page Giter Club logo

Comments (13)

zim514 avatar zim514 commented on July 19, 2024

Yeah, there's a few cases of that happening, I must have missed some

from script.service.hue.

mgonzales71 avatar mgonzales71 commented on July 19, 2024

thanks for looking into it and your work on this addon

i noticed the hue app lets you create entertainment zones where you place the lights in respect to you and tv - is that something that could be of use with this addon?

just curious - i just noticed that option this evening and I have not read up on yet beyond finding that option

thanks - looking forward to future updates - glad I finally bought some hues lights after resisting so long. 😃

from script.service.hue.

zim514 avatar zim514 commented on July 19, 2024

Entertainment zones use a different protocol (DTLS) that I haven't been able to find a way to implement in Python. I've tried different libraries but none of them work with Hue in particular. If I can find a DTLS library in the future I would like to implement it but I don't think it will be any time soon.

from script.service.hue.

mgonzales71 avatar mgonzales71 commented on July 19, 2024

looked a little and found a few things that could be useful?

mariusmotea/diyHue#150

in C++

https://github.com/BradyBrenot/huestacean

and

looks like these guys have working python libs but not sharing code
https://www.reddit.com/r/Hue/comments/ecikfy/upcoming_release_harmonize_for_philips_hue_demo/

probably a good place to seek info would be here maybe?

https://community.home-assistant.io/

I am not a programmer else I would help 😞

from script.service.hue.

zim514 avatar zim514 commented on July 19, 2024

I had a look through most of those in my research and unfortunately the solutions won't work in the context of Kodi.

The network errors should be improved in v.0.12.12, more of them should now just be handled instead of triggering the pop-up. If you still run across some, continue reporting it so I can see it and catch it on my next pass.

from script.service.hue.

mgonzales71 avatar mgonzales71 commented on July 19, 2024

updated to 0.12.13 - less errors but did get a couple just a moment ago - hopefully this helps narrow down things:

2020-03-01 18:56:20.332 T:12836   ERROR: [script.service.hue][AmbiGroup][_updateHueRGB](227): Ambi: Hue call fail: Received response 500 from http://10.0.0.10/api/I6vY7uNAvP2dLlMcbAPIDv3XEvXC1qHEy2LnE0-S/lights/8/state
                                            Traceback (most recent call last):
                                              File "C:\Users\Mario\AppData\Roaming\Kodi\addons\script.service.hue\resources\lib\AmbiGroup.py", line 221, in _updateHueRGB
                                                self.bridge.lights[light].state(xy=xy, bri=bri, transitiontime=int(transitionTime))
                                              File "C:\Users\Mario\AppData\Roaming\Kodi\addons\script.service.hue\resources\lib\qhue\qhue.py", line 60, in __call__
                                                raise QhueException("Received response {c} from {u}".format(c=r.status_code, u=url))
                                            QhueException: Received response 500 from http://10.0.0.10/api/I6vY7uNAvP2dLlMcbAPIDv3XEvXC1qHEy2LnE0-S/lights/8/state
2020-03-01 19:03:42.470 T:13020   ERROR: [script.service.hue][AmbiGroup][_updateHueRGB](227): Ambi: Hue call fail: Received response 500 from http://10.0.0.10/api/I6vY7uNAvP2dLlMcbAPIDv3XEvXC1qHEy2LnE0-S/lights/4/state
                                            Traceback (most recent call last):
                                              File "C:\Users\Mario\AppData\Roaming\Kodi\addons\script.service.hue\resources\lib\AmbiGroup.py", line 221, in _updateHueRGB
                                                self.bridge.lights[light].state(xy=xy, bri=bri, transitiontime=int(transitionTime))
                                              File "C:\Users\Mario\AppData\Roaming\Kodi\addons\script.service.hue\resources\lib\qhue\qhue.py", line 60, in __call__
                                                raise QhueException("Received response {c} from {u}".format(c=r.status_code, u=url))
                                            QhueException: Received response 500 from http://10.0.0.10/api/I6vY7uNAvP2dLlMcbAPIDv3XEvXC1qHEy2LnE0-S/lights/4/state

noticed hue has a windows sync client that does access the entertainment zones but doesn't look like it can be controlled via command line just a few hot keys and no where near as useful as your addon.

i did run across a post somewhere that listed a bunch of binaries for hue sync but can't find them - that could be another avenue maybe for platform specific addons?

I will let you know if I find anything that might be helpful.. most of what I have found is just not in python

thanks for the updates!!

from script.service.hue.

zim514 avatar zim514 commented on July 19, 2024

OK Error 500 that's not a connection error but the Hue Hub actually having a problem with a command. Does that happen a lot? Have you tried restarting the hub? Also please make sure it's on the latest firmware.

Can you please check your fresh interval and increase it to at least 200?

from script.service.hue.

mgonzales71 avatar mgonzales71 commented on July 19, 2024

sorry for the delay in replying. I have 5 lights and the refresh is at 300 - but I am ok with the occasional timeouts - they don't happen often just would be nice to silence all error modal dialogs - maybe an option to let all that go to a log file instead of a forced modal dialog.

I would think that typically that sort of error reporting is reserved for critical errors and faults

from script.service.hue.

zim514 avatar zim514 commented on July 19, 2024

The thing is that it's not a timeout, error 500 is the hue bridge saying there's a critical internal error within the bridge itself but the Hue documentation doesn't say what it could be. Before I ignore it in code, I want to understanding why it's happening since it's indicating something's wrong with the bridge.

I think it may be because it's getting overloaded. There's a limit of 25 zigbee commands / second but with 5 lights, 2 commands per refresh (brightness & colour), 3.3 times per second, you're at about 33 commands per second.

Can you try setting the refresh to 500 or even 1 second, to see if it goes away? Another option is to reduce the number of lights.

If and the error goes away, it'll confim my theory and then I can find a better way to handle it - maybe some kind of error message that explains what's happening so users can adjust with a "don't show again" button.

from script.service.hue.

mgonzales71 avatar mgonzales71 commented on July 19, 2024

increased refresh and have not seen any 500 messages.

from script.service.hue.

zim514 avatar zim514 commented on July 19, 2024

Ok, thanks for the information and testing it out. I'll fix it in the next version

from script.service.hue.

zim514 avatar zim514 commented on July 19, 2024

I tried to reproduce the problem, but when I overload it on purpose, I just get timeout errors in the logs and no messages or the "please report" dialogue... So I'm not sure now where the 500 errors come from. I still tried to fix it like I described, but I can't test it since I'm not able to get the 500 errors to happen.

Could you please try the version here and let me know what you get? If it gets the 500 error 10 times, it should pop up with a dialog box suggesting you change your settings, with a "dont show again" button.

https://github.com/zim514/script.service.hue/releases/tag/0.12.16-dev1

from script.service.hue.

zim514 avatar zim514 commented on July 19, 2024

fixed in 0.12.16

from script.service.hue.

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.