Тёмный

Use Arduino to Switch Power On and Off! 

DIY Tryin
Подписаться 186 тыс.
Просмотров 921 тыс.
50% 1

Mike picked up a $10 SainSmart 8 Channel DC 5V Relay Module, hooked it up to an Arduino micro controller (a Raspberry Pi should work, too!) and the next thing you know he's remotely controlling 8 electrical devices... it's like building an 8 channel remote, each relay on the board can handle some serious juice, up to 10A 230V AC, 30V 10A DC. It's super easy to set up. Learn how in the video!
www.arduino.cc/
arduino-info.wikispaces.com/Ar...
www.ebay.com/sch/i.html?_trksi...
www.ebay.com/itm/8-Channel-5V-...
Subscribe! ru-vid.com?...
Have an idea for something we should build? E-mail us!
DIYTryin@revision3.com
*New Episodes Every Week*
Subscribe for free!
ru-vid.com?...
DIY Tryin on Revision3:
www.revision3.com/diytryin
Tekzilla on Twitter:
/ tekzilla
Patrick on Twitter:
/ patricknorton
Michael on Twitter:
/ palmdalian
DIY Tryin is a brand-new show about do-it-yourself solutions and maker culture from the Tekzilla team! Here on DIY Tryin, we live by the motto; "Why buy when you can make?"

Наука

Опубликовано:

 

20 апр 2014

Поделиться:

Ссылка:

Скачать:

Готовим ссылку...

Добавить в:

