Vehicle-mounted skylight control method and device, controller and vehicle
By detecting the deviation calculation of window position and motor parameters, combined with weight adjustment, precise control of window anti-pinch force is achieved, solving the problem of inaccurate anti-pinch force detection in the existing technology, and improving the safety and reliability of sunroof control.
Patent Information
- Application Number
- CN202510493325.6
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-04-18
- Publication Date
- 2025-07-18
AI Technical Summary
In the prior art, the anti-clip force detection accuracy of the window is low and is easily affected by environmental factors and electromagnetic interference, resulting in inaccurate anti-clip control.
By detecting the current position of the vehicle sunroof, the actual speed and current of the drive motor are collected, the deviation of the speed and current is calculated, combined with weight adjustment, the actual anti-pinch force is determined, and the motor stops or reverse movement is controlled when the preset threshold is reached.
Improve the accuracy of anti-pinch force detection, ensure the accuracy and safety of sunroof anti-pinch control, and reduce the risk of misclipping and clamping.
Smart Images

Figure CN120331597A_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the technical field of skylight control, and particularly to a control method for a vehicle skylight, a controller, a control device for a vehicle skylight, and a vehicle. Background Art
[0002] With the progress of modern automotive electronic technology, traditional components and assemblies in vehicles are also developing towards mechatronics. A large number of electronic devices used in vehicles not only improve the comfort of the vehicle but also pose new requirements for the safety of the vehicle.
[0003] In the related art, the window is driven by a brushed DC motor, and the load torque change is calculated by monitoring the ripple current of the motor, thereby estimating the anti-pinch force for anti-pinch control. However, the ripple current collected by this technical solution is easily affected by environmental factors and electromagnetic interference between internal components of the motor, reducing the anti-pinch control accuracy of the motor. Summary of the Invention
[0004] The present application aims to at least solve one of the technical problems in the related art to some extent. To this end, the first object of the present application is to propose a control method for a vehicle skylight, which uses the motor speed and motor current together to confirm the actual anti-pinch force, improves the anti-pinch force detection accuracy, and ensures the skylight anti-pinch control effect.
[0005] The second object of the present application is to propose a controller.
[0006] The third object of the present application is to propose a control device for a vehicle skylight.
[0007] The fourth object of the present application is to propose a vehicle.
[0008] To achieve the above object, an embodiment of the first aspect of the present application proposes a control method for a vehicle skylight, including: detecting the current pose of the vehicle skylight, and collecting the actual speed and actual current of the drive motor of the vehicle skylight; matching the reference speed and reference current of the drive motor according to the current pose; calculating the speed deviation between the actual speed and the reference speed, and calculating the current deviation between the actual current and the reference current, and determining the actual anti-pinch force of the vehicle skylight according to the speed deviation and the current deviation, so as to control the drive motor to drive the vehicle skylight to stop or move in the reverse direction when the actual anti-pinch force is greater than or equal to a preset threshold.
[0009] According to the control method of the vehicle sunroof according to the embodiments of the present application, first, the current pose of the vehicle sunroof is detected, and the actual rotation speed and actual current of the drive motor of the vehicle sunroof are collected. The reference rotation speed and reference current of the drive motor are matched according to the current pose. Then, the rotation speed deviation between the actual rotation speed and the reference rotation speed is calculated, and the current deviation between the actual current and the reference current is calculated. Moreover, the actual pinch force of the vehicle sunroof is determined according to the rotation speed deviation and the current deviation, so as to control the drive motor to drive the vehicle sunroof to stop or move in the reverse direction when the actual pinch force is greater than or equal to the preset threshold. Thus, this method uses the motor rotation speed and motor current together to confirm the actual pinch force, improves the pinch force detection accuracy, and ensures the pinch protection control effect of the sunroof.
[0010] In addition, the control method of the vehicle sunroof according to the above embodiments of the present application may further have the following additional technical features:
[0011] According to an embodiment of the present application, determining the actual pinch force of the vehicle sunroof according to the rotation speed deviation and the current deviation further includes: determining a first weight corresponding to the actual rotation speed and a second weight corresponding to the actual current according to the current pose; determining the actual pinch force according to the first weight, the second weight, the rotation speed deviation, and the current deviation.
[0012] According to an embodiment of the present application, after determining the first weight corresponding to the actual rotation speed and the second weight corresponding to the actual current according to the current pose, it further includes: obtaining one or more of the startup duration of the drive motor, the supply voltage of the drive motor, the current vehicle speed of the vehicle, the ambient temperature where the vehicle is located, and the initial position of the vehicle sunroof; adjusting the first weight and / or the second weight according to one or more of the startup duration of the drive motor, the supply voltage of the drive motor, the current vehicle speed of the vehicle, the ambient temperature where the vehicle is located, and the initial position of the vehicle sunroof.
[0013] According to an embodiment of the present application, determining the actual pinch force according to the first weight, the second weight, the rotation speed deviation, and the current deviation includes: determining a first pinch force according to the rotation speed deviation, and obtaining the product of the first weight and the first pinch force to obtain a second pinch force; determining a third pinch force according to the current deviation, and obtaining the product of the second weight and the third pinch force to obtain a fourth pinch force; obtaining the sum value between the second pinch force and the fourth pinch force to obtain the actual pinch force.
[0014] According to an embodiment of the present application, matching the reference rotation speed and reference current of the drive motor according to the current pose includes: determining a first target reference model and a second target reference model according to the position interval where the current pose is located; inputting the current pose into the first target reference model to output the reference rotation speed; inputting the current pose into the second target reference model to output the reference current.
[0015] According to an embodiment of the present application, the drive motor is provided with two Hall sensors, and the two Hall sensors generate two Hall signals to detect the current position and posture of the vehicle sunroof, including: obtaining the initial position of the vehicle sunroof and the two Hall signals of the drive motor; determining the moving direction of the vehicle sunroof according to the phase difference between the two Hall signals; determining the moving distance of the vehicle sunroof according to the number of pulses of the two Hall signals; and determining the current position and posture of the vehicle sunroof according to the initial position, moving direction and moving distance.
[0016] According to an embodiment of the present application, collecting the actual rotation speed of the drive motor of the vehicle sunroof includes: obtaining the Hall signal of the drive motor; determining the actual rotation speed of the drive motor according to the pulse width of the Hall signal; or obtaining the ripple current of the drive motor; determining the actual rotation speed of the drive motor according to the change rate of the ripple current; or obtaining the Hall signal and ripple current of the drive motor; determining the actual rotation speed of the drive motor according to the pulse width of the Hall signal and the change rate of the ripple current.
[0017] To achieve the above object, an embodiment of the second aspect of the present application provides a controller, including a memory, a processor, and a control program of the vehicle sunroof stored in the memory and executable on the processor. When the processor executes the control program of the vehicle sunroof, the above control method of the vehicle sunroof is implemented.
[0018] According to the controller of the embodiment of the present application, when the processor executes the control program of the vehicle sunroof, the above control method of the vehicle sunroof is implemented. Based on the above control method of the vehicle sunroof, the anti-pinch force detection accuracy is improved, and the anti-pinch control effect of the sunroof is ensured.
[0019] To achieve the above object, an embodiment of the third aspect of the present application provides a control device for a vehicle sunroof, including: a detection module for detecting the current position and posture of the vehicle sunroof; a collection module for collecting the actual rotation speed and actual current of the drive motor of the vehicle sunroof; a matching module for matching the reference rotation speed and reference current of the drive motor according to the current position and posture; a determination module for calculating the rotation speed deviation between the actual rotation speed and the reference rotation speed, and calculating the current deviation between the actual current and the reference current, and determining the actual anti-pinch force of the vehicle sunroof according to the rotation speed deviation and the current deviation; and a control module for controlling the drive motor to drive the vehicle sunroof to stop or move in the reverse direction when the actual anti-pinch force is greater than or equal to a preset threshold.
[0020] The control device of the vehicle sunroof according to the embodiment of the present application detects the current position and pose of the vehicle sunroof through a detection module, collects the actual rotation speed and actual current of the driving motor of the vehicle sunroof through a collection module, matches the reference rotation speed and reference current of the driving motor according to the current position and pose through a matching module, calculates the rotation speed deviation between the actual rotation speed and the reference rotation speed through a determination module, calculates the current deviation between the actual current and the reference current, and determines the actual anti-pinch force of the vehicle sunroof according to the rotation speed deviation and the current deviation. When the actual anti-pinch force is greater than or equal to a preset threshold, the control module controls the driving motor to drive the vehicle sunroof to stop or move in the reverse direction. Thus, the device uses both the motor rotation speed and the motor current to confirm the actual anti-pinch force, improves the anti-pinch force detection accuracy, and ensures the anti-pinch control effect of the sunroof.
[0021] To achieve the above object, the fourth aspect embodiment of the present application proposes a vehicle, including the above controller or the control device of the above vehicle sunroof.
[0022] The vehicle according to the embodiment of the present application, based on the above controller or the control device of the above vehicle sunroof, improves the anti-pinch force detection accuracy, ensures the anti-pinch control effect of the sunroof, and improves the safety of the vehicle.
[0023] Additional aspects and advantages of the present application will be given in part in the following description, become apparent in part from the following description, or be learned through the practice of the present application. Description of the Drawings
[0024] Figure 1 It is a flowchart of the control method of the vehicle sunroof according to the embodiment of the present application;
[0025] Figure 2 It is a waveform diagram of the Hall pulse width when an obstacle appears according to a specific embodiment of the present application;
[0026] Figure 3 It is a waveform diagram of the armature current when an obstacle appears according to a specific embodiment of the present application;
[0027] Figure 4 It is a waveform diagram of the Hall pulse width according to a specific embodiment of the present application;
[0028] Figure 5 It is a waveform diagram of the armature current according to an embodiment of the present application;
[0029] Figure 6 It is a flowchart of the control method of the vehicle sunroof according to a specific embodiment of the present application;
[0030] Figure 7 It is a block diagram of the controller according to the embodiment of the present application;
[0031] Figure 8 Schematic connection diagram of a control device for a vehicle sunroof according to an embodiment of the present application;
[0032] Figure 9 Block diagram of a vehicle according to an embodiment of the present application;
[0033] Figure 10 Block diagram of a vehicle according to another embodiment of the present application. Detailed implementation manners
[0034] Embodiments of the present application will be described in detail below. Examples of the embodiments are shown in the accompanying drawings, where the same or similar reference numerals denote the same or similar elements or elements having the same or similar functions throughout. The embodiments described below with reference to the accompanying drawings are exemplary and are intended to explain the present application, and should not be construed as a limitation of the present application.
[0035] A control method for a vehicle sunroof, a controller, a control device for a vehicle sunroof, and a vehicle proposed according to an embodiment of the present application will be described below with reference to the accompanying drawings.
[0036] Figure 1 Flowchart of a control method for a vehicle sunroof according to an embodiment of the present application.
[0037] As Figure 1 shown, the control method for a vehicle sunroof according to an embodiment of the present application includes:
[0038] S1. Detect the current pose of the vehicle sunroof, and collect the actual rotational speed and actual current of the drive motor of the vehicle sunroof;
[0039] S2. Match the reference rotational speed and reference current of the drive motor according to the current pose;
[0040] S3. Calculate the rotational speed deviation between the actual rotational speed and the reference rotational speed, calculate the current deviation between the actual current and the reference current, and determine the actual anti-pinch force of the vehicle sunroof according to the rotational speed deviation and the current deviation, so as to control the drive motor to drive the vehicle sunroof to stop or move in the reverse direction when the actual anti-pinch force is greater than or equal to a preset threshold.
[0041] Specifically, the current pose of the vehicle sunroof includes the current position, which can be obtained through a position sensor or estimated by combining parameters such as the Hall signal of the drive motor of the vehicle sunroof, and specific limitations are not made. In addition, to improve the control accuracy, the current pose of the vehicle sunroof may further include parameters such as the moving direction of the sunroof.
[0042] The actual rotational speed of the drive motor can be collected by Hall sensors installed inside the motor. For example, a brushed DC motor with an internal four-pair eight-pole magnetic ring is used to drive the electric sunroof. The magnetic poles are arranged alternately. During the rotation of the motor, the magnetic field changes caused by the magnetic poles will be captured by the Hall sensors. To improve the accuracy of rotational speed sampling and the reliability of the signal, two Hall sensors in the drive motor are arranged orthogonally at 90°. The current rotational speed of the drive motor is calculated through the pulse width of the Hall pulses, where the pulse width is inversely proportional to the motor speed. During the detection process, the Hall sensors convert the captured magnetic field change signals into level signals, which are captured by the main control chip timer. The capture method is rising / falling double-edge capture. Each rotation of the drive motor will generate a total of 16 pulses by two Hall sensors, and the rotational distance accuracy corresponding to each pulse is 0.078 mm.
[0043] The actual current of the drive motor can be the armature current of the drive motor. Specifically, in the case of using an H-bridge scheme to drive the drive motor of the vehicle sunroof, a sampling resistor is connected in series between the lower bridge arm of the H-bridge and the ground terminal, that is, the armature current is collected by the single-resistor sampling method.
[0044] The resistance received by the vehicle sunroof varies at different poses. Therefore, the reference rotational speed and reference current of the drive motor are matched based on the current pose of the vehicle sunroof. Specifically, the mapping relationship between the vehicle sunroof and the rotational speed and current of the drive motor can be preset in advance, and then during the control process, based on the currently detected current pose, the corresponding reference rotational speed and reference current are determined from the preset mapping relationship. The mapping relationship can be a corresponding functional relationship or a preset mapping table, and there is no specific limitation.
[0045] When the vehicle sunroof is blocked during the movement, the load increases and the motor speed will decrease. Therefore, it is possible to determine whether an anti-pinch event occurs based on the rotational speed deviation between the actual rotational speed and the reference rotational speed of the drive motor. Taking the determination of the motor speed by the pulse width of the Hall signal as an example, in the embodiment of controlling the moving target distance of the vehicle sunroof, if an obstacle appears during the movement (sunroof position 19 - 106 mm), there will be Figure 2 a blue waveform diagram as an example, and the red line is the waveform diagram without an obstacle. At this time, the Hall pulse width increases and the motor speed decreases.
[0046] In addition, when the vehicle sunroof is blocked during the movement, the load increases, which will also cause the motor current to increase. Therefore, it is also possible to determine whether an anti-pinch event occurs based on the current deviation between the actual current and the reference current of the drive motor. Taking the use of the armature current as the motor current for sunroof control as an example, in the embodiment of controlling the moving target distance of the vehicle sunroof, if an obstacle appears during the movement (sunroof position 19 - 106 mm), there will be Figure 3 a blue waveform diagram as an example, and the red line is the waveform diagram without an obstacle. At this time, the current increases.
[0047] To improve the accuracy of anti-pinch force judgment, the actual anti-pinch force is calibrated jointly according to the rotational speed deviation and the current deviation. For example, a preset relationship among the rotational speed deviation, the current deviation, and the anti-pinch force can be established in advance, and the corresponding actual anti-pinch force is determined based on the invocation of the preset relationship during the control process. Then, the actual anti-pinch force is compared with a preset threshold. When the actual anti-pinch force is greater than or equal to the preset threshold, it is considered that there is an obstacle blocking during the movement of the vehicle sunroof. At this time, the driving motor can be controlled to stop rotating to drive the vehicle sunroof to stop moving, or the driving motor can be controlled to rotate in the reverse direction to drive the vehicle sunroof to move in the reverse direction. That is to say, during the closing process of the electric sunroof of the vehicle, if an object is clamped and a certain force (i.e., the preset threshold) is reached, the vehicle sunroof is controlled to stop moving or stop and move in the reverse direction to avoid being pinched. The preset threshold can be determined according to the current pose of the sunroof. A fixed value of 100N can be selected. If the preset threshold is too small, there may be false anti-pinch; if the preset threshold is too large, pinching may occur. In addition, this control method can be restricted to be triggered in the anti-pinch area of the vehicle sunroof, such as between 4mm and 200mm from the fully closed position of the sunroof, and no triggering application is performed in other areas, thereby reducing energy consumption while avoiding false pinching.
[0048] Based on the motor characteristics, it is known that the driving force of the driving motor is related to the voltage / current. Under the condition of constant voltage, the greater the load, the lower the rotational speed and the greater the current. Motor load = driving force of the sunroof without load + resistance of the sunroof during normal operation on the slide rail + anti-pinch force of foreign objects. In this embodiment, by calibrating the driving current and the motor rotational speed under normal conditions, the reference current and the reference rotational speed of the vehicle sunroof in different poses are obtained. When an anti-pinch force is applied, that is, when an obstacle is encountered during movement, it is judged whether the anti-pinch function is triggered according to the actual current and the actual rotational speed. Since the sampling period of the ADC (Analog to Digital Converter) current sampling mode triggered by the timer is about 100us, the change of the motor current can be quickly detected. The collected motor current is used as a supplementary signal for anti-pinch force judgment, which improves the response speed, makes up for the problem that the acquisition rate of the Hall signal is too slow under low rotational speed conditions, improves the anti-pinch detection accuracy, and improves the safety of sunroof control.
[0049] In some embodiments of the present application, determining the actual anti-pinch force of the vehicle sunroof according to the rotational speed deviation and the current deviation further includes: determining a first weight corresponding to the actual rotational speed and a second weight corresponding to the actual current according to the current pose; determining the actual anti-pinch force according to the first weight, the second weight, the rotational speed deviation, and the current deviation.
[0050] Specifically, the motor speed and motor current have different responses when the vehicle sunroof is in different poses. To ensure control accuracy, the weight values are set according to the recognition accuracy of the motor speed and motor current for the anti-pinch force when the vehicle sunroof is in different poses. During the application process, the first weight corresponding to the actual speed and the second weight corresponding to the actual current are obtained by calling and recognizing the preset parameters, and then the actual anti-pinch force is calculated according to the first weight corresponding to the actual speed, the second weight corresponding to the actual current, the speed deviation, and the current deviation, which is used for the trigger judgment of the anti-pinch function.
[0051] This embodiment calibrates the weights of the dual signals according to the pose information of the vehicle sunroof, improving the control flexibility and control accuracy.
[0052] In some embodiments of the present application, after determining the first weight corresponding to the actual speed and the second weight corresponding to the actual current according to the current pose, it further includes: obtaining one or more of the startup duration of the drive motor, the supply voltage of the drive motor, the current vehicle speed of the vehicle, the ambient temperature of the vehicle, and the initial position of the vehicle sunroof; adjusting the first weight and / or the second weight according to one or more of the startup duration of the drive motor, the supply voltage of the drive motor, the current vehicle speed of the vehicle, the ambient temperature of the vehicle, and the initial position of the vehicle sunroof.
[0053] Specifically, taking the example of identifying the current speed of the drive motor based on Hall signals, the acquisition frequency of Hall signals is proportional to the speed. In the initial stage of the startup of the drive motor, the motor speed is still low, that is, the first few Hall sampling periods can reach hundreds of milliseconds. At such a low sampling frequency, it is easy to generate speed misjudgment. However, the ADC sampling of the current is driven by the MCU (Microcontroller Unit) timer, and the sampling period is stable at 100 microseconds, which can accurately identify the anti-pinch object when the motor starts. Therefore, in the initial stage of the startup of the drive motor, the second weight can be increased, and the anti-pinch force is judged mainly based on the current sampling result. For example, when the startup duration is less than the preset time, the second weight is adjusted to the second target weight, and the first weight remains unchanged or is adjusted to the first target weight. It is also possible to pre-set the mapping function relationship between the startup duration and the adjustment coefficient of the weight, and the adjustment coefficient is determined in real time through the call of the function relationship to adjust the first weight and / or the second weight.
[0054] The supply voltage of the drive motor can be directly collected by the MCU from the supply terminal of the LDO (Low Dropout Regulator) power supply, and the LDO power supply is used to supply power to the drive motor. The stability of the supply voltage has a great influence on the motor current. Therefore, when the fluctuation amplitude of the supply voltage is greater than the preset threshold, the first weight can be increased to increase the judgment proportion of the motor speed.
[0055] When the current vehicle speed increases, the road conditions are bumpy, and the vibration increases, the probability of anti-pinch misjudgment can be increased. At this time, the first weight and the second weight can be reduced, or the anti-pinch threshold, that is, the preset threshold, can be increased to reduce misjudgment. The ambient temperature of the vehicle can cause the internal resistance of the motor to increase and the resistance of the slide rail to change. At this time, the weight can be reduced or the preset threshold can be increased to reduce misjudgment. The initial position of the vehicle-mounted sunroof affects the resistance of the slide rail. Therefore, the weight can be adjusted according to the initial position of the vehicle-mounted sunroof to prevent misjudgment.
[0056] In this embodiment, the first weight and / or the second weight are adjusted based on one or more of the startup duration of the drive motor, the supply voltage of the drive motor, the current vehicle speed of the vehicle, the ambient temperature of the vehicle, and the initial position of the vehicle-mounted sunroof, so as to improve the control accuracy and enhance the control flexibility.
[0057] In some embodiments of the present application, the actual anti-pinch force is determined according to the first weight, the second weight, the rotational speed deviation, and the current deviation, including: determining a first anti-pinch force according to the rotational speed deviation, and obtaining the product between the first weight and the first anti-pinch force to obtain a second anti-pinch force; determining a third anti-pinch force according to the current deviation, and obtaining the product between the second weight and the third anti-pinch force to obtain a fourth anti-pinch force; obtaining the sum value between the second anti-pinch force and the fourth anti-pinch force to obtain the actual anti-pinch force.
[0058] Specifically, a preset mapping relationship between the rotational speed deviation, the current deviation, and the anti-pinch force can be set respectively. During the sunroof control process, the first anti-pinch force and the third anti-pinch force judged according to the rotational speed deviation and the current deviation are obtained respectively, and then the actual anti-pinch force is obtained through fusion calculation by the first weight and the second weight. The calculation formula is:
[0059] N = N1 * k1 + N2 * k2
[0060] Wherein, N is the actual anti-pinch force, N1 is the first anti-pinch force, k1 is the first weight, N2 is the third anti-pinch force, and k2 is the second weight.
[0061] In some embodiments of the present application, the reference rotational speed and the reference current of the drive motor are matched according to the current pose, including: determining a first target reference model and a second target reference model according to the position interval where the current pose is located; inputting the current pose into the first target reference model to output the reference rotational speed; inputting the current pose into the second target reference model to output the reference current.
[0062] Specifically, in the case of no anti-pinch force, that is, when there is no obstacle during the movement of the vehicle sunroof, the reference current and reference speed of the vehicle sunroof at each position are different, but show a stable change pattern. Therefore, the motor motion characteristic curves are fitted with the current and speed respectively according to the sunroof position for subsequent calculation of the reference current and reference speed at each position.
[0063] In the mass-produced sunroof controller, the usage of memory space needs to be considered. During a complete sunroof stroke, tens of thousands of Hall pulses will be generated, and recording all the sampling point curves requires a large amount of memory space. To reduce the memory occupancy while ensuring the control accuracy, the sunroof stroke is partitioned, such as Figure 4 and Figure 5 shown, divided into 5 regions. There are similar parameter change rates within the same region. Therefore, function fitting is performed based on the test data in each region to establish and store the first target reference model and the second target reference model corresponding to each position region. Among them, the first target reference model is used to characterize the relationship between the sunroof pose, that is, the position and the motor speed, and the second target reference model is used to characterize the relationship between the sunroof pose, that is, the position and the motor current.
[0064] Then, the current pose is respectively input into the first target reference model and the second target reference model to obtain the reference speed and reference current, and the actual anti-pinch force is calculated according to the speed deviation between the actual speed and the reference speed and the current deviation between the actual current and the reference current. Actually, the algorithm complexity in the MCU is relatively low, and the anti-pinch algorithm has low requirements for the MCU performance. By recording the motor anti-pinch characteristic curve in a segmented manner, the memory space on the MCU is saved.
[0065] Furthermore, the theoretical derivation process of the anti-pinch algorithm is as follows:
[0066] According to the force balance relationship, the following equation can be obtained:
[0067]
[0068] Among them, F p is the actual anti-pinch force, F m is the motor driving force, F f is the track friction force, m is the mass of the sunroof, is the sunroof acceleration.
[0069] According to the torque balance relationship, the following formula can be obtained:
[0070]
[0071] Among them, T m is the motor output torque, T f is the resistance torque, J r is the moment of inertia, is the angular acceleration.
[0072] Based on the basic torque formula and the complete torque formula including back electromotive force, the following formula is determined:
[0073] T m = K t ·I a (3)
[0074]
[0075] where U is the motor input voltage, K t is the torque constant, I a is the armature current, K e is the back electromotive force constant, R a is the internal resistance of the motor.
[0076] The linear acceleration / angular acceleration conversion formula is as follows:
[0077]
[0078] where l is the radius of rotation and i is the turbine transmission ratio.
[0079] The relationship between torque and driving force is:
[0080]
[0081] According to formulas (1) to (6), the following formula can be obtained:
[0082]
[0083] During a normal motion cycle, the motor input voltage is constant, the resistance to be overcome is constant. Additionally, under this operating condition, the motor output speed is ωr and the driving voltage is Ir. Then formula (7) can be simplified to:
[0084]
[0085] Another Then formula (8) can be simplified to:
[0086]
[0087] Usually K t and K e , the resistance of the skylight running on the track is affected by temperature changes. The temperature change curve can be obtained through calibration for temperature compensation; while K2 is only related to the mechanical structure and mass of the skylight and the motor, and is a pure constant term; is the rate of change of speed; ω is the actual motor speed; ω r is the reference speed under normal conditions without anti-pinch force; I ris the reference current under normal working conditions without pinch force prevention; the relationship curve of the actual pinch force F p can be obtained by calibration.
[0088] In this embodiment, corresponding reference models are set according to the skylight stroke partition for determining reference values. On the premise of ensuring the pinch prevention performance, the algorithm is streamlined. In the actual mass production skylight controller project, the selection space of the hardware MCU is increased, which is beneficial to reducing the cost of the hardware BOM (Bill of Material).
[0089] In some embodiments of the present application, the drive motor is provided with two Hall sensors, and the two Hall sensors generate two Hall signals to detect the current pose of the vehicle-mounted skylight, including: obtaining the initial position of the vehicle-mounted skylight and the two Hall signals of the drive motor; determining the moving direction of the vehicle-mounted skylight according to the phase difference between the two Hall signals; determining the moving distance of the vehicle-mounted skylight according to the pulse numbers of the two Hall signals; and determining the current pose of the vehicle-mounted skylight according to the initial position, the moving direction and the moving distance.
[0090] Specifically, a brushed DC motor with four pairs of eight-pole magnetic rings is used to drive the electric skylight, and the magnetic poles are arranged alternately. During the rotation of the motor, the magnetic field changes caused by the magnetic poles will be captured by the Hall sensors. To improve the accuracy of rotational speed sampling and the reliability of signals, the two Hall sensors in the drive motor are arranged orthogonally at 90°. The rotation direction of the drive motor is determined according to the phase difference between the two Hall signals, so as to identify the moving direction of the drive motor driving the vehicle-mounted skylight. The rotation angle of the drive motor is determined according to the pulse numbers of the Hall signals, and thus the moving distance of the vehicle-mounted skylight is obtained by conversion. The initial position of the vehicle-mounted skylight can be obtained according to the position sensor.
[0091] Assume that when controlling the vehicle-mounted skylight to open, the moving direction is negative, and when controlling the vehicle-mounted skylight to close, the moving direction is positive. Then the current pose of the vehicle-mounted skylight can be calculated by the formula L = L0 + S * L1, where L represents the current pose of the vehicle-mounted skylight, L0 represents the initial pose, S represents the moving direction, and L1 represents the moving distance.
[0092] This embodiment uses Hall sensors to record the skylight movement position, which has higher stability and anti-interference ability than using current ripple to deduce the skylight position, so as to achieve precise control of the automatic percentage opening and closing position of the skylight.
[0093] In some embodiments of the present application, collecting the actual rotation speed of the driving motor of the vehicle sunroof includes: obtaining the Hall signal of the driving motor; determining the actual rotation speed of the driving motor according to the pulse width of the Hall signal; or obtaining the ripple current of the driving motor; determining the actual rotation speed of the driving motor according to the change rate of the ripple current; or obtaining the Hall signal and the ripple current of the driving motor; determining the actual rotation speed of the driving motor according to the pulse width of the Hall signal and the change rate of the ripple current.
[0094] Specifically, the actual rotation speed of the driving motor can be determined only according to the pulse width of the Hall signal, or can be determined only according to the change rate of the ripple current, or the actual rotation speed of the driving motor can be identified by combining the pulse width of the Hall signal and the change rate of the ripple current, and there is no specific limitation.
[0095] In the embodiment of determining the actual rotation speed of the driving motor by using the pulse width of the Hall signal, the rotation speed is collected from the Hall sensor, the original parameter is the pulse width, and the Hall pulse width is inversely proportional to the rotation speed. To reduce the data conversion error, the pulse width can be directly used to represent the rotation speed. In this embodiment, the Hall signal is combined with the motor current detection, the motor rotation speed is calculated from the Hall pulse, and the anti-pinch force is identified according to the change of the motor current and the rotation speed. The dual-signal detection improves the reliability of the anti-pinch detection and ensures that there is still a reliable sunroof control function when the Hall sensor fails or the current fluctuates violently due to unstable automotive battery voltage.
[0096] During the commutation of the motor brushes, due to the short-term change in the contact area between the brushes and the commutator, fluctuations in the armature current will occur. This phenomenon is called current ripple. For the controller solution using a high-performance MCU, the motor ripple can be collected and processed at a higher sampling rate. Based on the change rate of the ripple, the motor rotation speed can be calculated, and the ripple current has a higher sampling rate than the Hall signal.
[0097] In addition, for the technical solution of using the dual signals of the Hall signal + ripple current to collect the motor rotation speed and using the dual detection of rotation speed + current to detect the anti-pinch force, under the condition that the performance resources of the MCU are sufficient, more stable and sensitive anti-pinch detection can be improved.
[0098] As a specific embodiment of the present application, as Figure 6 shown, the control method of the vehicle sunroof may include:
[0099] S101, detecting the initial position of the vehicle sunroof and obtaining two-way Hall signals and the actual current of the driving motor of the vehicle sunroof.
[0100] S102, identifying the moving direction of the vehicle sunroof according to the phase difference between the two-way Hall signals.
[0101] S103, calculating the moving distance of the vehicle sunroof according to the number of pulses of the two-way Hall signals.
[0102] S104. Determine the current position of the vehicle-mounted sunroof according to the initial position, moving direction, and moving distance.
[0103] S105. Determine the actual rotational speed of the drive motor according to the pulse width of the Hall signal.
[0104] S106. Match the reference rotational speed and reference current of the drive motor according to the current position.
[0105] S107. Obtain the rotational speed deviation between the actual rotational speed and the reference rotational speed, and determine the first anti-pinch force N1 based on the rotational speed deviation.
[0106] S108. Obtain the current deviation between the actual current and the reference current, and determine the third anti-pinch force N2 based on the current deviation.
[0107] S109. Determine the first weight k1 corresponding to the actual rotational speed and the second weight k2 corresponding to the actual current.
[0108] S110. Calculate the actual anti-pinch force N = N1 * k1 + N2 * k2.
[0109] S111. Determine whether the actual anti-pinch force is greater than or equal to the preset threshold. If so, execute step S112; if not, execute step S113.
[0110] S112. Control the drive motor to drive the vehicle-mounted sunroof to stop or move in the reverse direction.
[0111] S113. Control the drive motor to operate normally.
[0112] The above control method for the vehicle-mounted sunroof has a redundant design by collecting double signals of Hall and current, improving control safety, and calibrating the weights of the double signals according to specific projects, improving application flexibility and the accuracy of anti-pinch recognition.
[0113] In summary, according to the control method for the vehicle-mounted sunroof of the embodiment of the present application, first, the current pose of the vehicle-mounted sunroof is detected, and the actual rotational speed and actual current of the drive motor of the vehicle-mounted sunroof are collected. According to the current pose, the reference rotational speed and reference current of the drive motor are matched. Then, the rotational speed deviation between the actual rotational speed and the reference rotational speed is calculated, and the current deviation between the actual current and the reference current is calculated, and the actual anti-pinch force of the vehicle-mounted sunroof is determined according to the rotational speed deviation and the current deviation, so as to control the drive motor to drive the vehicle-mounted sunroof to stop or move in the reverse direction when the actual anti-pinch force is greater than or equal to the preset threshold. Thus, this method uses the motor rotational speed and motor current together to confirm the actual anti-pinch force, improving the detection accuracy of the anti-pinch force and ensuring the anti-pinch control effect of the sunroof.
[0114] Corresponding to the above embodiment, the present application also proposes a controller.
[0115] As shown Figure 7 in FIG. 0, the controller 100 according to the embodiment of the present application includes a memory 110, a processor 120, and a control program for a vehicle sunroof stored on the memory 110 and executable on the processor 120. When the processor 120 executes the control program for the vehicle sunroof, the above-mentioned control method for the vehicle sunroof is implemented.
[0116] According to the controller of the embodiment of the present application, when the processor executes the control program for the vehicle sunroof, the above-mentioned control method for the vehicle sunroof is implemented. Based on the above-mentioned control method for the vehicle sunroof, the anti-pinch force detection accuracy is improved, and the anti-pinch control effect of the sunroof is ensured.
[0117] Corresponding to the above embodiment, the present application also proposes a control device for a vehicle sunroof.
[0118] As shown Figure 8 in FIG. 1, the control device for a vehicle sunroof according to the embodiment of the present application includes: a detection module 10, a collection module 20, a matching module 30, a determination module 40, and a control module 50.
[0119] Among them, the detection module 10 is used to detect the current position and posture of the vehicle sunroof; the collection module 20 is used to collect the actual rotation speed and actual current of the drive motor of the vehicle sunroof; the matching module 30 is used to match the reference rotation speed and reference current of the drive motor according to the current position and posture; the determination module 40 is used to calculate the rotation speed deviation between the actual rotation speed and the reference rotation speed, and calculate the current deviation between the actual current and the reference current, and determine the actual anti-pinch force of the vehicle sunroof according to the rotation speed deviation and the current deviation; the control module 50 is used to control the drive motor to drive the vehicle sunroof to stop or move in the reverse direction when the actual anti-pinch force is greater than or equal to a preset threshold.
[0120] According to an embodiment of the present application, the determination module 40 determines the actual anti-pinch force of the vehicle sunroof according to the rotation speed deviation and the current deviation, specifically: determining a first weight corresponding to the actual rotation speed and a second weight corresponding to the actual current according to the current position and posture; determining the actual anti-pinch force according to the first weight, the second weight, the rotation speed deviation, and the current deviation.
[0121] According to an embodiment of the present application, after the determination module 40 determines the first weight corresponding to the actual rotation speed and the second weight corresponding to the actual current according to the current position and posture, it is further used to: obtain one or more of the start duration of the drive motor, the supply voltage of the drive motor, the current vehicle speed of the vehicle, the ambient temperature of the vehicle, and the initial position of the vehicle sunroof; adjust the first weight and / or the second weight according to one or more of the start duration of the drive motor, the supply voltage of the drive motor, the current vehicle speed of the vehicle, the ambient temperature of the vehicle, and the initial position of the vehicle sunroof.
[0122] According to an embodiment of the present application, the determination module 40 determines the actual anti-pinch force according to the first weight, the second weight, the rotational speed deviation, and the current deviation. Specifically, it is used to: determine the first anti-pinch force according to the rotational speed deviation, and obtain the product between the first weight and the first anti-pinch force to obtain the second anti-pinch force; determine the third anti-pinch force according to the current deviation, and obtain the product between the second weight and the third anti-pinch force to obtain the fourth anti-pinch force; obtain the sum value between the second anti-pinch force and the fourth anti-pinch force to obtain the actual anti-pinch force.
[0123] According to an embodiment of the present application, the matching module 30 matches the reference rotational speed and the reference current of the driving motor according to the current pose. Specifically, it is used to: determine the first target reference model and the second target reference model according to the position interval where the current pose is located; input the current pose into the first target reference model to output the reference rotational speed; input the current pose into the second target reference model to output the reference current.
[0124] According to an embodiment of the present application, the driving motor is provided with two Hall sensors, and the two Hall sensors generate two Hall signals. The detection module 10 detects the current pose of the vehicle sunroof. Specifically, it is used to: obtain the initial position of the vehicle sunroof and the two Hall signals of the driving motor; determine the moving direction of the vehicle sunroof according to the phase difference between the two Hall signals; determine the moving distance of the vehicle sunroof according to the pulse numbers of the two Hall signals; determine the current pose of the vehicle sunroof according to the initial position, the moving direction, and the moving distance.
[0125] According to an embodiment of the present application, the acquisition module 20 acquires the actual rotational speed of the driving motor of the vehicle sunroof. Specifically, it is used to: obtain the Hall signal of the driving motor; determine the actual rotational speed of the driving motor according to the pulse width of the Hall signal; or obtain the ripple current of the driving motor; determine the actual rotational speed of the driving motor according to the change rate of the ripple current; or obtain the Hall signal and the ripple current of the driving motor; determine the actual rotational speed of the driving motor according to the pulse width of the Hall signal and the change rate of the ripple current.
[0126] It should be noted that for the details not disclosed in the control device of the vehicle sunroof in the embodiments of the present application, please refer to the details disclosed in the control method of the vehicle sunroof in the above embodiments of the present application, and will not be elaborated here specifically.
[0127] The control device of the vehicle sunroof according to the embodiment of the present application detects the current position and pose of the vehicle sunroof through a detection module, collects the actual rotation speed and actual current of the drive motor of the vehicle sunroof through a collection module, matches the reference rotation speed and reference current of the drive motor according to the current position and pose through a matching module, calculates the rotation speed deviation between the actual rotation speed and the reference rotation speed through a determination module, calculates the current deviation between the actual current and the reference current, and determines the actual anti-pinch force of the vehicle sunroof according to the rotation speed deviation and the current deviation. When the actual anti-pinch force is greater than or equal to a preset threshold, the control module controls the drive motor to drive the vehicle sunroof to stop or move in the reverse direction. Thus, the device uses both the motor rotation speed and the motor current to confirm the actual anti-pinch force, improving the anti-pinch force detection accuracy and ensuring the anti-pinch control effect of the sunroof.
[0128] Corresponding to the above embodiment, the present application also proposes a vehicle.
[0129] As Figure 9 shown, the vehicle 200 according to the embodiment of the present application includes the above-mentioned controller 100, or as Figure 10 shown, the vehicle 200 according to the embodiment of the present application includes the control device 210 of the vehicle sunroof mentioned above.
[0130] The vehicle according to the embodiment of the present application, based on the above-mentioned controller or the control device of the vehicle sunroof, improves the anti-pinch force detection accuracy, ensures the anti-pinch control effect of the sunroof, and enhances the safety of the vehicle.
[0131] It should be noted that the logic and / or steps represented in the flowchart or otherwise described herein, for example, can be considered as a definite sequence list of executable instructions for implementing logical functions, and can be specifically implemented in any computer-readable medium for use by an instruction execution system, apparatus, or device (such as a computer-based system, a system including a processor, or other systems that can fetch and execute instructions from the instruction execution system, apparatus, or device), or in combination with these instruction execution systems, apparatuses, or devices. For the purposes of this specification, a "computer-readable medium" can be any device that can contain, store, communicate, propagate, or transport a program for use by or in combination with an instruction execution system, apparatus, or device. More specific examples (non-exhaustive list) of computer-readable media include the following: an electrical connection portion with one or more wirings (electronic device), a portable computer diskette (magnetic device), a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber device, and a portable compact disc read-only memory (CDROM). Additionally, the computer-readable medium can even be paper or other suitable media on which the program can be printed, because the program can be obtained electronically, for example, by optically scanning the paper or other media, followed by editing, interpretation, or otherwise processing as appropriate, and then storing it in a computer memory.
[0132] It should be understood that various parts of the present application can be implemented using hardware, software, firmware, or combinations thereof. In the above-described embodiments, multiple steps or methods can be implemented using software or firmware stored in a memory and executed by a suitable instruction execution system. For example, if implemented using hardware, as in another embodiment, any one or a combination of the following techniques well known in the art can be used: discrete logic circuits having logic gate circuits for implementing logical functions on data signals, application specific integrated circuits having appropriate combinational logic gate circuits, programmable gate arrays (PGAs), field programmable gate arrays (FPGAs), etc.
[0133] In the description of this specification, the description with reference to terms such as "one embodiment", "some embodiments", "example", "specific example", or "some examples", etc. means that the specific features, structures, materials, or characteristics described in connection with the embodiment or example are included in at least one embodiment or example of the present application. In this specification, the schematic representations of the above terms do not necessarily refer to the same embodiment or example. Moreover, the specific features, structures, materials, or characteristics described can be combined in a suitable manner in any one or more embodiments or examples.
[0134] In addition, the terms "first" and "second" are used for descriptive purposes only and should not be construed as indicating or implying relative importance or implicitly specifying the quantity of the indicated technical features. Thus, features defined with "first" and "second" may explicitly or implicitly include at least one such feature. In the description of this application, the meaning of "a plurality" is at least two, such as two, three, etc., unless otherwise specifically and explicitly defined.
[0135] In this application, unless otherwise clearly specified and defined, terms such as "installed", "connected", "linked", "fixed", etc. shall be understood in a broad sense. For example, it may be a fixed connection, a detachable connection, or integrated; it may be a mechanical connection or an electrical connection; it may be directly connected or indirectly connected through an intermediate medium, and it may be the communication inside two elements or the interaction relationship between two elements, unless otherwise clearly defined. For those of ordinary skill in the art, the specific meanings of the above terms in this application can be understood according to specific circumstances.
[0136] Although the embodiments of this application have been shown and described above, it can be understood that the above embodiments are exemplary and should not be construed as limiting this application. Those of ordinary skill in the art can make changes, modifications, substitutions, and variations to the above embodiments within the scope of this application.
Claims
1. A control method for a vehicle sunroof, characterized in that, Including: Detecting the current pose of the vehicle-mounted sunroof and collecting the actual rotation speed and actual current of the driving motor of the vehicle-mounted sunroof; Matching the reference rotation speed and reference current of the driving motor according to the current pose; Calculating the rotation speed deviation between the actual rotation speed and the reference rotation speed, calculating the current deviation between the actual current and the reference current, and determining the actual anti-pinch force of the vehicle-mounted sunroof according to the rotation speed deviation and the current deviation, so as to control the driving motor to drive the vehicle-mounted sunroof to stop or move in the reverse direction when the actual anti-pinch force is greater than or equal to a preset threshold.
2. The control method of the vehicle sunroof according to claim 1, characterized in that, The determining the actual anti-pinch force of the vehicle-mounted sunroof according to the rotation speed deviation and the current deviation further includes: Determining a first weight corresponding to the actual rotation speed and a second weight corresponding to the actual current according to the current pose; Determining the actual anti-pinch force according to the first weight, the second weight, the rotation speed deviation, and the current deviation.
3. The control method of the vehicle sunroof according to claim 2, wherein, After determining the first weight corresponding to the actual rotation speed and the second weight corresponding to the actual current according to the current pose, it further includes: Obtaining one or more of the startup duration of the driving motor, the supply voltage of the driving motor, the current vehicle speed of the vehicle, the ambient temperature of the vehicle, and the initial position of the vehicle-mounted sunroof; Adjusting the weight of the first weight and / or the second weight according to one or more of the startup duration of the driving motor, the supply voltage of the driving motor, the current vehicle speed of the vehicle, the ambient temperature of the vehicle, and the initial position of the vehicle-mounted sunroof.
4. The control method of the vehicle sunroof according to claim 3, characterized in that, The determining the actual anti-pinch force according to the first weight, the second weight, the rotation speed deviation, and the current deviation includes: Determining a first anti-pinch force according to the rotation speed deviation, and obtaining the product between the first weight and the first anti-pinch force to obtain a second anti-pinch force; Determining a third anti-pinch force according to the current deviation, and obtaining the product between the second weight and the third anti-pinch force to obtain a fourth anti-pinch force; Obtaining the sum value between the second anti-pinch force and the fourth anti-pinch force to obtain the actual anti-pinch force.
5. The control method of the vehicle sunroof according to claim 1, wherein, The matching the reference rotation speed and reference current of the driving motor according to the current pose includes: Determining a first target reference model and a second target reference model according to the position interval where the current pose is located; Inputting the current pose into the first target reference model to output the reference rotation speed; Inputting the current pose into the second target reference model to output the reference current.
6. The control method of the vehicle sunroof according to claim 5, characterized in that, The driving motor is provided with two Hall sensors, and the two Hall sensors generate two Hall signals. The detecting the current pose of the vehicle-mounted sunroof includes: Obtaining the initial position of the vehicle-mounted sunroof and the two Hall signals of the driving motor; Determining the moving direction of the vehicle-mounted sunroof according to the phase difference between the two Hall signals; Determining the moving distance of the vehicle-mounted sunroof according to the pulse numbers of the two Hall signals; Determining the current pose of the vehicle-mounted sunroof according to the initial position, the moving direction, and the moving distance.
7. The control method of the vehicle sunroof according to any one of claims 1-6, characterized in that, Collecting the actual rotation speed of the driving motor of the vehicle sunroof includes: Obtaining the Hall signal of the driving motor; Determining the actual rotation speed of the driving motor according to the pulse width of the Hall signal; or Obtaining the ripple current of the driving motor; Determining the actual rotation speed of the driving motor according to the change rate of the ripple current; or Obtaining the Hall signal and the ripple current of the driving motor; Determining the actual rotation speed of the driving motor according to the pulse width of the Hall signal and the change rate of the ripple current.
8. A controller, characterized in that, It includes a memory, a processor, and a control program for the vehicle sunroof stored on the memory and executable on the processor. When the processor executes the control program for the vehicle sunroof, it implements the control method for the vehicle sunroof according to any one of claims 1-7.
9. A control device for a vehicle sunroof, characterized in that, It includes: A detection module for detecting the current position and pose of the vehicle sunroof; A collection module for collecting the actual rotation speed and actual current of the driving motor of the vehicle sunroof; A matching module for matching the reference rotation speed and reference current of the driving motor according to the current position and pose; A determination module for calculating the rotation speed deviation between the actual rotation speed and the reference rotation speed, calculating the current deviation between the actual current and the reference current, and determining the actual anti-pinch force of the vehicle sunroof according to the rotation speed deviation and the current deviation; A control module for controlling the driving motor to drive the vehicle sunroof to stop or move in the reverse direction when the actual anti-pinch force is greater than or equal to a preset threshold.
10. A vehicle, characterized in that, It includes the controller according to claim 8, or includes the control device for the vehicle sunroof according to claim 9.