I'm looking for a button device to use as a switch

Hi,

I am looking for a button device that I can hook up to OpenHab to help with some automation

There are a few things I have found

  • Flic - but it appears to be bluetooth - phone apps only
  • Amazon dash button - not available in the UK and is rather ugly

What I would like would be

  • Small / discrete button that could be placed beside light switches
  • Battery powered
  • Multi function on a single button (much like flic) i.e. single press, double press, hold

Any good and preferably cheap solutions?

Another comment on Dash is their range is a bit limited and there is a large delay (seconds) from the time you push the button to OH receiving the message. I tried to set one up as a garage door opener remote. It can see it being useful for controlling things in the background (e.g. set away mode, log some info, etc) but if you are using it to control something where the lag is noticeable (e.g. lights) I wouldn’t recommend it.

Seems a bit strange to have a delay - I thought it would just call a URL directly? Is it routing out to a webservice?

Its a shame that the company thats making them for Amazon doesn’t do an open version of them

You have to be clever to get the Dash button to work. It doesn’t stay connected to your network all the time and if you configure it to the point where it is hitting its URL you will end up purchasing a box of Tide or something every time you turn on the lights.

How to get it to work is to initially set up up through Amazon’s app on your phone but bail on the last step. This lets you configure the Dash so it can join your network but not actually order something when you press the button. This also means it doesn’t ever hit a URL either. Then you have to set up a network sniffer that looks for ARP packets from the MAC address of the Dash button. Once you see that packet you know the button has been pressed. But the Dash has to negotiate the wifi connection to your network (it doesn’t stay connected all the time) before it can send that ARP packet and that is the cause of the delay I’ve seen.

I suspect they cost significantly more than the $5 Amazon charges for them. I suspect they have the same business model as printers, sell the device below cost and make up the difference through later purchases (not to mention you have to have already paid for Prime to order one). Also, given the physical way it works described above, I’m not sure it would be all that attractive for HA even where it available.

Makes sense when you describe whats going on

Just a thought - Does it make any difference if you set a static arp?

The Dash button would seem pretty limited in functionality - It would be ideal if the flic connected to wifi.

These look interesting too…

Probably not because the delay is caused by negotiating the wifi connection which takes place before the ARP packet is sent.

Indeed but I see two problems from an OH perspective. First is it uses Zigbee which is not supported by OH 1 (and I don’t know if OH 2 fully supports it yet, though it is planned) and it says on the site “Notes: This item must match the xiaomi multifunctional gateway to use” which I interpret to mean you have to use their hub.

But the price and form factor is indeed perfect. Maybe someone will have some time to reverse engineer their hub or maybe it will work with other Zigbee hubs eventually. I have several use cases where having a simple button like this would simplify things for me too and I’ve been hesitant to tackle building my own.

I just want to point out that Flic might be an option.

There may be a native binding for Flic in the future.
You would need a server with Bluetooth of cause.
And the range might be limited.
But there is already a linux library. You don’t have to use a phone to connect your Flic.

But there is already a linux library.

Out of curiousity, are you referring to Bluez ? Have you worked with it? I have, and would love to find something else. I’ve hacked a crude bluetooth to mqtt translator into one of the sample programs, but crafting something from straight C/C++ without a lot of dependencies looks, well, beyond my capabilities at the moment.

(With apologies for hijacking the thread)

john

All I have done is using Flic via Tasker.

But there is an official linux library:

How about something like this: http://www.vesternet.com/z-wave-philio-smart-colour-button-gen5

Possibly a bit expensive for a simple switch function, but being z-wave, should work out of the box with openHAB.

What about a USB keypad connected to a Raspberry pi? By running a keylogger on the raspberry, you’d have many possibilities: do that if 0 is pressed, do this if 1 is pressed, etc…

1- use LogKeys to log keystrokes
2- use incrontab to execute commands on new keystrokes
3- use curl to communicate with openHab

What a zwave key chain?

http://z-wave.us/key-fob-4-buttom-z-wave-me-remote-control.html

You need the xiaomi gateway, but I’m currently thinking about testing theze: https://www.gearbest.com/smart-light-bulb/pp_257679.html?wid=21

It seems you have revived an old thread, but quite relevant to why I am on here today. I bought one of these (not managed to get it bound yet):hank SC01 Scene controller
Which would have answered this query from 2016!
But as its active again and it may get searched I thought I’d contribute.

Oh It was’n t my intention to :wink: but it still is an issue. I’m still looking for simple buttons to perform simple actions, like turning the radio on anf off… This one is quite expensive though. I ordered some Xiaomi gear and will try these out.

@bdv out would be great to see what one’s you bought and to know how you get on with them.
Perhaps a link to the product? as i will need something like this in the future, and cheaper is always good!
The Hank Scn01 I have to admit was bought for its looks. It needed to please my other half and she liked the look of this one most. It’s now bound and sends decimal numbers great. I just need to work on the rules for these numbers now.

I have a few Aeotec MiniMotes (https://aeotec.com/homeautomation) for this. They are not really a mounted solution, but they are small and can easily be stuck to a wall, under a table, etc. It can be setup as a Scene controller (it’s a zwave device), and can also be used to include/exclude devices. There are 4 buttons, but each has a long and short press (8 scenes). But using rules, this can be extended indefinitely. My favorite use is setup as a long press on button 2, which triggers an audio notification that beer is being requested!

Buydig.com was recently dumping open-box minimotes for $2.99/each with 50% off the third one purchased. All three of the ones I received had completely dead batteries, but Buydig refunded the money and didn’t require the minimotes to be returned. The batteries were cheap and easy to solder in, so I ended up with 3 minimotes for the cost of replacement batteries.

@Nutterbloke you can find an overview on tweakers.net (in dutch, but the table is self explanatory: https://gathering.tweakers.net/forum/list_messages/1811109

@5iver
Cool, i’ll check m out!