ESP8266MOD - Migration from ESPEasy to ESPHome

Hello together,

I have a new project that I’m unfortunately stuck on and need your help. I want to make my Hörmann garage door smart. I use the Hörmann adapter board (UAP1) which can show the state of the door (open / closed), the state of the light (on?) and control the door (up, down, ventilation position) and the light (on / off).
To control that with HA I have ordered an Board based on a ESP8266MOD with wich all the functions can be done and all the states can be shown.

Now the problem: The board is based on ESPEasy. I want to migrate it to ESPHome but there are some topics I don’t know how to handle it.

1) I created an project in ESPHome but here I just could choose ESP8266. In the yaml-file is the following written. Is that correct? I don’t know the exact type, vendor,… But in ESPEasy is written “Espressif Generic ESP8266 ESPEasy 4M Flash 1M FS”
In another thread here in the community a user has written “nodemcu” at board.

esp8266:
  board: esp01_1m

2) In ESPEasy are 7 Swicht inputs. The states (door open, door closed, light on) are no problem. They I can set as a binary sensor like:

binary_sensor:
  - platform: gpio
    pin: 1
    name: "garage door opened"
    device_class: garage

But how can the switches be written? Here the rules in ESPEasy:

on up do
 gpio,12,1
  timerSet,1,1
endon

on down do
  gpio,15,1
  timerSet,1,1
endon

on part do 
  gpio,13,1
  timerSet,1,1
endon

on light do
  gpio,14,1
  timerSet,1,1
endon

on Rules#Timer=1 do 
  gpio,12,0
  gpio,13,0
  gpio,14,0 
  gpio,15,0
endon

Am I right with the following example-code?

switch:
  - platform: gpio
    pin: 12
    id: relay
    name: "open gate"
    icon: "mdi:gate"
    on_turn_on:
    - delay: 200ms
    - switch.turn_off: relay

If yes, do I have to set different id’s for the different switches (e.g. relay1, relay2,…)?

3) A generell question: In ESPEasy is written for example “GPIO-1 (D10)”. Fo I have to use for pin: “1” or “D10”?

4) The big problem I have is that there is no USB-port at the ESP. Because of have to flash the ESPHome firmware via ESPEasy and it has to work directly at the first time (except the sensors / switches).

Thank you in advance!!

Best regards
Andreas

Looks ok to me, assuming you want to momentarily turn on gpio12.

In ESPHome you have options for how to refer the pin. See here.

The part with gpio12 was just an copied example. I just want to rebuild the ESPeasy firmware (which is partly written at #2) in ESPHome. When I’m finished the following things should be possible:

  • show if garage door is open
  • show if it is closed
  • show if the light is on
  • open the garage door
  • close the garage door
  • bring the door in ventilation position
  • turn the light on

Do you also know which board I have to write in ESPHome? Is it the one I wrote in #1? It was the standard ESPHome directly have written in the blank configuration file.
Regarding to the following page it could also be esp12e (the person who sold the board to me said it is a ESP-12F) or esp01_1m (but here the Flash value is not correct).

Here the pins which are used at the moment at ESPeasy:

Can nobody help?

I tried today with board: esp12e and everything works as it should :slight_smile: