ESP8266 and Single Channel Relay Module

Hi everyone,

Been playing around with Arduino and came across this pretty neat chip ESP8266. Have a songle SRD-05DCV etc module and an ESP8266. Decided to use the ESP8266 as the main controller.

SO, I connected up (without relay) ESP8266 with an LED light - used wifi to turn on light - all seems to work ok

Then connected in the Relay module - when activated the LED on the relay light up but the switch doesn't seem to work ie. connecting up the COM and NO to make a DC 12V circuit that activates a motor.
I'm thinking the relay is supposed to be powered at 5V but the pins from the ESP8266 only supply 3.5V - is that the problem? If so, then why is the LED lit up on the board when I switch it on?

Just so you know , the motor works fine if COM and NC are connected. The problem is the switch - any pointers would be appreciated.

Thanks

"The problem is the switch - any pointers would be appreciated."

Have you used a multimeter to verify the relay is operating as desired? Trying to power a 5v relay with just 3,3v board pin is suspect.

Thanks for getting back to me so quickly.
Problem is the 5V required by the switch.
I need to somehow convert the signal from the 8266 pin from 3.5V up to 5V.

I'll scan the web - should be a straightforward solution with the bits I've got in my starter kit ... (there's always a bug somewhere to be found !)

I refer you to this post. :grinning:

Thanks Paul - I actually manually connected the switch to a 5V line and it worked .. haven't had enough time to look yet - but I need to essentially step up the voltage from the 3.5V pin to 5V .. I'm sure I've seen an article about using a transistor and summink else ... have to read up on it tonite ..

Cheers

I think you need to show us - with a Web link- what relay module you are using. A transistor - other than the one already in the relay module - should not be necessary.

Hi Paul,

So after reading up a little - I have a SONGLE SRD-05VDC Module - it has the necessary transistors and diodes etc on there ..
The ESP8266 module runs off a 3.3V powersupply handily driven from my USB connection to my PC.
I have a DC power supply of 12V (for the motor)

Also a different power supply on a breadboard of 5V.

Connected up 5V supply to SONGLE.
The common (signal coming from ESP8266) connects directly @ 3.3V to the SONGLE module.

The ground from the 5V power supply however goes to the GND pin on the ESP8266 module.

And voila - it all works - I did a physics degree and for the life of me , I really don't understand why this works - but hey ho .. a lot more reading methinks.

Z

zbhuia:
So after reading up a little - I have a SONGLE SRD-05VDC Module - it has the necessary transistors and diodes etc on there ..

Unfortunately, that tells us what relay it is, but not what module, and there are a few quite different ones. A web link would be useful.

zbhuia:
The ESP8266 module runs off a 3.3V power supply handily driven from my USB connection to my PC.

I would be passably interested to know which one that is also, to advise on whatever it is entirely sufficient. :grinning:

"I really don't understand why this works"

Pretty simple type circuit, the pin 3.3v/current goes to the base of the transistor, out the emitter of the transistor, and back to the ESP8266 thru the common ground. This allows the transistor (assuming NPN) to open and the supply 5v/current to flow thru the transistor to power the relay and back to the 5v ground.