[SOLVED] [HUE BINDING] Whats causing my hue lights to dim and turn off

Hi all,
I’ve got a bit of a weird issue. my hue lights are dimming randomly and then 30 seconds later turning off. id really like to get to the bottom of what’s going on here.
so Rileys lamp is hue_0210_00178829a0c5_26.
I have no rules with this light but when I switch it on in the sitemap it then randomly dims and then turns off this is happening with about half of my hue lights. The logs are below.

2019-01-07 21:50:47.215 [vent.ItemStateChangedEvent] - hue_0210_00178829a0c5_26_color changed from 60,0,99 to 60,0,0
2019-01-07 21:50:51.578 [ome.event.ItemCommandEvent] - Item 'Rileys_Lamp' received command 51.167513,0.647700,97.715736
2019-01-07 21:50:51.593 [nt.ItemStatePredictedEvent] - Rileys_Lamp predicted to become 51.167513,0.647700,97.715736
2019-01-07 21:50:51.595 [vent.ItemStateChangedEvent] - Rileys_Lamp changed from 60,0,0 to 51.167513,0.647700,97.715736
2019-01-07 21:50:52.283 [ome.event.ItemCommandEvent] - Item 'Rileys_Lamp' received command 51.167513,0.647700,95.516077
2019-01-07 21:50:52.290 [nt.ItemStatePredictedEvent] - Rileys_Lamp predicted to become 51.167513,0.647700,95.516077
2019-01-07 21:50:52.311 [vent.ItemStateChangedEvent] - Rileys_Lamp changed from 51.167513,0.647700,97.715736 to 51.167513,0.647700,95.516077
2019-01-07 21:50:57.331 [vent.ItemStateChangedEvent] - Rileys_Lamp changed from 51.167513,0.647700,95.516077 to 60,0,96
2019-01-07 21:50:57.340 [vent.ItemStateChangedEvent] - hue_0210_00178829a0c5_26_color changed from 60,0,0 to 60,0,96
2019-01-07 22:06:01.301 [vent.ItemStateChangedEvent] - Rileys_Lamp changed from 60,0,96 to 60,0,45
2019-01-07 22:06:01.320 [vent.ItemStateChangedEvent] - hue_0210_00178829a0c5_26_color changed from 60,0,96 to 60,0,45
2019-01-07 22:06:31.420 [vent.ItemStateChangedEvent] - Rileys_Lamp changed from 60,0,45 to 60,0,0
2019-01-07 22:06:31.426 [vent.ItemStateChangedEvent] - hue_0210_00178829a0c5_26_color changed from 60,0,45 to 60,0,0

Your log is a bit hard to follow

Could you post the log with only the relevant lines from when you turn on the light on the UI, please

sorry, updated the above log

Have you tried setting the autoupdate to false on the items:

Color Rileys_Lamp { channel="sdasdgag", autoupdate="false" }

EDIT: Ignore that for now, please see below

no I haven’t, what will that do?, as in any downsides?

You have 2 items trying to do the same thing

hue_0210_00178829a0c5_26_color and Rileys_Lamp

Remove the link between the channel and the item hue_0210_00178829a0c5_26_color
I guess that this item was auto generated
Only keep the link between the channel and Rileys_Lamp

Rileys_Lamp should be like:

Color Rileys_Lamp "Blah Blah" { channel="hue:sdfsa:sdfa:color" }

Copy and paste the channel from the paperUI to the text file

yea that’s pretty well how ive got Rileys lamp in the items file. see below.

Color	Rileys_Lamp     		"Rileys Lamp"     	<dimmer>      	(RileysRoom, Lights, LightRileysRoom)              	["Lighting"]   	{channel="hue:**************************:color"}

unlinking the auto generated items hasn’t fixed the issue.

But your also have another item, probably auto generated called hue_0210_00178829a0c5_26_color
Remove the link to it in the channel config and deleted it in the paperUI

yea thats what I meant, ive unlinked the auto generated thing in paper ui

Try putting the autoupdate back in:

Color	Rileys_Lamp     		"Rileys Lamp"     	<dimmer>      	(RileysRoom, Lights, LightRileysRoom)              	["Lighting"]   	{channel="hue:**************************:color", autoupdate="false"}

ok Ive added that into all of my hue lights and ill report back how I get on. I really appreciate your help :slight_smile:

So the lights are still dimming down -50% from there set value then turning off 30 seconds after they dimmed. Any more ideas as to what’s happening?

Are there any rules where these items are involved?

No, there’s no rules involving Riley’s lamp or any of the groups associated with it. Some of the other lights have this rule Setting up office light timers with time of day but that shouldn’t be causing Riley’s lamp to be doing anything.

I’ve also loged into my online hue account and removed all other apps that could control my hue lights to make sure there’s nothing on the hue side. I’ve also power cycled the hue hub.

Any hue binding experts out there?

Hi Rick,

