Design of Vehicle Control Unit Based on DSP for a Parallel HEV

3 downloads 2860 Views 237KB Size Report
Department of Automation, Shanghai JiaoTong University. ShangHai ... Email: [email protected] ... International Conference on Automation and Logistics.
Proceedings of the IEEE International Conference on Automation and Logistics August 18 - 21, 2007, Jinan, China

Design of Vehicle Control Unit Based on DSP for a Parallel HEV∗ Weimin Li

Guoqing Xu

Department of Automation, Shanghai JiaoTong University ShangHai,P.R.C. 200240 Department of MAE, The Chinese University of Hong Kong Shatin, N.T., Hong Kong Email: [email protected]

Department of Electrical Engineering, TongJi University Shanghai, P.R.C. 200331 Shenzhen Institute of Advanced Integration Technology, CAS/CUHK, Shenzhen,P.R.C. 518067 Email:[email protected]

Hang Tong

Yangsheng Xu

Department of MAE, The Chinese University of Hong Kong Shatin, N.T., Hong Kong Email: [email protected]

Abstract— This paper presents a DSP based vehicle control unit (VCU) for hybrid electric vehicle (HEV). Digital Signal Processor (DSP) based real time controller plays a key role in HEV system operation. It provides an efficient platform to run complex optimization algorithms for energy management strategy. First, the hardware design of VCU is introduced in detail. Then software design of VCU and C code automatic generation technical based on RTW are discussed. A flexible and configurable method is described to automatically deploy the Simulink-model into the VCU. Experimental results have demonstrated the reliability of hardware design and flexibility of software design of the proposed VCU. Index Terms— hybrid electric vehicle, DSP TMS320F2812, automatic code generation

Department of MAE,The Chinese University of Hong Kong Shatin, N.T., Hong Kong Shenzhen Institute of Advanced Integration Technology CAS/CUHK,Shenzhen, P.R.C. 518067 Email: [email protected] regenerative braking during deceleration and allows efficient motor assist and recharge operations by the engine [3]. Hybrid electric vehicle are composed of several subsystems,

I. INTRODUCTION Hybrid electric vehicles have been widely studied in recent years because of their potential to significantly improve fuel economy and reduce emissions without sacrificing vehicle performance. It combines an internal combustion engine (ICE) and electric motor (EM) together with an energy storage that can each act independently or in combination. Adding an additional degree of freedom, the hybrid powertrain can improve fuel economy by operating ICE in the optimum efficiency range and by making use of regenerative braking during deceleration [1]-[2]. In the specific parallel hybrid architecture shown in figure.1, the powertrain integrates an engine, an electric traction motor/generator, Ni-Hi batteries, an automatic clutch, and an automated manual transmission system. The motor is directly linked between the output of the master clutch and the input to the transmission. This architecture provides the ∗ This work was supported by the Innovation Technology Fund of the Hong Kong Special Administrative Region.

1-4244-1531-4/07/$25.00 © 2007 IEEE.

Fig. 1.

Schematic of the parallel hybrid electric vehicle drivetrain.

such as vehicle control unit (VCU), engine, transmission, motor/ generator and Ni-Hi battery. VCU collects signals from driver operation unit and receives relative information transferred by each subsystem controller. According to energy management strategy, VCU coordinates the operation of vehicle subsystems to achieve performance targets such as maximizing fuel economy and reducing exhaust emissions. Therefore, VCU is the kernel of hybrid electrical vehicle system. Its capability will directly affect reliability and performance of HEV. The focus of this paper will be to describe the design of VCU for a parallel HEV. The remainder of this paper is organized as follows: Section 2 describes hardware design of VCU based on DSP TMS320F2812 in detail. The software design

1597

Signal conditioner

A. Overview of VCU The selection of main chip should meet requirements of complex algorithm operation. In our design, energy management strategy, the core part of vehicle control unit, is designed using graphical model-based development environments, Matlab/Simulink/Stateflow, which provides a convenient environment to adjust control algorithms. The model can be converted to C code automatic through RTW and then download to flash memory of VCU. The rapid prototyping and the automatic code generation not only reduce the development time, but also greatly enhance the code quality and reliability. Texas Instruments DSP TMS320F2812 is selected as the main chip of VCU. It has the following features: – 150 MHz, 150 MIPS, 32-bit fixed point digital signal processor, which can provide adequate computational performance. – Equipped with 16K RAM, 128K bytes FLASH. This should be sufficient so that no external memory is required in VCU. – 16 circuit 12 digit high-speed ADC, 16 circuit PWM output, 56 circuit digital I/O and three 32bit CPU timers, built-in WATCHDOG and JTAG debug interface. A combination of integrated function modules makes it especially suitable for electrical motor and other industry controls. – Enhanced Controller Area Network (eCAN), 32 mailboxes and two Serial Communications Interfaces (SCI), Standard UART. This allows rapid communication with subsystem controllers and information exchange with display monitor. Additionally, TMS320F2812 supports C/C++ compiler, hence enabling users to develop not only their system control software in a high-level language, but also complicate math algorithms using C/C++. The TMS320F2812 is as efficient in DSP math tasks as it is in system control tasks that typically are handled by microcontroller devices. So that it is very suitable to develop a fully digital controller and a complicated intelligent control algorithm in HEV control.The control signal flow in VCU is shown in figure.2.

