diyhue / diyHue

Main diyHue software repo
https://diyhue.org/
Other
1.56k stars 279 forks source link

Add support for Hue Tap Dial Switch? #869

Open Kickbut101 opened 1 year ago

Kickbut101 commented 1 year ago

Is your feature request related to a problem? Please describe.

I would like to be able to use the Hue Tap Dial Switch natively in the Hue app on my phone (with Zigbee2MQTT and DIYHue as it's backend. Both of which are hosted on Raspi w/Home assistant).

Describe the feature that you would like to be added

Support for this device

Describe alternatives you've considered

Describe your use case for this feature Using the native Hue app to manage and control my lights without having to make logic and templates via home assistant Checklist

Additional context

mariusmotea commented 1 year ago

Hi,

For this device to work you only need to add the conversion of the names used in zigbee2mqtt and Hue buttonevents. Here you can see how this is made for already supported devices:

https://github.com/diyhue/diyHue/blob/master/BridgeEmulator/services/mqtt.py#L30

From our old Arduino sketch that emulate this device the buttonevents codes are 34 for button 1, 16 button 2, 17 button 3 and 18 for button 4.

https://github.com/diyhue/Devices/blob/master/HueTapSwitch/ESP8266/HueTapSwitch/HueTapSwitch.ino#L162-L172

https://www.zigbee2mqtt.io/devices/8718696743133.html

The possible values are: press_1, press_2, press_3, press_4

GitHub
diyHue/mqtt.py at master · diyhue/diyHue
Main diyHue software repo. Contribute to diyhue/diyHue development by creating an account on GitHub.
GitHub
Devices/HueTapSwitch.ino at master · diyhue/Devices
Sensors and Controllers with support for diyHue. Contribute to diyhue/Devices development by creating an account on GitHub.
Philips 8718696743133 control via MQTT | Zigbee2MQTT
Integrate your Philips 8718696743133 via Zigbee2MQTT with whatever smart home infrastructure you are using without the vendor's bridge or gateway.