Do you use a Philips Hue Motion Sensor in your home? Is it connected to the bulb?

1 Like

We are using hue motion sensors but under all 3 of the options they are all set to do nothing.

Edit: after reading a little on the hue motion sensor it dims the lights before it turns them off which sounds like the issue I’m having. What I’ve now done is remove all the sensors from “rooms” in the hue app and verified that they still work in openHAB which they do. I’ll update within the next couple of days with if it’s fixed my issue.

Yeah, that’s the default setup in the Hue bridge. Kind of a warning that the light(s) will turn off soon when no motion is detected for the defined time.
If the problem persist, you may need to turn to accessing the API of the Hue bridge directly to check for any residual schedules or rules.

@noppes123
Ok do you have any links how I’d go about doing this?

Sure, but a fair warinig upfront: my aproach has some complexity… :sunglasses:. Alternatively, there are apps out there that can probably help you, but I have no experience with that. So, here is how I would go about.

For starters, you need a so called whitelisted Hue user. You can find that in either your binding definition in the .things file or in Paper UI. It’s a string that looks like a bunch of randome letters and digits, like AvW8220ZezINkJpfelDisdXAvkP8HPgk4loHK1FM. With your browser of choice go to http://hue-bridge-ip//debug/clip.html. You will be presented with a screen like this:

Enter the Hue user at the yellow marked field and press GET (don’t use ENTER). This will give you a JSON formatted response with all kinds of details about your Hue bridge. If you leave the /config part out, you get the entire configuration, existing of lights, groups, schedules, scenes, rules (yes, Hue has rules too…), and sensors.

