COM means COMmon.
It is the connection that is connected to the moving part of the relay.
NO means Normally Open.
It is the connection with which the moving part is disconnected if the relay is not active.
It will be connected if the relay is active.
NC means Normally Closed.
It is the connection with which the moving part is connected if the relay is not active.
It will be disconnected if the relay is active.
You always need to use the COM terminal.
You decide if you want the NO or the NC, but most of the times the choice goes to NO.
Connect the negative wire of your part to ground. Connect COM of the relay to whatever power source you are using for the siren or light. Connect the positive wire of your part to the NO pin of the relay. Then, turning on the relay will turn on your light.
Thank you very much sir....now i understand the works of a relay...it's logic....the arduino sends the siglan to close circuit for the alarm...for that many seconds... nice job sir...u are a eye opener
You asked a follow up question via PM.
Don't do that, i will not reply to such questions.
I'm visiting the forums on a daily basis, so i can help you, others, and myself with any questions i can help with.
By doing so, i hope to help you, but also others who are interested in the same subject.
This is impossible if we all would communicate through PM.
So please ask your questions in the forum.
Perhaps someone will be faster in answering your question than i will be able to.
If you ask a question, make sure you provide all information.
You asked for polarity of some power connection.
The Arduino variant you are using, is supposed to be compatible with an Uno.
It has a cheaper main chip (smd 328 instead of a PDIP one), and cheaper USB/serial solution (CH340).
But the power connector is the same.
The outer ring is negative, the inner pin is the positive connection.
I don't know what battery you are planning to use, so i can't tell anything about that.
you are correct sir, and sorry to all people watching this forum, again thank you for responde, at the moment i will be using 8.4nimh airsoft battery, or 7.4v lipo airsoft battery or if i run out , 11.1v lipo battery.
Ok, i've done my project , i have the relay , and it's conected how u said it should be, when relay is activated : a red light comes on... but there is no green light ( i look at forums and stuff...and 2 lights should go on
i have the VCC cable to arduino... so it gives the order to activate... have the power pin to IN1 conected ... and Black ground to ground pin conected...
That picture doesn't tell all.
We'd need some more information on what module you've got exactly, and a picture of how it is connected.
If you tell exactly what module you have, perhaps a schematic could be found to see how it was built.
you can find the CODE and schematics, i followed step by step and it's working all fine, but only red light from relay goes on. the light near GND wire
i switched out the RED + wire that goes to IN1 and put it in VCC
i switched out the GREEN wire that goes to VCC and put it in IN1
Both leds are on now, but they stay on ( so that means that relay is always on ? ) ..
ok so i searched the code and the only thing i found about mosfet options is :
void activateMosfet(){
//lcd.print("Mosfet ON!");
digitalWrite(mosfet, HIGH); // turn the LED on (HIGH is the voltage level)
delay(MOSFET_TIME); // wait for 4 second //lcd.print("Mosfet OFF!");
digitalWrite(mosfet, LOW);
in 1 page of coding and also found this :
//mosfet
boolean mosfetEnable = false;
const int mosfet = 9;
//IS VERY IMPORTANT THAT YOU TEST THIS TIME. BY DEFAULT IS IN 1 SEC. THAT IS NOT TOO MUCH. SO TEST IT!
const int MOSFET_TIME = 5000;
on other page .... how i said ... if 5v wire goes to VCC , then controller goes to IN1 and GROUND to GND , the relay stays on both leds on, and click right when i conect battery to whole project... and never changes state.... and if 5V to IN1 , controller to VCC and GND to GND ... relay only activates , but does not click and nothing and only 1 led on .
If it does not, is the 328 chip hot to the touch? That would indicate most likely that an IO pin has been damaged, and its just a matter of time until the chip fails.
I got the 9 pin conected to VCC
i got 5v to In1
negative to GND wire as told by users
do u want me to make video with the relay func ?!
i will paste here code with mosfet output..i found it
for(int i = 200; i>0; i--)// this is the ultra hi definition explosion sound xD
{
tone(tonepin,i);
delay(20);
}
noTone(tonepin);
if(mosfetEnable){
activateMosfet();
}
delay(5000);
cls();
Post your whole code - I can't follow how tonepin, mosfet, REDLED and GREENLED are supposed to work together from the snippet you posted.
Also post the schematic of what you have connected currently.
i have VCC - on 9wire
i have IN1 - on 5v wire
GND - to GND wire
when the mosfet is turned on , only 1 led comes on, it's like half working ......i took out mosfet for debuging and if i put a 5v alarm with positive to VCC and negative to GND it works, so what is wrong with mosfet ( relay ) .
VCC is your supply.
Why did you connect it to an output ?
IN1 is supposed to be controlled by an (Arduino) output pin; don't you want to control that module ?
honest mistake. like all people. now, what's the problem with this ? ...do u have a helping word ? or u only come to ask question, that shows like i said i am new at this, only building from schematic.