20: Driving of DC Motor

Publisher:知者如渊Latest update time:2019-08-13 Source: eefocus Reading articles on mobile phones Scan QR code
Read articles on your mobile phone anytime, anywhere

Write the picture description here

DC

DC motor is one of the main types of motors. Due to its good speed regulation performance, it is widely used in many occasions with high speed regulation performance requirements. DC motors are also widely used in electronic production.
Write the picture description here

When the load is constant, the greater the average current flowing through the DC motor, the greater the torque generated, and thus the faster the speed of the DC motor; when the current is constant, the greater the load, the slower the speed of the DC motor.

Write the picture description here

#Drive of DC motor
1. Linear amplifier drive
The linear driver is actually a linear power amplifier, and the principle is as follows. The control signal output by the processor is converted into a voltage signal by D/A, and the driver performs linear power amplification on this signal and provides it to the motor. Since the current and voltage drop passing through the driver are relatively large, the biggest disadvantage of this driving method is high power consumption and low efficiency. However, since there is no high-frequency switching action in the linear power amplifier, the output voltage is stable, and compared with switching drive methods such as PWM, the electromagnetic noise and interference are much smaller.
Write the picture description here
2. Switching driver

Switch drive uses the switching action of high-power transistors to convert the constant DC power supply voltage into a certain square wave voltage and add it to the motor pivot. Different from the linear drive mode, in this drive mode, the power tube of the driver works in a switching state. When the device is turned on, the current of the device is large but the voltage drop is small; when the device is turned off, the voltage drop is large but the current is small. Therefore, the driver has low power consumption, low heat generation and high efficiency. By controlling the frequency and pulse width of the switch, the rotation of the motor can be controlled.
Write the picture description here

#DC motor switch drive circuit
There are two main types of DC motor switch drivers, T-type irreversible driver and H-type reversible driver
Write the picture description here

Principle explanation to be supplemented!

experiment

Write the picture description here

#Code

* 【Course 21】 ****DC Motor Experiment***********

*

* 【illustrate】 ****

*

* 【Description】 ****Realize the forward, reverse and stop of the motor.

*

**********************************************************************/

#include //51 header file,


//---------Two commonly used macro definitions-------------- 

#define uint8 unsigned char

#define uint16 unsigned int


sbit Motor_A = P1^0;

sbit Motor_B = P1^1;


sbit Key1 = P3^0; //Forward

sbit Key2 = P3^1; //Reverse

sbit Key3 = P3^2; //Stop



//------------Function declaration-----------------

void DelayMS(uint16 dly);


void main(void)

{

while(1)

{

/*if(Key1==0) //Forward

{

Motor_A = 0;

Motor_B = 1;

}

else if(Key2==0) //Reverse

{

Motor_A = 1;

Motor_B = 0;

}

else if(Key3==0) //Stop

{

Motor_A = Motor_B = 0;

}

*/

Motor_A = 0;

Motor_B = 1;

DelayMS(9);

Motor_A = 0;

Motor_B = 0;

DelayMS(1);

}

}


/********************************************************

** Name: void DelayMS(uint16 dly)

** Function: millisecond delay (24M crystal oscillator)

** Input parameter: dly

User delay parameters   

** Export parameters: None   

*************************************************************/

void DelayMS(uint16 dly)

{

uint16 x,y;

for(x=dly;x>0;x--)

for(y=247;y>0;y--);

}


Reference address:20: Driving of DC Motor

Previous article:199: Temperature reading of DS18B20
Next article:21: EEPROM Operation

Latest Microcontroller Articles
  • Download from the Internet--ARM Getting Started Notes
    A brief introduction: From today on, the ARM notebook of the rookie is open, and it can be regarded as a place to store these notes. Why publish it? Maybe you are interested in it. In fact, the reason for these notes is ...
  • Learn ARM development(22)
    Turning off and on interrupts Interrupts are an efficient dialogue mechanism, but sometimes you don't want to interrupt the program while it is running. For example, when you are printing something, the program suddenly interrupts and another ...
  • Learn ARM development(21)
    First, declare the task pointer, because it will be used later. Task pointer volatile TASK_TCB* volatile g_pCurrentTask = NULL;volatile TASK_TCB* vol ...
  • Learn ARM development(20)
    With the previous Tick interrupt, the basic task switching conditions are ready. However, this "easterly" is also difficult to understand. Only through continuous practice can we understand it. ...
  • Learn ARM development(19)
    After many days of hard work, I finally got the interrupt working. But in order to allow RTOS to use timer interrupts, what kind of interrupts can be implemented in S3C44B0? There are two methods in S3C44B0. ...
  • Learn ARM development(14)
  • Learn ARM development(15)
  • Learn ARM development(16)
  • Learn ARM development(17)
Change More Related Popular Components

EEWorld
subscription
account

EEWorld
service
account

Automotive
development
circle

About Us Customer Service Contact Information Datasheet Sitemap LatestNews


Room 1530, 15th Floor, Building B, No.18 Zhongguancun Street, Haidian District, Beijing, Postal Code: 100190 China Telephone: 008610 8235 0740

Copyright © 2005-2024 EEWORLD.com.cn, Inc. All rights reserved 京ICP证060456号 京ICP备10001474号-1 电信业务审批[2006]字第258号函 京公网安备 11010802033920号