28BYJ-48 STEPPER MOTOR WITH ULN2003 DRIVER - Arduino tutorial #14

Поділитися
Вставка
  • Опубліковано 4 жов 2024

КОМЕНТАРІ • 68

  • @v.ssarath911
    @v.ssarath911 2 роки тому

    THANKS a lottttttttt. THANK YOU SOO MUCH

  • @heathcarter4654
    @heathcarter4654 3 роки тому

    Cheers really usefull

    • @BasonTech
      @BasonTech  3 роки тому

      Great to hear, thanks! 😃

  • @last1b4free
    @last1b4free 3 роки тому

    new subscriber !

  • @expires_today
    @expires_today Рік тому

    I have a problem, I connected everything correctly, but the motor only makes sounds and does not spin, it also vibrates, I have already tried to increase the voltage, but it still does not work

    • @BasonTech
      @BasonTech  Рік тому +1

      It could be that the pin layout is different on you PCB board. Then the steps will not work.

  • @OregonDARRYL
    @OregonDARRYL 3 роки тому

    Line 29 reads "degrees per revolution"... when I think you meant "degrees per one full step".

    • @BasonTech
      @BasonTech  3 роки тому

      Hi Darryl, 1 revolution is 360 degrees. It has 64 steps per revolution. 360 / 64 = 5.625 degrees per revolution. This is the same as degrees per one step.

    • @OregonDARRYL
      @OregonDARRYL 3 роки тому +1

      @@BasonTech 360 degrees per one revolution. 5.625 degrees per step. Line 27 in your code says "5.625 degrees per revolution". That is incorrect. Good video though. Thanks.

  • @iszjhxsbxb
    @iszjhxsbxb 5 років тому +1

    how many stepper motors can i control with ardino uno

    • @BasonTech
      @BasonTech  5 років тому

      Theoretically as much as you want. Practically there are some limitations: speed of controlling all motors, current drawn by the motors, the number of pins available. This topic quite covers your question forum.arduino.cc/index.php?topic=241152.0

  • @carlosvargas1443
    @carlosvargas1443 3 роки тому

    where is the course description so I look at the code

    • @BasonTech
      @BasonTech  3 роки тому

      It depends how you watch this video. You'll find all the links in the video description. For this tutorial it is arduino-tutorials.net/tutorial/control-28byj-48-stepper-with-uln2003-driver-with-arduino 😃

  • @Brandon-qp7gq
    @Brandon-qp7gq 2 роки тому

    how is it safe to connect the ground of the power supply to the arduino while the positive voltage comes from elsewhere? what if the power supply is a battery?

    • @BasonTech
      @BasonTech  2 роки тому

      I don't understand your question. They share a common ground but the circuits are individual for powering the motor and for the driver.

  • @ValerianKapeller
    @ValerianKapeller 2 роки тому

    Why always 8,9,10,11 pins on the arduino? Can i go for 2,3,4,5 as well?
    Thank you :)

    • @ahmadaidit6175
      @ahmadaidit6175 2 роки тому

      i think you can, just change the pin at 4:45

    • @BasonTech
      @BasonTech  2 роки тому +1

      Hi, that depends on the requirement of the pins. Pin 2, 3, 4 and 5 could work but you have to keep in mind if your application needs for example PWM pins. It then is important to select the correct ones.

    • @ValerianKapeller
      @ValerianKapeller 2 роки тому

      @@BasonTech thank you very much for your answer! :) Got it!

  • @ersatz7107
    @ersatz7107 5 років тому

    is there a code for controlling the motor with a potentiometer like how you would control a servo motor with a potentiometer?

    • @BasonTech
      @BasonTech  5 років тому

      You can combine the code of the potentiometer tutorial with this one. Convert the range of the potentiometer to the amount of degrees you want the motor to rotate.

  • @speedstacker593
    @speedstacker593 Рік тому

    When I connect my external power supply, same as yours, my arduino does not light up and turn green and orange. Any idea why? Wiring is identical as in the video

    • @speedstacker593
      @speedstacker593 Рік тому

      I believe it is the power adapter. When I plug the external source directly into the arduino, it works fine but when I use the adapter and wire like you it doesn’t not work

    • @BasonTech
      @BasonTech  Рік тому

      Maybe the voltage is too low?

    • @speedstacker593
      @speedstacker593 Рік тому

      @@BasonTech it works when it is just the power supply plugged into the arduino. When I use the adapter and breadboard it does not work

    • @BasonTech
      @BasonTech  Рік тому

      Sound like an incorrect wiring or a faulty breadboard

    • @speedstacker593
      @speedstacker593 Рік тому

      @@BasonTech The breadboard is working properly and the wiring is identical to the video. I will keep playing around with it and see what I can get. Thank you for the help!

  • @jennifercraig3820
    @jennifercraig3820 3 роки тому

    Hi there, would it be possible to connect a battery pack of 6V as the power supply rather than an adapter? (sorry if this is a silly question, I'm new to electronics and don't want to end up frying my arduino or blowing something up!)

    • @BasonTech
      @BasonTech  3 роки тому +1

      6V is too much, the motor is rated 5V max. Also make sure your battery pack can provide enough amps.

  • @fadygharbi7479
    @fadygharbi7479 2 роки тому

    Hi there I did the same code
    The motor is just vibrating not turning any solution ?

    • @BasonTech
      @BasonTech  2 роки тому

      If the code is exactly the same, please check your wiring. Maybe there is a loose connector or the wrong power supply.

  • @rekhasaini672
    @rekhasaini672 3 роки тому

    Can I use a 5v breadboard supply module for instead of the adapter

    • @BasonTech
      @BasonTech  3 роки тому

      You can, but you shouldn't. The motor can draw peak powers which could damage your Arduino.

    • @rekhasaini672
      @rekhasaini672 3 роки тому

      Thank you

  • @juliusaitken
    @juliusaitken 2 роки тому

    Hi Baz! How would i amend the code to control TWO stepper motors so they behave completely independently?

    • @BasonTech
      @BasonTech  2 роки тому

      What part did you get stuck and did not work?

  • @dinzzz0000
    @dinzzz0000 2 роки тому

    Hi, my stepper is vibrating nut it is not actually rotating :( do you know what the problem might be ?

    • @BasonTech
      @BasonTech  2 роки тому +1

      Hi, make sure the wires are connected correctly. Other thing could be the power supply not being connected correctly

  • @alanpereira6824
    @alanpereira6824 3 роки тому

    I want to turn off the stepper motor once it rotates half way. I do not want it to loop. Can the driver do that?

    • @BasonTech
      @BasonTech  3 роки тому

      Sure, that should not be a problem

  • @dogme666
    @dogme666 2 роки тому

    hi, thanks for the video! it got me severall steps forward, i have a question though, im using a computer power suply , when i conect it like this to the 12v power rail of the psu it works for about half a minute and stops, the chip gets really hot and if i disconect and wait a bit it works again, do you have any suggestion to what i might have done wrong? my ground rail comes from the power suply as well. any insight on this will be extremely helpfull.
    edit: there is a problem with my uln2003 board, a diferent board works perfectly, gonna trtoubleshoot the traces now, thank you for the video!!!

    • @BasonTech
      @BasonTech  2 роки тому +1

      Thanks for the update! Maybe you've damaged the ULN2003 chip with a faulty connection and that makes it hot?

    • @dogme666
      @dogme666 2 роки тому

      @@BasonTech the ic works on a different board, so I suspect there is a short on the little circuit board.

    • @BasonTech
      @BasonTech  2 роки тому

      Great you got it working, well done! 😃

  • @azozalshateri5029
    @azozalshateri5029 3 роки тому

    The ULN2003 driver dose not show lights, I do not know why?

    • @BasonTech
      @BasonTech  3 роки тому +1

      Are you sure you've powered the motor and board correctly?

    • @azozalshateri5029
      @azozalshateri5029 3 роки тому

      @@BasonTech yes, I am so sure that I do the same what you did in the video.
      May there a problem in Uln2003 itself or the type of Arduino because when you run the code it appears green light in your Arduino but my Arduino red light apears.

    • @azozalshateri5029
      @azozalshateri5029 3 роки тому

      @@BasonTech many thanks, I solved the problem. The problem was the jumper was not connected to the Uln driver.

    • @BasonTech
      @BasonTech  3 роки тому +1

      Great to hear you've solved it, thanks for sharing! 😃

  • @biswa145
    @biswa145 4 роки тому

    What is the steps per revolution of the stepper motor you used?

    • @BasonTech
      @BasonTech  4 роки тому

      Hi Mishra, Officially it is 64, some people at forum.arduino.cc/index.php?topic=71964.15 calculated it is actually 63.68395 😃

    • @biswa145
      @biswa145 4 роки тому

      @@BasonTech There's no single answer. Some are saying it's 64, some saying it's 4096?!

  • @santhosheaswaramoorthy8685
    @santhosheaswaramoorthy8685 3 роки тому

    Why are you using power plug?

    • @BasonTech
      @BasonTech  3 роки тому

      You want to separate the motor current form the Arduino current. The high peaks might damage your Arduino. Therefore I make the motor power go completely separated from the Arduino one.

  • @nadavdanieli
    @nadavdanieli 2 роки тому

    It moves 90 degrees, (as defined in the code) :)😝

  • @Marco.Malatesta
    @Marco.Malatesta 4 роки тому

    hello and congratulations for the video, I need the same code but for 2 motor steppers, do you know what I should modify? thanks and good day.

    • @BasonTech
      @BasonTech  4 роки тому +1

      It is basically the same code. You define another 4 pin variables e.g. motor2Pin1, motor2Pin2 etc. And create a second instance of the stepper like:
      AccelStepper stepper2(AccelStepper::HALF4WIRE, motor2Pin1, motor2Pin3, motor2Pin2, motor2Pin4);
      Instead of stepper.setMaxSpeed(1000.0); your now use stepper2.setMaxSpeed(1000.0);
      So everything works the same but now you have two instances: stepper and stepper2. Hope this helps :)

    • @BasonTech
      @BasonTech  4 роки тому

      @@Marco.Malatesta On arduino-tutorials.net there is a contact button which you can use :)

    • @Marco.Malatesta
      @Marco.Malatesta 4 роки тому

      @@BasonTech Hi, after many tests I managed to modify the code, now it works well, thank you for the help you have given me, bye.

    • @BasonTech
      @BasonTech  4 роки тому

      Great! Unfortunately this is the best way to learn stuff ;)

  • @Koto-Sama
    @Koto-Sama 4 роки тому

    2:44 this is incorrect for this type of motor

    • @BasonTech
      @BasonTech  4 роки тому

      Thanks for your remark, I've removed the scene from the video

    • @Koto-Sama
      @Koto-Sama 4 роки тому

      @@BasonTech thx