I've only done basic things with my arduino so i can say im a complete noob to it, blink worked, some more simple test circuits. I cant really follow along with circuit diagrams because i dont know all the symbols yet. So what im trying to do is automate my garden, really simple though, i want to have the arduino turn the pump on for 5 minutes every day. So basically, turn on pump for 5 minutes, then sleep 24 hours, do it again.
I have an GS-SH205T relay that says DC5V, my pump is an [ecoplus 185 3V pump[/url]. Im assuming that since the relay says 5V it should be able to power this pump no problem. So i have all the parts, the problem now is i dont know how to set up the relay. Heres a picture of my circuit.
I read the box wrong, its 120V, my relay wont work at all. Either way, how do i set up a relay?
one on the left goes to digital output, and the other go ground(obviously)
The transistor(?) im using is an LM7812
Since transistors(?) have different pin layouts i had to figure it out, this one goes
| | |
IN GND OUT
This circuit was a simple test to see if i could even control the relay at all, i dont know how to wire it. The tutorials on youtube were only slightly helpful, i probably watched about 5 of them. This circuit was just a simple test for me to see how relays work.
I know theres the garduino tutorial, and once i figure out how the relay works im going to probably be following this
I tried putting an LED near on the end of the relay and that didnt work either. So i cannot figure it out. Does anyone know what im (clearly) doing wrong?[/s]
](http://www.amazon.com/EcoPlus-185-Submersible-Pump-GPH/dp/B0018WVNXC)
0xicl33n:
The transistor(?) im using is an LM7812Since transistors(?) have different pin layouts i had to figure it out, this one goes
| | |
IN GND OUT
That's no transistor, it's a 12V voltage regulator. So, put that to one side.
You want an N-channel MOSFET transistor, wired something like this:
Where I have "electric strike" put your relay coil. You could use 5V instead of 12V at the top of the circuit. The diode handles coil "kick back" when it opens.
I noticed that you seem to have your components sideways in the breadboard.
Please read the documentation.
Good point. That won't help.
Everything in the vertical columns are joined together (except at the bottom where you run an unnecessary wire).
Thanks for that, i didnt really know, sure looked like one
MaJiG:
I noticed that you seem to have your components sideways in the breadboard.
And i thought it didnt matter what way you connect components to a breadboard..hence it being a breadboard(but what do i know)
Anyway thanks guys, gonna try rewiring it today
Warning
It looks from your first post that you are not very experienced with electronics.
Tackling mains wiring in one of your first projects could prove fatal. Especially plugged into a breadboard like that. A simple mis-connection could make the Arduino, your computer (or that transistor) "live" and may kill you, your friends or your family.
Alternatively, you might start a fire. I would definitely hold off actually plugging in high voltages until you are certain it works (eg. test with a light and a battery). Also make sure that nothing can move, and insulate the mains side of things. High voltages are not a game.
0xicl33n:
And i thought it didnt matter what way you connect components to a breadboard..hence it being a breadboard(but what do i know)
You need to know which pins of you breadboard are connected together internally, and then plug your components and link wires in making use of those internal connections to make a circuit. And I'm sure you've understood how breadboards work that far. But the connections you've made don't look right and suggest that you may have the wrong idea of what the internal connections of the breadboard are.
Alternatively, you could just buy one of these:
It isn't particularly cheap, but its ready to go.
--- bill
WELL i figured out my problem, the pins on my arduino are not working anymore, i can upload sketches and blink the led 13 on the board, but any wires in the pins do not work. I must have done something wrong, and im not very experienced, but at least a few weeks ago i was able to make circuits without breaking the arduino, i cant see how i shorted the pins though, i had a voltage regulator or resistor between the arduino and the chips whenever i was playing with circuits, i guess its my own fault.
I went on vacation for a week, came back and immediately started playing with it(crappy excuse, but the truth), since im already new to circuits, i kinda had to take some time to remember everything. Now that ive done a lot of research its all starting to make more sense, but now i cant do anything because the arduino does not work.
Ive decided to abandon my automated garden, because the pump i have is so strong i only really need to run it for 2 minutes, and thats a huge waste of the microcontroller which i can use to experiment more. Now i just want my arduino working
Ive also decided..if i stop working with it for awhile, the first thing i will have to do, is the blink circuit when i come back to it, just to make sure i remember everything.
And since i have no ardruino, ive been playing with circuits on EveryCiruit, and all those have worked (with the symbols i remember of course)
How can i fix my pins? I saw something about Mprog and reflashing the FTDI? Would i do that?
0xicl33n:
i cant see how i shorted the pins though
Given those pictures of the breadboard wiring, I think that damage was almost inevitable. I'm not sure whether you understand electronics well enough to know how to design a circuit, but that needs to come first. Then you need to understand how to use a solderless breadboard to build a circuit. The pictures make me think you don't understand that yet.
Have you tested all the pins? I would expect the damage to be limited to individual pins that have been burned out.
Which Arduino do you have? If you have an Arduino with a socketed chip, you can replace it fairly cheaply and easily. Unfortunately if you have an Arduino with a surface mounted chip then repairs get much harder and are probably not feasible for you.
i tried pins 0, 1, 2, most of the other digital. i tried to plug the led to 5v (with a resistor) and ground and that didnt work either(on the analog side).
The other reason i wired weird is i dont like how negative is on the left side of my breadboard and positive is on the other side, i didnt know it mattered which way breadboards are used, thats why i did it whichever. The comments pertaining to the "you dont know enough to be working with this" are very discouraging, i am in love with this little board, i get to learn how circuits and how C works. What could be better? I realize i probably screwed up, now i need more research. Could you just tell me how to fix it ?
i have an arduino uno..
0xicl33n:
i tried to plug the led to 5v (with a resistor) and ground and that didnt work either(on the analog side).
That's curious. Are you sure you aren't testing it with a blown LED? What resistor value are you using?
0xicl33n:
The other reason i wired weird is i dont like how negative is on the left side of my breadboard and positive is on the other side, i didnt know it mattered which way breadboards are used, thats why i did it whichever.
There should be two rails on each side of the board, conventionally used for power and ground. Some solderless breadboards boards are printed to make it clear which pins are connected internally, but yours doesn't seem to be. You need to be clear how they're connected internally, and at the moment you aren't, judging by the way you connected the circuit in that picture. This wikipedia article about breadboards describes it and has pictures of the connections which should make things much clearer for you.
0xicl33n:
i have an arduino uno..
If it's a recent UNO then the microcontroller is a chip mounted in a socket and can be replaced for a fraction of the cost of the whole board, if worst comes to worst and it has been ruined. Your comment that the onboard LED works gives me hope that the damage may not be as bad as it seems, though.
PeterH:
i tried to plug the led to 5v (with a resistor) and ground and that didnt work either(on the analog side).That's curious. Are you sure you aren't testing it with a blown LED? What resistor value are you using?
i was using a yellow, purple, orange, gold (470K ohm) resistor, what i just tried to do now was twist the resistor around a couple LED's and try and fire them up with a battery and some aligator clips, none seemed to work, very strange, maybe ill try a different reistor?
PeterH:
If it's a recent UNO then the microcontroller is a chip mounted in a socket and can be replaced for a fraction of the cost of the whole board, if worst comes to worst and it has been ruined. Your comment that the onboard LED works gives me hope that the damage may not be as bad as it seems, though.
and thats good to hear
but for now im stuck still, when i noticed nothing was working i tried to follow the steps in this tutorial (which i was doing while it was working, and there was no problem) with no success
0xicl33n:
i was using a yellow, purple, orange, gold (470K ohm) resistor, what i just tried to do now was twist the resistor around a couple LED's and try and fire them up with a battery and some aligator clips, none seemed to work, very strange, maybe ill try a different reistor?
I don't mean to be unkind, but if you are just going to connect stuff together at random like this then you might as well chuck your hardware in the bin for all the good it's going to do you.
Do you understand that the resistance value matters - it has to be correct? Have you made any attempt to find out what value is required in this case, or to find out how to work out what value is required? All the information is readily available on the internet, you just have to look for it.
I have Recommendations For You - DealeXtreme module but i can't put ON the relay. I put an external supply of 12V in the Vcc pin of the module and connect the GND of arduino and the GND cable of the power supply in a protoboard. Then i connect the signal pin of arduino in the Signal pin of the relay module. I see that the led is always ON and the current flows although I charge the blink example...
Can anyone help me please??
Thanks!
man3l3t, you'll have to make a new thread to get new questions answered.