Vous êtes sur la page 1sur 5

PSoC Implementing Vehicle Auxiliary Vacuum Brake System with Kalman Filter

Chia-Chang Tong, Yau-Jeng Tsai, Shih-Fan Li, Jhih-Yu Lin, Ming-Han Ho, Yu-Hao Lin
Department of Electrical Engineering Chien-Kuo Technology University Changhua, Taiwan willtong@ctu.edu.tw,
AbstractA compact, reliable, and robust auxiliary vacuum brake system has been implemented by utilizing a programmable system-on-chip (PSoC). All the circuit elements in this control system are integrated into one chip without any external electronic components. Circuit as well as system is compact in size and concise in design. Also, Kalman filter algorithm is employed and implemented within PSoC chip by software to surpass the noises and disturbances from hostile surrounding in the vehicle. A prototype has been built and tested. Test results have confirmed that the performance of Kalman filter is better than that of low-pass filter. Furthermore, Kalman filter is capable of dealing with noises and disturbances from vacuum pump and other sources while low-pass filter is not.

brake booster. (b) Provide the brake function when engine is not operating. (c) Assist the engine inlet manifolds in case the engine is under heavy loads or vehicle is descending steep grades, etc. However, there are two major problems [2]. Firstly, sensor and controller system circuits are bulky. Secondly, the noisy surroundings impose difficulties upon design. II. PROBLEM FORMULATION

In order to implement a compact, reliable, and robust auxiliary brake system to overcome these difficulties stated in previous section, a system-on-chip implementation of auxiliary vacuum brake system with Kalman filter is proposed to overcome these issues. The system block diagram of Key Words: Programmable System-on-chip (PSoC), Auxiliary proposed control system is illustrated in Fig. 1. The pressure Vacuum Brake System, Kalman Filter. of vacuum chamber is observed by a pressure sensor via the pipe. Sensor signal is processed by a programmable SoC chip. I. INTRODUCTION Control strategy is made by the micro-processor through The hydraulic brake system of vehicles comprises six parts: Kalman filter and hysteresis controller algorithm to engage the a brake pedal, a power brake booster, a master cylinder, electric auxiliary vacuum pump. The purpose is to maintain hydraulic lines, wheel cylinders, disc brakes and/or drum the pressure of the vacuum chamber between 300 mm-Hg and brakes [1][2]. When the brake pedal is activated, the power 420 mm-Hg. Hence, the hydraulic brake system is always brake booster multiplies the force and pushes the master working in the best performance range. cylinder to engage the pressured hydraulic fluids to wheel cylinders through hydraulic lines [3]. This force then is applied to disc brakes and/or drum brakes to generate a braking torque for the vehicle. It is well-known that the power brake booster utilizes the pressure difference between the vacuum chamber and working chamber providing pneumatic boosting to enhance the force from the brake pedal. The vacuum sources of vacuum chamber may come from inlet manifolds of engine or vacuum pump driven by either engine or electricity. An auxiliary vacuum pump is provided to ensure the vacuum power. Normally, the auxiliary vacuum pump is only occasionally activated when the pressure of vacuum is reaching run-out [2]. Yet, it is better to play an active role and manipulate the auxiliary vacuum pump to keep the pressure difference within a range for good braking force. Figure 1. Structure of auxiliary vacuum brake system There are some advantages in this way: (a) Ensure the brake force without further increase the size and weight of power

978-1-4244-2342-2/08/$25.00 2008 IEEE.

77

A PSoC CY8C29466 chip is chosen to integrate the sensor conditioning, ADC, Kalman filter, controller circuits all in single system-on-chip IC. Eliminate the bulky circuit space and immunize the control system from circuit layout problems and component variations. The reliability of the system can be secured. Also, Kalman filter is implemented in the PSoC chip to surpass the noisy surroundings. Kalman filter is an optimal estimator to evaluate the internal state of a dynamic system under certain patterns of process and/or measurement disturbances presented in the physical world. There are many successful applications, including target tracking in interactive computer graphics, navigation, adaptive controls, radar signal processing, etc [4]-[9]. All of these applications have one thing in common, dealing with uncertainty. Therefore, Kalman filter is the best choice to resolve the noise problems in this application. III. METHEDOLOGY

