Introduction: Web Controlled Socket by Arduino
I made one Web controlled socket by Taiwan cloned Arduino, which is based by Arduino Pro Mini and ESP8266-1, the official site of this clone is : Webduino = Web x Arduino
Follow the 19 pictures, and you can build one. The program is very easy, just send HIGH/LOW to an Arduino pin by digitalWrite() to on/off a LED.
By this, the Relay becomes a switch, when we send HIGH to active it, the COM and NO terminals will be connected.
Get the three pins on relay, and remember the mapping of wires...please!
Seal and fix everything.
Test...it works! But, please remember the specifications of components are very important.Especially, safety matter. The controller is Webduino, power it by a smartphone wall charger in orange.
The code is so simple, just like light up a LED : https://webduino.io/tutorials/tutorial-01-led.html