Fig. 2.

Drive Circuit

Signal conditioner

II. H ARDWARE DESIGN OF VCU BASED ON DSP

DSP TMS320F2812

Signal conditioner

and automatic code generation technical based on RTW are introduced in section 3. At last, conclusions are drawn in section 4.

Control signal flow in VCU.

vehicle. This has a direct affect to signal collection. Before all of these signals are connected TMS320F2812, they should be modulated by interface circuits, and some measurements are be taken to anti-vibration. The vehicle speed is measured by Hall Effect sensor which is also supplied power by 12V battery in vehicle. It’s a standard square waveform except its value. It can be read into TMS320F2812 from CAP1, and speed value is acquired by calculating. Because battery voltage has plus or minus at different time, and TMS3202812 can accept 0–3.3V analog signal, the vehicle speed signal have to be modulated, before it is been connected to CAP1 pins of DSP. Figure.3 shows the circuit of signal modulation. After modulation, the signal is rectified to 0-5V range, then we can use a 5V–3.3V voltage convert chip to transfer it to 0–3.3V.

Fig. 3.

Interface circuit of I/O input and vehicle speed signals.

C. Digital output and Relay control B. I/O and wheel speed Signal Measuring and Modulation Circuits The controller need measuring vary type signals, such as digital signals, analog signals, and square waveform signal. In the vehicle’s electrical control system, some switch signals are supplied power by 12V battery in vehicle. But the voltage of battery is not stable. For example, the voltage may be high to 14–16V, whereas it will decrease greatly when starting the

In VCU we need to output digital signals to control some outside devices, such as engine stop,air conditioner,DC/DC control and so on. The BTS724 is a four channel high-side switch designed for solenoid control in harsh automotive applications, but is well suited for other environments. The device can also be used to control all types of resistive, inductive and capacitve loads, most suitable for loads with high inrush currents. It can replace electromechanical relays,

1598

fuses and discrete circuits. BTS724 can provide multi protections, such as short circuit protection, overload protection, current limitation, thermal shutdown, overvoltage protection (including load dump) with external resistor and reverse battery protection with external resistor. In addition, it also possess some diagnosis function and can provide diagnosis information to VCU. The use of integration chip not only simplify the design of VCU but also enhance its reliability.The schematic of relay control circuit is shown in figure.4. +5V

+12V

Fig. 5.

Schematic diagram of CAN interface circuit.

+5V

Start Initialization

P1.1 P1.2

3 4 5

P1.3 P1.4 P1.5

7 8 9

P1.0

18

IN1 ST1/2 IN2

OUT1 OUT2

17

IN3 ST3/4 IN4

OUT3

14

OUT4 2

6

13

Self dection

Relay1 Relay2

High voltage connection

Relay3 Relay4

Signals sample and process

BTS724

GND

Fig. 4.

Malfunction diagnosis

Schematic of BTS724 drive circuit.

D. The Interface Circuit of CAN Bus The controller area network (CAN) uses a serial multimaster communication protocol that efficiently supports distributed real-time control with a very high of data integrity and communication speeds of up to 1 Mbps. The CAN bus is ideal for applications operating in noisy and harsh environments, such as in the automotive and other industrial fields that require reliable communication. The ECUs involved in HEV system are also connected by CAN bus. TMS320F2812 is equipped with enhanced Controller Area Network (eCAN) module which is compatible with the CAN 2.0B standard (active). With 32 fully configurable mailboxes and time-stamping feature, the eCAN module provides a versatile and robust serial communication interface. The TMS320F2812 controller needs a connection to a transceiver to be attached to the CAN bus. In our design ,we use SN65HVD230 as the transceiver. To enhance the capability of anti-jamming, a high speed optical isolation 6N137 is usually used to realize electric isolation between the VCU and outside circuit. Figure.5 shows a schematic diagram of CAN interface circuit. III. S OFTWARE DESIGN AND AUTOMATIC CODE GENERATION

Figure.6 shows the main programme flowchart of controller. Software of VCU can be divided into 2 parts. One

High voltage power management

Malfunction process

Energy management strategy, Run finite state machine to decide proper operation state Compute optimal torque distribution between engine and motor HCU output control signals to each subsystem