measurement and a measurement prediction with a weighted gain K as shown below x k = x k + K ( z k Cx k ) (8)

In order to find a suitable gain K that minimizes the a posteriori error covariance in (7). This minimization can be accomplished by first substituting (8) into the above definition for ek, substituting that into (7), performing the indicated expectations, taking the derivative of the trace of the result with respect to K, setting that result equal to zero for finding minimum, and then solving for K. One form of the resulting K that minimizes (7) is given by
K = Pk C T (CPk C T + R ) 1

(9)

A. Discrete Kalman Filter Algorithm The probabilistic filtering problem in the Kalman sense can be formulated in this manner [10]. Consider the statespace model of a linear discrete time dynamical system according to:
xk = Axk 1 + Buk 1 + wk 1 yk = Cxk z k = Cxk + vk

(1) (2) (3)

The Kalman filter estimates a process by using a form of feedback control: the filter estimates the process state at some time and then obtains feedback in the form of noisy measurements. As such, the equations for the Kalman filter fall into two groups: time update equations (prediction) and measurement update equations (estimator). The time update equations are responsible for projecting forward (in time) the current state and error covariance estimates to obtain the a priori estimates for the next time step. The measurement update equations are responsible for the feedbacki.e. for incorporating a new measurement into the a priori estimate to obtain an improved the a posteriori estimate. B. Programmable System-on-Chip (PSoC) In order to implement the peripheral devices and execute the Kalman filter algorithm and hysteresis controller of digital signal processing in one chip, the CY8C29466 Programmable System-on-Chip (PSoC) from Cypress is selected [11][12]. This chip is one of the best choices in the market. PSoC is a mixed-signal array with on-chip controller component. This device is designed to replace multiple traditional MCU-based system components with one, low cost single-chip programmable components. It includes configurable blocks of analog and digital hardware components as well as programmable interconnecting and pins to create a customized peripheral configuration that matches the requirements of each individual application. General features of the CY8C29466 device are:

where xk is the state vector, uk-1 is the input vector, yk is the output vector, wk-1 is the process noise vector, zk is the measurement vector and vk is the measurement noise vector. The probability of process noise wk is P(w) with process noise covariance Q. The probability of measurement noise vk is P(v) with measurement noise covariance R. The a priori estimate error and a posteriori estimate error are defined as follow
ek = xk xk

(4)
(5)

ek = x k x k

where xk and xk are the a priori state estimate and a posteriori state estimate respectively. The a priori estimate error covariance Pk is then formulated as:

Pk = E{ek ek } = APk 1 AT + Q

Harvard Architecture Processor speeds to 24 MHz without any external clock crystal. 12 Analogue PSoC Blocks: Three types of ADC, from 6-bit to 14-bit DAC and Multiplier, from 6-bit to 9-bit Amplifier, Instrumentation Amplifier, and Comparator Low-pass and Band-pass Filter

(6)

and the a posteriori estimate error covariance Pk is developed


T Pk = E{ek ek }

= E{[ xk xk + K ( z k Cxk )] [ xk xk + K ( z k Cxk )]T }

= ( I KC ) P

(7)

16 Digital PSoC Blocks: Counters, Timers, and PWMs, from 8-bit to 32-bit. CRC and PRS Modules Up to 4 Full-Duplex UARTs

In deriving the algorithm for the Kalman filter, one should begin with the goal of finding an equation that computes an a posteriori state estimate as a linear combination of an a priori estimate and a feedback from error between an actual

78

Connectable to all GPIO Pins I C Slave, Master, and Multi-Master


2

Flexible On-Chip Memory, 32KB Flash for program 2KB SRAM for data, and up to 2KB EEPROM Programmable Pin Configurations In-System Serial Programming