Мой плейлист
Посмотреть позже
Комментарии : 361   
@gmslayton
@gmslayton 10 лет назад
Cool episode. It would been cool to see how the lights and fan were hooked up and powered. Seeing that could give me more insight as to how the wires are.
@diytryin
@diytryin 10 лет назад
Think of the relay switch as interrupting one of the wires. When it's switched off, it's like you cut the wire. For the fan we literally cut one of the fan wires and put one half in the COM (common connection) and one in the NC (normally closed) slots. Take a look at this page for a better explanation: arduino-info.wikispaces.com/ArduinoPower
@Lyrabon
@Lyrabon 7 лет назад
DIY Tryin My L led is off and NO is dim what does that mean?
@neppy5
@neppy5 10 лет назад
cool demo and great to see Patrick after all these years, used to watch him on The Screen Savers lol
@Kattemageren
@Kattemageren 9 лет назад
I really like the atmosphere of this video, very smooth and friendly. Very unlike some of the akward episodes I've seen on e.g. Tested
@stampgermany
@stampgermany 8 лет назад
You've been so helpful! Thanks! I really like your videos and their quality!
@prajasena1
@prajasena1 7 лет назад
thanks for the useful practical demo
@gmctech
@gmctech 6 лет назад
Endless options here! I just ordered a DTMF decoder, arduino and relay bank... I'm going to use my two way radios to operate my garage door using dial tones.
@toycarfoushboy
@toycarfoushboy 6 лет назад
I subbed up guys! Really like learning this kinda of stuff and seems like y'all are gonna teach me some.
@benlambert8481
@benlambert8481 Год назад
LOVE the channel name...
@SeeJaysPlace
@SeeJaysPlace 9 лет назад
Patrick Norton, I'm not sure if I'm old school or not but, I miss watching Screen Savers
@anthonyvolkman2338
@anthonyvolkman2338 9 лет назад
I like to use solid state relays because they act as a transistor, whatever frequency you give it, it can turn on and off at that frequency, a mechanical relations can only oscillate so much
@pingu99991
@pingu99991 10 лет назад
I like the apple logo conspicuously hiding behind the tape haha
@spokosjr
@spokosjr 10 лет назад
you covered the apple logon on the macbook but you forgot down on the right the apple box
@JustinOnScreen
@JustinOnScreen 7 лет назад
Very neat. Thanks for the tutorial.
@nogster
@nogster 10 лет назад
Seeing Patrick here really makes me miss the days of TechTV. I actually was able to attend a taping while in San Fran back in the day.
@vaper1986
@vaper1986 10 лет назад
Will play around with this, thanks for sharing.
@diytryin
@diytryin 10 лет назад
Let us know if there's any other cool projects or ideas you'd like to see in the future!
@paziipa
@paziipa 8 лет назад
Subbed just for that ending dance
@DaveHurka
@DaveHurka 9 лет назад
gee, I wonder what kind of laptop he is using...
@Wisdomofautumn
@Wisdomofautumn 6 лет назад
I’m a beginner Arduino experimenter and found this video very useful, interesting, and entertaining! I am wanting my first project to be a small weather station looking at temperatures and humidity...any pointers?
@Beall619
@Beall619 9 лет назад
you have earned a subscriber
@MainlandRC
@MainlandRC 10 лет назад
basic coding etiquette: if someone posts their code online to share it is perfectly acceptable to use some, or all of their code in your own code; however, if you share any code that has other people's work in it you should credit them just like any other work.
@DarkStar851
@DarkStar851 9 лет назад
Just thought I'd toss this in for anyone interested in toggling a mechanical style relay with any sort of frequency like Michael did with the 40ms delay -- you're going to burn the thing out fairly quickly if you're doing something like that all day long. You should consider a solid state relay (more expensive than these old mechanical ones) for that application. Or a high-power MOSFET (which effectively is all a solid state relay is, just without the heatsink and terminal block attached)
@RealDealHolyfield2099
@RealDealHolyfield2099 10 лет назад
Music with the relays is a great idea! This other channel on RU-vid, MrSolidSnake745, plays midi music with stepper motors from old floppy disk drives. I'm pretty sure he uses Arduinos too. Really cool and really fun stuff!
@tuckervaldeze7179
@tuckervaldeze7179 10 лет назад
I know this video is 2 months old but I purchased a Sainsmart 8 channel relay board for my arduino and i was wanting to know if the relay is Active LOW or Active HIGH, and what you used as a power supply to isolate the arduino and relay board, I can't seem to find a straight answer anywhere, and I watched your video and thought I might get a straight answer here.
@l.b.4817
@l.b.4817 10 лет назад
Deserve aThumbs up and subscription from Brazil ;)
@Reaptechsolutions
@Reaptechsolutions 8 лет назад
Hi guys, great channel!!! liking the relay idea, please post the arduino codes up that you used to drive the 8ch board, thanks
@Arabic_
@Arabic_ 2 года назад
guys you are awsome, may god bless you
@suelinerr
@suelinerr 9 лет назад
Thanks for sharing.
@Sorcli
@Sorcli 7 лет назад
Great info. Could this also be used as a 12v fuses box, so if one was running 12v devises it would protect them?
@ixamBee
@ixamBee 6 лет назад
Hey, I want to use an arduino to make a circuit which when I turn on switches off within 1 second Anyone has an idea how to do that
@MrChezco1995
@MrChezco1995 8 лет назад
This is nice if you want to do something like a Home Automation setup :D
@lennova5846
@lennova5846 5 лет назад
Great video! Just what I was looking for. The link for the code is down any chance of getting the info? also any help on how to do the serial control would be appreciated. Thanks!
@Aterrebgnuoy
@Aterrebgnuoy 8 лет назад
Did anyone else feel bad for those relays when he set the delay to 40ms?
@attackandsnack
@attackandsnack 8 лет назад
soooo many tabs!!! lol :) thanks for the video
@nitishroat
@nitishroat 5 лет назад
Would the laptop be on the whole day ?? to ON and OFF the relay??
@meemvids738
@meemvids738 9 лет назад
Thanks guys, very useful. Although it's fun to watch you dance about while switching on lights. I would like to know HOW you switched those colours. lol Do you have a particular video on the serial port? I'm total noob.
@mdafroz4190
@mdafroz4190 8 лет назад
this is a nice and awesome video and i have a request for you can you make this relay control by smart phone via bt hc 05 please
@EEEnthusiast
@EEEnthusiast 9 лет назад
Using relays to drive LED strips... Interesting...
@lolz2018
@lolz2018 9 лет назад
Sarcasm? :p i would think mosfets are way better?
@shyamharidas1828
@shyamharidas1828 9 лет назад
EEEnthusiast they were probably just trying to inrodyce us to the idea. We can even apply this to AC appliances
@michaelsills8038
@michaelsills8038 7 лет назад
@diederik you are correct that mosfets would be much better for these types of applications. Either works tho.
@raidzor5452
@raidzor5452 7 лет назад
Yeah... But there is no real difference... Relays are just easier to connect...
@MrFixBroken
@MrFixBroken 5 лет назад
They literally applied it to an AC appliance in the video (the fan)
@andrewk8636
@andrewk8636 8 лет назад
thats right cover that apple logo, hiding the shame lol
@rabbitdrink
@rabbitdrink 8 лет назад
Hehe
@peachpark7568
@peachpark7568 8 лет назад
i dont understand, wheres the shame in using apple?
@rabbitdrink
@rabbitdrink 8 лет назад
It means "i am an idiot because I spent all my money on a computer from the 90s"
@peachpark7568
@peachpark7568 8 лет назад
lololololololololololololol thanks
@zm7160
@zm7160 8 лет назад
Apple will fuck you on the price of their hardware, and the hardware is always last generation. That said, OSX is a very decent OS; If your into hacking / software dev, having a *NIX based OS that works is GREAT. For productive use, it really can be good for some people.
@danrtavares
@danrtavares 9 лет назад
wow you are a genius ! you pick a pre build relay shield and put in a newbie programmable system named Arduino and make it work ! sincerely you deserve a nobel prize.
@smstiao-tecnologia
@smstiao-tecnologia 10 лет назад
Hi boys, very very nice your projects with arduino.
@akilhamilton665
@akilhamilton665 7 лет назад
hey great episode! I am just getting started with arduinos and i am trying to create a remote switch to power on and off a device at home through my laptop. Would this work?
@UmairHussaini
@UmairHussaini 9 лет назад
I may be wrong here, but I think that the Arduino is not a microcontroller. It is a development board with a microcontroller (Eg Atmel AtMega328) at its core and peripherals on board that allow for easy project making.
@tugraunsalan5523
@tugraunsalan5523 9 лет назад
thank you man...
@dalivrubot5909
@dalivrubot5909 10 лет назад
Mike, how did you manage to wire up the external power supply to the relay in order to save the Arduino MC from having to power it? What power supply did you use, just one that was lying around?
@ExStaticBass
@ExStaticBass 7 лет назад
One of the things I've been trying to figure out is how to increase and decrease the duty cycle on the PWM pins of my Uno board. The goal is to make some DIY signage that changes brightness with an LDR so that it's as visible in bright light as it is in dimly lit situations whereas it can also save power. I've figured out how code for the sine change from let's say "open" to "closed" using some transistors and a diode AND gate network. The brightness thing with the LDR though is a little harder to wrap my head around. Little help?
@mikesimmonds1916
@mikesimmonds1916 7 лет назад
If you wanted to set a pair of Christmas lights flashing for 10 minutes then swap to another pair for 10 minutes, how would this work with this relay? Mike
@lorenzo3
@lorenzo3 7 лет назад
I can control 12v load with this relay 5v arduino?
@rageshadey
@rageshadey 6 лет назад
*cough circuit board with a micro controller cough* Love your videos. I really needed this to help me learn techniques to use on my arduino. Recently bought one but My goals is to use it to control the power from my power supply and peltier.
@fernandovera7363
@fernandovera7363 6 лет назад
What power supply did you use?, Do you use a power regulator? How did you make they conections?
@user-wn3nh4ec2g
@user-wn3nh4ec2g 5 лет назад
Long time seen big man
@bartbonnyns
@bartbonnyns 4 года назад
Hello guys, Thnx a lot for your great RU-vid, It means a lot if you char what you’re good in, so we can learn from each other. I hope you have time for a small simple question. Is there power on your relay coil when the NO contact is closed (when you’re hooked up appliance is on) like a standard relay or does it gets a pulse each time you switch on and off you’re appliance? Greats Bart
@alexrodgers8367
@alexrodgers8367 9 лет назад
Can you please share the code you used with serial communications to control the relays with everyone?
@rohanbharadwaj3470
@rohanbharadwaj3470 9 лет назад
How would you go about plugging a fan into the relay?
@adryx_92
@adryx_92 9 лет назад
Hi, I have a question: the "external power supply", as you call it in the video, is simply a 5v bridge?
@FathinLuqmanTantowi
@FathinLuqmanTantowi 9 лет назад
6-12V, since 5V usually comes with less than the label, which is bad. it works but won't give you proper 5V output from arduino
@nautitard
@nautitard 7 лет назад
I love the tape over the logo. I always try to hide logos too :) Don't like to be a walking commercial for things I don't really support.
@TheMrFrontera
@TheMrFrontera 7 лет назад
it does jack shit. obviously it's a macbook. Makes no sense to me, except maybe they can't get sued now. But in terms of support, means nothing
@nautitard
@nautitard 7 лет назад
If you're looking it does. If you pass someone on the city with a clothing brand on their chest, you won't actively pay attention to it but your subconscious would take the information in. Obviously advertisement works, so I try not to encourage people to consume unneccesary things x)
@ipconfigearth102
@ipconfigearth102 6 лет назад
Please make a short and simple video on remote turn on of pc... No wake on lan option in mobo.
@vishaldaga3009
@vishaldaga3009 5 лет назад
super thanks... subscribed, liked thanks :)
@alfidapvl9994
@alfidapvl9994 6 лет назад
Can you guys put a video how to control electric appplainces using headcount
@thinkvantage1684
@thinkvantage1684 6 лет назад
hey guys thanks for the video. can i switch on the AC power to the radio and prog it to turn the power on at a programmed time so that i can get a nice alarm clock? thanks.
@sommawolf4273
@sommawolf4273 8 лет назад
which code did you used to control relays with serial port
@sth6027
@sth6027 7 лет назад
Yes it is legal to use codes from arduino that other ppl put online, because it's Open Source which means anybody can work on it to improve it.
@PontusWelin
@PontusWelin 10 лет назад
hmmmm. Maybe I should get my hands on one of those. Could be fun to write some code for. Not sure what I would use it for right now though =)
@joeyserrano4693
@joeyserrano4693 9 лет назад
May i ask what is the specific Arduino board part no.you used as well as the software and source code.
@abjurian
@abjurian 8 лет назад
Do you have a link to the code you used to turn the relay's on and off with the serial monitor?
@beadgcf1754
@beadgcf1754 10 лет назад
i think this was the first episode i saw braces on patrick.. >.>
@JordanMiller1117
@JordanMiller1117 6 лет назад
The "external power supply", what exactly is it? What is with the screen on it?
@JustifyJustin
@JustifyJustin 9 лет назад
A show with a lot of potential - just a pity you guys never showed how to do the actual wiring. Hope nobody electrocutes themselves trying to emulate this ;)
@deucedeuce1572
@deucedeuce1572 Год назад
Does the 5v need to be on constantly for the relay to stay open (on)?
@azimalif266
@azimalif266 6 лет назад
Is it possible to split a large load among multiple relays? so that an arduino can control a large load.
@jeremyhenderson163
@jeremyhenderson163 5 лет назад
:) Thank you for your videos, great stuff. What would be a good basic automatic relay circuit to make load A2 turn on when load A1 shuts off?
@jeremyhenderson163
@jeremyhenderson163 5 лет назад
I recently bought a 30A power supply (P-360-12) to control the sprinkler system and heating in my greenhouse during the winter. The stat sheet ( www.wlgled.com/estaticos/media/producto-pdf/8PS120360DCU.pdf ) said "2) Do not overload, also avoid free of load while a power supply is powered on, keep proper loading" so now I'm concerned about damaging the power supply in the time that both the automatic heating (12v-16ish A) and watering (12v-2A) circuits disconnect. So I was thinking of adding another load (12v-15A) that would only turn on when the heating circuit disconnects (As it will be the most used load, as well as the biggest.). I'd prefer to lean away from Arduino as I am currently a novice and haven't yet ventured into it, any suggestions?
@SirArghPirate
@SirArghPirate 8 лет назад
So the text on the relays states that they are rated for 10A @ 250V, but is it generally safe to use them with this voltage? I want to use one of these to control a 165W fan running on 230V.
@supermanpussy
@supermanpussy 6 лет назад
It will be nice if you show how you connect them.
@FOATE
@FOATE 5 лет назад
I'm still a bit confused, I have this relay shield that has 4x 250 v 10 A AC relays, so you'd think it could switch 2500 watts but the data sheet says its switching power is only 70 watts? Can I still safely power a heater thats a kilowatt on this relay or should I be careful not to exceed 70 watts?
@shubhamkumar-oq8qr
@shubhamkumar-oq8qr 7 лет назад
relay circuit response on 3 v too from arduino or it takes only 5v
@vistanationrockafellaz
@vistanationrockafellaz 4 года назад
Patrick you old tech guys buddies is Rosevelt right
@dice2333
@dice2333 10 лет назад
can u post the last code plz "switching on and off using 1 and 0"
@GurpreetSingh-mz8tz
@GurpreetSingh-mz8tz 8 лет назад
how the relay is connected to the arduino plz explain it with a circuit diagram
@gjalvarez
@gjalvarez 7 лет назад
can you help me to configure the modem so I can access the web control page from internet? without being on the local network
@billyrowe0064
@billyrowe0064 9 лет назад
Now some of your relays have been switched to normally closed and normally opened. That is a lot of switching for those relays. :)
@tomlaight
@tomlaight 9 лет назад
can you implement a PID with arduinos? I really have never had anything to do with them
@rabbitdrink
@rabbitdrink 8 лет назад
It would be nice if you could teach me how to wire this up.
@melannieworld
@melannieworld 2 года назад
Love the energy... I've been looking around for some advice. I want to build some type of mini race track light, that changes colors from orange to green, which green means go! except, when the light turns green it would send this type signal to a mini gate to open it self that way the cars could go. Any idea?>
@PhattyMo
@PhattyMo 10 лет назад
Stick an ethernet shield on there,and WE can control your fan!
@DarrenLandrum
@DarrenLandrum 10 лет назад
So do you guys have to come up with primary and secondary ideas for each episode? Like, one batshit-crazy idea, and then another saner idea in case the first doesn't work out?
@diytryin
@diytryin 10 лет назад
You've always got to have a Plan B (and C, and D, and E, and sometimes F)
@DarrenLandrum
@DarrenLandrum 10 лет назад
Well, here's to more Plan A's working out. :)
@alcool1729
@alcool1729 8 лет назад
Try this ==> facebook.com/1517160868604660/photos/a.1517166945270719.1073741828.1517160868604660/1519730448347702/?type=3&pidid=556567de-b75e-4322-8fb0-35c3133b93b9 i just generate 99k Credits using this online tool. Works on all devices. 100% working Use Arduino to Switch Power On and Off!
@rabbitdrink
@rabbitdrink 8 лет назад
+Al cool there's no such thing as arduino credits idiot
@maynardbicos9293
@maynardbicos9293 8 лет назад
4:09 +DIY Tryin did the electric fan plug in to the outlet?
@dansnow7
@dansnow7 10 лет назад
How about adding bluetooth and an app for mobile devices?
@johnpleskina9268
@johnpleskina9268 9 лет назад
How can I power the relay externally? It appears my relay module is not properly interupting 120VAC
@tomhetto9397
@tomhetto9397 8 лет назад
Hey , you say its not possible to power the relays wi the arduino if you want to switch them all at the same time. Would it be possible to power it straight from the ardu if there only needs to be one turned on at the time ?
@DaiShuryoTechnus
@DaiShuryoTechnus 8 лет назад
Where would the ground wires go for the 120 V devices??
@johnross3752
@johnross3752 6 лет назад
can you use this as a brake out bord for stepper drivers like gecko
@Jazzcasanova
@Jazzcasanova 9 лет назад
Will you plz share that RelayControllerNoDelay sketch??
@FreeParkingSearch
@FreeParkingSearch 9 лет назад
I have the fan hooked up to the relay. The relay is switching on and off and directed in the code, but the fan does not turn on. When I fan wires directly into a house outlet it powers up. What am I doing incorrectly?
@btn135
@btn135 9 лет назад
The external power source connected to the relay wasn't explained very well. Would anyone be able to tell me what exact board was used as an external power supply? A link to the product would be much appreciated.
@Zack-dk3pt
@Zack-dk3pt 9 лет назад
i used bluetooth to control the arduino wirelessly from my phone with an app to turn relays on and off only problem is i havent figured out how to get the arduino to stay in whatever state it is when i exit the app as soon as it losed blutooth connection power to the relays returns to default
@elricho72
@elricho72 8 лет назад
Please could you post a image of wiren diagram for the rele and the power extra suply, because i see on the video you put the GND to arduino too ? and i suppose you put the 5V and gnd to the extra power suply
@vdic7
@vdic7 9 лет назад
How do you make the control with the computer, it would be nice if u put the last code :)
@AnxBeta
@AnxBeta 5 лет назад
I'm trying to have a RF remote turn on and off power to a Nano with a relay, can this be done?
@_dipoots
@_dipoots 6 лет назад
please teach me how to connect my relay to an external power supply
@franciscosanchez9406
@franciscosanchez9406 8 лет назад
does the relay vcc and ground need to be connected to the arduino or can you just use the other power supply?
@jeffreyho6625
@jeffreyho6625 6 лет назад
So i just have to put digitalWrite as output to control switching on and off of relay is it? I mean using digital signal is good enough to switch it on and off?
Далее
DIY Smart Switch - Part 1 how to use a relay
8:02
Просмотров 638 тыс.
Whose action is better?🥹 #filaretiki #shorts
01:00
Рыбачка
00:14
Просмотров 15 тыс.
치토스로 체감되는 요즘 물가
00:16
Просмотров 4,5 млн
How To Wire It! Buttons & Switches
9:52
Просмотров 130 тыс.
What's the difference? Arduino vs Raspberry Pi
6:21
Просмотров 1,8 млн
How many relays can I connect to one Arduino?
9:38
Просмотров 49 тыс.
Connecting a Relay Module to a Microcontroller
11:41
Просмотров 217 тыс.
#123 Arduino Auto Shutdown (and switch off)
34:47
Просмотров 28 тыс.
Магниты и S Pen 🖊️
0:37
Просмотров 61 тыс.