Re: ESP8266-01 gpio2 5v out to trigger relay
Posted: Tue Jun 07, 2016 8:22 am
I sincerely think that you need to give us more info...
-->
Open Community Forum for ESP8266, Come share Arduino and IoT (Internet of Things)
https://www.esp8266.com/
The PN2222 isn't the best part to do a relay driver, especially if the relay coil requires a lot of current.
It is better to use MOSFET.
Also, about the use of GPIO2 : beware that GPIO2 needs to be pulled-up for proper boot mode, therefore you should consider that idle state of the relay driver should be OFF when GPIO2 is HIGH, so the driver would need an inverting stage, which mean a second MOSFET.