Hass.io Add-on: Sonoff Server / Sonoff no need of flash

Hi @gerswin

Since the latest update this is no longer working. I’ve notice a few errors with the addon authenticating with home assistant recently too.

Integration sonoff not found when trying to verify its light platform.

Any ideas?

Cheers

Andy

Hi @Jhonny

I’m struggling to test this, the addon doesn’t show up when I add your two repo’s to hassio addon store, any suggestions?

Many thanks

Andy

I have the add-on installed and running. I have issued the command to the sonoff, but I don’t see it under the device list (on port 1080). The sonoff (ifan02) is connected to my network. Has firmware version 2.7.0 I think.

What I’m I doing wrong.

Hi @mcinnes01

My repos were not intended to be used through the hassio addon store,
I have a Home Assistant setup on a laptop using docker (so hassio & hassio addon store is not available for my setup).

My repos were intended to be used “manually”.

You can use the https://github.com/SideCodeIO/Sonoff-Server repo
to setup your own sonoff server (nodejs server) on your machine
And the second repo: https://github.com/SideCodeIO/Home-Assistant-Sonoff-Server-Integration
Is more like instructions on how to manually add your sonoff devices to home assistant as light components.
And this can be done by:

  • Adding a custom “sonoff” component to your “custom_components” folder.
  • Connecting Home Assistant to the server by adding the host and port to the configuration.yaml file as specified in the repo.
  • Adding the device to your sonoff.ha.json.

Hope it helps!

Hi @Dinoaus

I am not sure if my or any other “private sonoff server” solution supports the ifan02 device, I don’t have one in order to help and check if it does.

I can see in my router the ifan02 trying to connect the 13.56.122.167:1081.

I assume this is something to do with the new firmware, that stops it from connecting without a validate cert. Might have to go down the TASMOTA route. Was hoping to not have to flash it and be able to use the included remote.

IFAN02 remote will work even with TASMOTA flashed.

1 Like

Ending up frashing TASMOTA on it, only have 2 speeds. Medium and high (Low = Medium, Medium = high and high = high). Wondering if replacing one of the capacitors with a smaller one would fix the issue?

Hi @Jhonny

Sorry for the late reply, I’ve took the plunge and moved from Microsoft server at home to ubuntu and docker for everything, so finally got home assistant back up and running.

As I said I’m moving things to docker, I’ve got a few things I’m trying to port myself, but in the meantime I found it easier to use @gerswin’s containerised sonoff server. (I did have a try to get your’s working in a container but I’m still learning docker and I still haven’t fully got my head around how to interface with the hassio base images).

So the current problem with @gerswin’s is the custom light component is no longer supported. As the server element of both your’s and @gerswin’s are based off the same sonoff server implementation, I wondered would your light component work with @gerswin’s server? I.e. if I just set the port to 1081?

Many thanks

Andy

Why would you say that @gerswin light component is no longer supported?
In any case, my light component and @gerswin light component are basically the same, as far as i remember I just used his and bunched it with all of the other needed configuration to better document it with my complete setup.

About the port, I don’t know how @gerswin sonoff server works exactly, but in any case, Make sure to be consistent with the port numbers you assign in the config’s.
And make sure that https port is working with any valid SSL Certificate (it won’t work without it).
And that this port is the port you set when you setup a new device (when you access it via wifi and doing the post request to to tell it to use your sonoff server as the “sonoff cloud” server)

Yeah I’ve started having a good dig through the component myself and as you say it’s pretty much identical. I’ve been comparing to the example light component and tweaking it accordingly. I’ll let you know if I make any headway.