Multi position virtual switch

That's the problem: there is no template for a 3 position switch in the Dashboard.

Using @Cobra's driver (which can be accessed by registering at his site https://cobra-apps.co.uk/), it is very easy to set up a button tile which then drives the switch state (up to 4 are allowed) which can be reported in another tile. This is the one I set up for my dog bark (which has 3 states; off, on, and away). It works perfectly and I think the UI is good enough. It would be better as 3 radio buttons of course.... :dog:

20200705_002948

@chillibenny fyi above, hope it helps. Cheers.

3 Likes

Thank you Bud, much appreciated!!

what code would you add to to this to make it auto go to Away after 2 seconds. ... from on or off.
In my case, I want to control 2 different IFTTT triggers, but system might be On, and the switch here already Off, so I can't command it Off (more like a momentary on/off with a neutral resting possition.

HI Angus I don't know if your rules needed to set the custom attribute. If so perhaps you could look at my other post Setting a custom attribute if you know.

Hiyah. No I don't think I had to do that for my use case, sorry. I see a reply already from someone to your question regarding custom attribute setting. Maybe that will assist you.

Hey All,

These are both great drivers!
Now, comes the seemingly obvious question: how I get them to apply to an actual physical device?
I created a virtual button/switch for them, but that is where I am now stumped.

Use Rule Machine to set up some rules that switch the actually device based on the state of the virtual device. The trigger would be a change to the virtual device. Then a set of conditionals that say if the virtual device is set to X, then set the physical device to Y, or suchlike.

1 Like

Hi,

I'm new to hubitat, but getting the hang of it so far. I am trying to use HSM and get my current Zwave based alarm system migrated over from Indigo. One thing I have is a control panel which is in Node-Red and gets it's values via MQTT. So I am trying to get the states of HSM into MQTT and the only way I can see to do this at the moment is using a Multi-positional switch and rule engine to set the switch when HSM changes. The switch is then exposed to MQTT sunig the MQTT link.

I have signed up to the Cobra Apps site, but my account hasn't been activated, any idea on how long this normally takes?

Any better ways to achieve a link between HSM and MQTT?

Thanks

Stuart

It wasn't your question, but I'll point out that there is a set of Hubitat nodes for node-red.

Could just bring hsm status into node-red directly, and skip using mqtt as the middle man.

2 Likes

This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.