# Philips Hue - Issue with state #1690

**URL:** <https://community.gladysassistant.com/t/philips-hue-issue-with-state-1690/8172>\
**Category:** Développement\
**Created:** [May 20, 2023, 8:07pm UTC](https://community.gladysassistant.com/t/philips-hue-issue-with-state-1690/8172 "2023-05-20T20:07:01Z")\
**Posts on this page:** 13\
**Page:** 1

<div class="post-metadata">

**Author:** ![cicoub13](https://gladys-assistant-community.b-cdn.net/user_avatar/community.gladysassistant.com/cicoub13/32/4482_2.png) [@cicoub13](https://community.gladysassistant.com/u/cicoub13)\
**Post date:** [May 20, 2023, 8:07pm UTC](https://community.gladysassistant.com/t/philips-hue-issue-with-state-1690/8172/1 "2023-05-20T20:07:01Z")

</div>

Hello,

I started fixing this issue [Philips Hue - Issue with state · Issue #1690 · GladysAssistant/Gladys · GitHub](https://github.com/GladysAssistant/Gladys/issues/1690) but I don’t have any Philips hardware to test (I sold the bridge).

I’m looking for volunteers to test the color/brightness reporting of the bulbs with the image `cicoub13/gladys:fix-philips-hue-poll`

Here’s a tutorial to run a test image

---

<div class="post-metadata">

**Author:** ![cicoub13](https://gladys-assistant-community.b-cdn.net/user_avatar/community.gladysassistant.com/cicoub13/32/4482_2.png) [@cicoub13](https://community.gladysassistant.com/u/cicoub13)\
**Post date:** [May 21, 2023, 6:28am UTC](https://community.gladysassistant.com/t/philips-hue-issue-with-state-1690/8172/2 "2023-05-21T06:28:09Z")

</div>

@Kevin I think you had the problem

---

<div class="post-metadata">

**Author:** ![Kevin](https://gladys-assistant-community.b-cdn.net/user_avatar/community.gladysassistant.com/kevin/32/6521_2.png) [@Kevin](https://community.gladysassistant.com/u/Kevin)\
**Post date:** [May 21, 2023, 7:05am UTC](https://community.gladysassistant.com/t/philips-hue-issue-with-state-1690/8172/3 "2023-05-21T07:05:39Z")

</div>

Indeed, I have that issue. I’m heading 150 km away from home in a few minutes and will be back in the evening/night.  
I’ll try to look into it tomorrow after work; that will let me try a test image to help you 🙂 In any case, many thanks for taking an interest in the problem 🙂

---

<div class="post-metadata">

**Author:** ![cicoub13](https://gladys-assistant-community.b-cdn.net/user_avatar/community.gladysassistant.com/cicoub13/32/4482_2.png) [@cicoub13](https://community.gladysassistant.com/u/cicoub13)\
**Post date:** [May 21, 2023, 7:22am UTC](https://community.gladysassistant.com/t/philips-hue-issue-with-state-1690/8172/4 "2023-05-21T07:22:32Z")

</div>

Yes, no rush 😉

---

<div class="post-metadata">

**Author:** ![Kevin](https://gladys-assistant-community.b-cdn.net/user_avatar/community.gladysassistant.com/kevin/32/6521_2.png) [@Kevin](https://community.gladysassistant.com/u/Kevin)\
**Post date:** [May 23, 2023, 5:47am UTC](https://community.gladysassistant.com/t/philips-hue-issue-with-state-1690/8172/5 "2023-05-23T05:47:03Z")

</div>

The image starts correctly.

However, before I break anything, a quick question:

Is it normal to have to recreate a

---

<div class="post-metadata">

**Author:** ![cicoub13](https://gladys-assistant-community.b-cdn.net/user_avatar/community.gladysassistant.com/cicoub13/32/4482_2.png) [@cicoub13](https://community.gladysassistant.com/u/cicoub13)\
**Post date:** [May 23, 2023, 8:28am UTC](https://community.gladysassistant.com/t/philips-hue-issue-with-state-1690/8172/6 "2023-05-23T08:28:12Z")

</div>

The SQLITE\_FILE\_PATH represents the **internal path** (inside Docker)  
It’s actually the line `-v /var/lib/gladysassistant\_

---

<div class="post-metadata">

**Author:** ![Kevin](https://gladys-assistant-community.b-cdn.net/user_avatar/community.gladysassistant.com/kevin/32/6521_2.png) [@Kevin](https://community.gladysassistant.com/u/Kevin)\
**Post date:** [May 23, 2023, 9:12am UTC](https://community.gladysassistant.com/t/philips-hue-issue-with-state-1690/8172/7 "2023-05-23T09:12:48Z")

</div>

Okay, that’s part of the internal path inside the container, nothing to do with my DB file.

I followed the maintainer’s tutorial and went with this:

```auto
docker run -d \
--log-driver json-file \
--log-opt max-size=10m \
--cgroupns=host \
--restart=always \
--privileged \
--network=host \
--name gladys-philips-hue-test \
-e NODE_ENV=production \
-e SERVER_PORT=8001 \
-e TZ=Europe/Brussels \
-e SQLITE_FILE_PATH=/var/lib/gladysassistant/gladys-production.db \
-v /var/run/docker.sock:/var/run/docker.sock \
-v /var/lib/gladysassistant_philips_hue_test:/var/lib/gladysassistant \
-v /dev:/dev \
-v /run/udev:/run/udev:ro \
cicoub13/gladys:fix-philips-hue-poll

```

So I’ll continue 🙂 Thanks for that clarification.

---

<div class="post-metadata">

**Author:** ![Kevin](https://gladys-assistant-community.b-cdn.net/user_avatar/community.gladysassistant.com/kevin/32/6521_2.png) [@Kevin](https://community.gladysassistant.com/u/Kevin)\
**Post date:** [May 23, 2023, 2:05pm UTC](https://community.gladysassistant.com/t/philips-hue-issue-with-state-1690/8172/8 "2023-05-23T14:05:19Z")

</div>

Quick feedback :

1. On / Off  
Gladys retrieves the correct information when the lamp is turned on. But it does not detect when it is turned off.  
Gladys can turn the lamp on and off.

2. Color  
Everything seems to work. Gladys can change the color and retrieves the modified color via the Philips Hue app.

3. Brightness  
Gladys can change the brightness.  
The brightness state is not retrieved in Gladys if the brightness is changed via the Philips Hue app.

4. Color temperature  
Nothing seems to work. Gladys does not retrieve any information and does not seem to be able to control anything.

---

<div class="post-metadata">

**Author:** ![cicoub13](https://gladys-assistant-community.b-cdn.net/user_avatar/community.gladysassistant.com/cicoub13/32/4482_2.png) [@cicoub13](https://community.gladysassistant.com/u/cicoub13)\
**Post date:** [May 23, 2023, 3:10pm UTC](https://community.gladysassistant.com/t/philips-hue-issue-with-state-1690/8172/9 "2023-05-23T15:10:57Z")

</div>

Thanks for the tests 🙏

For your information, polling occurs every minute (once per minute).  
This means Gladys requests the status of all Philips devices and updates the information at that frequency.

Did you wait that amount of time during your tests?

@pierre-gilles Could we consider reducing this polling interval? I’ll check what Philips recommends but I don’t know what is done for the other integrations.

---

<div class="post-metadata">

**Author:** ![cicoub13](https://gladys-assistant-community.b-cdn.net/user_avatar/community.gladysassistant.com/cicoub13/32/4482_2.png) [@cicoub13](https://community.gladysassistant.com/u/cicoub13)\
**Post date:** [May 23, 2023, 3:33pm UTC](https://community.gladysassistant.com/t/philips-hue-issue-with-state-1690/8172/10 "2023-05-23T15:33:52Z")

</div>

Home Assistant uses a polling frequency of 5 seconds

---

<div class="post-metadata">

**Author:** ![Kevin](https://gladys-assistant-community.b-cdn.net/user_avatar/community.gladysassistant.com/kevin/32/6521_2.png) [@Kevin](https://community.gladysassistant.com/u/Kevin)\
**Post date:** [May 23, 2023, 4:00pm UTC](https://community.gladysassistant.com/t/philips-hue-issue-with-state-1690/8172/11 "2023-05-23T16:00:41Z")

</div>

Yes yes, I was aware of the one-minute polling.  
That’s why I used the color as a reference point since I noticed that part worked 100%.

If the color changes state twice and nothing happens with the brightness, I assume no miracle will occur 😛

---

<div class="post-metadata">

**Author:** ![cicoub13](https://gladys-assistant-community.b-cdn.net/user_avatar/community.gladysassistant.com/cicoub13/32/4482_2.png) [@cicoub13](https://community.gladysassistant.com/u/cicoub13)\
**Post date:** [May 23, 2023, 5:25pm UTC](https://community.gladysassistant.com/t/philips-hue-issue-with-state-1690/8172/12 "2023-05-23T17:25:17Z")

</div>

OK, I’ll take a look

---

<div class="post-metadata">

**Author:** ![pierre-gilles](https://gladys-assistant-community.b-cdn.net/user_avatar/community.gladysassistant.com/pierre-gilles/32/5886_2.png) [@pierre-gilles](https://community.gladysassistant.com/u/pierre-gilles)\
**Post date:** [May 24, 2023, 3:03am UTC](https://community.gladysassistant.com/t/philips-hue-issue-with-state-1690/8172/13 "2023-05-24T03:03:19Z")

</div>

> [@cicoub13](#):
>
> @pierre-gilles Can we consider reducing this polling time? I’ll check what Philips recommends but I don’t know what’s done for the other integrations.

> [@cicoub13](#):
>
> Home Assistant uses a polling frequency of 5 seconds

Yes, it’s possible to change! After all, 5 seconds is a bit aggressive, I think — can we move to 15/30 seconds already?
