Rotate Two Motion Activated Servo Motors In Opposite Directions - A Beginner Arduino Project
HTML-код
- Опубликовано: 22 июл 2024
- See how to rotate two motion activated servo motors in opposite directions. This is a beginner Arduino project with an example of how to create opening and closing double doors.
🔔🔔 SUBSCRIBE 🔔🔔 don't forget to subscribe and click the bell!
/ @bmonsterlaboratory
Facebook: / bmonster-laboratory-10...
Twitter: / b_monsterlab
get code for the project on our Facebook page. search #ServoUnio on Facebook
check out our Arduino play list!
• Easy Arduino projects ...
Chapters:
0:00 intro
0:32 component list
1:24 wiring diagram
2:39 servos and PIR sensor in action
3:13 the code
4:53 example for use of this project
---------------------------------------------------------------------------------------------------------------------------------------------------------
I used 2 different servos in this video, the micro servo with plastic gears and a MG995 metal gear servo. The MG995 servo was used in the cardboard box with door demo. They both rotate at 180 degrees and operate well at 5V power. The MG995 has about 4-5 times the torque of the micro servo when the max voltage (7.2v) is applied. They can bother operate off the same code, which is what I did here. In the interest of making this a short video I cut that out....probably shouldn't have :)
Here are the amazon links to those servers below.
MG995 servo:
www.amazon.com/Control-Angle1...
SG90 micro servo:
www.amazon.com/Micro-Helicopt...
------------------------------------------------------------------------------------------------------------------------------------------------------
If you were looking for a way to make servo motors spin in opposite directions or just looking for projects with motion senor functionality, I hope this video was helpful. This motion activated servo motor project is perfect for a beginner Arduino project. If you have any Arduino project ideas, be sure to mention them in the comments below! If you're looking for the programming code for Arduino IDE, check our Facebook page. It will not fit in the comment section below. Thanks for watching~
TNX..dear sir...sir make vedio on same two servo opposite movement but using IR sensor and megnetic hall sensor...pls
sure. opposite rotation and instead of motion activation, use ir sensor or hall sensor activation?
does the code also work for raspberry pi?
Hey there! Arduino uses C/C++ language. Most of the time you will see Python used with Raspberry Pi but there is a way to use C++ on a pi. I have never done it that way but it is possible.
I'm about to do this with the servos pulling 2 part poppers.
We have raccoons that won't go away.
Hiya, Dood! Raccoons are no fun at all. I hope it works out for you. 👍
Would this work with a Chinese Nano?
@@HappyHermitt hey there! Sure it would. Elegoo, Sunfounder, or any other Chinese brand would be fine. Make sure you have an external power source for the motors, though! 👍
Hello I have an issue with my servo and sensor. In TINKERCAD its working perfectly fine but irl the motors seem to be opening and closing even when theres nothing going through the sensor further more even without the sensor the motors kept opening and closing pls help. Im so confused and tried everything to fix it.
hi there! are the motors getting the right about of current? maybe you could add a pull-down resistor to stabilize the input signal to the sensor. A pull-down resistor is typically used to ensure that a pin or input has a defined low state when no signal is present, which can help prevent false signals or erratic behavior.
@@BMonsterLaboratory I connected my motor in the bread board and that bread board os connected to the arduino 5v and no i dont have any pull down resistor. Im using SG92R motors.
@@BMonsterLaboratory I used your door project as a curtain project of mine since the function og thr doors can be turned into curtain puller. It's for a school project
@@BMonsterLaboratory even the light bulb keeps turning on and off, whenever it's on the motors stop moving and when it's off it moves.
Can you send a diagram to me on face book?
Delaynya kalo di rubah agak pelan caranya gimana?
ubah angka di () untuk mengubah penundaan. penundaan (milidetik) - penundaan (1000).
Anda dapat menggunakan milis () sebagai gantinya. Dengan cara ini, Anda dapat menangani tugas-tugas lain dalam fungsi loop() tanpa diblokir oleh penundaan().
@@BMonsterLaboratory saya coba aku rubah malah jedanya gerak eg mas yang agak lama...tapi kalo di bikin agak smoth geraknya gimana ya?
@@BMonsterLaboratory biar agak kalem geraknya...
@@ahmadwahyusyaffudin1776 Try increasing current. Try an external power supply that can provide 4-5amps if you're using 2 servos. If that doesn't work, post your code and lets take a look 👍
@@BMonsterLaboratory kalo program pake push botten gimana pak?
@BMoster Laboratory--- hello I would like to contact you in gmail for a project I might know what your email is🙃
Sure. email is bmonsterlab@yahoo.com. Happy to help however I can.