L9110 with Arduino Code - Part 2: How to Control Linear Actuators

Поділитися
Вставка
  • Опубліковано 1 сер 2024
  • L9110 with Arduino Code - Part 2: How to Control Linear Actuators
    In this tutorial I will show you how to use the L9110 motor control board and write simple Arduino code (see code below) to control various types of motors in your own personal projects. The L9110 is a compact and inexpensive H bridge motor control board that easily interfaces with microcontrollers such as the Arduino or Raspberry Pi.
    This board can be used to control two small DC motors simultaneously or can be used to control a small stepper motor, such as a NEMA 17. The board operates between 2.5- and 12-volts DC. It is capable of sourcing 800 mA per phase sustained and 1.5 Amps momentarily.
    This tutorial is divided into 3 videos. Part 1 covers the speed and direction control of DC motors. Part 2 discusses the control of linear actuators. Part 3 demonstrates how to control the speed and direction of stepper motors. Each video includes step-by-step set-up instructions as well as basic Arduino coding that can be incorporated into your own projects.
    The following are affiliate links for products I used in this video. Using these links will not affect the price for your purchase but may result in a small commission for me, allowing me to keep making helpful and entertaining videos.
    L9110 with Arduino Code - Part 1: • L9110 with Arduino Cod...
    L9110 with Arduino Code - Part 3:
    L9110S H-bridge Dual Channels Motor Driver Control Board for Arduino
    rover.ebay.com/rover/1/711-532...
    5A/30V DC Precision Power Supply:
    rover.ebay.com/rover/1/711-53...
    12V Actuator
    rover.ebay.com/rover/1/711-532...
    Arduino
    rover.ebay.com/rover/1/711-532...
  • Наука та технологія

