Tail gate anti-pinch method, electronic equipment and readable storage medium
By collecting motor parameters and adjusting the anti-pinch threshold in real time, the problems of high false alarm rate and poor adaptability in the electric tailgate anti-pinch detection method are solved, achieving higher accuracy and safety.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2026-03-03
- Publication Date
- 2026-04-07
AI Technical Summary
Existing anti-pinch detection methods for electric tailgates use fixed or empirical thresholds, which fail to adapt to complex and ever-changing actual working conditions, resulting in high false alarm rates, long response delays, and poor adaptability.
By collecting motor parameters, the gravity torque compensation, gas spring damping compensation, and environmental compensation are determined, the anti-pinch threshold is adjusted in real time, and the anti-pinch judgment is made based on the baseline current.
It significantly reduces the false alarm rate, improves the accuracy and safety of anti-pinch judgment, adapts to different working conditions, and reduces manual debugging costs.
Smart Images

Figure CN121803128A_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of tailgate anti-pinch technology, and more specifically, to a tailgate anti-pinch method, electronic device, and readable storage medium. Background Technology
[0002] With the continuous improvement of automotive intelligence and comfort features, electric tailgates, as an important functional component of mid-to-high-end models, have been widely used in various passenger vehicles. Electric tailgates use motors to automatically open and close, greatly enhancing user convenience. However, in actual use, the tailgate may trap foreign objects (such as hands, clothing, obstacles, etc.) during its movement. If this is not detected and protected in time, it can easily lead to safety accidents. Therefore, a reliable anti-pinch function has become a key safety requirement for electric tailgate systems.
[0003] Currently, most mainstream electric tailgate anti-pinch detection methods employ indirect detection based on motor current. The basic principle is that when the tailgate encounters external resistance during operation, the load on the drive motor increases, leading to a rise in operating current. By monitoring the current change and comparing it with a preset threshold, it can be determined whether a pinching event has occurred. However, existing technologies generally use fixed current thresholds or empirically set segmented thresholds for anti-pinch judgment, which has significant technical shortcomings and is difficult to adapt to complex and changing actual working conditions.
[0004] In summary, existing anti-pinch methods based on fixed or empirical thresholds fail to consider the unique multi-physics coupling characteristics of tailgate systems, resulting in rigid anti-pinch threshold settings, difficulty in balancing sensitivity and robustness, and problems such as high false alarm rate, long response delay, and poor adaptability. Summary of the Invention
[0005] The purpose of this invention is to provide a tailgate anti-pinch method, electronic device, and readable storage medium, which can improve the accuracy and safety of anti-pinch judgment.
[0006] To achieve the above objectives, the technical solutions adopted in the embodiments of this application are as follows: In a first aspect, embodiments of this application provide a tailgate anti-pinch method, the method comprising: Motor parameters are collected at a preset sampling period each time the tailgate opens or closes; Based on the motor parameters, gravity torque compensation, gas spring damping compensation, and environmental compensation are determined. Determine the baseline current of the motor, wherein the baseline current indicates the long-term stable average load current of the motor when the tailgate is operating normally at a preset angle without clamping. The anti-pinch threshold is determined in real time based on the gravity torque compensation, gas spring damping compensation, environmental compensation, and the baseline current, so as to perform tailgate anti-pinch based on the anti-pinch threshold.
[0007] In an optional implementation, the motor parameters include the equivalent mass of the tailgate, the tailgate opening angle, and the equivalent distance of the tailgate's center of gravity relative to the tailgate pivot. The step of determining the gravitational torque compensation based on these motor parameters includes: The gravitational torque of the tailgate at the tailgate opening angle is determined based on the equivalent mass of the tailgate, the equivalent distance of the tailgate center of gravity relative to the tailgate pivot, the gravitational acceleration, and the tailgate opening angle. The equivalent conversion coefficient of the motor load current is determined based on the gravitational torque; Gravity torque compensation is determined based on the equivalent conversion coefficient of the motor load current and the tailgate opening angle.
[0008] In an optional implementation, the gravitational moment of the tailgate at the tailgate opening angle is calculated using the following formula: =MgLsinθ; in, Let M be the gravitational torque of the tailgate at the tailgate opening angle, g be the equivalent mass of the tailgate, g be the gravitational acceleration, L be the equivalent distance of the tailgate's center of gravity relative to the tailgate's pivot axis, and θ be the tailgate opening angle. The gravitational torque compensation is calculated using the following formula: ; in, For gravitational torque compensation, This is the equivalent conversion factor for the motor load current.
[0009] In an optional implementation, the motor parameters include the tailgate opening angle, and the step of determining the gas spring damping compensation based on the motor parameters includes: The gas spring damping is determined based on the tailgate opening angle. The equivalent current compensation corresponding to the gas spring damping is determined as the gas spring damping compensation.
[0010] In an optional implementation, the gas spring damping is calculated using the following formula: ; in, For gas spring damping, The attenuation amplitude coefficient is related to the angle. The angular attenuation rate coefficient, For the residual force of the stable section, This refers to the opening angle of the tailgate; The gas spring damping compensation is calculated using the following formula: ; in, For gas spring damping compensation. This is the equivalent conversion factor from gas spring force to motor load current. It is a gas spring damper.
[0011] In an optional implementation, the motor parameters include: the real-time ambient temperature during tailgate operation and the current power supply voltage of the tailgate motor. The step of determining environmental compensation based on the motor parameters includes: Environmental compensation is determined based on the real-time ambient temperature during the tailgate's operation and the current power supply voltage of the tailgate motor.
[0012] In an optional implementation, the environmental compensation is calculated using the following formula: ; in, Here, T represents the temperature compensation coefficient, and T is the real-time ambient temperature during the tailgate's operation. For reference temperature, V is the voltage compensation coefficient, and V is the current power supply voltage of the tailgate motor. This is the reference voltage.
[0013] In an optional implementation, the anti-pinch threshold is calculated using the following formula: ; in, Baseline current, For gravitational torque compensation, For gas spring damping compensation. For environmental compensation, For the safety margin of volatility, This refers to the current fluctuation.
[0014] Secondly, embodiments of this application provide an electronic device, including a memory and a processor, wherein the memory stores a computer program, and the processor executes the computer program to implement the steps of the tailgate anti-pinch method.
[0015] Thirdly, embodiments of this application provide a computer-readable storage medium having a computer program stored thereon, which, when executed by a processor, implements the steps of the tailgate anti-pinch method.
[0016] This application has the following beneficial effects: This application collects motor parameters at a preset sampling period during each opening or closing of the tailgate. Based on the motor parameters, it determines gravity torque compensation, gas spring damping compensation, and environmental compensation, and determines the motor's baseline current. The baseline current indicates the long-term stable average load current of the motor when the tailgate is running normally at a preset angle without clamping. Based on gravity torque compensation, gas spring damping compensation, environmental compensation, and baseline current, it determines the anti-pinch threshold in real time, and performs tailgate anti-pinch based on the anti-pinch threshold to improve the accuracy and safety of anti-pinch judgment. Attached Figure Description
[0017] To more clearly illustrate the technical solutions of the embodiments of the present invention, the accompanying drawings used in the embodiments will be briefly introduced below. It should be understood that the following drawings only show some embodiments of the present invention and should not be regarded as a limitation on the scope. For those skilled in the art, other related drawings can be obtained based on these drawings without creative effort.
[0018] Figure 1 A block diagram of an electronic device provided in an embodiment of the present invention; Figure 2 This is one of the flowcharts illustrating a tailgate anti-pinch method provided in an embodiment of the present invention; Figure 3 This is a second schematic flowchart of a tailgate anti-pinch method provided in an embodiment of the present invention; Figure 4 This is a third flowchart illustrating a tailgate anti-pinch method provided in an embodiment of the present invention. Figure 5 This is a structural block diagram of a tailgate anti-pinch device provided in an embodiment of the present invention. Detailed Implementation
[0019] To make the objectives, technical solutions, and advantages of the embodiments of the present invention clearer, the technical solutions of the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of the present invention, and not all embodiments. The components of the embodiments of the present invention described and shown in the accompanying drawings can generally be arranged and designed in various different configurations.
[0020] Therefore, the following detailed description of the embodiments of the invention provided in the accompanying drawings is not intended to limit the scope of the claimed invention, but merely to illustrate selected embodiments of the invention. All other embodiments obtained by those skilled in the art based on the embodiments of the invention without inventive effort are within the scope of protection of the invention.
[0021] It should be noted that similar labels and letters in the following figures indicate similar items. Therefore, once an item is defined in one figure, it does not need to be further defined and explained in subsequent figures.
[0022] In the description of this invention, it should be noted that if terms such as "upper," "lower," "inner," or "outer" are used to indicate the orientation or positional relationship based on the orientation or positional relationship shown in the accompanying drawings, or the orientation or positional relationship in which the product of this invention is usually placed, they are only for the convenience of describing this invention and simplifying the description, and do not indicate or imply that the device or element referred to must have a specific orientation, or be constructed and operated in a specific orientation, and therefore should not be construed as a limitation of this invention.
[0023] Furthermore, the terms "first" and "second" are used only to distinguish descriptions and should not be interpreted as indicating or implying relative importance.
[0024] In the description of this application, it should also be noted that, unless otherwise expressly specified and limited, the terms "set up," "install," "connect," and "link" should be interpreted broadly. For example, they can refer to a fixed connection, a detachable connection, or an integral connection; they can refer to a mechanical connection or an electrical connection; they can refer to a direct connection or an indirect connection through an intermediate medium; and they can refer to the internal connection of two components. Those skilled in the art can understand the specific meaning of the above terms in this application based on the specific circumstances.
[0025] Research has revealed that most mainstream electric tailgate anti-pinch detection methods currently employ indirect detection based on motor current. The basic principle is that when the tailgate encounters external resistance during operation, the drive motor load increases, leading to a rise in operating current. By monitoring the current change and comparing it to a preset threshold, it can be determined whether a pinching event has occurred.
[0026] However, existing technologies generally use fixed current thresholds or empirically set segmented thresholds for anti-pinch determination, which has significant technical defects and is difficult to adapt to complex and ever-changing actual working conditions.
[0027] Existing anti-pinch methods based on fixed or empirical thresholds fail to consider the unique multi-physics coupling characteristics of tailgate systems, resulting in rigid anti-pinch threshold settings, difficulty in balancing sensitivity and robustness, and problems such as high false alarm rate, long response delay, and poor adaptability.
[0028] In view of the above-mentioned problems, this embodiment provides a tailgate anti-pinch method, electronic device, and readable storage medium. It can collect motor parameters at a preset sampling period during each tailgate opening or closing process, determine gravitational torque compensation, gas spring damping compensation, and environmental compensation based on the motor parameters, and determine the motor's baseline current. The baseline current indicates the long-term stable average load current of the motor when the tailgate is running normally at a preset angle without clamping. Based on gravitational torque compensation, gas spring damping compensation, environmental compensation, and baseline current, an anti-pinch threshold is determined in real time. Tailgate anti-pinch is then performed based on the anti-pinch threshold to improve the accuracy and safety of anti-pinch judgment. The solution provided in this embodiment is described in detail below.
[0029] This embodiment provides an electronic device capable of determining the anti-pinch function of the tailgate. In one possible implementation, the electronic device can be a user terminal, such as, but not limited to, a server, smartphone, personal computer (PC), tablet computer, personal digital assistant (PDA), mobile internet device (MID), etc.
[0030] Please refer to Figure 1 , Figure 1 This is a schematic diagram of the structure of the electronic device 100 provided in the embodiments of this application. The electronic device 100 may further include... Figure 1 The more or fewer components shown, or having the same Figure 1 The different configurations shown. Figure 1 The components shown can be implemented using hardware, software, or a combination thereof.
[0031] The electronic device 100 includes a tailgate anti-pinch device 110, a memory 120, and a processor 130.
[0032] The components of the memory 120 and processor 130 are electrically connected directly or indirectly to achieve data transmission or interaction. For example, these components can be electrically connected to each other through one or more communication buses or signal lines. The tailgate anti-pinch device 110 includes at least one software function module that can be stored in the memory 120 in the form of software or firmware or embedded in the operating system (OS) of the electronic device 100. The processor 130 is used to execute the executable modules stored in the memory 120, such as the software function modules and computer programs included in the tailgate anti-pinch device 110.
[0033] The memory 120 may be, but is not limited to, Random Access Memory (RAM), Read Only Memory (ROM), Programmable Read-Only Memory (PROM), Erasable Programmable Read-Only Memory (EPROM), Electrically Erasable Programmable Read-Only Memory (EEPROM), etc. The memory 120 is used to store programs, and the processor 130 executes the programs after receiving execution instructions.
[0034] Please refer to Figure 2 , Figure 2 For application Figure 1 The flowchart of a tailgate anti-pinch method for electronic device 100 is shown below, and the method includes each step in detail.
[0035] S201: Collect motor parameters at a preset sampling period during each opening or closing of the tailgate.
[0036] S202: Determine gravity torque compensation, gas spring damping compensation, and environmental compensation based on motor parameters.
[0037] S203: Determine the baseline current of the motor.
[0038] Among them, the baseline current indicates the average load current of the motor when the tailgate is running normally at a preset angle without clamping.
[0039] S204: The anti-pinch threshold is determined in real time based on gravity torque compensation, gas spring damping compensation, environmental compensation and baseline current, so as to prevent tailgate from being pinched based on the anti-pinch threshold.
[0040] After each tailgate operation, motor parameters are collected at a preset sampling period. These parameters may include the average current, fluctuation, peak ratio, equivalent mass of the tailgate, equivalent distance from the center of gravity to the shaft, equivalent conversion coefficient of the motor load current, tailgate opening angle, baseline current, real-time ambient temperature during tailgate operation, and current power supply voltage of the tailgate motor.
[0041] Volatility can be calculated using the following formula: ; in, This represents the average current.
[0042] It should be noted that the motor's baseline current also changes in real time during the motor's operation. Based on motor parameters, gravity torque compensation, gas spring damping compensation, and environmental compensation are determined. Baseline current is then compensated to obtain the anti-pinch threshold. The baseline current indicates the long-term stable average load current of the motor when the tailgate is operating normally at a preset angle without clamping.
[0043] By compensating the baseline current based on gravity torque compensation, the load current changes caused by the tailgate's own gravity can be accurately separated, avoiding the misjudgment of normal current fluctuations caused by angle changes as clamping events.
[0044] In electric tailgate control systems, gas springs, also known as struts, are widely used as auxiliary support components to reduce motor load and improve opening smoothness. However, their output force exhibits significant nonlinear time-varying characteristics: it provides a large thrust in the initial stage, rapidly decays as the travel progresses, and tends to stabilize as a residual force in the large-angle region. Therefore, by compensating for the baseline current based on gas spring damping compensation, equivalent current mapping and dynamic correction can be performed on the motor load changes caused by the gas spring, thereby improving anti-pinch sensitivity.
[0045] This application introduces an environmental compensation mechanism, comprehensively considers the impact of temperature changes and power supply voltage fluctuations on the motor drive system, and incorporates it into the generation process of the dynamic anti-pinch threshold, which can significantly improve the stability and accuracy of anti-pinch judgment under different external conditions.
[0046] In summary, this application constructs a multi-dimensional compensation model that includes gravitational torque, gas spring damping, and environmental variables by collecting motor operating parameters. Combined with a long-term self-learning mechanism, it determines the baseline current and generates a dynamic anti-pinch threshold in real time. This enables adaptive anti-pinch capabilities across angles, environments, and lifecycles; significantly reduces false alarm rates and missed detection risks; the algorithm is simple and efficient, suitable for low-cost automotive MCU platforms; it supports automatic calibration and aging compensation, reducing manual debugging costs; and it improves user safety and driving experience.
[0047] There are several ways to determine gravitational torque compensation based on motor parameters. In one such method, such as... Figure 3 As shown, it includes the following steps: The motor parameters include the equivalent mass of the tailgate, the tailgate opening angle, and the equivalent distance of the tailgate's center of gravity relative to the tailgate pivot.
[0048] S301: Determine the gravitational torque of the tailgate at the tailgate opening angle based on the equivalent mass of the tailgate, the equivalent distance between the tailgate center of gravity and the tailgate pivot, the gravitational acceleration, and the tailgate opening angle.
[0049] The equivalent mass of the tailgate is not the actual mass of the entire vehicle tailgate, but rather the equivalent concentrated mass with reference to the pivot axis. The equivalent distance between the tailgate's center of gravity and the tailgate pivot axis is the equivalent force arm length from the tailgate's center of gravity to the pivot axis.
[0050] The gravitational moment of the tailgate at its opening angle is calculated using the following formula: =MgLsinθ; in, Let M be the gravitational torque of the tailgate at the tailgate opening angle, g be the equivalent mass of the tailgate, g be the gravitational acceleration, L be the equivalent distance of the tailgate's center of gravity relative to the tailgate's pivot axis, and θ be the tailgate opening angle.
[0051] S302: Equivalent conversion coefficient for determining motor load current based on gravitational torque.
[0052] The equivalent conversion factor of the motor load current is the same as the equivalent conversion factor of the gravitational torque to the motor load current. The equivalent conversion factor of the motor load current characterizes the gearbox transmission ratio, motor torque constant, mechanism friction, mechanical efficiency, etc. The equivalent conversion factor of the motor load current is the equivalent factor that maps the tailgate gravitational torque to the motor load current, and can be obtained through calibration or online learning.
[0053] Its function is to map the torque generated by gravity at different opening angles of the tailgate into the equivalent current value required by the motor. It does not rely on precise physical modeling of the motor, transmission mechanism or tailgate structure, but is a comprehensive equivalent parameter obtained through system calibration or online learning.
[0054] There are multiple ways to obtain this value. In one implementation, it can be obtained by performing actual tests and calibrations on multiple prototype vehicles under standard operating conditions, and then written as the initial value into the controller's non-volatile memory.
[0055] In another implementation, online self-learning updates can be performed using current and angle data from multiple normal operating processes to compensate for system characteristic drift caused by mechanical wear or environmental changes during vehicle use.
[0056] S303: Gravity torque compensation is determined based on the equivalent conversion coefficient of the motor load current and the tailgate opening angle.
[0057] Gravitational moment compensation is calculated using the following formula: ; in, For gravitational torque compensation, This is the equivalent conversion factor for the motor load current.
[0058] By introducing a gravitational torque compensation mechanism, the anti-pinch threshold can be dynamically adjusted according to the opening angle, effectively distinguishing between normal current fluctuations caused by structural mechanics and abnormal loads caused by external obstacles, thus solving the problem of false triggering caused by angle-related gravity effects in the existing technology.
[0059] Gravity torque compensation is used to correct the baseline current, so that the anti-pinch judgment benchmark always matches the actual load requirements under the current working conditions, thereby improving the system's environmental adaptability and judgment accuracy.
[0060] There are several ways to determine the gas spring damping compensation based on motor parameters. In one method, such as... Figure 4 As shown, it includes the following steps: Motor parameters include the tailgate opening angle.
[0061] S401: Determine the gas spring damping based on the tailgate opening angle.
[0062] The gas spring damping is calculated using the following formula: ; in, For gas spring damping, The attenuation amplitude coefficient is related to the angle. The angular attenuation rate coefficient, For the residual force of the stable section, The opening angle of the tailgate.
[0063] The magnitude of the additional support / damping force provided by the gas spring at a small angle is characterized. The force is large at the initial stage of the tailgate and gradually decreases as the angle increases. The greater the nonlinearity of the damping / support force as a function of angle, the faster it decays. and All of these can be obtained through calibration or learning. This characterizes the basic support force that the gas spring still has at large angles, preventing the model from approaching zero at large angles.
[0064] S402: Determine the equivalent current compensation corresponding to the gas spring damping, as the gas spring damping compensation.
[0065] The gas spring damping compensation is calculated using the following formula: ; in, For gas spring damping compensation. This is the equivalent conversion factor from gas spring force to motor load current. It is a gas spring damper.
[0066] This indicates the equivalent load current that maps the force of the gas spring to the motor side.
[0067] By introducing an angle-dependent gas spring damping compensation mechanism, the nonlinear support force provided by the gas spring at different opening stages is converted into an equivalent motor load current and superimposed on the dynamic anti-pinch threshold. This enables the system to accurately distinguish between normal operation and external clamping states during gas spring force changes, solving the misjudgment problem caused by ignoring the nonlinear characteristics of the strut in the prior art.
[0068] There are several ways to determine environmental compensation based on motor parameters. In one method, environmental compensation is determined based on the real-time ambient temperature and the current power supply voltage of the tailgate motor during tailgate operation.
[0069] Environmental compensation is calculated using the following formula: ; in, Here, T represents the temperature compensation coefficient, and T is the real-time ambient temperature during the tailgate's operation. For reference temperature, V is the voltage compensation coefficient, where V is the current power supply voltage for the tailgate motor. This is the reference voltage.
[0070] T indicates the ambient temperature inside the vehicle, the internal temperature of the tailgate controller, or the vehicle's temperature signal. It indicates the reference temperature selected during system calibration or design, at which the system load characteristics are most stable. The weights describing the impact of temperature changes on the tailgate drive load are typically: lower temperature → increased damping → increased current, a>0.
[0071] Indicates the current power supply voltage of the tailgate motor, which comes from the BMS or MCU ADC. The meaning is the nominal operating voltage (such as a 12V system) or the calibrated reference voltage. When the voltage decreases, in order to obtain the same torque, the threshold for motor current rise needs to be raised accordingly to avoid misjudgment.
[0072] In actual operation, the motor current is strongly correlated with temperature and voltage. A second-order approximation model can be used, for example: a = 0.01 A / °C, b = 0.05 A / V. The lower the temperature and voltage, the higher the threshold is automatically adjusted.
[0073] By introducing a joint compensation mechanism based on real-time ambient temperature and power supply voltage, the anti-pinch threshold can be dynamically adjusted according to external operating conditions, effectively eliminating interference caused by increased system damping due to low temperature or abnormal current rise caused by voltage fluctuations, thus improving the reliability and consistency of anti-pinch judgment in complex environments.
[0074] Environmental compensation generates an environmental correction factor based on preset reference temperature and reference voltage, combined with temperature compensation coefficient and voltage compensation coefficient, and applies it to the basic anti-pinch threshold, thereby obtaining a final anti-pinch judgment threshold that comprehensively reflects the current working conditions. This solves the problem of frequent malfunctions caused by strong environmental sensitivity in existing technologies.
[0075] The anti-pinch threshold is determined in real time based on gravity torque compensation, gas spring damping compensation, environmental compensation, and baseline current. The tailgate anti-pinch function is based on the anti-pinch threshold, which is calculated using the following formula: ; in, Baseline current, For gravitational torque compensation, For gas spring damping compensation. For environmental compensation, For the safety margin of volatility, This refers to the current fluctuation.
[0076] To improve system stability, upper and lower limits can be set to prevent the anti-pinch threshold from getting out of control, thus ensuring that the learned anti-pinch threshold is between the upper and lower limits. If the anti-pinch is triggered N times consecutively, self-learning is paused.
[0077] Each time the anti-pinch threshold is calculated, it is stored in EEPROM or Flash. When power is restored, the last anti-pinch threshold is loaded, realizing long-term self-learning and dynamic self-calibration.
[0078] During the tailgate movement, current changes are monitored in real time. When the current exceeds the self-learned anti-pinch threshold and continues for more than a set time window (e.g., 100 ms), or when the motor speed drops below the minimum threshold, an obstacle state is determined.
[0079] Upon detecting an obstacle, the motor output is immediately stopped, a short-distance reverse action is performed, an audible and visual alarm signal is issued, a log is recorded, and the information is reported to the vehicle control unit.
[0080] The tailgate anti-pinch method based on an anti-pinch threshold can be implemented by calculating the anti-pinch threshold using the method provided in this application each time the power is turned on, and then performing anti-pinch protection based on this threshold. In another example, after calculating the anti-pinch threshold using the tailgate anti-pinch method of this application, the calculated anti-pinch threshold can be used as the tailgate anti-pinch threshold on the next power-on. And determine the average current of the motor within the current sampling period, and calculate the current anti-pinch threshold based on the following formula: ; in, To prevent pinching threshold, This represents the average current.
[0081] If the current current of the motor exceeds the current threshold by 1.2 times and persists for 100 ms, it is considered an obstacle, and the motor immediately stops and reverses 80 mm. After 100 consecutive runs, a stable threshold model is established, and it can be automatically corrected for ±0.2 A based on the temperature curve.
[0082] Experiments show that the algorithm reduces the false alarm rate by 35% and the clamping detection response time by about 120 ms compared to the fixed threshold scheme.
[0083] Please refer to Figure 5 This application embodiment also provides an application for Figure 1 The tailgate anti-pinch device 110 of the electronic device 100 includes: The sampling module 111 is used to collect motor parameters at a preset sampling period during each opening or closing of the tailgate. The determination module 112 is used to determine gravity torque compensation, gas spring damping compensation, and environmental compensation based on the motor parameters; determine the baseline current of the motor, wherein the baseline current indicates the long-term stable average load current of the motor when the tailgate is running normally at a preset angle without clamping; and determine the anti-pinch threshold in real time based on the gravity torque compensation, gas spring damping compensation, environmental compensation, and the baseline current, so as to perform tailgate anti-pinch based on the anti-pinch threshold.
[0084] This application also provides an electronic device 100, which includes a processor 130 and a memory 120. The memory 120 stores computer-executable instructions, which, when executed by the processor 130, implement the tailgate anti-pinch method.
[0085] This application embodiment also provides a computer-readable storage medium storing a computer program, which, when executed by the processor 130, implements the tailgate anti-pinch method.
[0086] In the embodiments provided in this application, it should be understood that the disclosed apparatus and methods can also be implemented in other ways. The apparatus embodiments described above are merely illustrative. For example, the flowcharts and block diagrams in the accompanying drawings illustrate the architecture, functionality, and operation of possible implementations of apparatus, methods, and computer program products according to various embodiments of this application. In this regard, each block in a flowchart or block diagram may represent a module, segment, or portion of code containing one or more executable instructions for implementing a specified logical function. It should also be noted that in some alternative implementations, the functions marked in the blocks may occur in a different order than those marked in the drawings. For example, two consecutive blocks may actually be executed substantially in parallel, and they may sometimes be executed in reverse order, depending on the functions involved. It should also be noted that each block in a block diagram and / or flowchart, and combinations of blocks in block diagrams and / or flowcharts, can be implemented using a dedicated hardware-based system that performs the specified function or action, or using a combination of dedicated hardware and computer instructions.
[0087] Furthermore, the functional modules in the various embodiments of this application can be integrated together to form an independent part, or each module can exist independently, or two or more modules can be integrated to form an independent part. If the function is implemented as a software functional module and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of this application, in essence, or the part that contributes to the prior art, or part of the technical solution, can be embodied in the form of a software product. This computer software product is stored in a storage medium and includes several instructions to cause a computer device (which may be a personal computer, server, or network device, etc.) to execute all or part of the steps of the methods described in the various embodiments of this application. The aforementioned storage medium includes: USB flash drives, portable hard drives, read-only memory (ROM), random access memory (RAM), magnetic disks, optical disks, and other media capable of storing program code.
[0088] It should be noted that, in this document, relational terms such as "first" and "second" are used only to distinguish one entity or operation from another, and do not necessarily require or imply any such actual relationship or order between these entities or operations. Furthermore, the terms "comprising," "including," or any other variations thereof are intended to cover non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements includes not only those elements but also other elements not expressly listed, or elements inherent to such a process, method, article, or apparatus. Without further limitations, an element defined by the phrase "comprising one..." does not exclude the presence of other identical elements in the process, method, article, or apparatus that includes said element.
[0089] The above descriptions are merely various embodiments of this application, but the scope of protection of this application is not limited thereto. Any variations or substitutions that can be easily conceived by those skilled in the art within the technical scope disclosed in this application should be included within the scope of protection of this application. Therefore, the scope of protection of this application should be determined by the scope of the claims.
Claims
1. A tailgate anti-pinch method, characterized in that, The method includes: Motor parameters are collected at a preset sampling period each time the tailgate opens or closes; Based on the motor parameters, gravity torque compensation, gas spring damping compensation, and environmental compensation are determined. Determine the baseline current of the motor, wherein the baseline current indicates the long-term stable average load current of the motor when the tailgate is operating normally at a preset angle without clamping. The anti-pinch threshold is determined in real time based on the gravity torque compensation, gas spring damping compensation, environmental compensation, and the baseline current, so as to perform tailgate anti-pinch based on the anti-pinch threshold.
2. The method according to claim 1, characterized in that, The motor parameters include the equivalent mass of the tailgate, the tailgate opening angle, and the equivalent distance of the tailgate's center of gravity relative to the tailgate pivot. The step of determining gravitational torque compensation based on these motor parameters includes: The gravitational torque of the tailgate at the tailgate opening angle is determined based on the equivalent mass of the tailgate, the equivalent distance of the tailgate center of gravity relative to the tailgate pivot, the gravitational acceleration, and the tailgate opening angle. The equivalent conversion coefficient of the motor load current is determined based on the gravitational torque; Gravity torque compensation is determined based on the equivalent conversion coefficient of the motor load current and the tailgate opening angle.
3. The method according to claim 2, characterized in that, The gravitational moment of the tailgate at the tailgate opening angle is calculated using the following formula: =MgLsinθ; in, Let M be the gravitational torque of the tailgate at the tailgate opening angle, g be the equivalent mass of the tailgate, g be the gravitational acceleration, L be the equivalent distance of the tailgate's center of gravity relative to the tailgate's pivot axis, and θ be the tailgate opening angle. The gravitational torque compensation is calculated using the following formula: ; in, For gravitational torque compensation, This is the equivalent conversion factor for the motor load current.
4. The method according to claim 1, characterized in that, The motor parameters include the tailgate opening angle. The step of determining gas spring damping compensation based on these motor parameters includes: The gas spring damping is determined based on the tailgate opening angle. The equivalent current compensation corresponding to the gas spring damping is determined as the gas spring damping compensation.
5. The method according to claim 4, characterized in that, The gas spring damping is calculated using the following formula: ; in, For gas spring damping, The attenuation amplitude coefficient is related to the angle. The angular attenuation rate coefficient, For the residual force of the stable section, This refers to the opening angle of the tailgate; The gas spring damping compensation is calculated using the following formula: ; in, For gas spring damping compensation. This is the equivalent conversion factor from gas spring force to motor load current. It is a gas spring damper.
6. The method according to claim 1, characterized in that, The motor parameters include: the real-time ambient temperature during tailgate operation and the current power supply voltage of the tailgate motor. The step of determining environmental compensation based on these motor parameters includes: Environmental compensation is determined based on the real-time ambient temperature during the tailgate's operation and the current power supply voltage of the tailgate motor.
7. The method according to claim 6, characterized in that, The environmental compensation is calculated using the following formula: ; in, Here, T represents the temperature compensation coefficient, and T is the real-time ambient temperature during the tailgate's operation. For reference temperature, V is the voltage compensation coefficient, and V is the current power supply voltage of the tailgate motor. This is the reference voltage.
8. The method according to claim 1, characterized in that, The anti-pinch threshold is calculated using the following formula: ; in, Baseline current, For gravitational torque compensation, For gas spring damping compensation. For environmental compensation, For the safety margin of volatility, This refers to the current fluctuation.
9. An electronic device, characterized in that, It includes a memory and a processor, the memory storing a computer program, and the processor executing the computer program to implement the steps of the method according to any one of claims 1-8.
10. A readable storage medium having a computer program stored thereon, characterized in that, When executed by a processor, the computer program implements the steps of the method according to any one of claims 1-8.