Control a Positional Servo Motor with an Arduino (Lesson #10)

แชร์
ฝัง
  • เผยแพร่เมื่อ 19 ธ.ค. 2024

ความคิดเห็น •

  • @shakejones
    @shakejones วันที่ผ่านมา +1

    Brilliant! Thank you for sharing mate 🙏🏻

  • @oggythepro
    @oggythepro 8 หลายเดือนก่อน +3

    4:28 you can change the pos to an float and change the code

  • @mshalima1654
    @mshalima1654 ปีที่แล้ว +17

    Can you make a video about how to make a jet engine?

    • @Science.Buddies
      @Science.Buddies  ปีที่แล้ว +9

      That is a little too advanced for us!

    • @Uilyam719
      @Uilyam719 ปีที่แล้ว

      here is a video on someone making a good jet engine(rocket engine but we will call it a jet engine)
      th-cam.com/video/imRAnN4ylZs/w-d-xo.html
      sorry if you do not know Russian the video is in Russian.

    • @GabrielTcheunta
      @GabrielTcheunta 6 หลายเดือนก่อน +1

      Bu i and my bro really wanted to make one 😢

    • @GabrielTcheunta
      @GabrielTcheunta 6 หลายเดือนก่อน +1

      ​@@Science.Buddiesand from the look of things we're not the only ones

  • @Nick-ef1ms
    @Nick-ef1ms 4 หลายเดือนก่อน +3

    For anyone wondering where to connect the wires, the brown goes to ground, red to 5V, and orange to pin 9

    • @KnowledgeNuggets-n7x
      @KnowledgeNuggets-n7x หลายเดือนก่อน

      It's also worth mentioning you can change the pin that the orange goes to but you have to change the line of code stating what pin the servos are on to whatever pin you change it to

  • @A.E.Robotics
    @A.E.Robotics ปีที่แล้ว +1

    Hey, would you explain to me if I would be able to switch a servo between 90 and 140 quickly? I also want to have it so when I press a button it opens to 140, and when I let go it goes back to 90. Any way? I think you would know.

    • @Science.Buddies
      @Science.Buddies  ปีที่แล้ว

      Hi - if you check out the rest of our Arduino tutorial playlist, we have videos on using buttons and other inputs.

    • @A.E.Robotics
      @A.E.Robotics ปีที่แล้ว

      @@Science.Buddies hello, I am very familiar with buttons and arduinos. But something that has been stumping me is getting the servo to go to a certain position for the duration of the button pressed. I looked into tutorials, and all what others seem to want is to make a servo move to a position and back every time a button is pressed. I want mine two positions, like an animatronic mouth. Open, and closed. Thanks!

    • @Science.Buddies
      @Science.Buddies  ปีที่แล้ว

      Hi - we can't provide help writing code for individual projects, but you might be able to find help in the official Arduino forums or other sites like Stackexchange.

  • @Vexed-dev
    @Vexed-dev 9 หลายเดือนก่อน +1

    what hole is the orange wire in

  • @bernardomendes10
    @bernardomendes10 ปีที่แล้ว

    Can i rule my servo rotation to a specific range, like a 60 degrees rotation counter clockwise and clockwise?

    • @Science.Buddies
      @Science.Buddies  ปีที่แล้ว

      Yes, you would just need to use a variable to keep track of the angle, then add or subtract 60 degrees from that angle depending on which way you want to rotate.

    • @bernardomendes10
      @bernardomendes10 ปีที่แล้ว

      @@Science.Buddies, thanks!

  • @shaun6831
    @shaun6831 9 หลายเดือนก่อน

    How do I make my servo to move to a angle and delay for about 4 sec and go back to the same angle with a sensor right now I have a Arduino uno and an IR sensor I can't figure out how to do it I've watch many videos but all of them failed how can I code thisM

    • @Science.Buddies
      @Science.Buddies  9 หลายเดือนก่อน

      Hi - if you need help with code you can try asking on the official Arduino forums, or if you are a student doing a school science project you can ask in the Ask an Expert forums on our website www.sciencebuddies.org.

  • @AlexNeir
    @AlexNeir 10 หลายเดือนก่อน +4

    Where is the code?

    • @piotrp409
      @piotrp409 10 หลายเดือนก่อน +2

      If you have the liblary downloaded then it is in example codes which u find under 'file' lable

    • @Studs_Studio
      @Studs_Studio 10 หลายเดือนก่อน

      @@piotrp409 where do you download it? also why didnt science budies give a link thats kinda weird

    • @marshallrobinson4073
      @marshallrobinson4073 8 หลายเดือนก่อน

      @@piotrp409 where do i go to download this liblary

  • @murtazasyed3392
    @murtazasyed3392 หลายเดือนก่อน

    do I need a capacitor or resistors I read u need them but I am confused.

    • @Science.Buddies
      @Science.Buddies  หลายเดือนก่อน

      Small hobby servos like this can usually be directly connected to the Arduino with no additional parts, but you should read the data sheet or instructions that come with your servo.

  • @udaykaranwal1662
    @udaykaranwal1662 ปีที่แล้ว

    How can I add a switch to this? like I want the servo to go clockwise when I turn the switch on and anticlockwise when I turn the swtich off

    • @Science.Buddies
      @Science.Buddies  ปีที่แล้ว

      We can't write the code for you in a TH-cam comment, but please see the rest of our Arduino tutorial series (linked in the description) which includes various inputs like buttons, switches, and other sensors.

  • @TheQueenuvhearts
    @TheQueenuvhearts ปีที่แล้ว

    I see the wires connected from the Arduino to the breadboard. Can you tell me what those are and how to set that up? I'm just a mom trying to get the motor to work for the Halloween pumpkin and I'm not very tech savvy. Any help would be very much appreciated.

    • @Science.Buddies
      @Science.Buddies  ปีที่แล้ว

      Hi - if your circuit literally just has a single servo motor, you do not actually need a breadboard. You can search Amazon for "Arduino male to male jumper wires" and just plug the three wires from your servo motor directly into your Arduino (as described in the video, color coding will depend on your motor). However, if this is the first video you're watching, it might help to back up a bit and start with our How to Use a Breadboard video: th-cam.com/video/6WReFkfrUIk/w-d-xo.htmlsi=OfQ2Fr6RqSBoms2Y and watch at least the first three videos in our How to Use an Arduino series: th-cam.com/play/PLlBVuTSjOrclb0iCMSRpS_H1lSrlSVeEm.html&si=iZF8YZwDDhnUT5CZ. Hope that helps!

  • @livarei
    @livarei ปีที่แล้ว

    Hi, can you make video about controlling a servo motor by a slider button assigned to a variable command such as = (if val == '(inserted variable)')... then the specific command to do so with a slider.
    Just working on a bluetooth car with a robotic arm that has 3 servo motors that require the usages of sliders. Thank you!

    • @Science.Buddies
      @Science.Buddies  ปีที่แล้ว

      Hi - we don't currently have plans to add a video that specific, but we do have a video about slide switches that you may find helpful: th-cam.com/video/0ZXYRU9KPG8/w-d-xo.htmlsi=rMzlhcxUV73bmPFT

  • @SYLVIAFUNGKAISUEN
    @SYLVIAFUNGKAISUEN 8 หลายเดือนก่อน

    CAN U MAKE A SENSOR TO CHECK WE HAVE TAKE OUR KEY WHEN WE GO OUT?

  • @Saffron_SV
    @Saffron_SV 3 หลายเดือนก่อน

    My Servo motor goes 0 to 90 to180 degree counter-clockwise is there anyway to make it clockwise, Like If I do `myservo.write(90);` ?? I want it to go 90 degree to the clockwise direction NOT counter-clockwise.

  • @Nevaan3103
    @Nevaan3103 ปีที่แล้ว

    Can you make a car and drone

    • @Science.Buddies
      @Science.Buddies  ปีที่แล้ว

      If you search our website, www.sciencebuddies.org, you will find many projects about both cars and drones!

  • @Malak-yj3or
    @Malak-yj3or 9 หลายเดือนก่อน +1

    my problem is that my motor doesn’t move i have the right codes and the right wires placed but it just doesn’t move