Entity not available

I have an ESP8266 based light switch which I made following a guide I found online.
It consists of a wifi module, a solid state relay and an ac/dc power supply (from 220 to 3v).
I flashed the module using a usb to serial adapter and everything works like a charm!

At this point, I must say I am no expert and I only have a reeeeaallly basic clue on what I have achieved so far. I understand the connections, and I also am able to understand part of the code I (copy-pasted) flashed on my module to connect to my wifi and HA can discover it.
What I am NOT sure is: How to know if this creation is recognized as a specific brand. I think the firmware I flashed was supposed to be a Wemo switch. Can I confirm this somehow?

Now to my real problem.

While this whole thing is successfully connected to my network, every time I restart HA, the switch is not discovered and I cannot turn it on or off.
I have to either reboot my wifi router or turn off the physical switch for 4-6 seconds and then turn it on again. It sounds like the switch is only broadcasting its presence only at the time it connects to the network.

I know I asked if there is a way to know if it is a wemo switch (and will probably look silly if you see below), but I asked only because I am not sure what and if I am doing this the right way. My configuration.yaml is this:

wemo:
  static:
    - 192.168.1.xx

The frontend shows this:
3

It’s pretty hard to know anything about the problem without at least a link to where you got the instructions for building your switch.

Thank you for your reply.
Here is the guide I followed for building the switch:

and this what I flashed in the module:

The documentation says you can try to discover devices automatically. Have you tried that yet?

If you just put

wemo:

in your configuration.yaml it will try to discover wemo devices on your network.

If discovery doesn’t work and you need to use a static config did you set your router to give the switch a static IP address?

In my original post (check the bottom) I mention my configuration.yaml setup which indicates that I have already done that. What I didnt mention is that nmap discovers the switch with the correct IP. I can also ping the device.

I am not really sure what the problem is, but it looks like the device is connected, but HA doesnt discover it after restart.

English is not my native language but I will try to be more specific.

The device is connected to the network, I can ping it, nmap discovers it and HA can switch it on and off. Everything works fine.
BUT: If I restart HA it wont reconnect to the device. At that time, I can see the device in my network, i can ping it, and nmap can discover it.
SOLUTION: I have to physically switch off the device (or shutdown my wifi router) for some time and then turn it on again. Only then HA will discover it again.

Thank you for your time!

try removing the the “static:” part of your config and see if HA will discover it automatically.

It still doesn’t discover it. I even waited for about 5 mins, just in case.

Sorry, I’m out of ideas.

With DIY stuff it’s hard to tell what you are going to get.

Hopefully with the additional info provided someone else with more knowledge may come along to help out.

1 Like

Thank you very much for even trying!

1 Like

I just saw a new thread with someone else having a problem with a wemo device that gave me a reminder…

Is there anything in the log file when HA restarts dealing with wemo?

My logs are full of this annoying message saying Failed to parse headers when you have an mpeg camera. So my logs are pretty much useless… I have to disable the cameras and I will do it sometime in the weekend I guess…