Control 5v relay with 3.3v ESP8266

Thread Starter

Asger Nohns Jensen

Joined Jul 7, 2017
2
Hi all!

I want to switch on a 5v relay with a 3.3v signal.

I have my ESP8266 running off a 3.3v linear regulator (LM1117T). The source is a USB 5v capable of delivering 500mA. Shoudn't i be able to use this 5v signal to control the relay?

I have tried a lot of setups but without luck! I could really need some help. :)

I have a MOSFET (IRL540N) and a BJT (BC547).
The relay is 2 relay module.
 

DickCappels

Joined Aug 21, 2008
10,224
If your relay coil can operate a little bit below 5V you can probably use the USB 5V supply to power it.
Can you provide some information about your relay:

• Pull-in voltage
• Resistance

The actual datasheet would be even better.

I guess that is enough. Which output on the ESP8266 are you trying to use?
 

Thread Starter

Asger Nohns Jensen

Joined Jul 7, 2017
2
Please post details of the relay module.
This may already include driver circuitry for the relay.
The relay is here: http://www.everbuying.net/product1160582.html
I can't really find the datasheet I'm sorry.

If your relay coil can operate a little bit below 5V you can probably use the USB 5V supply to power it.
Can you provide some information about your relay:

• Pull-in voltage
• Resistance

The actual datasheet would be even better.

I guess that is enough. Which output on the ESP8266 are you trying to use?
I have tried to power the relay with 5v from the USB cable, and then tried to send a 3.3v signal which doesn't work. I'm trying to use the GPIO2 pin on the ESP8266.
 

AlbertHall

Joined Jun 4, 2014
12,384
On the JD-VCC, VCC, GND connector remove the link and connect VCC to your +5V and GND to your GND.
On the other connector at that end of the board connect:
GND to your GND
VCC to +3.3V
IN1 to your GPIO2
IN2 to another GPIO if you want to use both relays.
I believe (but cannot be certain from the module description) that taking IN1 or IN2 low will operate the relay and taking them high will release the relay.
 
Top