Best way to create virtual switches and virtual RGB dimmers

Hello, I am trying to learn different ways on how to use Home Assistant before being forced to migrate from SmartThings/WebCoRE.

In ST, I would create virtual switches with two or three purposes:
The main use was to trigger groups of devices, i.e. I’d have one RGB dimmer switch called “color bedroom lights”, and whenever I changed this, it would apply the same RGB values to a group of RGB bulbs.

The second use was to set action’s schedule by voice: I’d set a Washing Machine dimmer switch to 70% to make the washer start at 7AM (there was a WebCoRE piston that would react to this dimmer switch and set the start time).

And the third use was to store boolean variables. For example, I have a Blinds Lock switch to avoid closing the blinds when I leave home.

As I’m entering this new platform, I am looking for recommendations on better ways of having these same things. I’ve explored helpers a bit (just as booleans) and I know I can create devices from the configuration file, but I’d like to know if there is a recommended way of creating virtual dimmer switches and RGB dimmers.

For RGB dimmers, I would love to have a device that, when it’s opened from the interface, shows a palette of recently used colors.
And these switches need to be seen as switches or bulbs (can I choose?) by Google Home.

Thanks for the support :slight_smile:
Rodrigo

See:

I’m not sure if you can set an input_datetime helper from your voice assistant but if so, this coupled with an automation that triggers at that time would be one way to accomplish your needs.

1 Like

In HA you can create a light entity that groups all lights: Group - Home Assistant

There are two ways:

  • Use a template entity where you can set a value. E.g. light brightness (as you do now), climate temperature, media player volume, etc.
  • If you use Alexa you can use Alexa Actions. Alexa could ask you for the time.

In Home Assistant you would use Input Booleans that are used like a switch in a voice assistant.

1 Like

Thanks @tom_l and @FPro for your recommendations. I understand how scenes work, but I think I need something different here. Scenes set a specified brightness/RGB level, but I want a control that lets me set many lights at the same time by selecting whatever color I want at the moment. I think the Groups are more in line of what I need here, I’ll be testing this later.

How exactly would I do this? Where can I find these entities? I see the boolean helpers but I’m not finding one that lets me set RGBW values.

Thanks,
Rodrigo

Then yes a light group would be a better option.

Search in the Integrations section for the keyword “Template”. You’ll find everything you need.

1 Like