Relay to wemos d1

Hey,

Can I connect 5v relay module to 5v pin on wemos d1 even if the board is 3.3v?

TomasRoj: Hey,

Can I connect 5v relay module to 5v pin on wemos d1 even if the board is 3.3v?

The 5V pin provides a constant 5V output. It would be pointless to connect a relay to that pin, since the relay could not be toggled. But, you can do it.

Can the 5V pin supply enough current for the unknown relay coil? Can the 3.3V output pin reliably trigger the unknown relay? A web link to the unknown module might help.

TomasRoj: Can I connect 5v relay module to 5v pin on wemos d1 even if the board is 3.3v?

There is a trick with the opto-isolated relay boards (so we need to know exactly which relay board you have).

Those which use an active-LOW input and have an indicator LED in series with the opto-coupler: |500x206 require more than 3.3 V to actuate, so you connect "VCC" to 5 V and the "IN" to the WeMOS. The voltage drop of the two LEDs in series guarantees that it will not tend to pull the "IN" pin above 3.3 V but when it pulls low, the opto-coupler is fully turned on.

Of course a relay module requires 5 V on "JD-VCC" to function.