I’ll show an example configuration from one of my montion sensors ('ll leave the temperature sensor, light level sensor and some irrelevant fields out):

    "rules": {
          ...
		"94": {
			"name": "MotionSensor 28.day-on",
			"conditions": [
				{
					"address": "/config/localtime",
					"operator": "in",
					"value": "T08:15:00/T19:00:00"
				},
				{
					"address": "/sensors/28/state/presence",
					"operator": "eq",
					"value": "true"
				},
				{
					"address": "/sensors/28/state/presence",
					"operator": "dx"
				},
				{
					"address": "/sensors/31/state/status",
					"operator": "lt",
					"value": "1"
				},
				{
					"address": "/sensors/29/state/dark",
					"operator": "eq",
					"value": "true"
				}
			],
			"actions": [
				{
					"address": "/groups/9/action",
					"method": "PUT",
					"body": {
						"on": true,
						"bri": 112,
						"ct": 359
					}
				},
				{
					"address": "/sensors/31/state",
					"method": "PUT",
					"body": {
						"status": 1
					}
				}
			]
		},
		"95": {
			"name": "MotionSensor 28.day-dark-on",
			"conditions": [
				{
					"address": "/config/localtime",
					"operator": "in",
					"value": "T08:15:00/T19:00:00"
				},
				{
					"address": "/sensors/28/state/presence",
					"operator": "eq",
					"value": "true"
				},
				{
					"address": "/sensors/29/state/dark",
					"operator": "eq",
					"value": "true"
				},
				{
					"address": "/sensors/29/state/dark",
					"operator": "dx"
				},
				{
					"address": "/sensors/31/state/status",
					"operator": "lt",
					"value": "1"
				}
			],
			"actions": [
				{
					"address": "/groups/9/action",
					"method": "PUT",
					"body": {
						"on": true,
						"bri": 112,
						"ct": 359
					}
				},
				{
					"address": "/sensors/31/state",
					"method": "PUT",
					"body": {
						"status": 1
					}
				}
			]
		},
		"96": {
			"name": "MotionSensor 28.night-on",
			"conditions": [
				{
					"address": "/config/localtime",
					"operator": "in",
					"value": "T19:00:00/T08:15:00"
				},
				{
					"address": "/sensors/28/state/presence",
					"operator": "eq",
					"value": "true"
				},
				{
					"address": "/sensors/28/state/presence",
					"operator": "dx"
				},
				{
					"address": "/sensors/31/state/status",
					"operator": "lt",
					"value": "1"
				},
				{
					"address": "/sensors/29/state/dark",
					"operator": "eq",
					"value": "true"
				}
			],
			"actions": [
				{
					"address": "/groups/9/action",
					"method": "PUT",
					"body": {
						"scene": "-U6HUKmize7diXS"
					}
				},
				{
					"address": "/sensors/31/state",
					"method": "PUT",
					"body": {
						"status": 1
					}
				}
			]
		},
		"97": {
			"name": "MotionSensor 28.night-dark-on",
			"conditions": [
				{
					"address": "/config/localtime",
					"operator": "in",
					"value": "T19:00:00/T08:15:00"
				},
				{
					"address": "/sensors/28/state/presence",
					"operator": "eq",
					"value": "true"
				},
				{
					"address": "/sensors/29/state/dark",
					"operator": "eq",
					"value": "true"
				},
				{
					"address": "/sensors/29/state/dark",
					"operator": "dx"
				},
				{
					"address": "/sensors/31/state/status",
					"operator": "lt",
					"value": "1"
				}
			],
			"actions": [
				{
					"address": "/groups/9/action",
					"method": "PUT",
					"body": {
						"scene": "-U6HUKmize7diXS"
					}
				},
				{
					"address": "/sensors/31/state",
					"method": "PUT",
					"body": {
						"status": 1
					}
				}
			]
		},
		"98": {
			"name": "MotionSensor 28.dim",
			"status": "enabled",
			"conditions": [
				{
					"address": "/sensors/28/state/presence",
					"operator": "eq",
					"value": "false"
				},
				{
					"address": "/sensors/28/state/presence",
					"operator": "ddx",
					"value": "PT00:04:00"
				},
				{
					"address": "/groups/9/state/any_on",
					"operator": "eq",
					"value": "true"
				}
			],
			"actions": [
				{
					"address": "/scenes/R3YHvRbI5ZIMj7W",
					"method": "PUT",
					"body": {
						"storelightstate": true
					}
				},
				{
					"address": "/groups/9/action",
					"method": "PUT",
					"body": {
						"bri_inc": -128
					}
				},
				{
					"address": "/sensors/31/state",
					"method": "PUT",
					"body": {
						"status": 2
					}
				}
			]
		},
		"99": {
			"name": "MotionSensor 28.recover",
			"conditions": [
				{
					"address": "/sensors/28/state/presence",
					"operator": "eq",
					"value": "true"
				},
				{
					"address": "/sensors/28/state/presence",
					"operator": "dx"
				},
				{
					"address": "/sensors/31/state/status",
					"operator": "gt",
					"value": "1"
				}
			],
			"actions": [
				{
					"address": "/groups/9/action",
					"method": "PUT",
					"body": {
						"on": true,
						"bri": 112,
						"ct": 359
					}
				},
				{
					"address": "/sensors/31/state",
					"method": "PUT",
					"body": {
						"status": 1
					}
				}
			]
		},
		"100": {
			"name": "MotionSensor 28.off",
			"conditions": [
				{
					"address": "/sensors/28/state/presence",
					"operator": "eq",
					"value": "false"
				},
				{
					"address": "/sensors/31/state/status",
					"operator": "ddx",
					"value": "PT00:00:30"
				},
				{
					"address": "/sensors/31/state/status",
					"operator": "gt",
					"value": "1"
				}
			],
			"actions": [
				{
					"address": "/groups/9/action",
					"method": "PUT",
					"body": {
						"on": false
					}
				},
				{
					"address": "/sensors/31/state",
					"method": "PUT",
					"body": {
						"status": 0
					}
				}
			]
		},
		"101": {
			"name": "MotionSensor 28.arm",
			"conditions": [
				{
					"address": "/groups/9/state/any_on",
					"operator": "eq",
					"value": "false"
				},
				{
					"address": "/sensors/28/state/presence",
					"operator": "eq",
					"value": "false"
				}
			],
			"actions": [
				{
					"address": "/sensors/31/state",
					"method": "PUT",
					"body": {
						"status": 0
					}
				}
			]
		},
          ...
    "sensors": {
          ....
		"28": {
			"state": {
				"presence": false,
				"lastupdated": "2019-01-10T10:01:11"
			},
			"config": {
				"on": true,
				"alert": "none"
			},
			"name": "Hue motion sensor Toilet",
			"type": "ZLLPresence",
			"productname": "Hue motion sensor",
		},
		"29": {
			"state": {
				"lightlevel": 0,
				"dark": true,
				"daylight": false,
				"lastupdated": "2019-01-10T10:40:07"
			},
			"config": {
				"on": true,
				"alert": "none",
				"tholddark": 17576,
				"tholdoffset": 7000
			},
			"name": "Hue ambient light sensor 1",
			"type": "ZLLLightLevel"
		},
          ....
		"31": {
			"state": {
				"status": 0,
				"lastupdated": "2019-01-10T10:33:55"
			},
			"config": {
				"on": true,
				"reachable": false
			},
			"name": "MotionSensor 28.Companion",
			"type": "CLIPGenericStatus",
			"modelid": "PHA_STATE"
		},

As can be seen, there are 3 sensors involved, a motion sensor (28), a light level sensor (29) and a companion sensor (31), and many rules. The rules are where the dimming takes place, so they are the interesting part. They have conditions and actions, much like OH rules when and then sections. Conditions are for instance about whether it is in a certain time slot, presence is detected or the light level is below or above a certain value. Rule 98 is an example of how the dimming takes place after 4 minutes of no presence detected (and rule 99 recovers the light level if motion is detected during the dimming period).

Before ‘we’ go about deleting rules, you should determine if this kind of configuration is active in your Hue bridge.

1 Like