#Flip state of a device? Garage door open closed state

1 messages · Page 1 of 1 (latest)

stable hemlock
#

I installed 2 iotorero garage door devices. I installed them a different way so I only had run the wire 1 ft instead of like 20 ft. But this meant the magnet is in range of the sensor when the door is open, not closed.

Can I flip the state of the device somehow so it will show the garage is open when it’s close to the magnet instead of closed?

wheat blade
#

How did you integate it with HA?

stable hemlock
#

It’s an ESP32. So I connected to its WiFi to setup my WiFi. Then it popped right up in HA

wheat blade
#

so, ESPHome?

ancient skiff
#

It's gonna show as closed when it's 95% open.... which is not really what you want for security :\

stable hemlock
stable hemlock
smoky ember
#

Are you using a cover template to create the cover? The code I used had a lambda for open/closed - just had to swap them as my reed switches were NO not NC or something similar… was a long time ago.

#

On mobile so it’s a bit of a shit to copy paste but this is one of the old ones (running on a Shelly 1)

#

Plus inverting the binary sensor state

stable hemlock
#

The cover is just auto made via the button I guess. That’s all I did, added a button to my dashboard and selected the entity. But I’ll look into a template

smoky ember
#

Ah ok if you didn’t / can’t access the actual Esphome code, maybe see if the reed switch itself has different connectors for Normally Open vs Normally Closed

stable hemlock
wheat blade
#

yes

stable hemlock
#

Gotcha. And I can flash it with the OTA firmware update?

smoky ember
#

Yep. Pretty sure you’d just need to add the invert bit to the sensor for the mag switch.

stable hemlock
#

Yeah I’d try that first

smoky ember
#

Yeah, does it let you BYO yaml file for the firmware or something?

stable hemlock
#

And that yaml and found the yaml on the store page https://www.athom.tech/blank-1/garage-door-opener-for-esphome

AthomTech

Compatible Test: Please make sure it compatible with your door openner before place the order. Use a needle nose plier or papaerclip to touch the two garage door teminals together.​If the garage door opens and closes, the Smart Garage Door Opener is compatible with your garage door opener Pre flashed ESPHome built in ESP32C3 For Yaml, please...

smoky ember
#

Yeah if that’s looking for a yaml file then all good. If it wants a precompiled firmware you might have to suss with athom

stable hemlock
#

Ah

wheat blade
#

You can probably just take control with the ESPHome builder and build and install from there

stable hemlock
#

I figure it would want yaml since it’s provided on the store page

smoky ember
stable hemlock
#

Ok I’ll do that

smoky ember
#

Plus with esphome builder you can tweak the yaml, click update, and it’ll compile and upload wirelessly. Super easy for developing in the live environment 😂

stable hemlock
#

Yeah I’ll take a closer look tomorrow when I’m at my pc. Don’t wanna mess too much from phone / couch

#

But I took control of both

stable hemlock
#

so when I click edit on the device. do I just clear all that and replace with whats on github?

#

Then click install?

#

because what I see now, I assume is just a wrapper for the yaml thats pulled from github?

smoky ember
#

Sorry was driving. Yeah it looks like that just replaces the ‘packages’ bit with the yaml from GitHub. Not sure whether you’d need to merge the bits from esphome / api etc but maybe? Eg the yaml still needs your api key and wifi secrets etc

stable hemlock
#

Gotcha

stable hemlock
smoky ember
#

Hrmm. Not sure. Did it change IP address?

stable hemlock
#

Good question

#

No, still 47

#

and now it only does this. It did a lot more the first time

stable hemlock
#

maybe I need to use a usb

#

When I took control of these in Home Builder, it wanted me to install something which I did not

stable hemlock
#

Idk, im at a loss

#

cant install wirelessly or plugged in

stable hemlock
#

@smoky ember any ideas?

wheat blade
#

Seems like you picked the wrong YAML. The one you originally pointed to clearly says ESP32

stable hemlock
#

This is what I am trying to install. A mix of what showed originally from ESP Home and the github

wheat blade
#

esp8266:
board: esp8285

#

That's your problem

stable hemlock
#

what in the world

#

somehow got the wrong github at some point

#

progress i guess

#

and still...

#

feeeellling like its not working lol

#

Started again from within the edit and redoing the YAML again

#

oh that was wireless, got this

#

but cooking now maybe

#

mayybe

#

wants me to install something, trying that

#

so can I click stop??

#

seems like it installed

#

Just counter intuitive to click “stop” to close this window

smoky ember
#

Soz been offline. Yeah that looks good. And agree it’s counterintuitive

stable hemlock
#

Feel like the WiFi isnt working now, cannot take control

#

No local server running for me to control from

#

I did another install where this time I tried to invert the binary sensor

#

After that first install last night it was working as stock

stable hemlock
#

I can still see it here

#

Wont let me configure WiFi

stable hemlock
#

Feels like this thing is dead in the water now @wheat blade

#

I can conect to it and Prepare install from here, it finishes, then tells me it cant connect to it, cant configure wfi, isnt discoverable in HA ESP Home Builder

smoky ember
#

Dammit. Does it show up on your dhcp/router etc?

stable hemlock
stable hemlock
#

I dont even get a blinking light anymore... maybe I borked it

#

But it does appear as a com port

stable hemlock
stable hemlock
#

added this to substitutions
status_inverted: false