Overview

The Sonoff Dual R2 offers control of 2 relays on one board. 



GPIOFunction
0Button 0 on header
1Serial Rx and Optional Sensor
3Serial Tx and Optional Sensor
5Relay 2 (RED LED)
9Button 1 on header
10Button on Case
12Relay 1 (GREEN LED)
13Blue Led (Inverted)


Hardware Preperation

This device uses the ESP8285 module which is different than the other SONOFF products. 

The four serial pins (VCC, Rx, Tx, GND) are available at the short end of the PCB and can be seen on the left of the image above.

You will want to solder on some header pins onto the VCC, Rx, Tx, GND points.


Flashing the Tasmota Firmware

Configuring the Software

Entering Programming Mode

As with all ESP8266/ESP8285 modules pulling GPIO0 to GND is needed to put the chip in programming mode. You need to connect GPIO0 (button 0) and GND during power up.

Luckily both GND and GPIO0 (as BUTTON 0) are available on the second header. A simple jumper between GND and BUTTON 0 while programming will do the trick.


<PIC>

Uploading the Firmware

From the Arduino IDE, click Sketch → Upload


Reference

ReferenceURL
Product Infohttp://sonoff.itead.cc/en/products/sonoff/sonoff-dual
Schematic for Dualhttps://www.itead.cc/wiki/images/1/1d/Sonoff_Dual_View.pdf
Sonoff-Tasmotahttps://github.com/arendst/Sonoff-Tasmota/wiki/Sonoff-Dual-and-Dual-R2
Sonoff-Tasmota Switch Modeshttps://github.com/arendst/Sonoff-Tasmota/wiki/Understanding-SwitchMode-and-SwitchTopic