Arduino Obstacle Avoiding Robot

Поделиться
HTML-код
  • Опубликовано: 5 авг 2016
  • In this Arduino project video, we are going to build an Arduino Robot that can avoid obstacles. It is a fun project and a great learning experience, so without any further delay, let's get started!
    Required Hardware:
    1x Arduino UNO R3:
    bit.ly/2xt9MVk (Banggood)
    amzn.to/2LZr6t4 (Amazon)
    1x L293D Motor Drive Shield:
    bit.ly/2H7vmy9 (Banggood)
    amzn.to/3qADuic (Amazon)
    1x HC-SR04 Ultrasonic Distance Module:
    bit.ly/2kJXZsN (Banggood)
    amzn.to/3s4SbdT (Amazon)
    1x SG90 9g Mini Servo:
    bit.ly/2JoUQMY (Banggood)
    amzn.to/3avwe1N (Amazon)
    1x Bracket for HC-SR04:
    bit.ly/3bvvF68 (Banggood)
    amzn.to/2Nxcsd3 (Amazon)
    1x Wheel and Gear Motor:
    bit.ly/2RXAWLS (Bangood)
    amzn.to/2M2pChV (Amazon)
    1x Front Wheel:
    bit.ly/2Kuhbr6 (Banggood)
    amzn.to/2M0KkP4 (Amazon)
    Robot Car Chassis Kit:
    bit.ly/2sqIHgy (Banggood)
    amzn.to/2M2rirJ (Amazon)
    3 in 1 Jumper Wire:
    bit.ly/2J6de9E (Banggood)
    amzn.to/3doetmT (Amazon)
    Arduino Compatible SCM & DIY Kits:
    bit.ly/2J2AFF7
    Recommended Items:
    Use Your Muscles in Project - amzn.to/3wdL45C
    37 Sensor & Module Packages - amzn.to/3m66WeQ
    Try this Robot Arm - amzn.to/3fq8DCl
    Best Resin 3D Printer - amzn.to/39tY8KB
    Arduino Compatible Kits - bit.ly/2J2AFF7
    Banggood Spring Sale - bit.ly/3slMbOn
    Install AFMotor.h library: learn.adafruit.com/adafruit-m...
    Install NewPing.h library: bitbucket.org/teckel12/arduin...
    Source Code: github.com/MertArduino/Arduin...
  • НаукаНаука

