[OBSOLETE] Advanced Button Controller (ABC)


As you may have noted, I no longer use or develop for SmartThings. @Paul_Sheldon has taken over updating the ABC app for this platform and has been adding new features, including support for the new ST app. (My app was developed for the classic app only).
Please follow the link below for Paul’s updated version. Thank you for taking this over and I’m glad it will continue to be a benefit to the community in your hands.

UPDATE 2/12/18:
Nothing materially different. Really just backend and formatting changes.

  • Reformatted the Button Config Preview layout
  • Structured Button Config page for easy code editing (removed ~75 lines of code
  • reduced clutter (hid secondary inputs until primary inputs were configured)

UPDATE 1/14/18:
Original smartApp has been split into 2 new Parent/Child smartapps to be compliant with smartThings coding recommendation. This new 2 part version is recommended, but not necessary for those who already have this app installed and functional.
It fixes the hanging during initial setup on IOS devices. Any further updates will be applied to this new 2 part version.
The original version is now deprecated…See post 58 below for links to the original hybrid smartApp.

Update 1/28/18: Added Icons and details for Remotec ZRC-90US Button Controller.

Yes, I know…another button controller smartApp. I created this one for myself but I figured I would share it for those who felt the flow of the other apps needed improvement. Below are the minor annoyances this smartApp is meant to fix

  • Existing button Controllers required me to “next my way through” a static number of buttons (4 or 6) to configure or change a single setting.
  • In some of these you were presented with an endless pages of options to scroll through
  • I love CoRe but making a quick change on the fly for testing became a bit of a chore…and assisting my non techie friends and family meant I pretty much had to create and maintain all their configs as well as my own.

This smartapp allows you to use a device with buttons including, but not limited to:

  • Aeon Labs Minimotes
  • HomeSeer HS-WD100+ switches (See InApp User’s Guide for details)
  • HomeSeer HS-WS100+ switches
  • Lutron Picos (See User’s Guide for details)

It is a heavily modified version of @dalec’s ‘Button Controller Plus’ which is in turn a version of @bravenel’s ‘Button Controller+’.
Some of the included changes are:

  1. All button configs are listed under one Parent App so they don’t clutter the ST SmartApp List
  2. A complete revamp of the configuration flow. This app will detect the number of buttons on your device or allow you to manually specify (only needed if device does not report on its own).
  3. The button configuration page has been collapsed by default for easier navigation.
  4. You can now tell at a glance, what has been configured for each button on the main device page.
  5. Allows for incremental level (volume and brightness) increases/decreases.
  6. Allows you to give your buton device full speaker control including: Play/Pause, NextTrack, Mute, VolumeUp/Down.
    (Standard Pico remotes can be converted to Audio Picos)

I also made a quick video here that shows what setting up a new device feels like and shows what the advanced options do as well. Hopefully some of you see a benefit to this version.




Special Thanks to @dalec for his testing , feedback and the device icons he created for this smartapp. Much appreciated sir!!


This smartapp really does rock it! I have changed from using my own Button Controller Plus and instead use @stephack Advanced Button Controller smartapp! Yes it really is that much better that I switched to ABC. :smiley:

I think my favorite features are how it automatically sets up the number of buttons to program and then using images and notes makes it extremely intuitive for configuring the device. By using collapsing menus and intelligence it reduces the amount of screen clutter when programming.


Thank you @stephack for the fantastic step forward with this smartapp. And thank you dalec for your predecessor work. And to @Darwin for the DTH! For all I know, there are others who came before. As a noob around here, this is what I love about the ST community—so many people who “pay it forward”.

Can I trouble you to address a few questions about ABC and @Darwin’s device handler? I have read just about every related forum in their entirety, but just can’t crack this.

I have installed and included (v2 ST hub) a WS100+ from ZWP (V5.17 firmware). It’s one of several I was planning to install because I love the instant status feature for scene control. I installed the first WS100 in a 2-gang box where one of the switches was dead/unused anyway. So I installed it without connecting the load. Since this particular box is strategically located at the top of the stairs to our basement, my plan was to use several of the 8 “buttons” to control scenes in the basement (anyone with kids will immediately get why this is so useful! :grin:. All I have done so far with ABC is configured Button 8 (single tap lower paddle) to turn off all my downstairs lights And I configured Button 7 (single tap upper paddle) to turn on a couple basement lights.

This brings me to my three questions:

  1. When I single tap on or off the WS100 from the iOS app, the hub sees the status change as expected. And I can see in the device event log where the command is send to the device. In response, the device “clicks” and the LED turns off or on, as appropriate. Cool so far. But when I physically single tap (up or down) the switch, the event log captures a big fat void of nothingness. To be fair, the Homeseer manual says clearly that a paddle tap powers the load–which makes me think, since I have no load, that it’s behaving exactly as designed by doing nothing. But then, shouldn’t the device handle cause the hub to see the device turn on or off?

  2. Even when the hub does register an “on” or “off” event (through a tap on the iOS app), ABC is not acting on the button 7 or button 8 push. Since ABC added button 7 and button 8, I would think this should work. What I am doing wrong? (FWIW, if I use the SmartLighting app to automate the same behavior, but from a switch on/off rather than a button push, it works–but of course I can’t extend this approach to buttons 1-6.) Here’s how I’ve configured ABC:

  3. And finally a relatively simple question: in ABC’s button 8, I noticed the “when pushed” option list under “Switches (Turn Off)” includes a mix of both on/off switches and as well as dimmers. Does this mean that, if I have no need to adjust dimmer levels, and only want to switch off the dimmers completely, I can simply select dimmers (alongside switches) from the “Switches (Turn Off)” list?

Thank you in advance for your help. :confounded: If I’ve asked anything the wrong way or in the wrong place, that is my ignorance showing—in which case, I will gladly take any coaching you can offer!

Ok…that’s a lot to take in. Unfortunately I do not own any Homeseer devices and relied on @dalec for any testing with regards to those. Hopefully he can assist with questions 1 and 2 as I don’t know what effect of your “special” configuration would have on the normal operation of the switch. Also, my smartapp can only respond to button presses when the device tells the hub that the button has been pressed. Assuming the device logs show all button press events, then the issue probably does not lie with my app but with your switch or your configuration of the device handler. Again, I would rely on @dalec or @darwin for confirmation on this.

Question 3…yes. This would allow you to turn off any device with the switch capability, whether it is a switch, dimmer, fan etc.

So I setup a ghost device to get a better understanding of your issue and have a couple of things I noticed.

  1. There appears to be multiple device handlers from @Darwin for these switches. Are you using the one listed here?
    [RELEASE] HomeSeer Dimmer and Switch (HS-WD100+ / HS-WS100+) Device Handlers

  2. I skimmed through the code and from what I can tell, there is no “digital” way to send button presses 7 and 8…only physical. This again is based on assumptions, but it might be that for single taps (7 and 8) the handler is waiting for a response from the device that it successfully turned the load on and off. Since this is not connected on your end, it never receives this confirmation and thus never sends the button pressed event.

  3. I edited the device handler to send button 7 and 8 press events digitally with triple tap up and triple tap down … and it worked as expected.

I have a couple of the HomeSeer switches but unfortunately I haven’t been able to update the latest firmware (requires you to have a HomeSeer frontend) that exposes the button 7 & 8 functions so I couldn’t test those specifically. It seems you get to be the first! :smiley:

@MLUCK - When you physically tap up on the switch, you should see the button status (lower left in the UI window below the On/Off status) change to “Tap ▲”. The “Recently” mobile UI tab should also log that button 7 has been pressed. The IDE Live logging should also show several logs describing the sceneNumber and keyAttributes as well as additional information regarding what the parse is returning. Are you seeing any of these indicators? If not, it does make me wonder if not having a load on the switch is affecting operation, but this would be somewhat surprising to me. I did notice I had an issue specifying if the button 7 & 8 events are physical or digital, but that didn’t appear to affect operation for me. I’ll get out a fix for that shortly.

Currently the WS100+ device handler only sends a button 7/8 event in response to a physical tap of the switch, so that may at least explain this one.

I set up a simple test using ABC and the WS100+ switch and it appeared to respond appropriately for me for physical up/down (button 7/8) presses, but I’ll try to investigate more as well as fix the digital/physical indicator. I’ll admit the button 7/8 logic has had limited testing.

Great app @stephack!

@Darwin, I wonder if @MLUCK doesn’t have the latest firmware in his WS100+?

What firmware release is needed that exposes the button 7 & 8? My device handler shows v5.14 so it has to be something later than that.

I believe the mapping for the Central Controller is Scene 1 should be configured for a value of 255 and Scene 2 should be a value 0.

Scene 1, Key 0 == Normal Tap On
Scene 1, Key 1 == Hold Press
Scene 1, Key 2 == Double
Scene 1, Key 3 == Triple

Scene 2, Key 0 == Normal Tap On
Scene 2, Key 1 == Hold Press
Scene 2, Key 2 == Double
Scene 2, Key 3 == Triple

So settings would be:
zwave.sceneActuatorConfV1.sceneActuatorConfSet(sceneId: 1, dimmingDuration: 0, level: 255, override: true)
zwave.sceneActuatorConfV1.sceneActuatorConfSet(sceneId: 2, dimmingDuration: 0, level: 0, override: true)

I could also be very wrong :slight_smile:

Actually, the device handler is simply using the instant status central scene notifications to trigger the button 7 and 8 response so there should not be a firmware update required for these buttons. I’m currently on V5.14 though and haven’t tested on V5.17. The buttons should respond similarly to an on/off press of the switch with the added advantage of still being triggered regardless of whether the switch is already in the on or off state.

1 Like

@Darwin, I noticed a few differences to how you were handling “single tap up/down” vs all other combinations. I edited your code to make it consistent and tested with a digital on/off and it appears to be sending button presses 7 and 8 that way. I don’t have this switch so I can’t verify the physical aspect. How would you like me to send the changes…via pull request or PM?

1 Like

Thanks @stephack, I see your GitHub pull request. Looks like a good change to add those buttons for the mobile app/digital on/off presses. I’ll take a closer look when I have a few minutes and get it pulled in.

1 Like

I made the same changes to the WD100 dth so @dalec could test. He advised that the 7 and 8 status updates sent correctly. I sent another pull request including both WD100 and WS100.

@MLUCK it looks like @Darwin has updated the device handlers to utilize button 7 and 8. It should also work when you turn on/off in the ST app. Please update from Darwin’s repository and test. Let us know how it goes. Make sure you are using the handlers located here:

Great, thanks @stephack

Gents, thanks again for your help. I updated @Darwin’s device handler to v1.02, the latest version as of 6/25/17. When I single tap from the iOS app, the hub sees that Button 7 was pushed, but live logging shows the following error:

12:32:23 AM: debug Parse returned [name:switch, value:on, type:digital, isStateChange:true, displayed:true, linkText:Basement Scene Controller, descriptionText:Basement Scene Controller switch is on]
12:32:23 AM: error groovy.lang.MissingMethodException: No signature of method: script14986263968581059460091.messageHandle() is applicable for argument types: (java.lang.String) values: [Basement Scene On]
Possible solutions: messageHandle(java.lang.Object, java.lang.Object) @ line 345
12:32:23 AM: debug Basement Scene Controller: Button 7 was pushed

I get similar logging when I push Button 8. The downstream rules in the ABC smartapp don’t process, but I assume that’s because of the above error. In case this helps the debugging, I noticed that if I use Smart Lighting to look for a switch on/off event from the WS100, rather than a button push, the smartapp behaves as expected, and I can control my scenes. But of course that solution is not extensible for buttons 1-6. :frowning:

One other bugaboo…if I do exactly the same as above, but using a physical tab (single up or single down), the hub shows nothing until I press the refresh button in the iOS app. This behavior is surprising to me since the reason I picked this device was due to its “instant status” feature. I interpreted (misinterpreted?) that to mean that a button press would be recognized by the hub near instantaneously (or should I say ST-instantaneously? :grin:).

Appreciate your thoughts on this!

Have updated to the latest ABC code?
There was an error I fixed shortly after release, regarding notification handling. The latest is ver 170620.

There are ongoing issues with ST regarding status updates with many threads open on this. I have to constantaly refresh or back out of the thing view and go back in to see updates. As long as the button reponds as designed, then the issue is probably on the side of ST and not your device.

Woo Hoo. That did the trick. ABC fires correctly upon button 7 or 8 push from iOS app. Thank you. :joy:

However, this (above) is still a problem. Notably, if I physical tap (whether single, double, or triple), then refresh from the iOS app, the “last tap” indicator tile in the lower left of the “Right Now” view does not change even though the iOS app correctly indicates a state change from on to off in the case of single tap off (and vice versa). As a result, the ABC app does not fire. :confused:[quote=“stephack, post:19, topic:90188”]
There are ongoing issues with ST regarding status updates with many threads open on this. I have to constantaly refresh or back out of the thing view and go back in to see updates.

Gotcha, thanks for the heads up. Assuming that these ST issues did not exist (obviously a hypothetical question–hey, dreaming is good for the soul :innocent:), am I basically correct to understand that a device that accurately bills itself as having “instant status” means that the device will push its state change to the hub in near real time?