Relay Pinout

I have this relay, and I can’t seem to figure out the Pinout. The pin header pins are +-/s
No description
No description
No description
56 Replies
Coder_DO_As_Impossible
Usually the middle one is Common pin, left side is NO (Normally Open) and right one is NC (Normally Closed).
…Aarav…
…Aarav…OP2d ago
Thank you ! So, where would +/- from a micro USB cable go? And it has GND too. This is my first time using relays.
No description
…Aarav…
…Aarav…OP2d ago
It’s being controlled from ESP 32 on S pin and powered with 5v
Coder_DO_As_Impossible
+ is the positive 5V, - is nothing but GND and S is the Signal But do you know what is voltage rating of your relay?
AnonEngineering
there is no USB involved...
Coder_DO_As_Impossible
There are many type available, 5V, 12V are the most common
…Aarav…
…Aarav…OP2d ago
10 amp 240 v
AnonEngineering
it's a 5v coil
No description
…Aarav…
…Aarav…OP2d ago
Ok
Coder_DO_As_Impossible
Barely visible, but yeahh, by the pic you sent 💯
…Aarav…
…Aarav…OP2d ago
I want this to turn on a lamp, is that possible or will a normal transitor work ?
AnonEngineering
for an AC powered lamp a relay is the way to go
…Aarav…
…Aarav…OP2d ago
No description
Coder_DO_As_Impossible
Is this an Active relay or a Passive relay?
…Aarav…
…Aarav…OP2d ago
I don’t know, it came in an dev kit It’s an normal desk lamp
Coder_DO_As_Impossible
By looking it seems an Active relay tho. But can't say.
AnonEngineering
it has a transistor driver on it
Coder_DO_As_Impossible
I asked coz I have got both the types with transistor on them
…Aarav…
…Aarav…OP2d ago
It has an resistor, LED, and an flubsck diode, And transitor
AnonEngineering
idk what a "passive relay" is
Coder_DO_As_Impossible
They require the LOW signal on the Signal pin to turn on and HIGH to turn off. Active is the vice-versa
…Aarav…
…Aarav…OP2d ago
After an quick google search they are different
AnonEngineering
that is just drive polarity... active LOW or active HIGH
Coder_DO_As_Impossible
Yeahh... but I call the active LOW as passive relay. But nvm...
…Aarav…
…Aarav…OP2d ago
So, can this relay be used to drive my 5v DC lamp?
AnonEngineering
oh, your "normal lamp" is 5v DC? yes
…Aarav…
…Aarav…OP2d ago
Yea
…Aarav…
…Aarav…OP2d ago
It’s this
No description
AnonEngineering
the relay acts like an on / off switch
Coder_DO_As_Impossible
It seems like it has already a battery built-in and a motherboard to control it
…Aarav…
…Aarav…OP2d ago
It does not have an battery it’s an desk lamp that needs be plugged in 5v
Coder_DO_As_Impossible
Then why are you trying to connect a relay to it tho?
AnonEngineering
so that's where the USB came from, you'll need to switch the 5v USB power
…Aarav…
…Aarav…OP2d ago
So I want to use an esp 32 to turn this lap on. Yeah I’m switching from 5v
Coder_DO_As_Impossible
But it has a touch switch for power right. Just from the pic.
AnonEngineering
the 5v will be on relay output side - that's fine does the relay turn on when you apply LOW to "S"?
…Aarav…
…Aarav…OP2d ago
Idk I’m an noob, I want to use an IR sensor, when it detects and hands, to turn on the LED, I tied hooking up 5v to the +- bottom header pins the led did not turn on So I’m using 5v 1 amps power, to turn on this 5v lamp
AnonEngineering
you need to go step by step if you set your lamp on, and unplug the USB, what happens when you plug it back in?
…Aarav…
…Aarav…OP2d ago
The lamp works if o plug it into 5v I’ve been using it for years It does not have an battery I’m 100% sure of that I’ve been using it for years
AnonEngineering
i'm asking that specific question for a reason, does the lamp remember what state it was in when power goes away?
Coder_DO_As_Impossible
Like, if you turn it on the first time, then remove the USB power directly and then again if you give the power does it turn on directly, or do you have to turn it on again by touching it?
…Aarav…
…Aarav…OP2d ago
No It turns on, but the setting is to saved
AnonEngineering
ok, so if it
…Aarav…
…Aarav…OP2d ago
There is no battery I’m sure of that
AnonEngineering
s on, you unplug it it turns back on when plugged in right?
Coder_DO_As_Impossible
We got it.
…Aarav…
…Aarav…OP2d ago
Yeah but the color brightness etc is not saved
AnonEngineering
ok, the relay will act like unplugging / plugging it back in
…Aarav…
…Aarav…OP2d ago
https://a.co/d/imEanzP this is the lamp or very similar
White crown LED Desk Lamp - Versatile and Dimmable
White crown LED Desk Lamp Dimmable Table Lamp Reading Lamp with USB Charging Port, 5 Lighting Modes, Sensitive Control, 30/60 Minutes Timer (White, First-Generation)
…Aarav…
…Aarav…OP2d ago
Ok , I know that but it may misbehave
AnonEngineering
so if that is OK, next step is to make sure the ESP will trigger the relay
…Aarav…
…Aarav…OP2d ago
I can’t rn, I don’t wanna waste you time I can in an hour or so Thank you!🙏
AnonEngineering
np, i might be around, or maybe my wife has "honey-do" projects for me 🙂
…Aarav…
…Aarav…OP2d ago
Thus, I need to write an code that gives the S pin an signal? and, what pin is it? Is it the header pin on the botton that says S? Also, is the diode on the dev board a good enough fly back diode? (I don’t have time to code for an couple of hours)
…Aarav…
…Aarav…OP2d ago
No description
…Aarav…
…Aarav…OP2d ago
ACTUALLY the light does not turn on when plugged in, so I’ll find smth else, like an led light strip coz I wanna do this project

Did you find this page helpful?