Design of anti-pinch scheme for electric windows

Publisher:ZenMaster123Latest update time:2012-06-07 Source: 21IC Reading articles on mobile phones Scan QR code
Read articles on your mobile phone anytime, anywhere

0 Introduction

With the advancement of modern automotive electronic technology, traditional parts and assemblies in automobiles are also developing towards mechatronics. The large number of electronic devices used in automobiles not only improves the comfort of automobiles, but also puts forward new requirements for automobile safety. In order to facilitate drivers and passengers, a large number of automobiles use electric windows. Many electric windows do not have anti-pinch functions, which can easily cause harm to passengers, especially children. The U.S. Department of Transportation has promulgated FMVSSll8, a regulation for electric window switch systems, which clearly stipulates the relevant parameters of window anti-pinch, and stipulates that all cars and minivans sold in North America after October 1, 2008 must enforce this regulation. Although my country has not yet made legal provisions on this issue, it is absolutely necessary to develop a window control module with anti-pinch function for safety reasons.

After referring to the literature, the anti-pinch design scheme of this paper adopts the combination of detecting the motor speed and detecting the change of the motor current by the Hall sensor to realize the anti-pinch function. This scheme avoids the defect that the window anti-pinch system is easily affected by the external environment, ensures the reliable anti-pinch effect, and has low cost. It is not necessary to change the production process of traditional car doors. When modifying old models without anti-pinch function of electric windows, it is not necessary to change the mechanical structure and circuit structure of the existing car doors. It is only necessary to replace the electric window lifting controller, which is very convenient.

1 Electric window anti-pinch design

The so-called anti-pinch function means that when the electric window is raised and an object is clamped and a certain force is reached, the electric window will automatically stop or fall back to prevent objects (especially human bodies) from being pinched. During the lifting and lowering of the window, anti-pinch control is only required during the window rising stage. The defined anti-pinch area is an area of ​​4 to 200 mm from the maximum position (top) of the electric window glass without obstacles. This definition complies with the relevant requirements of European 74/60/EEC and American FMVSSll8. The anti-pinch function is only activated in the anti-pinch area. Therefore, the anti-pinch design should first determine the current position of the window.

1.1 Determination of window position

The rotation of the window control motor will drive the movement of the steel wire rope, thereby controlling the up and down movement of the window. During the movement of the window, the number of turns of the motor is proportional to the movement distance of the window. One rotation of the motor rotor will cause the Hall sensor to generate a square wave pulse signal. When the window rises from the lowest position to the top, the pulse signal output by the Hall sensor can be counted by the MCU, from the bottom to the top of the window, up and down 3 times, and the average value nth is taken as the calibration reference and recorded in the E2PROM. After that, the software control starts running from the bottom position of the window (at this time it is manually controlled, the window runs to the bottom, and the motor is blocked), and the counting starts from zero. The rising process is counted according to the current count value, and the falling process is counted according to the current count value. Therefore, the pulse output and counting scheme of the Hall sensor can determine the current position of the window in real time, and determine whether the window is in the anti-pinch area according to the provisions of the European 74/60/EEC and the US FMVSSll8 standards. For this system, the error of pulse counting during the measurement process can be ignored, and the error that may be caused during long-term operation can be solved by regular calibration.

1.2 Determination of anti-pinch solution

This system uses the method of detecting the motor armature current to determine whether the window encounters an obstacle during the rising process. The following problems need to be solved during the specific implementation of the solution:

(1) Determine the anti-pinch area and window position. Determine the corresponding anti-pinch area and window position in accordance with European 74/60/EEC and American FMVSSll8 standards.

(2) Determination of the motor armature current threshold ith during anti-pinch operation, that is, when the current value in the anti-pinch area rises to the set threshold, it is considered that an obstacle is encountered and the window anti-pinch function is activated. The problem here is that when the window button is just pressed (whether it is rising or falling) and the window motor is just started, the motor's back electromotive force has not yet been established, so the current will have a short-term large amplitude. The current amplitude at this time is often larger than the set anti-pinch current threshold. It is necessary to distinguish this state of large current amplitude from the obstacle encountered during the window rising process. After the window motor is started, the current detection is performed after a delay of 50 ms, which can avoid the impact of the instantaneous overshoot of the motor current at the initial start-up on the anti-pinch current threshold setting. In the actual design, a central controller that can be used for diagnostic functions is used in conjunction with the USB-CAN200 tool produced by Wuhan Jiyang Optoelectronics Co., Ltd. to feed back the data during the operation to the PC, present it in the form of an Excel table, and draw a graph, so as to conveniently determine the threshold ith, and determine the appropriate threshold through multiple running tests.