Stop Fig. 6.

Main programme flowchart of VCU.

is signals collections, CAN communication and interrupt service subprogram. The other is the design of energy management strategy, which is core task in HEV control. A. Energy Management Strategy Energy management strategy is the core of software design. Usually, the operating mode of HEV is divided into different states. A collection of all possible operating modes of the vehicle and their meaning is listed in table I. Due to the multi operating modes and complexity of states

1599

TABLE I COLLECTION OF HEV OPERATION MODES

VSC State

Engine

Clutch

Motor

OFF

Engine Off

Disengaged

Off

Vehicle off state

Description

MOTOR DRIVE

Engine Off

Disengaged

Tractive Force

Motor Propelling the vehicle

REGEN

Engine Off

Disengaged

Generating

Regenerative Braking

ENGINE DRIVE

Engine On

Engaged

Off

Engine propelling the vehicle

BOOST

Engine On

Engaged

Tractive Force

Engine and motor both propelling the vehicle

CHARGING

Engine On

Engaged

Generating

Engine propelling the vehicle and charging the battery

ENGING STOP

Engine Off

Disengaging

Tractive Force

Motor propelling the vehicle and stopping the engine

ENGINE START

Engine On

Engaging

Tractive Force

Motor propelling the vehicle and starting the engine

BLEEDING

Engine On

Engaged

Tractive Force

Engine and motor both propelling the vehicle, but motor output torque at its most, the engine supplement the rest.

ENG_STARTED_FLAG &BOOST_FLAG &|KEY_OFF_OR_STALL_FLAG

ENG_STARTED_FLAG &CHARGE_FLAG &|BOOST_FLAG &|KEY_OFF_OR_STALL_FLAG

Engine_start