КОМЕНТАРІ • 103

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

    Please check out my new video ua-cam.com/video/qLltghqVrvI/v-deo.html that uses an L298N and 3-button switch to control the same actuator.

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

      This video is similar using the L298N ua-cam.com/video/qLltghqVrvI/v-deo.html

  • @danny12345
    @danny12345 4 роки тому +2

    I was glad to have added a sketch of all the connections including the power supply

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

      You may be interested in this new video as well:ua-cam.com/video/qLltghqVrvI/v-deo.html
      See my Facebook page for the connections.

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

    Thank you for posting this. Seriously… I’ve been searching for this exact subject.

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

    I cannot tell you how much at ease you have put my mind to with this explanation! Absolutely love it! May you advise as to how a light source tracking PCB board is connected and coded to a linear actuator? The goal is to create a solar tracking system and I'm familiar with the linear actuator, just not how the connection and coding to the sun tracker and arduino works.

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

      Have you watched my video about the miniature solar tracker? The same code would work with a full sized actuator.

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

    Wonderful

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

    you are a legend.

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

    It will great have it to extend to certain height when its activates o power it and stop when touch the magnet automatically

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

      I hope to do another linear actuator video soon with position control.

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

    Super useful video, thank you Sir....please if possible make video to control speed and direction of 3 phase AC motor using arduino...thanks

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

      I'm hoping to to do a simple single phase relay video in a few months. I would love to do a 3-phase, but I don't have 3-phase at home. For that you need a variable frequency drive. Some of those have analog or serial inputs, which can both work with Arduino.

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

    Great video! I am fairly new to ardunios and found your video because I am looking for a tutorial on how to use a arduino with a linear actuator using one switch. Turn on the switch actuator goes full out and stops and then turn off the switch and actuator goes full in or home.
    Also would like to see a stepper motor do the samething. One switch controls actuator out then turn off and actuator goes in. Could you please do a video on these? Thank you sir I appreciate you taking the time to help noobs out like me 😁

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

      I just made another video about linear actuators using a switch ua-cam.com/video/qLltghqVrvI/v-deo.html . Thanks for watching.

  • @milesk5853
    @milesk5853 3 роки тому +3

    Great Video! I am also at looking to control a linear actuator with a joystick, with the actuator returning to 0 once the Joystick is released (neutral position) I know it’s possible, just wondering how to set it up? Thanks in advance

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

      If you are just going to have it go to one end, you could command a retract or extend if the pulse width is less than 1600 and then have it change directions when the pulse width is greater. If you want it to stop somewhere in the middle, that is a bit trickier as you would need position feedback. Hope that helps.

  • @Mr.GS-147
    @Mr.GS-147 4 роки тому

    Great demonstration! was doing research for a project I’m about to get my hands into and this is exactly what I needed 😊.
    Btw, if I was to say, use two actuators to move two flaps, in two different directions, I will need two proximity sensors I’m assuming? In which case my next question would be, can I wire two sensors in Parallel to the pins used in this vid? Or the board has an option for two sensors.

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

      Glad it was helpful. You can connect multiple sensors to the Arduino board. The 5V and GND will be in parallel, but the sensor wires would connect to different pins on the Arduino. These videos may also help: ua-cam.com/video/qLltghqVrvI/v-deo.html & ua-cam.com/video/Vc0LKeh_0FQ/v-deo.html

    • @Mr.GS-147
      @Mr.GS-147 4 роки тому

      Science Fun thank you. What a about an lED upon activation? Does this board supports an activation signal?

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

    Wow....great work dude....your projects are awesome....iam also...making...projects in...my channel...too dude..

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

    I’m interested in learning about a linear sequence of events such as when one actuator has finished its given action another starts a given action and then reverse the process

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

      With some actuators you can get position feedback to the Arduino. I will be doing a video about that in a few weeks (once the new actuator arrives).

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

      @@ScienceFunInnovations great I would love to watch and learn

  • @taytus
    @taytus 6 місяців тому

    Thank you so much for the tutorial. I'm just learning and I'd like to create a can crusher. How can I make actuators to go faster?

    • @ScienceFunInnovations
      @ScienceFunInnovations  6 місяців тому +1

      Use a BTS 7960 motor controller at the full rated voltage of the actuator. You can also look for high speed actuators since you only need a little force to crush a can.

    • @taytus
      @taytus 5 місяців тому

      @@ScienceFunInnovations thank you!!

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

    I like your videos and I think you got a lot to teach, so I subscribed, but please try to avoid asking people to subscribe so often!! maybe once in each video would be fine but some of your videos are like 20% references to other videos / asking people to subscribe!!
    Good luck and thanks for the video :)

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

      Thanks for the support and the feedback. It is hard to know as a new UA-camr how much to encourage subscriptions. I think my content is getting better, so hopefully more people subscribe with less persuasion and I can get my channel to a sustainable level. Thanks for watching!

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

      ​@@ScienceFunInnovations I'll keep watching :) by the way, you should look at instructables.com, you can often get lots of views for your projects and they have lots of contests where you can get awesome prizes
      good luck and I hope you get many more subscribers :)

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

    Could you use a laser tripwire in place of the magnetic sensor to activate the linear actuator?

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

      Definitely. I would connect the tripwire to digital pin 2 or 3 on the Arduino and use an interrupt command to set the mode to extend. Then use the other interrupt channel to retract when a button is pushed, for example. I talk a little about interrupts in my latest video: ua-cam.com/video/1Ssh2aTDPGY/v-deo.html

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

      Could you do a video on this i'm not very good with this

  • @ajw6715
    @ajw6715 4 роки тому +5

    Hi, Just found your channel. I am looking for a way to use an arduino to make an actuator return to it's
    half way out or half way in position when power is released from a joystick. Would love to see a video on this setup. Regards, AJ.

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

      I've had a few similar requests, so I will work on a future video for that. I might need to order a few parts, so it may be a little while before I get to it. Thanks for watching!

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

      @@ScienceFunInnovations Looking forward to it. I am new to the Arduino. So many possibilities. Thanks.

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

      I am almost certain this is not as simple as you hope. Linear actuators have no FEEDBACK, the just have endstops. the arduino has no idea WHEN it it in the middle, or anywhere along it's axis, so this would probably just be a timed move to an approximate center. I guess to do this you would have to add some form of encoder, or an extra limit switch in the center to provide that feedback.

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

    If i ran the linear actuator off a 7- pin rocker switch and i wanted to have a 2 switch controlling the main power it would as a power switch. How would i do that

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

      Do you have a diagram for the switches you want to use? You can send your questions to my business email sciencefunbiz@gmail.com.

  • @12kimmi21
    @12kimmi21 Рік тому

    I have been on the lookout for something like this, I want to get a robot vacuum cleaner and hide the docking station under a drawer or something similar, then id like to have a lid to open and close for the vacuumcleaner to get out from. (I 'll let the lid stay open while the cleaner is doing its thing so that I can keep it simple and just control the lid with am initiator/sensor as you have done here) The only thing is that I think the actuator would move too slowly for the vacuum so that it'll crash before its fully open. I know you powered your cylinder with 6V, I wonder if I'll have to power my cylinder with 9V or 12V to see if that would solve my problem, do you have any suggestions or ideas? (I havent bought anything or started this project yet, this is purely wishful thinking and planning)
    Thanks

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

      Yes. 12V should double the speed. Also consider using a lever where the actuator only moves a few inches, but the other end moves much further. The actuator should have plenty of force.

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

    Hi,
    Thanks a lot, its really greate effort and great knowledge.
    i need to do a project for a preset position linear actuator with a DC motor abd a stepper motor, with Arduino Mega or UNO but i am not able to write the code and the scheme, can you please help.
    Regards

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

      Normally I would help, but I have too many customers right now and so it would probably be several months before I could help. Sorry.

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

    I want to be able to open and close with a remote control, a flip top cabinet door that houses my split system AC/heater. I guess the best way to do that is with a linear actuator. Not sure where to buy the necessary parts. Any ideas?

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

      Linear actuator is a good way to go. I have another video showing how to control with an RC controller, and I am working on a video showing how to control and actuator with your phone. Hopefully I get it done this month.

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

    How much voltage drop does the L9110 have? i.e. I am guessing not mosfet so around 1.5V?

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

    How are the power sources connected? Is the Arduino connected to your computer? And how is the actuator's 6v power supply connected?

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

      Both the arduino and motor control board were connected to the 6V power supply. The actuator gets power from the L9110, which gets power from the power supply.

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

    My actuator extended but it did not retract after I reverse the connections. Do the power supply have to support reverse polarity?

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

      Doesn't sound like the power supply. Try using a 9 volt battery. May be an issue with the actuator. Good luck.

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

    if i used a light duty small linear actuator, can i use the L9110 with 12 V?

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

      You would just have to check the current under load is less than 0.8Amps. But check out my other videos where I use stronger motor controllers that work almost the same as the L911.

  • @TF-nr2tj
    @TF-nr2tj Рік тому

    Hi, I am wondering if you are able to help me with a assignment i am working. it is very similiar to this project except i am attempting to use a load cell to move the actuator. i.e. have the actuator move when weight is removed from the load cell

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

      I would love to help normally, but I have too many clients right now to take on more work. Good luck though.

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

    How can I have the actuator extent with power on and retract when power turns off.

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

      This type of actuator requires power to move either direction. They do make some some that have spring return that go back after power is off.

  • @user-wo8gq5me8d
    @user-wo8gq5me8d 6 місяців тому

    Hi! Hobbyist here, was wondering why when I received my L9110 that it didn't work with my 12VDC actuator and my adapter/power supply but I see now that you are working with a voltage-box etc and ramping down power to meet the ampage limits of your driver (still a little puzzled how the motor inside the actuator is running on half the voltage, but I digress).
    Since I don't have a 6v power supply is there any recreation of this with the L298N and a two wired actuator for the same kind of directional and speed control with 12VDC. Or might I be better off using a relay to do the same functions achieved here? Thanks!

    • @ScienceFunInnovations
      @ScienceFunInnovations  6 місяців тому

      My new favorite controller for linear actuators is the BTS7960. I can handle full 12V and heavy current loads. Works pretty much the same as the L9100, but can handle much more power. I use it in some of my later videos.

    • @user-wo8gq5me8d
      @user-wo8gq5me8d 6 місяців тому

      @@ScienceFunInnovations Thank you for the reply, yes actually at the same time you replied I found another of your videos where you're using a two-wire linear actuator with a 12v battery, L298N driver, so basically the same setup as me. The coding was where my issue was, it turns out! I was previously following some circuit that used the ENA pin, which you completely bypass in the video, and finally got my Arduino to trigger the actuator with just the two pins. But I will look into BTS7960 in the future.

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

    how can i calcul the mechanical couple of this actctr please ?

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

    Hello 👋🏽. So I'm trying to figure out a way to control 4 linear actuators at the same time. I want them to stay closed when there is no secondary 12volt source. When there is an external 12volt trigger I want the actuators to open. And as soon the secondary 12volt source drops I want the actuators to close again. Can you help me achieve this? I'm building a poor man's air brake setup... or better known as active areo. The actuators are connected to a spoiler on my car. I thought I could do this using 3 relays but my eyes go crossed when I try to figure out the wiring 🤣.

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

      If you are not trying to automate it, I would just use a reversible motor controller. This one could probably power all 4. amzn.to/3Br4vKo

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

      @@ScienceFunInnovations I really don't see this working for me but thanks.

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

    Hey I need some help setting up a linear actuator. Push button to extend, and then auto retract after extension, any way u can help me set this up? Thanks so much!

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

      Do you want to do it with or without an Arduino? You could do that with the right double poll switch. This video uses a button ua-cam.com/video/qLltghqVrvI/v-deo.html You could do something similar with a single button. Does this help?

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

      @@ScienceFunInnovations I’m gonna take a look at it tomorrow and I’ll let u know, thanks so much for responding. I’ll let u know tomorrow

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

      @@ScienceFunInnovations hi I saw that video, I don’t want to push a second button to retract the actuator. So it doesn’t matter to me whether I use arduino or not, I just want one button that I push once to extend the actuator, and then it automatically retracts after extension. Thanks so much for the help

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

      The easiest way would be to use a reversing switch. Try searching:
      DC Momentary Reversing Rocker Switch (double pole double throw)

  • @dark_family
    @dark_family 4 місяці тому

    sir can the l9110 handle 1A input current

    • @ScienceFunInnovations
      @ScienceFunInnovations  4 місяці тому

      It can only handle 0.8A. But other motor controllers in my other videos can handle much more. Hope this helps.

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

    Please explain duck clutch system for convert manual car clutch in automatic clutch

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

      I know people have used these for CVT transmissions, but it would be tricky to control a manual transmission.

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

      @@ScienceFunInnovations please explain ? What pcb they use and what kind of actuator if u have all
      Deatails kindly share

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

      @@ScienceFunInnovations sir if u have someone else project link(automatic clutch) please share the same

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

    Is there a way to code it so that It would stop? Using the L9110 ?

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

      Yes, just set both outputs to the same value, such as 0. This would hold it in place. Look for my next video in the next week or two on building a solar tracker. I will discuss this in more detail with example code. Thanks!

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

      @@ScienceFunInnovations Appreciate the immediate reply, thanks.

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

      @@weirdobros1415 just uploaded a similar video using a 3 button switch (extend, retract, and stop) ua-cam.com/video/qLltghqVrvI/v-deo.html

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

    Hello good afternoon. I am a handicapper and I want to turn an old Segway into a wheelchair, I have seen designs online and who sells them but they are very expensive so I decided to do my own project. I want to put two actuators as legs, but I don't know if there is a way that when they feel the force, when they touch the ground they will stop. If you can help me I will thank you.

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

      One way would be to put force sensitive resistors (FSR) on the ends of the legs. These can be connected to an Analog input pin on the Arduino to detect the change in force. Another way would be to put a current sensor on the power going to the actuator. The current going to the actuator will increase with the resistive force. If you monitor the current, you should see an increase once the actuators hit the ground. Hopefully this gives you some ideas. Good luck!

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

      Science Fun thank you. I will try it.

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

      Hello again, although I do not know about the subject, I was checking what he suggested to me to use a force sensitive resistors (FSR) for my project although I think after watching some videos that it would take more wiring than using a current sensor on the power going to the actuator, I mean, it would take the FSR to the tip of the kickstand and from there take the force emanating from the Actuator, what do you think? I would like if you were so kind and see in this video at minute 1:19 how the kickstands come out and tell me what do you think they could be using for the mechanics? something similar is what I want, but I can't buy a chair like that. Thanks in advance. Here I leave the link.
      ua-cam.com/video/LefWULvn98Q/v-deo.html&ab_channel=NinoSpain

  • @kremitontoast5344
    @kremitontoast5344 11 днів тому

    How would I be able to control a 24v actuator?

  • @AnandSingh-qy5pd
    @AnandSingh-qy5pd 3 роки тому +1

    How can we fetch it with ultrasonic sensor

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

      Are you looking to use the ultrasonic sensor for position feedback or just an event trigger? In my latest video I use an infrared sensor as an event trigger. Are you looking to do something like that with the ultrasonic sensor?

    • @AnandSingh-qy5pd
      @AnandSingh-qy5pd 3 роки тому

      @@ScienceFunInnovations Both of it.

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

    Any way to work for switch.

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

      Yes. Check out my other videos. There are many ways to control these.

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

      @@ScienceFunInnovations just an on/off switch? Off (not pushed) its retracted & press, it extracts?

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

    Can you fix for me i want to buy with you

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

    Nice video buddy!
    I want to make a standing desk using two linear actuators. This is the project I'm inspiring from: ua-cam.com/video/EXjR-o5gu2w/v-deo.html
    Using Arduino, I want to tell the linear actuators to lift the table to a certain height (standing position) by pressing one button and then pressing another button to tell them to go to the sitting height position. Which electronic components would I need? I'm kind of a noobie and don't know with certainty where to start...
    Thanks for being so helpful!

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

      I hope to do a linear actuator position video soon that would show what to do. But using two actuators can be tricky if one is a little faster than the other, your mechanism might bind up.