One CY8C29466 PSoC chip can provide all the hardware components needed for this design application, such as instrumentation amplifier, programmable gain amplifier, filter, ADC, DAC, counter, timer, LCD driver, and digital I/O pins. No external component is employed; therefore, no circuit board debug is needed. High-level integration, immunity to noise, and insensitivity to component variations can all be achieved. This configurable system-on-chip can speed up the development process as well as save a lot of hardware costs. The software programming feature provides engineers the flexibility to adapt high-level functions (API), the user module application programming interface, to control and respond to hardware events at run-time. IV. PSOC IMPLEMENT OF AUXILIARY VACUUM SYSTEM

B. Signal Conditioning and A/D, D/A Converter An instrumentation amplifier provides high impedance differential inputs to pick up the differential bridge output from pressure gauge. Gain is set to 8. A programmable gain amplifier (PGA) is used to provide extra gain of 4 to make 1atm (14.696 psi) pressure to 2.586 V, suitable for 2.6 V input range of ADC. The signal conditioning task, i.e. amplification, is achieved by PSoC analogue continuous time (CT) blocks. Then, a 12-bit incremental ADC is selected to convert 2.6 V analogue input range into 12-bit digital output. The sampling rate of ADC is 480 sps. For ADC function, an analogue switched capacitor (SC) PSoC block along with a digital counter and a counter blocks are used. The corresponding pressure signal is processed in digital fashion by Kalman filter algorithm. The optimal estimation data from Kalman filter is yielded to steer a hysteresis controller for vacuum pump. This part of data manipulations is accomplished in C code. For visual comparison, a 9-bit D/A converter is utilized to send out the result of the Kalman filter in analogue. Also, a 2nd order Butterworth low-pass filter is connected after PGA to generate a filtered analogue output to compare with Kalman filter. The cutoff frequency of this low-pass filter is 10 Hz. C. Kalman Filter Algorithm After the pressure signal is processed and converted into digital, the Kalman filter algorithm is implemented in C code by the following procedure shown in Fig. 3. In this application, the pressure data from ADC is the noisy measurement zk. Parameters are, measurement noise variance R, process noise variance Q, estimate error variance Pk , Kalman gain K, and system matrix A=1 and output matrix C=1. The a posteriori estimate xk is the optimal estimation by Kalman filter. The purpose of Kalman filter is to fight the noisy environment in a vehicle and give a real-time optimal estimation of the pressure to control the vacuum pump. Thus, Kalman filter is the key role to success of this auxiliary vacuum brake system.
Initiate Variables Q, R, xk 1 , Pk 1, Taking In New Sample zk A Priori Estimate (Prediction) State xk = Axk 1 A Priori Estimator Error Covariance Pk = APk 1 AT + Q

To implement this auxiliary vacuum pump system, a system block diagram is designed with one CY8C29466 PSoC chip to implement all of signal conditioning and control, shown in Fig. 2. The system is made of a pressure sensor, a LCD display, one PSoC chip, and a vacuum pump with its driver. All the circuit components are carried out by interconnecting the configurable analogue and digital hardware blocks in PSoC. Cut a lot of development time and save a lot of hardware expenses. Design is described as follows:

Figure 2. PSoC implement of auxiliary vacuum brake system

A. Pressure Sensor A differential pressure sensor SCC05N from SenSym is employed to measure the pressure of vacuum brake system. This sensor is designed for pneumatic control, automotive diagnostics, medical or dental equipment. The output of this sensor is differential bridge and measured by experiment as 5.5mV/psi. The maximum range is 20 psi. The working span of this application is 1 atm, or 14.696 psi. One of differential inlets is connected to vacuum brake system, while the other inlet is bonded to the open air. Therefore, the gauge pressure measured is absolute pressure.

A Posteriori Estimate (Estimator) State xk = xk + K ( z k Cxk ) A Posteriori Estimator Error Covariance Pk = ( I KC ) Pk Kalman Gain K = PkC T (CPk C T + R ) 1

Figure 3. Implement of Kalman filter algorithm

D. Hysteresis Controller for Vacuum Pump A hysteresis controller is written in C code to steer the vacuum pump and keep the pressure within 300 mm-Hg to 420 mm-Hg range in absolute pressure. The control pattern is illustrated in Fig. 4. It is intended to overcome excessively noisy surroundings. One I/O pin is used to control the pump