[BOOST_FLAG &|KEY_OFF_OR_STALL_FLAG

Charge

Boost

[CHARGE_FLAG &|SA_DISABLED_FLAG &(DISALLOW_EN_MGT_FLAG ||MAX_SOURCE_CURRENT_ZERO_FLAG) &|KEY_OFF_OR_STALL_FLAG [BOOST_FLAG &|REGEN_FLAG &|KEY_OFF_OR_STALL_FLAG &|BOOST_REQUEST_FLAG &|SA_DISABLED_FLAG REGEN_FLAG &DISALLOW_EN_MGT_FLAG &(ENG_RESTART_OKAY_FLAG &|MAX_SOURCE_CURRENT_ZERO_FLAG |||SA_DISABLED_FLAG) (CHARGE_OFF_FLAG &|KEY_OFF_OR_STALL_FLAG |||CHARGE_ENABLE_FLAG ||SA_DISABLED_FLAG) &|ENERGY_MGT_FLAG DISALLOW_BOOST_FLAG &|KEY_OFF_OR_STALL_FLAG &|ENERGY_MGT_FLAG &(|REGEN_FLAG [(soc>soc_hi_limit &|KEY_OFF_OR_STALL_FLAG ||SA_DISABLED_FLAG) &trq_veh>=0 &|BOOST_FLAG &trq_veh123]

[ENG_STARTED_FLAG &|BOOST_FLAG &|CHARGE_FLAG &|KEY_OFF_OR_STALL_FLAG &|BLEEDING_FLAG

[[BRAKE_SWITCH &TRANS_ENGAGED &|REGEN_FLAG] [(ENG_ON_FLAG ||(IDLE_CRANK_FLAG& |REGEN_FLAG &(|BRAKE_SWITCH || |TRANS_ENGAGED))) & |FLG_SHIFTIN &|SA_DISABLED_FLAG &|KEY_OFF_FLAG

REGEN_FLAG &|SA_DISABLED_FLAG &|KEY_OFF_FLAG

Battery_drive

Regen REGEN_FLAG &|SA_DISABLED_FLAG &|KEY_OFF_FLAG

REGEN_FLAG &(ENG_RESTART_OKAY_FLAG |||SA_DISABLED_FLAG) &|KEY_OFF_OR_STALL_FLAG

Engine_drive

[(|REGEN_FLAG &(L_FLAG||VS_ENG_DRV_FLAG)) ||(SA_DISABLED_FLAG &|ENG_RESTART_OKAY_FLAG)] &|KEY_OFF_OR_STALL_FLAG

KEY_CRANK_FLAG &|CRANK_INH

|REGEN_FLAG &|KEY_OFF_FLAG &|SA_DISABLED_FLAG &(ENG_STOPPED_FLAG ||BRAKE_SWITCH)

BLEEDING_FLAG &ENG_STARTED_FLAG &|BOOST_FLAG &|CHARGE_FLAG &|KEY_OFF_OR_STALL_

REGEN_FLAG &|KEY_OFF_FLAG &|SA_DISABLED_FLAG &(ENG_STOPPED_FLAG ||BRAKE_SWITCH)

|BLEEDING_FLAG &|ENERGY_MGT_FLAG &|KEY_OFF_OR_STALL_FLAG &|BOOST_FLAG BLEEDING_FLAG &|CHARGE_FLAG &|DISALLOW_EN_MGT_FLAG &|KEY_OFF_OR_STALL_FLAG

ENERGY_MGT_FLAG ||KEY_OFF_OR_STALL_FLAG

Engine_stop

BOOST_FLAG &|KEY_OFF_OR _STALL_FLAG

Bleeding

ENERGY_MGT_FLAG ||KEY_OFF_OR_STALL_FLAG

Fig. 7.

HEV operation mode transitions based on Matlab/Stateflow.

transitions, a finite state machine model that describes the HEV system’s state transitions is developed for a simulation first [4]. MATLAB/simulink/Stateflow is a graphical design tool for modeling and simulating event driven systems. In particular, Stateflow and Simulink provide powerful capabilities for verification and validation of a model’s behavior, such as a flexible debugger and support of state-transition animation. Therefore, it is easy to consider various scenarios and iterate until the Stateflow diagrams and the simulation results perform the desired behavior. Transitions between

different operating modes are shown in figure.7. B. C Code Automatic Generation from Stateflow Compared with a conventional development process, simulation-based development avoids implementation errors, enables an early behavior check.A second objective was not only to simulate the system but to generate code for the VCU without any further hand-coding. This, the so called Automatic Code Generation, is widely tested and applied especially in automotive applications [5].

1600

The MATLAB environment provides special libraries for MATLAB

SIMULINK

DSP2812 Library

Model.mdl System.tmf (DSP.tmf)

Real Time Workshop

Model.rtw TLC system file Target Language (DSP2812.tlc) Compiler TLC block files TLC function library Model.c Model.h Model_types.h Model_private.h Model_main.c Model_macros.h Make

Code Composer Studio

DSP Terminal

DSP2812 Board

Fig. 8. C code automatic generation process based on MATLAB/RTW and DSP TMS320F281.

automated code generation of simulink/stateflow models supporting selected families of Texas Instruments, Inc., Motorola, Inc. and Xilinx, Inc., devices. Code generation for simulink models is based on the Real-Time Workshop (RTW). Real-Time Workshop is a powerful and applicable tool that enables automatic C code generation from the simulink model [6]. Generated code is well optimized and it’s comparable with the hand written code. The process of C code automatic generation process is shown in figure.8. IV. CONCLUSION This paper has implemented VCU for a parallel HEV based on DSP TMS320F2812 from TI Company. Hardware design and software flowchart are given in details. An energy management strategy based on finite state machine and MATLAB/Stateflow tools is introduced together with C code generation technical, which provides an intact process of VCU design. A prototype is setup and experiment result proves the excellent performance of the presented VCU. V. ACKNOWLEDGMENTS The authors would like to thank Automation Dept, ShangHai JiaoTong University and MAE Dept, the Chinese University of HongKong for their helpful support and constant encouragement. R EFERENCES [1] Anthony M. Phillips, Miroslava Jankovic, and Kathleen E. Bailey , ”Vehicle System Controller Design for a Hybrid Electric Vehicle”, Proceedings of the 2000 IEEE International Conference on Control Applications Anchorage, Alaska, USA September 25-27, 2000

1601

[2] Gregory A. Hubbard, Kamal Youcef Toumi, ”System Level Control of a Hybrid-Electric Vehicle Drivetrain”, Proceedings of the American Control Conference Albuquerque, New Mexico June 1997. [3] Chan-Chiao Lin, Huei Peng and Jessy W. Grizzle, ”Control System Development for an Advanced-Technology Medium-Duty Hybrid Electric Truck”, International Truck Bus Meeting Exhibition, Fort Worth, TX, November 2003. [4] Weimin Li, Guoqing Xu, Zhangcheng Wang, Yangsheng Xu,”A Hybrid Controller Design For Parallel Hybrid Electric Vehicle”, IClT 2006, ShenZhen, China. [5] AndreM Wagener, Peter Seger, Christian Koerner, Herbert Kabza, ”Simulation-Based Automatic Code Generation for ECUs in Distributed Control Systems, Applied in a Testbed for a Hybrid Vehicle Drivetrain”, ISIE’2000, Cholula, Puebla, Mexico. [6] [6] Darko Hercog, Milan Curkovic, Gregor Edelbaher, Evgen Urlep, ”Programming of the DSP2 board with the Matlab/Simulink”, IClT 2003, Maribor. Slovenia.

Suggest Documents