Config to create switch to set 2 sensor states?

Hi all,

I’m quite new to the Home Assistant club, and I’m trying to get some basic automations working.

I’m having trouble finding how to create a front page virtual switch which will set 2 different states, eg: on=99, off=0 on a sensor.

Additionally, I am trying to figure out how to switch it ‘off’ after 10 seconds.

Can anyone help?

This is how you create a virtual switch.

An automation can be used to do something and then turn it off after 10 seconds.

You can have multiple actions in a automation.