79

through a driver. An average pump driving current within the range of 60 A to 80 A is observed.

Figure 4. Hysteresis controller for vacuum pump

E. LCD Display An industry standard two-line by 16 character LCD display is employed. First line shows the gauge pressure taken from 12-bit ADC in mV. Second line displays the corresponding pressure reading from Kalman filter estimation in mm-Hg.

frequency of 10 Hz is also implemented inside PSoC chip. The purpose of this low-pass filter is for performance comparisons. Both DAC output from Kalman filter and lowpass filter output are directly connected for testing from IC socket. Three types of tests are performed: (a) 1 Hz and 10 Hz sinusoid wave input with noise. (b) 1 Hz sinusoid wave input with disturbances from vacuum pump through power line. (c) hysteresis controller output response to 1 Hz sinusoid wave input. The testing sinusoid wave input is taken into PSoC by its instrumentation amplifier and then a programmable gain amplifier with the total differential magnitude gain of 32 before fed into 12-bit ADC. The low-pass is designed by analogue and digital functional blocks provided by PSoC, while Kalman filter is implemented by PSoC Designer in C code. The performances of Kalman filter and low-pass filter are recorded by TDS-1020 digital oscilloscope from Tektronics and put together for comparisons.

F. PSoC Interconnecting Diagram Figure 5 illustrates all the PSoC analogue and digital functional blocks used, and the interconnecting diagram in the application. This PSoC architecture exactly implements the Figure 6. (a) Prototype. (b) Sensor, Circuit board and LCD diplay structure of auxiliary vacuum brake system described in Fig. 2. All the circuit elements are integrated in one chip without any A. Sinusoid Input with Noise in Different Frequencies external electronic components. Immunity to both noise and Testing signal of 1 Hz and 10 Hz sinusoid wave with noise component variations as well as circuit reliability can all be are sent into PSoC chip to test the performances of both filters. improved. From Fig. 7 and Fig. 8, the magnitude change and phase shift of low-pass filter are very obvious for different input frequencies, while those of Kalman filter are slight.

Figure 7. 1 Hz test results: (a) Kalman Filter. (b) Low-pass Filter

Figure 5. PSoC circuit blocks and interconnecting diagram

V.

TEST RESULTS
Figure 8. 10 Hz test results: (a) Kalman Filter. (b) Low-pass Filter

A prototype circuit board is built to evaluate control system performance, shown in Fig. 6(a) and (b). In Fig 6(b), this system is made of a pressure sensor, a LCD display, one PSoC chip, a 5-V voltage regulator with an output capacitor, and connectors to power, sensor, and vacuum pump driver. As one can see, control system is compact in size and concise in design. A 2nd order Butterworth low-pass filter with cutoff

B. Noisy Input Signal with Disturbances Signal of 1 Hz sinusoid wave with disturbances from vacuum pump are tested, shown in Fig. 9. A lot of

80

disturbances caused by vacuum pump through 12-V power line are observed. Comparing Fig. 9(a) with Fig 7(a), the output of Kalman filter does not have any significant changes. However, the output of low-pass filter is corrupted, shown in Fig. 9(b). In a vehicle, generator, ignition, pumps, and other electronic devices all make noises and disturbances. Hardware low-pass filters are vulnerable to power disturbances via ground noises, while Kalman filters are immune because Kalman filters are implemented by software. These noises and disturbances cause signal conditioning circuit as well as control system to malfunction. Satisfactory signal conditioning circuit is the key to satisfying control outcome. Apparently, Kalman filter is capable of fighting hostile environments and is a better choice.

problems and component variations. At the same time, save a lot of hardware costs.

Kalman filter algorithm is successfully carried out within PSoC chip by software. The resultant Kalman estimate is taken as the input for hysteresis controller. The Kalman filter plays a key role of this system to surpass the hostile working environment. The test results confirm that Kalman filter performs better than low-pass filter in two senses: less magnitude change and phase shift for different input frequencies. Also, Kalman filter has proven to fight the disturbances from vacuum pump while low-pass filter failed to do so. By applying Kalman filter in this design, the annoying issue mentioned in [2] has been solved without any bulky noise filter apparatus. ACKNOWLEDGMENT

