Need help integrating a RGB spotlight

Hello everyone,

My pool installer just finished to wire the RGB spotlight of our pool.
The only way I can change the color is by turning the power off and on.
Then the color change from red to orange, the next time from orange to yellow and so on.

Changing it by HA is ok since I already had a Shelly 4PM Pro installed, But I’d like to know which color it is when it’s on.
Even better, I’d love to get a color picker, and when I chose a color, it ended up being that color… But maybe, I’m dreaming too much :smiley:

Let’s say the colors are (on that order and on a loop):

  • red
  • orange
  • yellow
  • green
  • blue
  • purple
  • pink

Let me clarify my goal by some example:
Let’s say it’s off.
When it was on yesterday, the spot was red
So I turn it on and it’s orange (on HA et IRL)
But I would like green, so I pick green on HA somehow and it keeps toggling on and off until it’s green.

I know it would require anyone at home to NOT change the color other than through HA, but that I can manage :-).

Any idea where to start?
With an Input select ?

Thanks in advance

You might want to give the brand, so that someone else does not inadvertently buy this product.
Such a crazy way to change colors :smiley:

I have something similar in our bedroom that the previous owner left.
I can’t understand why this kind of light is still sold.

I think you can use an input select where you list the colors and just iterate the list each time the light goes from off to on in an automation.
I wouldn’t be surprised if it goes out of sync though.

Regarding color selector, probably possible with a second input select.
When this changes the power should cycle until the two input selects states are the same.

Ahah, you’re right. I’ll ask for the brand to my installer.
Acutally, I should have done that before I bought the spot but communication is unfortunately not the best skill of the installer :-1:

@Hellis81: Nice idea, I’ll give it a try and share the results.

Ho yeah, I see what you mean.
Because some times, it will just power it off and then on with the use of a button and so it will increments the input_select. But other times, I’ll just it off for the day until the next time and this is gonna be painful to take into account.

I think I should change the state of the input select based on the change of state of the light itself (from off to on) and not when the button is pressed

I think I’m gonna do it step by step.

Here I’ve created an input_button “Color changer” and an automation which:

  • Power off the switch
  • Wait for 1s
  • Power it on again

Here is the button and its automation:

alias: Piscine - Changer la couleur du spot
description: ''
trigger:
  - platform: state
    entity_id:
      - input_button.changer_de_couleur
condition: []
action:
  - type: turn_off
    device_id: 294906350f865640f453b92e38d49be7
    entity_id: light.spot_de_la_piscine
    domain: light
  - delay:
      hours: 0
      minutes: 0
      seconds: 1
      milliseconds: 0
  - type: turn_on
    device_id: 294906350f865640f453b92e38d49be7
    entity_id: light.spot_de_la_piscine
    domain: light
mode: single
1 Like