dresden-elektronik / deconz-rest-plugin

deCONZ REST-API plugin to control ZigBee devices
BSD 3-Clause "New" or "Revised" License
1.89k stars 498 forks source link

Device Integration: Samsung SmartThings Button #993

Closed mysteryan closed 5 years ago

mysteryan commented 5 years ago

Is it possible to add compatibility for SmartThings Button: https://www.amazon.com/Samsung-SmartThings-GP-U999SJVLEAA-One-Touch-Appliances/dp/B07F8ZFFQK/ Hoping integration would be simple since other SmartThings products have been integrated and its already recognized by Deconz GUI. Device transmits events for button press, double press, hold and temperature. Node shows up in GUI, but missing from rest api. ef5cf35d-f3f6-46a5-a21b-3545a5319999 45539a50-98d1-41d3-a7d7-c3872de957fe 53f83a5b-5d78-4491-85da-9f2654abadcf 5b41d16c-3546-4bed-9a5e-2cd6fe05c161 e14271ee-9da3-4674-94bc-3b39ba839dea 95755626-1563-4ea7-9a4f-0ef3e18bedc6 af24b1c0-d50a-4426-8fa2-553dd0086b81 6acef3ab-c936-418f-9ffe-cae5375b12fd 69ca7e68-c412-4270-b0d5-02d647996423 81148e5f-dad4-48d8-b8f7-cfd698b71c70 9fa34f2a-7fc8-40aa-aade-ad1984267d71 888f4ece-4356-423f-8ef9-dbb9cbe4dad3 4dfd90be-bdef-4abe-b4e7-90115477192c

mysteryan commented 5 years ago

The endpoints and attributes appear very similar to a leak sensor another person mentioned here: https://github.com/dresden-elektronik/deconz-rest-plugin/issues/946

mysteryan commented 5 years ago

Debug (aps,zcl,zdp) output doesn’t seem to with frep filtered result of nwk address doesn’t seem to yield anything useful. 2865fc23-7c6e-4d9a-89c4-230505c56c45 9a4c5966-2f78-4ece-b238-a35ed3489a1b

I do notice changes in zone status when I press the button shown in no press, press, double press and hold in that order: a5534016-e690-4a9a-a10e-bdb5d8d5afb5 415982f3-11fe-4022-bce4-f55b73b742d3 e083936b-6070-4fb0-8b56-1a0b3906b0f9 0008ea46-e24d-4335-a602-d17724d7ad7f

mysteryan commented 5 years ago

Just realized that it’s not necessary to manually press read to see the button presses. It’s shown instantly in GUI as ticks in the zone status. Alarm 1 for press, alarm 2 for double press, and alarm 1+2 for press hold. f1bc032a-1fa3-4abc-9fd9-cf52b5ce5b64 119e3be5-8abe-41c7-97df-c98f24c3f2e8 b611d63a-dba3-4a61-95ff-afd0b98191af

I’ve tried binding the IAS cluster to a group in hopes that I’ll get usable values in rest, but no luck. So everything looks like its working within GUI, just can’t get it to publish the values in rest.

blueleader07 commented 5 years ago

Any chance this will be available soon? Looks like manup has provided the code? https://github.com/mysteryan/deconz-rest-plugin/commit/876af0f427521ead699aa6e1e197a18a333d6510

Excited to use this one. I'm in the same boat where I see the Alarm 1 / Alarm 2 status being updated ... but can't get the device added to the REST API.

stale[bot] commented 5 years ago

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

qtjupsrkb commented 5 years ago

Is support for the Samjin button likely to be added in the future?

manup commented 5 years ago

Is support for the Samjin button likely to be added in the future?

Yes, we have it here for testing, but there is no ETA yet.

qtjupsrkb commented 5 years ago

Thanks for the update @manup !

That's exciting to hear :-)

keithcroshaw commented 5 years ago

Hello, Thanks for all the hard work going on here. I have one of these buttons that I'm looking to integrate. Has it made it out of the lab yet?

elmgrenen commented 5 years ago

^Wondering the same thing as keithcroshaw

indrora commented 5 years ago

Is there a way we can test this using, e.g., Home Assistant?

keithcroshaw commented 5 years ago

Was support released @indora? I'll gladly test if it was.

manup commented 5 years ago

The SmartThings button isn't integrated yet, but will be very soon :)

mysteryan commented 5 years ago

Button press, double press and hold seems now seems to fire the appropriate buttonevent in the latest commit. Temperature reports also seem to be working properly now. Thanks.

manup commented 5 years ago

Cool, thanks for testing.

elmgrenen commented 5 years ago

How do I add this to Home Assistant? I use conbee2 with deconz plugin so I use phoscon app

manup commented 5 years ago

You'll need to wait for the next version 2.05.70 (or compile the plugin). The button is then available in the same manner as other switch resources.

ecfitzgerald commented 4 years ago

I have 2.05.71 and I can add the button, but in Phoscon its in Switches, but if I try to add the switch to a group with the switch editor, the switch does not appear. I see the temperature and battery in Hassio. I suspect the not seeing the switch in the switch editor is the primary symptom, I can see my Ikea switch and use it in phoscon and hassio, but not this.

keithcroshaw commented 4 years ago

I wonder if it shows up as an event in Home Assistant? I wish that all buttons would show up as binary sensor entities.

bisby commented 4 years ago

It does indeed show up as an event in Home Assistant. single, double, and long presses are all different event types.

{
    "event_type": "deconz_event",
    "data": {
        "id": "button",
        "unique_id": "1",
        "event": 1004
    },
    "origin": "LOCAL",
    "time_fired": "2019-12-04T03:30:23.164600+00:00",
    "context": {
        "id": "1",
        "parent_id": null,
        "user_id": null
    }
}

"event" was 1002 for single press, 1004 for double press, and 1001 for long press.

mysteryan commented 4 years ago

I have 2.05.71 and I can add the button, but in Phoscon its in Switches, but if I try to add the switch to a group with the switch editor, the switch does not appear. I see the temperature and battery in Hassio. I suspect the not seeing the switch in the switch editor is the primary symptom, I can see my Ikea switch and use it in phoscon and hassio, but not this.

Treat it like a sensor and create a rule to toggle an existing group according to its buttonevent.

ebaauw commented 4 years ago

Does this device support Tamper detection and low battery in the IAS Zone Status? The code was inconsistent that state.tampered and state.lowbattery were not exposed on pairing, but were on restore from the database. I now don't expose them for both situations, see https://github.com/dresden-elektronik/deconz-rest-plugin/issues/2672#issuecomment-612491012.

mattiasflodin commented 1 year ago

This is listed in the support page but I see no indication in the issue whether it was actually verified as working. Is it supposed to work? Because I'm having no success pairing this in deconz 10.0.0.4 (FW version 261F0500).