(3) Selection of MCU and power driver. The anti-pinch solution involves a lot of real-time detection and real-time calculation, which requires the MCU to have high computing power. The software implementation in the solution is based on the transplantation of the μC/OS-Ⅱ real-time operating system solution. Therefore, the popular and high-performance Infineon XCl64CS MCU in European car series is selected, and the power driver chip is the BTS781 chip with fault diagnosis function. [page]

2 Anti-pinch system hardware design

The door control system consists of two parts: the electric window control system and the electric rearview mirror control system. The anti-pinch electric window is a submodule of the door control system. In the entire door control system, a "general distribution, local centralized" control scheme is adopted, as shown in Figure 1. That is, the control of the two front and rear doors on the left is used as one ECU module, and the control of the two front and rear doors on the right is used as another ECU module. The two modules and the modules and the central controller are connected in CAN bus mode.

Anti-pinch system hardware design

The hardware design of the anti-pinch system is based on BTS781, which is connected to the microcontroller XCl64CS chip through ST1, ST2, IH1, IH2, IL1, IL2 ports, and receives instructions from the microcontroller to control the lifting of the window. A 5 mΩ resistor R37 is connected in series to the 2nd and 13th pins of the full-bridge driver chip BTS781 to detect the change of the motor armature current, which is sent to the A/D port of the MCU for sampling after low-pass filtering and amplification, as shown in Figure 2.

Detecting motor armature current

The window position is determined by counting the pulses output by the Hall sensor. The Infineon TLE4923 Hall sensor is used to directly output a square wave signal, which is low-pass filtered and input into the MCU to count the pulses, thereby determining the current position of the window, as shown in Figure 3.

Infineon TLE4923 Hall sensor

[page]

3 Software Design

The software design of the system should not only consider the convenience of control, but also the future functional expansion. Therefore, the software design of this system is based on the real-time operating system, that is, first transplant the μC/OS-Ⅱ real-time operating system kernel to the XCl64CS MCU, and then add the anti-pinch window control as one of the tasks.

3.1 μC/OS-Ⅱ Real-time Operating System Kernel Transplantation

The transplantation is to transplant the μC/OS-Ⅱ real-time kernel to the XCl64CS microcontroller. Since μC/OS-Ⅱ can only read and write processor registers through assembly language, some processor-related codes must be written in assembly language, but most of the μC/OS-Ⅱ codes are written in C language. The transplantation work mainly enables μC/OS-Ⅱ to correctly define and use XCl64C-S. For details, please refer to the article written by the author of this article, which will not be repeated here.

3.2 Anti-pinch electric window software design

After transplanting the μC/OS-Ⅱ real-time operating system on the designed hardware platform, the anti-pinch electric window control is added in the form of a task, and the anti-pinch function is implemented with reference to the previous content. The flow chart is shown in Figure 4.

Anti-pinch electric window software design

[page]

When the controller XCl64CS is powered on, it reads the initial data such as nth and ith from E2PROM, detects the power supply voltage, and when the voltage value is stable, reads the window position stored in E2PROM, and then reads the key input. If there is a window lifting operation, the corresponding switch signal is set to drive the MOS tubes T1, T2, T3, and T4 in the chip BTS781. If the window moves upward, the timer starts counting, the Hall sensor pulse signal counts, and after a delay of 50 ms, it detects whether the current value is overcurrent. If an overcurrent signal is detected during the window rising process, that is, the current value of the window motor is greater than the current threshold ith, and the window position is in the anti-pinch start area, it is determined that the window is blocked, and the controller outputs a direction switch signal, and drives the motor to reverse through MOS tubes T1, T2, T3, and T4 for 1 s and then stops, and the anti-pinch operation is completed. Regardless of the motor lifting and lowering movement, the controller will record the number of pulse signals of the Hall sensor through the counting program, based on which the relative position of the window can be determined, and the position information can be written into the E2PROM when necessary.

4 Testing

After completing the hardware production and software programming, the experimental bench was made. After testing the bench, the test results shown in Figure 5 were obtained. The test results were plotted in Excel as the curve graph on the upper right side of Figure 5, and the current change curve actually tested by the oscilloscope is shown in the curve graph on the lower right side of Figure 5. The description of the actual test curve change of the oscilloscope is shown in Table 1.

Test results

Description of the changes in the actual test curve of the oscilloscope

As can be seen from FIG5 , the graph drawn by the test result is the same as the actual test graph of the oscilloscope, achieving the expected anti-pinch effect.

5 Conclusion

This paper describes an anti-pinch design for electric windows, which realizes the anti-pinch function of the windows without changing the original installation structure. The key is to design a suitable current detection threshold. This study gives the current threshold based on experiments and makes a test bench. The test results show that the design made in this paper can realize a reliable anti-pinch function for windows.

Reference address:Design of anti-pinch scheme for electric windows

Previous article:Design and implementation of a traffic accident warning system based on acceleration
Next article:Design of a Multifunctional Vehicle Driving Status Recorder

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号