Troubleshooting turning lights on

Hello everyone,

I am attempting to turn on a GROUP of lights when a sensor is triggered. At the moment I am only successful when turning on 1 light. Partly because I use “device type” instead of " Condition" for my action type selection.

Additional details:
OS: HassOS 4.15
Supervisor: 2020.11.0
Channel: Stable

Host hardware: Dell R720, hypervisor OS Esxi 7.0

I have groups created using visual studio HA add-on

  name: HAGroupLivingRoomLights
  entities:
    - light.lr_color_1
    - light.lr_color_2
    - light.lr_color_3
    - light.lr_color_4
    - light.lr_color_5
  all: "true"
type or paste code here

However I am not really interested in using HAGroup, I have also created HueGroupLivingRoomLights, that was created as a ‘room’ in the Hue app. Either way I have been unsuccessful with either group. I have a feeling I am using the ‘Actions’ section incorrectly.

I navigated to my automations folder and have copied the yaml part associated with this automation for easier troubleshooting below.

id: '1604545937348'
  alias: NightDoorOpenON
  description: This will trigger when front door is open at night, outside lights
    and living room lights should turn on.
  trigger:
  - type: opened
    platform: device
    device_id: aa66461a01a246c5905553eaf02128b1
    entity_id: binary_sensor.lumi_lumi_sensor_magnet_aq2_77c83a03_on_off
    domain: binary_sensor
  condition: []
  action:
  - condition: state
    entity_id: light.huegroup_livingroom
    state: 'on'
  mode: single

Change the Action Type to Service Call and for the service use light.turn_on.

2 Likes

Not for a group. For that you have to use homeassistant.turn_on.

If you want the group to act as a light don’t use this normal group:

  name: HAGroupLivingRoomLights
  entities:
    - light.lr_color_1
    - light.lr_color_2
    - light.lr_color_3
    - light.lr_color_4
    - light.lr_color_5
  all: "true"

Use the light group platform instead:

This will appear as a single light that you can set brightness, colour etc… also you can use the light.turn_on/off services instead of the homeassistant.turn_on/off services.

EDIT: oh it’s a hue group. I’d still use the light group platform. Ignore all this.

I know, but OP said that he’s using the light group created by the Hue app. And also in his example he uses the light group from the Hue app.

1 Like

Yeah just saw that and was editing my post.

1 Like

I disagree, the groups created from Hue are better for this.
When you have e.g. 10 lights in chandelier and turn it on from HA, with the light group HA will send 10 commands to the Hue bridge, which can lead to delayed/missing commands. Whereas with a group created in Hue, HA sends only one command to the Hue bridge and it will then automatically propagate the command to the individual bulbs accordingly.

1 Like

Sounds sensible. I’ll edit my post.

Or
Action Type: Device
Device: Name of Light
Action: Turn on Name of Light

First off,

Thank you all!

Burningstone, thanks for your clear and easy recommendation. This indeed did solve my problem.
Tom, I actually still appreciate this information, even though I have a HueGroupLightXX, I also clone them with a native HA group. I plan to redo all of my HAGroupLightsXX following the light group platform.

Apmillen
I also appreciate your suggestion, it is one I have tried and does work in other situations, just not the living room.

Please read my comment, it’s better to NOT use HA light groups but group the light in the Hue app.

Oh wanted to respond before going to bed. I am definitely using Hue native groups over HA groups.

I will still create HA groups just in case I ever run into an odd scenario. Also I have lights that arent hue branded.

For anyone else reading this, as Burningstone mention using Hue groups will send 1 request to the hub and the hub will figure it out.

When you have e.g. 10 lights in chandelier and turn it on from HA, with the light group HA will send 10 commands to the Hue bridge, which can lead to delayed/missing commands. Whereas with a group created in Hue, HA sends only one command to the Hue bridge and it will then automatically propagate the command to the individual bulbs accordingly.

1 Like