davolesh / mqtt_pushbutton

8 stars 1 forks source link

I need help #1

Open ikke68 opened 4 years ago

ikke68 commented 4 years ago

Hi Dave,

I saw your video on youtube, and i flashed a NodeMCU with your software using arduino. That all worked out because my device is connected to my wifi, but how do i set up my device in Home Assistant? because for other projects i use tasmota, and tasmota got a auto discovery function.. I'm looking forward to your answer!! Greatings, Rens

davolesh commented 4 years ago

Hi and thanks for getting in touch.

To get this to work with home assistant, you need to set up two different automations. 1 automation for the quick press, in one for the long press.

Here is an example of one of the automations. The automation wait for the word "toggle" then flips the switch of your choice.

Screenshot_20200225-071801_Home Assistant~01 Screenshot_20200225-071807_Home Assistant~01

I actually have this set up with tasmota in my house now. Both click and hold work for two different lights. Auto discovery also works. There will be a video on this soon.

-David

ikke68 commented 4 years ago

Hi David,

Thanks for the fast reply! i'll try it with your pictures. Is it possible you can show me now how you set it up in tasmota? Because that easier for me, i have a few tasmotized device's and that way i keep it al the same :) Thanks Rens,

davolesh commented 4 years ago

Absolutely, I'll give you the commands needed tonight, (they are at home, I'm at work.)

ikke68 commented 4 years ago

Okay thanks allot!

ikke68 commented 4 years ago

for the mqtt server part do i need to put :8123 behind it?

davolesh commented 4 years ago

8123 is the home assistant port. The MQTT port is 1883.