Please make sure you have removed all of the files from the earlier version of the library. There should now be only a single .py file in custom_components/sensors.
Cheers
thank you very much for your work and the library, but please make up your mind and don’t add more confusion
as far as i can tell by looking at the github page the component was renamed from hue_sensors to hue_sensor (at least in my case i had an old file namend hue_sensors).
The documentation should mention this.
Hi, please note that the custom component contains hue_sensor.py, and the docs state that if you are getting an error due to the failure of HA to install the dependency, then also add hue_sensors.py from this repo. I see it is confusing that they have almost identical names but it wasn’t my expectation that the user may need to have both in the same folder.
Cheers
Hi, is it possible to scan more often than once per second? I also tried the guide on hackster (https://www.hackster.io/robin-cole/hijack-a-hue-remote-to-control-anything-with-home-assistant-5239a4), but it seems I can’t set scan_interval lower than 1. And even then, sometimes it takes up to 2 seconds to update.
Yes you can override SCAN_INTERVAL. That topic came up in this thread before so a browse should answer your query.
Cheers
Thanks! I found your reply in Tutorial adding HUE Motion sensor (Lux,Temp and Motion) if that’s what you meant, but you’re saying the scan_interval isn’t even used with REST (unless I’m misunderstanding what you’re saying)?
It is used, default 1 second. You can override default. Cheers
Sorry, I can’t seem to get values < 1 working. As you wrote yourself:
I set scan_interval = 0.5 and appears to make no difference. I also removed scan_interval and that made no difference. Therefore I conclude that scan_interval is not required
I’m confused now, how should that work?
Sorry my memory on this is hazy. Perhaps the minimum scan interval is 1 second, but I’m just speculating.
Cheers
OK if you are feeling brave, the dev branch is updated to use phue for API polling and has a scan_interval of 0.1, so in my (very limited) testing is very fast. Please note the change in config. Please don’t complain as this change brings the sensor component in line with the lights component. Cheers
https://github.com/robmarkcole/Hue-sensors-HASS/tree/dev-phue
I have updated to .60 and added the latest hue_sensor.py to my custom_components/sensors folder. I don’t get any errors but I also no longer have the remote in HA. I think I have updated the configuration.yaml file correctly, since my lights are working. I changed the sensor entry to platform: hue_sensor. What else should I look for?
So I tried the dev version and it complained about a missing services.yaml file so I just added a blank file to the custom_components folder. Works now but the hue_sensor.py did not???
HI,
Im learning here, so please forgive if I ask a silly question:
I am reading the Hue configuration through your hue_sensor(s).py and it is working just fine,( thank you!).
At the same time, ive payed around bit with the Hue api caller, and created some Rest_sensors myself, following Hue instructions and this info: https://nickyb2.tweakblogs.net/blog/14037/home-assistant-philips-hue-motion-sensor.
Ive even created the virtual sensor, thats takes 5 min to re-state instead of the real sensor doing 30 seconds.
These sensors work fine too.
Is there any significant difference between the 2 techniques, besides being automatic versus hand made? Would there be any advantage or special use for one or the other technique?
Here’s what the raw sensors read:
I do have a formatting question: as you can see the trigger time is displayed rather unhandy. How would i have to change the sensor for it to read h:m:s:, d:m:y?
Cheers,
Marius
Hi @zarthan it is impossible to debug your specific issue without any logs. Most likely the dependency hue_sensors failed to install, and there will be an entry in your logs for that. Nevertheless sounds like you have it working now so all good.
Hi @Mariusthvdb both this custom component, and the hue lights (powered by phue) are basically glorified rest sensors/switches. Therefore you can build rest sensors that have the same functionality, but I can’t imagine any particular advantage (apart from reducing the size of your db if you only care about a subset of the sensor data).
Cheers
thanks, thought as much. keeping the code as tight as possible seems wise, though automation is a wonderful thing too
Please keep making the component better!
Cheers,
Marius
@robmarkcole is there any advantage to going the hue_sensor route? If how the component is developed going forward is changing, should I work at the hue_sensor.py integration and figure out what I need to change?
Sorry could you clarify your question? Cheers
How obscure of me. I thought you knew what I was thinking.
I used your latest dev version to get myself working again after the hue_sensor.py didn’t seem to load. The dev version follows the earlier version with a hue.py in custom_components and one in sensors while the Hue_sensor.py is a singular file in sensors. So should I go back and figure out why the hue_sensor.py version didn’t work or should I just keep using the dev version. If all future work will go into providing the component as hue_sensor.py then I should try to get it working???