AutoArduino Sonoff

Discussion in 'Guides / Examples / Ideas Forum' started by Tim44W, Jul 22, 2017.

  1. Tim44W

    Tim44W New Member

    Jul 22, 2017
    Likes Received:
    Hi Everyone.

    I am a complete newbie so please dumb down any responses please.
    I have decided to go down the road of home automation and have made some progress with the RM plugin controlling my TV, Audio and AC. Also made progress using Autovoice with google assistant but when I changed from US english to AUS English Autovoice isnt yet supported. Hopefully it will be soon so i can change from US english.
    I am now looking to control the power going to these devices to try save a few dollars in power while things are in standby mode. I have bought the Sonoff TH10 which i can control with the ewelink app but that is pretty useless. I have seen there is a way to emulate button pushes but im sure there is a better way. I am told the Sonoff uses an Ardunio board which I see there is an AutoArduino app now, does this app work through wifi? I just have no idea how to to make it all work.
    The end goal is to be able to talk to Google assistant and everything turns off or on.
    Any help would be great.
    Speshal likes this.
  2. Speshal

    Speshal New Member

    Sep 16, 2015
    Likes Received:
    Hi Tim (or is it G'day) :)
    All the Sonoff products run an ESP8266 Wifi module. The bad news is that the supplied firmware (eWelink) sucks donkey balls. The good news is that you can replace it really easily. I don't have the TH10, I only have the Sonoff mains switches but I have replaced the firmware with the ESpEasy firmware so that my switches communicate with a Domoticz server via MQTT and they work flawlessly, although you don't need a Domoticz server you can just pull the data from the onboard HTML page using something like AutoTools.

    You'll need an FTDI USB To TTL Serial Converter (you can get these off eBay for a couple of bucks) and a little patience.

    Here's a guide on how to flash the firmware -

    And another guide should you not use Linux -

    Once you've flashed the firmware, connect a serial monitor (Arduino ISP, putty et al) to find out the Sonoff's IP address.
    Where you go from there is up to you, the simplest way to get a Sonoff to turn on is to send a command like this http://<ESP IP address>/control?cmd=GPIO,<pin>,0 so for example if you get the IP of and the Sonoff switch relay is on pin 12 it would be,12,1 to switch on and,12,0 to switch off.
    I hope this helps and good luck.
    Any problems, drop me a line - Speshal at Speshal dot co dot uk

Share This Page