How to control a DC motor with an encoder
GitHub Code (under /encoderControl):
https://github.com/curiores/ArduinoTutorials
If your platform does not have access to "atomic.h" (and so you get an error message), you can use the alternative version of the code that has been uploaded to the repository. It is labeled "_NoAtomic".
An encoder makes it possible to control the position of a DC motor. In this video, I illustrate how an encoder works, and then use a PID control algorithm to control the motor position. All of the steps are included so that you will be easily able to make the system yourself.
Parts used in this video:
1. DC Motor - 19:1 Metal Gearmotor 37Dx68L mm 12V with 64 CPR Encoder:
https://www.pololu.com/product/4751
2. Motor Driver - TB67H420FTG Dual/Single Motor Driver Carrier:
https://www.pololu.com/product/2999
3. Microcontroller - Arduino Uno:
https://store.arduino.cc/usa/arduino-uno-rev3
(okay actually I used an Elegoo Uno, but the Arduino descriptions are better :)
Видео How to control a DC motor with an encoder канала Curio Res
https://github.com/curiores/ArduinoTutorials
If your platform does not have access to "atomic.h" (and so you get an error message), you can use the alternative version of the code that has been uploaded to the repository. It is labeled "_NoAtomic".
An encoder makes it possible to control the position of a DC motor. In this video, I illustrate how an encoder works, and then use a PID control algorithm to control the motor position. All of the steps are included so that you will be easily able to make the system yourself.
Parts used in this video:
1. DC Motor - 19:1 Metal Gearmotor 37Dx68L mm 12V with 64 CPR Encoder:
https://www.pololu.com/product/4751
2. Motor Driver - TB67H420FTG Dual/Single Motor Driver Carrier:
https://www.pololu.com/product/2999
3. Microcontroller - Arduino Uno:
https://store.arduino.cc/usa/arduino-uno-rev3
(okay actually I used an Elegoo Uno, but the Arduino descriptions are better :)
Видео How to control a DC motor with an encoder канала Curio Res
Показать
Комментарии отсутствуют
Информация о видео
Другие видео канала
How Rotary Encoder Works and How To Use It with ArduinoOne axis PID encoded DC motor controlWhat is the Difference between Absolute and Incremental Encoders?DC motor PID speed controlHow PWM works | Controlling a DC motor with a homemade circuitRotary encoder or: How to build a digital servo using an Arduino and photo sensorsWhat is Encoder?What is an ENCODER - Linear and Rotary encoder - Incremental and Absolute encoderBig Stepper Motors with ArduinoUsing Rotary Encoders with ArduinoCOMPREHENSIVE: PID CONTROLLER for DC MOTOR with Timer Interrupts and Anti-windupUnderstanding PID Control, Part 1: What Is PID Control?Rotary encoder - sensor arrangementMicrocontrolled DIY pinch valvesHow to use encoders (Optical, Hall Effect, Quadrature)Controlling DC Motors with the L298N H Bridge and ArduinoWhat is a Servo Motor and How it Works?Best code to use with a KY-040 Rotary Encoder? Let's find out!Control Large Gearmotors with PWM & ArduinoYou can learn Arduino in 15 minutes.