Since hybrid electric vehicles have two drive systems, the information exchange and coordination between the drive system and the vehicle control unit (VCU) is particularly important. CAN (Controller Area Network) bus is a serial communication network that effectively supports distributed control or real-time control. It belongs to the category of field bus and has the characteristics of strong real-time performance, high reliability, strong anti-interference, simple structure, good operability, and low price. Therefore, it is widely used in industrial control.
TMS320X24X is a series of chips designed by TI for digital motor control. Compared with TMS320C240 or TMS320F240 of the same series, TMS320F241 has a built-in CAN module in addition to the basic functions of the latter, so it is very suitable for the control of hybrid electric vehicle motor drive system.
1 Main features of TMS320F241
Compared with TMS320X240, TMS320F241 has the following differences besides an additional CAN module:
•The TMS320X240 has dual 10-bit A/D converters, 16 input channels, and a conversion time of 6μs; while the TMS320F241 has only one 10-bit A/D converter, 8 input channels, and a conversion time of 1μs.
•The event manager of TMS320X240 has 3 timers/counters, 4 capture units and 9 PWM outputs (6 Full PWM and 3 Simple PWM); while the event manager of TMS320F241 has only 2 timers/counters, 3 capture units and 6 PWM outputs (6 Full PWM), and the counting mode of the counter is also missing the single rising edge and single rising/falling edge modes.
TMS320F241 has 8K on-chip Flash and no extended RAM interface, so debugging is not very convenient. However, it can be debugged with the TMS320F243EVM board of the same series, and the program can be transplanted to the TMS320F241 chip with almost no modification.
2 Brushless DC Motor Control System Solution
Figure 1 is a block diagram of the motor system control, which uses conversion and current dual closed-loop control.
The rotor position is detected by the Hall element, which is three overlapping signals with a phase difference of 120 degrees (electrical angle) and a pulse width of 180 degrees (electrical angle). The speed can be obtained from the rotor position, and then the calculated value of the current can be obtained; the actual current can be detected by the current sensor, and the duty cycle of the PWM signal can be adjusted according to the difference between the current set value and the actual value, and the corresponding power switch device can be triggered according to the current rotor position, so as to achieve the purpose of controlling the motor speed.
The inverter uses an IPM intelligent power module, which contains power switching devices and drive circuits as well as process voltage, overcurrent and other detection circuits. The switching device is IGBT.
All functional modules in the motor control strategy (including ASR, ACR, PWM, commutation logic and speed calculation) are implemented by the TMS320F241 chip.
3 Peripheral Design of TMS320F241
Figure 2 is the main peripheral wiring diagram of the TMS320F241 chip. The relevant instructions are as follows:
A 5MHz crystal oscillator is connected between XTAL1 and XTAL2 to provide the system clock.
The pins CAP1, CAP2, and CAP3 of the three capture units are connected to the output of the Hall element, and the rotor position signal is stored in the buffer of the capture unit. The rotor speed can be obtained by calculation.
Among the 8-bit input channels of the A/D converter, 5 channels are used, and the input quantities are the DC bus current Idc, voltage Vdc and the motor three-phase currents Iu, Iv, and Iw; the other 3 channels are grounded through resistors.
The 6-way PWM output is connected to the control end of the six switching devices of the inverter, among which U+, V+, and W+ are connected to the upper bridge arm, and U- and VW- are connected to the lower bridge arm. These 6-way PWM signals control the opening and closing of the switching devices, thereby determining the flow path of the current.
The CAN module pins CANRX and CANTX of TMS320F241 are connected to the transceiver 82C250 through the optical coupler device 6N137, and the transceiver 82C250 is connected to the CAN bus through two pins CANH and CANL, thus realizing the communication between TMS320F241 and the CAN bus. Its communication medium uses twisted pair cable. If the communication distance is within 40m, the maximum transmission rate can reach 1Mbps.
4 CAN programming of TMS320F241
The CAN module of TMS320F241 is a FullCAN controller that can send and receive standard frames (11-bit identifiers) and extended frames (29-bit identifiers). It contains 6 mailboxes and 15 different 16-bit registers. These registers are divided into control registers, status registers, interrupt registers and local receive mask registers, which are mapped to the DSP data address space of 0x7100h~0x710Fh. Among the 6 mailboxes, there are two inboxes (numbered 0 and 1), two outboxes (numbered 4 and 5), and two mailboxes (numbered 2 and 3) that can be set as inboxes or outboxes as needed. Each mailbox contains three parts: identifier, information length, remote frame sending request, and data. The length of the data sent or received is 8 bytes. The 6 mailboxes occupy the address space of 0x7200h~0x722Fh.
To enable the TMS320F241 chip to send and receive information correctly, the CAN module must first be initialized. The bit transmission time of each node on the CAN bus is programmable (by setting the baud rate), but it must be the same. When a node receives a frame, the receiver must be synchronized with the transmitter. The steps for mailbox initialization are as follows:
(1) Disable the mailbox
CANMDER=00000000000000000000b
(2) Set up a change data request
CANMCR=0000000100000000b (bit8CDR=1)
(3) Change the mailbox identifier, control word and data (only the outbox can change the data)
(4) Return to normal mode
CANMCR=00000000000000000000b
(5) Enable mailbox (ME=1)
After initializing the CAN module and configuring it correctly, you can send and receive data information.
Figure 3 and Figure 4 are flow charts of the CAN module transmitting and receiving information, respectively.
From the above introduction, we can see that TMS320F241 is a DSP chip dedicated to motor control and embedded with CAN module. It can be used to conveniently control the speed of the permanent magnet brushless DC motor of hybrid electric vehicle (HEV). At the same time, using its embedded CAN module, it can communicate with the vehicle control unit (VCU) of the hybrid electric vehicle through the CAN bus (protocol specification CAN2.0). Therefore, it is very suitable for the control system of permanent magnet brushless DC motor of hybrid electric vehicle.
Previous article:Classification and process of electronic police
Next article:Application of TMS320F2812 in Vehicle Four-Wheel Steering Control System
- Popular Resources
- Popular amplifiers
Professor at Beihang University, dedicated to promoting microcontrollers and embedded systems for over 20 years.
- Innolux's intelligent steer-by-wire solution makes cars smarter and safer
- 8051 MCU - Parity Check
- How to efficiently balance the sensitivity of tactile sensing interfaces
- What should I do if the servo motor shakes? What causes the servo motor to shake quickly?
- 【Brushless Motor】Analysis of three-phase BLDC motor and sharing of two popular development boards
- Midea Industrial Technology's subsidiaries Clou Electronics and Hekang New Energy jointly appeared at the Munich Battery Energy Storage Exhibition and Solar Energy Exhibition
- Guoxin Sichen | Application of ferroelectric memory PB85RS2MC in power battery management, with a capacity of 2M
- Analysis of common faults of frequency converter
- In a head-on competition with Qualcomm, what kind of cockpit products has Intel come up with?
- Dalian Rongke's all-vanadium liquid flow battery energy storage equipment industrialization project has entered the sprint stage before production
- Allegro MicroSystems Introduces Advanced Magnetic and Inductive Position Sensing Solutions at Electronica 2024
- Car key in the left hand, liveness detection radar in the right hand, UWB is imperative for cars!
- After a decade of rapid development, domestic CIS has entered the market
- Aegis Dagger Battery + Thor EM-i Super Hybrid, Geely New Energy has thrown out two "king bombs"
- A brief discussion on functional safety - fault, error, and failure
- In the smart car 2.0 cycle, these core industry chains are facing major opportunities!
- Rambus Launches Industry's First HBM 4 Controller IP: What Are the Technical Details Behind It?
- The United States and Japan are developing new batteries. CATL faces challenges? How should China's new energy battery industry respond?
- Murata launches high-precision 6-axis inertial sensor for automobiles
- Ford patents pre-charge alarm to help save costs and respond to emergencies
- Are old tools better? Or are you just lazy?
- Smart car based on ESP32 road sign recognition
- Please recommend a cheap and available microcontroller
- Seven lines of code to implement an ultrasonic rangefinder (Oled screen display)
- NuMicro M0516-PC Communication Protocol
- New forum feature: Post by uploading a word document (good news for those who like to post a lot of pictures)
- A new version of micro:bit (V2) will be released soon
- What is this error?
- Have my friends in Beijing grabbed any Winter Olympics souvenirs?
- Where are my favorite articles? Where are the collectors?