Комментарии • 606

  • @maker101io
    @maker101io  3 года назад +1

    Source Code: github.com/MertArduino/Arduino-Obstacle-Avoiding-Robot
    Recommended Items:
    Use Your Muscles in Project - amzn.to/3wdL45C​
    37 Sensor & Module Packages - amzn.to/3m66WeQ​
    Try this Robot Arm - amzn.to/3fq8DCl​
    Best Resin 3D Printer - amzn.to/39tY8KB​
    Arduino Compatible Kits - bit.ly/2J2AFF7​
    Banggood Spring Sale - bit.ly/3slMbOn

  • @robertocameto487
    @robertocameto487 7 лет назад

    THANKS ......THANKS FOR YOUR HARD WORK AND SUPPORT. TODAY A FINALLY FINISHES
    AND TESTED MY PROYECT FOLLOWING YOUR INSTRUCTIONS AND WORKED FINE.
    EXCEPT THE CHASSIS (IT WAS MADE BY SELF), I GOT EVERY THING REQUIRED FOR THE PROJECT IN HONG KONG.
    THANKS AGAIN FOR ALL.
    BEST REGARDS.
    ROBERTO.
    MONTEVIDEO-URUGUAY

  • @MrHristoB
    @MrHristoB 5 лет назад +3

    Great beginners project, just for me. Code works fine. I did slight modification and used metal geared motors and powered the kit from the motor shield power IN with the jumper on as I'm using a standard servo, not micro servo. works great

    • @SoumenMishraKansbahal
      @SoumenMishraKansbahal 3 года назад

      Can you pls help me out, my obstacle robot motor moving forward and backward only again and again, pls help

  • @fabienc6287
    @fabienc6287 7 лет назад

    You explained a lot without saying a word. Congratulations and thanks ;)

  • @josemariaximenessantos5709
    @josemariaximenessantos5709 7 лет назад

    O que eu procurava a muito tempo, achei aqui, muito bem detalhado. Muito obrigado .

  • @aditisharma3724
    @aditisharma3724 5 лет назад

    Works just perfectly! Thank you so much! Just make sure you use a good quality battery with a high voltage.

  • @jhonsedwick5301
    @jhonsedwick5301 7 лет назад

    You have made a great project. Keep making good projects bro because 1 day you are gonna be awesome.

  • @theguidedone9734
    @theguidedone9734 6 лет назад +3

    It's Really Insane!Explanation of connections are the best.Keep it up for next videos!!😁

  • @spychou9745
    @spychou9745 6 лет назад

    Çok sağolun çok faydalı.Başta hiç sesli anlatım olmayışını yadırgamıştım.Ama şimdi kullandığınız yolun daha etkili olduğunu düşünüyorum ☺

  • @yukselbey913
    @yukselbey913 6 лет назад

    Çok teşekkürler. Programda code ile birlikte açıklamalar çok yardımcı oluyor.

  • @markliles4113
    @markliles4113 7 лет назад +2

    GREAT RoBot!!

  • @kirankamath5891
    @kirankamath5891 7 лет назад

    Bro your project is awesome , it really works and we were able do it in 1st attempt.☺

  • @ss00051
    @ss00051 7 лет назад

    dude awesome project just made it and it's working fabulous 😎

  • @asds2478
    @asds2478 7 лет назад

    That's beautiful...Thanks

  • @SirJeAdventure
    @SirJeAdventure 7 лет назад

    Thanks it really helps me for my project..

  • @CrazyCoupleDIY
    @CrazyCoupleDIY 6 лет назад

    Nice, love it

  • @kartiksingh9382
    @kartiksingh9382 7 лет назад

    I did the same as you told - uncompressed both the libraries and copied them in libraries folder. I opened the code that you provided and then just complied it.

  • @DhadamRobotics
    @DhadamRobotics 5 лет назад

    Good job Bhai , keep eat UP

  • @musical_flights8836
    @musical_flights8836 7 лет назад

    Sir thanks u make great videos.......

  • @digitalelectronics9017
    @digitalelectronics9017 5 лет назад +1

    Cute robot......it is so cool sir

  • @desireevalencia5587
    @desireevalencia5587 7 лет назад

    very good tutorial. Thank you!

  • @arunprabhakarsingh
    @arunprabhakarsingh 7 лет назад

    thanks for every thing code works well. explain every thing very well.

    • @arunprabhakarsingh
      @arunprabhakarsingh 7 лет назад

      bro but i have 1 problem that i have bo2 geared motor and use 2 battery 1 for shield another for arduino. but my wheels are not turning after 1/2 min any problem with motor, motor speed or battery (e/w , b/w the name of batteries).when i connect it to my computer for checking code it works very well

  • @RahulRoy-mi4zm
    @RahulRoy-mi4zm 7 лет назад +1

    Thank you sir for such a well explained video.
    But I have to connect 2 ultrasonic sensors (fixed at left and right side) to detect walls.
    So is this possible to attach 2 ultrasonic sensors and what extra thing I have to do?

  • @rivon8953
    @rivon8953 6 лет назад +2

    bro u r great tnx for your extreme help

  • @bouhrira1
    @bouhrira1 2 года назад

    merci pour ce video

  • @samilcanselklc7232
    @samilcanselklc7232 7 лет назад

    good project

  • @vijaypawar7000
    @vijaypawar7000 7 лет назад

    Dear sir,
    i am from robokitshop mumbai. i like your project thanks.

  • @harshvardhankumar9403
    @harshvardhankumar9403 7 лет назад

    Sir I read your comment on instructables. I have downloaded from the official website and this morning when I connected the battery AGAIN it started to move in circles. I will follow your steps which u gave me as soon as I can.

  • @user-nf4iq6wc6y
    @user-nf4iq6wc6y 7 лет назад

    Hi Sir! Thank you so much for giving me a good project :) I followed all things including wiring and coding. But once the servo starts to rotate, the Arduino restarts again and again. I followed some instruction to decrease noise using capacitor but didn't work. I used Panasonic 6LF22 9V battery and its voltage before operation is 7.1v. But when I connect it to the motor shield, it drops to 4.8V to 6.1V.
    1) If I plugged out the servo pins to Motor shield, the robot works although its neck doesn't move.
    2) If I connect arduino to PC and samely supply voltage to the Motor shield using the 9v, It works.
    3) If I connect arduino to another 9V and samely supply voltage to the Motor shield using 9v, it doesn't work (which means I used 2 9V batteries)
    4) If I connect arduino to smartphone Aux battery and samely supply voltage to the Motor shield using 9v, it works.
    I have tried to figure out what's the problem for a month.. Could you reply for me to solve this problem?? Thank you !!

    • @user-nf4iq6wc6y
      @user-nf4iq6wc6y 7 лет назад

      Mert Arduino Tutorial & Projects oh thanks! After I change the battery to Duracell, the robot is working even faster! Thanks:))

  • @sutariyahitkumar7126
    @sutariyahitkumar7126 5 лет назад +1

    Thanks for your project very useful

  • @Kncperseus
    @Kncperseus 7 лет назад +1

    thanks, man. Havne't uploaded the code, since waiting for parts but it verifies

  • @eeeprojectandmaintenance6261
    @eeeprojectandmaintenance6261 2 года назад

    Awesome

  • @laxmanshivde502
    @laxmanshivde502 7 лет назад

    thanks bro for this video

  • @yerr7774
    @yerr7774 7 лет назад +3

    Question: what does the error to comply to the arduino uno mean?

  • @allaboutiosgames3093
    @allaboutiosgames3093 7 лет назад

    appriciative man i has also maded an obstacle avoiding robot whith different source code and same hardware

  • @DevineIshaq107
    @DevineIshaq107 6 лет назад

    nice clean intuitive educative
    awesome

  • @yukselbey913
    @yukselbey913 6 лет назад

    Mert bey Obstacle avoiding robot projesini bitirdim. Arama robot durmadan kendi etrafında dönüyordu DC motorlardan birinin besleme uçlarını ters çevirdim problem çözüldü. Paylaşmak istedim. Tekrar teşekkürler.

  • @deepakkhopkar3353
    @deepakkhopkar3353 2 года назад

    Amazing

  • @arunsarang8781
    @arunsarang8781 7 лет назад +1

    thanks

  • @DenisBarbas
    @DenisBarbas 6 лет назад

    Hy.
    Great video.
    Can you please tell me , why in the CHECKPATH method , the for cycle is "for(pos = 144; pos >= 36; pos-=18)" why did you choose these values : 144, 36 and 18 ?
    I understand that it turns for 6 time (18 degrees each time) from 144 degrees to 36 degrees , but is there a reason for theese values or they're just random values???

    • @vell546
      @vell546 17 дней назад

      Hi can you copy and paste the code, I can't open the link code

  • @DhadamRobotics
    @DhadamRobotics 5 лет назад +1

    Wow brother

  • @christianaaronvelasquezbor4348
    @christianaaronvelasquezbor4348 6 лет назад +1

    the cables go to the A4 and the A5 or they go in the analog input

  • @arunsarang8781
    @arunsarang8781 7 лет назад

    for the arduino connection we can use jumper

  • @uhtijmai
    @uhtijmai 6 лет назад

    If anyone is experiencing problem with ultrasonic sensor like distance is zero when you test it after assembling shield on the Arduino then use Analog pins for trigger and echo or use digital pins 2 and 13 ... The reason is upto you to find... This is applicable for this particular motor shield...

  • @FutureAIDev2015
    @FutureAIDev2015 7 лет назад

    Why do you want to use the analog pins for the ping sensor? Isn't it a digital device that measures distance by counting the time from sending the signal to receiving the echo?

  • @raffayqazi5617
    @raffayqazi5617 7 лет назад

    thank u sir mert arduino that's my next project

  • @manjuchauhan1367
    @manjuchauhan1367 6 лет назад

    thanks sir very much i made it and got 1st price in state robotics contest.

    • @vamshibhargav6278
      @vamshibhargav6278 5 лет назад

      Bro I didn't get where to connect sensor wires please help me

    • @hari_arts4886
      @hari_arts4886 5 лет назад

      send some instruction bro my project is not working i did everything

  • @netanelonsu4531
    @netanelonsu4531 7 лет назад

    Thanks

  • @marinecell2641
    @marinecell2641 5 лет назад +1

    Thanks sir

  • @muhammadidreeskhan9221
    @muhammadidreeskhan9221 5 лет назад

    apprecaited

  • @ajcomputerandarduinoexpert703
    @ajcomputerandarduinoexpert703 7 лет назад +1

    thanks sir

  • @jaringjaring
    @jaringjaring 6 лет назад

    Awesome project, but could you combine this project with line follower.

  • @markliles4113
    @markliles4113 7 лет назад

    I would like to add 595 8bit shift register and led's that light up the closer it gets to an object with a buzzer.
    I wonder if it would be hard to add the led's and buzzer into your existing code?

  • @vishnudesai893
    @vishnudesai893 7 лет назад

    Also i wanted to know that when to install code after complete wiring with l298n and sensor or only in uno r3 board

  • @MasterNoxob
    @MasterNoxob 7 лет назад

    Çok güzel bir video olmuş. Bir sorum olacak, bu shield mega ile de uyumlu mu acaba?

    • @MasterNoxob
      @MasterNoxob 7 лет назад

      Yardımın için ben teşekkür ederim galiba v2 olanı uyumluymuş. Kanal çok iyi bu arada. Başarılarının devamını dilerim.

  • @prabhavshankar606
    @prabhavshankar606 6 лет назад +1

    I searched online for how to fix humming sound coming from motors and found that battery isn't a problem but you need to change the PWM frequency. Please can you tell me how can I change it in your provided code

  • @josueespinosolano6974
    @josueespinosolano6974 7 лет назад

    Hi! First of all, thanks for the video, it's very usefull for beginners in arduino like me. I have tried to replicate the project, but I have some problems. First of all, I have the adafruit motorshield V2.3. I made the changes in the code, but the robot doesn't work as is supposed to. I want to know if i can contact you and show you my code and tell you more details about the problems in the function of the robot, so you can help me to find where is the mistake (s) in the project. Thanks

  • @YuppiTube
    @YuppiTube 6 лет назад

    Süpersin :)

  • @DenisBarbas
    @DenisBarbas 6 лет назад

    Could you please tell me which code to modify to accelerate the speed of the motors ?

    • @lakshaynarayan1853
      @lakshaynarayan1853 5 лет назад

      In The Code You Will See An Option Like "Motor Speed" You Can Set From 10 To 225 So Set It According To Your Need ☺️

  • @seth8034
    @seth8034 7 лет назад

    seems like one motor is faster than the other. i had the same problem. i compensated by setting the speeds for each motor to different settings until they were mostly in sync.
    Do you know of any higher quality motors i could buy?

  • @johnduong5448
    @johnduong5448 6 лет назад

    s there a specific wire to connect the DC motors? what gauge? silicon or copper? and i notice the wires come black and red. or did you just snip off jumper wires and use those?

  • @cjbailey75
    @cjbailey75 7 лет назад

    Hello Sir. I am about to build this robot and have a few questions. I am using the arduino 101 should I use the 10 and 13 pin or the analog 4 and 5 pin?

  • @masterdamien2176
    @masterdamien2176 7 лет назад

    thanks for sharing: you inspired me to to buy my first arduino (leonardo) and build your cool robot. my robot looks great but downloading and uploading didn't work. I can't figure out what I did wrong. Is it because I used a leonardo?

  • @laurentamurat1676
    @laurentamurat1676 7 лет назад

    do you have to supply power to the Arduino as well or just the motor shield

  • @ishakshaik4514
    @ishakshaik4514 6 лет назад +1

    I have the same kit like you but I have IR sensor instead of your sensor ,then what can I do now

  • @_1waychris
    @_1waychris 6 лет назад

    What kind of screw driver would I need for the l293D motor shield

  • @Suresh-ll8ko
    @Suresh-ll8ko 6 лет назад +1

    I wanna make it using single motor driver ic, plzz which pairs of pins are output for drivng motor

  • @alhasnalhasn6620
    @alhasnalhasn6620 7 лет назад

    thank dude

  • @Matt-ci1lp
    @Matt-ci1lp 4 года назад

    So, where did you put the cables to the ultrasonic distance sensor, because I watched you put the cables on the B's place and you said that you put it at the A's place? Which one is right?

  • @jieunlee4599
    @jieunlee4599 6 лет назад

    I also have the same problem with others, all the parts are working except for the motor, it does only a buzzing sound. And you said that it's not supplying enough power, should i use a duracell 9v battery? Im currently using energizer 9v battery

  • @panasko228
    @panasko228 7 лет назад

    I am going to try to use solar power to drive my motors. will 4 (1.5 watts 5.5 volts) enough to power it. I am getting around 24.40 volts from 4 solar panels.

  • @christianaaronvelasquezbor4348
    @christianaaronvelasquezbor4348 6 лет назад +1

    which goes to the A4 yellow or blue wire please

  • @yuanfang2352
    @yuanfang2352 7 лет назад

    Hi thank you for the tutorial! Did you incur any error when validating the code? This happens to me: "a function-definition is not allowed here before '{' token " I copied the exact code from the tutorial...

  • @bbtx7160
    @bbtx7160 6 лет назад

    The product link for Bracket HC-SR04....you give in Description is different from the used in video. So please help me which I should use.....

  • @musical_flights8836
    @musical_flights8836 7 лет назад

    have a great day

  • @foerzaid4098
    @foerzaid4098 4 года назад +1

    sir,
    why the dominant wheel turns right?

  • @nikeshpyakurel4187
    @nikeshpyakurel4187 5 лет назад +1

    in which pin servo should be connected??

  • @yashkatewaarts
    @yashkatewaarts 6 лет назад

    which adafruit motor should is being used by you

  • @madhuyashwantha4202
    @madhuyashwantha4202 6 лет назад +1

    will you provide complete documentation for this project here by link...?????

  • @kukuhpriambodo3553
    @kukuhpriambodo3553 7 лет назад

    thanks for the your video, this video really help me to make a toys and im hopefully you can make a video more interesting than this.

  • @DenisBarbas
    @DenisBarbas 6 лет назад

    Excuse me sir, I did everything like in your video, but when I start my robot, the servo starts working, but the DC Motors DON'T! And my shield emets a continuous beeping sound. please tell me could it be that I switched the red and the black wire to the dc motors? help me please. Waiting for your kind answer

  • @elektrosharing5325
    @elektrosharing5325 6 лет назад

    Nice

  • @premalathababu4971
    @premalathababu4971 5 лет назад +1

    Will arduino UNO is enough to make the bot or arduino uno r3 please replay fast

  • @danielrafaeltorresmendoza1098
    @danielrafaeltorresmendoza1098 7 лет назад

    Is there another type of battery that a could use?, because, i cant get enough power for turning on the motors, even though i use one 9v battery for the arduino and another for the motor shield

  • @vrajparikh301
    @vrajparikh301 7 лет назад

    Do i need to power adafruit shield and arduino board both separately?

  • @pradeepbuddha5264
    @pradeepbuddha5264 7 лет назад

    your project discription is awesome , i needed the program code to build this project , can you please forward me in pdf formate

  • @abshanap2639
    @abshanap2639 5 лет назад

    Can we use 2 motor connector l293d module instead of l293d motor driver shield

  • @shadowgamer8426
    @shadowgamer8426 7 лет назад

    can it really work. i want a nice project for my school science competitions

  • @arduinoandbasics9877
    @arduinoandbasics9877 6 лет назад +1

    sir it takes you how much time to record a video

  • @Kncperseus
    @Kncperseus 7 лет назад

    Made my own chassis since I'm broke, but parts are otherwise all as recommended. How ever after turning the power on, the bot simply keeps rotating its head instead of moving? Is this supposed to happen?

  • @Freshboyarly
    @Freshboyarly 4 года назад

    How can I learn to code a robot like this? Is there some form of list that provides to appropriate syntax for you to accomplish a project like that?

  • @angie96blizz
    @angie96blizz 7 лет назад

    Good day! I got confused where exactly to put the wires for the echo and trig of the hc-sr04 sensor because in the video you plugged-in the wires in the digital pins then in the pin connections (in the diagram you've shown) it was plugged-in in the analog pins. Hoping for your reply. thank u!

    • @angie96blizz
      @angie96blizz 7 лет назад

      Good day. I tried your suggestion and it works! I will ask a question again...is it possible that the code can be converted in a maze solver code? I'm having a difficulty in converting it. If possible, can you give me some suggestions about it? Hoping for your reply. thanks a lot.

  • @charbelsarkis3567
    @charbelsarkis3567 7 лет назад

    are the screws on the motor shield there just to make it stick on top of it

  • @_1waychris
    @_1waychris 6 лет назад

    Can you please tell me the screwdriver size for the motor shield because I ordered it but it did not come with an screwdriver so what is the size for it.

  • @mariamgallardo910
    @mariamgallardo910 6 лет назад

    The servo motor make a different in the code? I mean.. If I don't get or not want to use it, does it change something in the code?

  • @seasnek7024
    @seasnek7024 6 лет назад

    Hey MertArduino and Tech, really cool robot. Am subscribed. Just wondering, is there any way to change the parameters on the ultrasonic sensor, because mine keep scanning distances far away, and registering them as too close. So because of that, mine will only move 1cm, then move to find a different position. Can you please help?

  • @nizipcom
    @nizipcom 6 лет назад

    Teşekkürler, elinize sağlık. Türkçe olan kanalınızı bulamadım.
    Devreyi ve kodları uyguladım. Herşey normal derken, Servo sağa sola devamlı dönüyor ve hiç durmuyor.
    Normalde engele gelince yapması gerekeni, her an yapıyor.
    elimi önüne koyunca tepki verip duruyor, devam ediyor.
    HC-SR04 değiştirim yine aynı
    Tekerler öne ve arkaya dönüyor, tepki veriyor.
    Servonun sağa sola devamlı dönmesini neye bağlıyorsunuz?

  • @emreyalcn2865
    @emreyalcn2865 7 лет назад

    iyi günler öncelikle projeniz çok başarılı olmuş tebrik ederim bir sorum olucakti ben öğrenciyim labirent çözen robot projem var bu robotu labirent çözen robot olarak da kullanabilir miyim ?

    • @emreyalcn2865
      @emreyalcn2865 7 лет назад

      Mert Arduino Tutorial & Projects geri dönüşünüz için teşekkür ederim öncelikle. robotun algoritması hazır durumda sizin ki gibi tıpkı yalnız dc motorları L293D entegre ile sürdüm bu yazdığınız kod la uyusmama sorunu olur mu ? Devrede servo motor da kullanacağım

  • @rambanarasi1826
    @rambanarasi1826 6 лет назад

    How does ur robot move so fast?
    Can we also fasten the speed of our DC motors?

  • @RAHULGUPTA-dt6yd
    @RAHULGUPTA-dt6yd 7 лет назад

    how your servo is rotating when some obstacles seen then tours servo looking left and right but my servo is continous rotating left and right