Authors would like to express our appreciation to Dr. FuShe Jan, Director of Business Incubation Center, Chien-Kuo Technology University and YT Stable Tech. Corp. for their technical support.
Figure 9. 1 Hz with disturbance: (a) Kalman Filter. (b) Low-pass Filter

REFERENCES
C. D. Holton, Auxiliary vacuum pump for power brakes, U.S. Patent 2 705 870, Sep. 17, 1953. [2] G. C. Fulks, J. W. Zehnder, D. E. Poole, T. A. Haerr, M. K. Goecke, and T. M. Schlangen, Vehicle brake booster with supplemental vacuum assist, U.S. Patent 6 301 883, Oct. 16, 2001. [3] S. Bacardit, Braking device for a motor vehicle, comprising a vacuum pump, U.S. Patent 6 871 493, March 29, 2005. [4] W. Y. Du and M. A. Gonzales, Kalman filter design and implementation for the 2D real-time testbed control using EVS, in Proceedings of the 2005 IEEE/ASME International Conference on Advanced Intelligent Mechatronics, Monterey, CA, July 2005, pp. 14531458. [5] S. S. Young, Attitude estimation by multiple-mode Kalman filters, IEEE Trans. Industrial Electronics, vol. 53, no. 4, pp. 1386-1389, Aug. 2006. [6] L. Angrisani, A. Baccigalupi, and R. S. L. Moriello, Ultrasonic timeof-flight estimation through unscented Kalman filter, IEEE Trans. Instrumentation and Measurement, vol. 55, no. 4, pp.1077-1084, Aug. 2006. [7] T. Senjyu, K. Kinjo, N. Urasaki, and K. Uezato, High efficiency control of synchronous reluctance motors using extended Kalman filter, IEEE Trans. Industrial Electronics, vol. 50, no. 4, pp. 726-732, Aug. 2003. [8] M. Jun, S. I. Roumeliotis, and G. S. Sukhatme, State estimation of an autonomous helicopter using Kalman filtering, in Proceedings of the 1999 IEEE/RSJ International Conference on Intelligent Robots and Systems, 1999, pp. 13461353. [9] W. Wu, A. Shaikhouniy, J. P. Donoghuey, M. J. Blackz, and B. Smith, Closed-Loop Neural Control of Cursor Motion using a Kalman Filter, in Proceedings of the 26th Annual International Conference of the IEEE EMBS, San Francisco, CA, Sep. 2004, pp.4126-4129. [10] M. S. Grewal and A. P. Andrews, Kalman Filtering. Englewood, NJ: Prentice Hall, 1993. [11] PSoC Mixed-Signal Controllers, Cypress Semiconductor, Available: http://www.cypress.com/psoc [12] PSoC Mixed Signal Array CY8C29466 Data Sheet, Document No. 3812013 Rev. H, Cypress Semiconductor, Feb. 15, 2007. [1]

C. Hysteresis Controller The output of Kalman filter then is used to implement a hysteresis controller in C code. The goal is to keep the pressure within 300 mm-Hg to 420 mm-Hg range in absolute pressure, refer to Section IV D. Testing signal of 1 Hz sinusoid wave is employed to test the controller performance. The hysteresis controller output is satisfying although there are some unexpected disturbances in the input, refer to Fig. 10.

Figure 10. 1 Hz input and hysteresis controller output

VI.

CONCLUSION

In this research, an auxiliary brake system is implemented by using single PSoC chip. By doing so, there are several distinctive achievements:

A compact, reliable, and robust auxiliary brake system has been built and tested. All of the functions are well executed as expected. The prototype has proven to be compact in size and concise in design. All the circuit elements in this control system are integrated in one chip without any external electronic components. Eliminate the bulky circuit space and immunize the control system from circuit layout

81

Vous aimerez peut-être aussi