Design of brushless DC motor control system for electric motorcycle

Publisher:温暖微风Latest update time:2014-01-24 Source: 电子设计工程 Reading articles on mobile phones Scan QR code
Read articles on your mobile phone anytime, anywhere
    Brushless DC Motor (BLDCM) is a new type of motor that has matured with the development of new power electronic devices and permanent magnet materials. It belongs to the category of synchronous motors. It has the advantages of reliable operation of AC motors and superior speed regulation performance of traditional brushed DC motors. Therefore, it has a wide range of application prospects.
    With the continuous improvement of people's living standards and environmental awareness, new electric vehicles with the concept of "greening" development will be popular all over the world, and electric motorcycles will surely become one of the main means of transportation for humans. As a green and environmentally friendly vehicle, electric motorcycles using brushless DC motors have the advantages of simple operation, comfortable riding, convenient maintenance, low pollution and low noise.
    The PIC series of microcontrollers are high-performance and cost-effective 8-bit embedded controllers (Embedded Controller) that use reduced instruction set RISC technology, Harvard bus and two-level instruction pipeline structure. The electric motorcycle control system studied here is a system with PIC16F737 microcontroller as the core and brushless DC motor as the control object.

1 Implementation of the control system
   
The principle block diagram of the control system is shown in Figure 1.

a.JPG


    Main components:
    1) Main control module: It is composed of PIC16F737 microcontroller, +5 V power supply and peripheral auxiliary circuits.
    2) Input circuit: It is composed of position signal detection, current signal detection circuit, and handlebar brake signal acquisition circuit.
    3) Output circuit: It is composed of drive circuit and inverter circuit with IR2110 as the core.
    4) Protection circuit: It is composed of overcurrent protection circuit, overvoltage protection circuit and alarm circuit.
    Working principle: The microcontroller, as the control core, processes the position detection and current detection signals and outputs the corresponding PWM wave through the driver chip to drive 6 power field effect transistors. The three-phase full-bridge drive circuit composed of it controls the motor, so the motor can be controlled by three closed loops of position loop, speed loop and current loop. When the brake signal appears or the motor is blocked and the current exceeds the limit, the microcontroller immediately cuts off the inverter circuit; when the battery voltage is lower than the setting, the motor drive circuit is automatically cut off to prevent the battery from being over-discharged and damaged.
1.1 System hardware design
   

1)     The external interface circuit of the microcontroller of the main control module is shown in Figure 2. It mainly includes: current sampling, including instantaneous current sampling signal input connected to RA0 port, and average current sampling signal input connected to RA1 port; overcurrent protection interrupt request connected to RB0 port of the microcontroller; battery power detection signal connected to RB1 port, the acquisition voltage corresponding to 48 V voltage is 2.66 V, and the corresponding acquisition voltage is 2.1 V when it is lower than 40 V, and protection is required at this time; the throttle speed regulation analog input is connected to RB3 port, and the brake handle analog input is connected to RA2 port; additional function inputs include alarm and cruise, and the inputs are connected to RA5 port and RB2 port respectively; the three Hall rotor position sensor inputs Ha, Hb, and Hc signals are connected to RB7 port, RB6 port, and RB5 port respectively; the power switch tube drive output in the inverter circuit realizes electronic commutation and stepless speed regulation of the brushless motor.

b.JPG


    2) Input circuit
    ① The Hall signal input
    rotor position detection circuit has two functions in the system: detecting the relative position of the motor stator and rotor to provide the correct commutation signal for the inverter circuit; detecting the number of Hall pulse signals in a certain channel, calculating and converting them into speed signals to form a speed feedback link. The position signal sampling of this system is detected by the Hall element of the brushless DC motor itself. Since the Hall element is an open collector output, its output signal is passed through the pull-up resistor to obtain a position square wave signal, and then sent to the pins of the microcontroller (U2-29, U2-30, U2-31) through the isolation circuit to capture the position signal, as shown in Figure 3.

c.JPG


    ②Current detection circuit
    This current detection circuit is composed of two LM358 operational amplifiers, as shown in Figure 4. One of them constitutes a voltage comparator, which compares the detected current signal with the known voltage to obtain an overcurrent output signal. When the overcurrent occurs, the comparator flips to trigger the microcontroller interrupt, and the power switch tube is turned off in time to form a protection circuit. The internal current loop current is obtained through another in-phase proportional amplifier circuit composed of an LM358 operational amplifier, and after amplification, it is converted into a voltage signal proportional to the current and sent to the PA2 port of the microcontroller. [page]

d.JPG


    3) Output circuit
    ① Inverter circuit design
    The motor rotation is controlled by the position of the motor rotor sensed by the Hall sensor, which determines the order of opening or closing the power transistors in the inverter. As shown in Figure 5, AH, BH, CH (upper arm power transistors) and AL, BL, CL (lower arm power transistors) in the inverter make the current flow through the motor coil in sequence, generating a forward or reverse rotating magnetic field, and interacting with the magnetic field generated by the rotor magnet to make the motor rotate forward or reverse. When the motor rotor rotates to the position where the Hall sensor senses another set of signals, the control part turns on the next set of power transistors again, and the motor can rotate in this cycle.

e.JPG


    ②IR2110 drive circuit
    The IR2110 chip is a dual-channel, gate-driven, high-voltage and high-speed power device monolithic integrated drive module. As shown in Figure 6, it is a brushless DC motor drive circuit schematic (single bridge arm) composed of IR2110. This drive circuit uses a three-phase full-bridge inverter circuit composed of 6 N-channel MOSFET tubes with 3 IR2110 as the center. The upper bridge arm adopts PWM modulation control; the lower bridge arm adopts a fixed angle control method, thereby driving the brushless DC motor.

f.JPG


1.2 System software design
   
Software design is the core part of the entire control system design. It will directly determine the control quality and efficiency of the entire control system, and determine the characteristics of the system output signal, including current size and stability, harmonic content, protection function perfection, reliability, etc. The PIC chip is programmed and simulated in its special software development environment Mplab, which brings great convenience to developers in designing and debugging programs. The focus of the system software design is the main program and interrupt service program. The flow chart is shown in Figure 7. The main program realizes the initialization of various variables and chips, and the selection of two working modes: cruise mode and non-cruise mode; the interrupt service program includes over-current and under-voltage interrupt subroutines, A/D conversion interrupt service subroutines, and brake interrupt subroutines.

g.JPG



2 Conclusion The control system based on PIC16F737 designed in
   
the language has the characteristics of simple hardware structure, perfect protection function, modular software design, easy secondary development by users, strong system reliability, convenient debugging, etc. The innovation of this article is to realize the selection of two working modes of motor speed regulation and fixed speed, and realize the undervoltage protection and overcurrent protection of the system from two aspects of software and hardware. In actual application, the whole system starts smoothly, has strong load capacity, can realize fast and accurate speed regulation, and runs well on site.

Reference address:Design of brushless DC motor control system for electric motorcycle

Previous article:PIC microcontroller read/modify/write problems and solutions
Next article:Design of PIC16C72 single chip microcomputer in water level and temperature controller of solar water heater

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号