I have ESPHome working controlling a range of devices, mostly self-built using NodeMCU and ESP8266_01 devices.
I’m now trying to add some Sonoff Basic switches and am struggling. I first tested the Sonoff switches using the EweLink app and they worked fine.
Using this guide, I then built my config in ESPHome and uploaded the firmware using esphomeflasher. It finishes OK, giving the MAC address etc. so I am fairly confident that the firmware has uploaded OK.
The problem is that once I’ve uploaded the firmware and power cycled the Sonoff Basic, it no longer connects to the WiFi, or gives any indication that it is working!
I used reserved leases on the DHCP so use fixed addresses for all my ESPHome devices. The addresses I’m using for the Sonoff basic switches are not in use and are reserved for these switches. I have copied / pasted the WiFi name and password from a working one so it should be correct.
I’m out of ideas so any help gratefully received!
esphomeyaml:
name: sonoff_basic_01
platform: ESP8266
board: esp01_1m
wifi:
ssid: 'MyWiFi'
password: 'MyPassword'
manual_ip:
static_ip: 192.168.100.186
gateway: 192.168.100.254
subnet: 255.255.255.0
api:
logger:
ota:
binary_sensor:
- platform: gpio
pin:
number: GPIO0
mode: INPUT_PULLUP
inverted: True
name: "Sonoff Basic Button"
on_press:
- switch.toggle: relay
switch:
- platform: gpio
name: "Sonoff Basic Relay"
pin: GPIO12
id: relay
status_led:
pin:
number: GPIO13
inverted: yes