Commands for push, hold, double tap and release etc

I am looking for that option as well. I have a virtual button in Hubitat with actions on Push and Hold, but I cannot use it in Hubivue.
But I love the direction Hubivue is going :+1:

1 Like

Currently, hubiVue supports two actions…

  1. single Tap; and
  2. single Tap and Hold

The above request was for adding a 3rd…

  1. double Tap

Just to confirm that you’re looking for a case of 3

No sorry, not looking for a 3rd double tap option.
The issue is, when the ‘virtual button’ is added to a tile, the tap action has no ‘command to run’ to activate the ‘push’ or ‘push and hold’ action as defined in hubitat.
In hubitat, a button can have 4 command (push, hold, double tap and release), and each command can have a set of actions with conditions. So what I am looking for is just a way to have a tile in Hubivue that can call one (or more) commands.

Okay - so if you want a new device, in this case a Hubitat Virtual Button (that has specific commands that are not normally associated with normal home automation devices/capabilities) then yes, it won’t be currently supported.

I’ve been planning to push “Custom Commands” up the list of enhancements, and this would allow you to define the command to be sent back to hubitat (in this case “push, hold, double tap and release” etc) back to the device in MakerAPI. This would solve your problem and avoid me writing countless versions of special devices with special commands etc.

I’ll get onto this promptly :stuck_out_tongue:

1 Like

I’ve also put this in its own topic as it wasn’t related to the topic you replied under

I came here for this, so thanks for acknowledging. The OP and I independently concluded that there is no prescribed way in HV to access the (physical) “Double Tap [1/2]” or “Long Press [1/2]” of a switch or button, never mind another action, “Release” of those numbered entities, that sometimes crop up in apps like Button Controller.

Warning: This conversation will become complicated by the disjoint use of similar-sounding “Tap” / “Double Tap” / “Hold” terminology in HV vs the aforementioned ones on the HE side.

Further muddying of the water will come when someone asks, “Can I set a Tile so that when I double-tap it, the hub will respond to a double-tap event from that device.” Because you’ll be forced to address the fact that most switches allow a “Double Tap” on both the “Up”/“On” and the “Down”/“Off” position! And I will be pleasantly surprised if Tiles can be made smart enough to distinguish what the user intends to do.

Because it would kinda suck if we literally had to create a separate Tile for each of those – potentially 16 different! – actions that a modest 4-button remote can already accommodate in the hand.

Definitely keeping my popcorn bowl full for this one!

P.S. I wonder what dashboard users generally do now to replicate all their Button Controller assignments?? What’s your target “device”?

First to admit I’m unsure what you’re referring to specifically, but HV doesn’t care what state the device is in - it will send whatever cmd you want at any point in time.

So the switch attribute of the device could be in the “on” state and a cmd of “doubleTap” can be sent in the very same way as when the switch attribute is in the “off” state. Makes no difference to HV.

The only thing I do, for the sake of knowing when the device cmd has completed, is to “watch” an attribute change state - and technically that can be any attribute you wish. If an action results in no state change then it probably means there is nothing to watch.

Seems like the custom cmd feature could be popular ! :thinking:

The nuts and bolts of what I was referencing… for example, I have a GE Jasco toggle light switch in my kitchen:

  • Toggle it up once, that’s “On” as far as HE is concerned, and nothing detectable to Button Controller;
  • Tap same toggle twice in the “Up” direction, that’s “Double Tap of Button 1” as far as HE knows, to which Button Controller can react. This triggers the BC rule associated with that action;
  • Tap it down once, that’s “Off”, nothing new here.
  • Tap it downward twice in rapid succession, that’s a “Double Tap of Button 2” action to which BC responds.
  • Lift and hold the toggle, that’s a long-press (“Held”) of Button 1 → BC
  • Lower and hold, ditto for Button 2 → BC

From HV’s point of view, say I have a Tile called “Kitchen Switch” linked to the physical wall switch device above:

  • Tapping the tile singly results in the toggling between “On” and “Off” actions as above. I presume this is communicate from HV to HE as “On” or “Off” → [switch] – using some undiscussed logic to discern which command currently applies – and the physical switch is thusly commanded by HE;
  • Tapping the tile doubly, on the other hand, does either nothing or one of the HV-specific things chosen from the drop-down in HV’s Tile > Edit dialogue… none of which (currently) include “Send double-tap action for Button X”;
  • Tap-and-holding the tile likewise either does nothing (by default), or performs a UI-specific action as instructed, but (currently) cannot possibly send a “Hold button X” command to HE;

Hope we are agreed that’s the current state of the union?

I’m not sure if we are on the same page.

As far as HV is concerned, it can only send the available cmds as defined by the device driver, which in turn is exposed by MakerAPI

As an example, a Virtual Button has the following commands

DoubleTap, Hold, Push and Release are the four(4) commands that will/can be sent by HV back to HE for the same action that you’d get if you tapped/clicked those hub Commands.

That’s it… nothing more complex than that.

HV Custom Cmd will allow you to enter the “name” of the command as outlined in the above pic - namely… doubleTap, hold, push and release - note the case sensitivity, this will be important and must match precisely for the custom command to work. I will also support adding values, but again it will require some specific formatting to work correctly.

What I’m proposing is that YOU define the action of the tile (be that single tap, double tap or hold) and what Tile Action you wish to occur… that could be a HV Custom Cmd as defined for that tile. So you could make it that a single tile tap results in a doubleTap command being sent to HE, or the hold command etc.

I don’t see any issues, but happy for you to keep thinking about this and comment as needed.

1 Like

No, we are on the same page. So long as the customCmd() lets me send doubleTap(button1) when Tile is currently in what looks like its “Off” state, and send doubleTap(button2) when Tile is in “On” state, it’ll work as expected**.

Sounds very much like that’s the direction you’re taking it, to me.

**at least, that’s the closest I think HV can ever get. In reality, I can walk up to my physical switch and double-tap it in either direction irrespective of the switch’s current state. If that functionality is important to one of your users, customCmd() would just have to be deployed in two separate tiles … no big deal.

Maybe show me the device page in HE so I can be sure that I’ll be able to send the “button1” or “button2” value as you’re showing here

1 Like

I’ll just borrow this from you

, then:

Here, I’d be asking the switch to “Double Tap” its number 2 button. Other red arrows are where I’d type in the desired number for the “Hold” or “Push” (what I’ve been calling “Tap”) actions.

NOTE: Button devices and Virtual Buttons can have something like up to 32 or more buttons; it’s crazy.

this is also something that i’ve just discovered that I need as well. Looking forward to custom cmd support.


Also looking forward to this feature being implemented.

1 Like

Feature is current in beta and will be released soon

1 Like

I’m contemplating, once Custom Commands gets fully fleshed out (it kinda already is as of the latest beta), that I may create a multi-button device on HE specially for receiving these various “button” commands.

The other half of the setup involves a set of Button Controller rules to execute whatever I want in response to each button push/type.

At least, for some very basic functions (esp. ones not requiring a “Watch” on some Maker device’s attribute), this would ease the demand for things like Activators, Connectors, and maybe even Hub Variables that otherwise clutter my HE UI.

I haven’t thought this all the way through, and am probably going to realize that it omits a crucial link (such as with Alexa) that I’ll miss somehow. Oh well, just thinking out loud!

1 Like

I’m now convinced more than ever that it makes sense to create a (single) dedicated Dash Buttons device on Hubitat, possessing as many virtual buttons as one cares to have for triggering various hub automations (at least, ones that don’t already have a Switch or Activator or Connector associated with them).

For each of its VB’s (1…N), I shall create a matching Tile on hubiVue, affording me up to 3N distinct Custom Commands if desired.

Apps like Room Lighting and Rule Machine can easily be triggered from a “Button Press” of any type (I plan to limit my choices to Push, Double Tap and Hold … saving Release for when I’ve run out of other options). And now Tiles can easily be programmed to send those commands, yay!

v1.3.2 is ready to be pushed out with the Watching attribute fix. So Custom Commands is finished and sorted.

1 Like

2 posts were split to a new topic: Windows dowbload