Trigger recognition algorithm based on three-axis acceleration sensor
Through a trigger recognition algorithm based on a three-axis acceleration sensor, combined with a sliding window integration and real-time update mechanism, the slow response and false triggering problems of existing collision detection algorithms are solved, and fast and reliable vehicle collision detection is achieved, which is suitable for embedded devices and low-power terminals.
Patent Information
- Application Number
- CN202510860154.6
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-06-25
- Publication Date
- 2025-09-12
AI Technical Summary
Existing collision detection algorithms cannot effectively perceive changes in vehicle speed and rely on server system detection, resulting in a high risk of false triggering and slow response speed, making it impossible to quickly detect vehicle collision accidents.
A trigger recognition algorithm based on a three-axis accelerometer is adopted. Through sliding window integration and real-time update mechanism, the acceleration change is calculated in real time. The trigger signal is judged in combination with the velocity change threshold. Piezoresistive MEMS sensitive elements and single-crystal silicon chips processed by bulk silicon MEMS technology are used to optimize anti-interference performance and resource efficiency.
It improves the real-time response capability of collision detection, reduces the risk of false triggering, reduces computational complexity and resource consumption, extends battery life, is suitable for embedded devices and low-power terminals, and enhances the applicability of the algorithm in complex environments.
Smart Images

Figure CN120629640A_ABST
Abstract
Description
Technical Field
[0001] The present invention belongs to the technical field of signal detection, and in particular relates to a trigger recognition algorithm based on a three-axis acceleration sensor. Background Art
[0002] The number of motor vehicles is increasing year by year, and this huge number of vehicles poses a significant challenge to road carrying capacity. Traffic accidents are also a frequent occurrence, and once a traffic accident occurs, it will lead to even more severe congestion. In response to the frequent collision accidents on the road, current collision detection algorithms mostly rely solely on the detection of acceleration signals, are unable to perceive changes in vehicle speed, and most rely on server systems for detection. Therefore, there is an urgent need for methods that can realize automatic vehicle collision detection, quickly detect vehicle collision accidents and complete the claims process quickly, which will play a vital role in effectively alleviating traffic congestion and preventing secondary traffic accidents. Summary of the Invention
[0003] The present invention provides a trigger recognition algorithm based on a three-axis acceleration sensor, which enhances anti-interference performance, reduces the risk of false triggering, and takes into account both response speed and reliability.
[0004] In order to achieve the above object, the present invention adopts the following specific technical solutions: A trigger recognition algorithm based on a three-axis acceleration sensor includes the following steps: Step 1: The acceleration signal collected by the three-axis acceleration sensor is integrated into an integration period according to a predetermined sampling period; Step 2, calculate the speed change during the integration period; Step 3, comparing the speed change with a set speed change threshold; Step 4: If the velocity change is less than the velocity change threshold, the new acceleration value collected by the three-axis acceleration sensor replaces the first acceleration value of the integration period, and the velocity change is recalculated, and the process returns to step 3; if the velocity change is greater than or equal to the velocity change threshold, it is determined that the trigger signal is recognized and the trigger signal is output.
[0005] Furthermore, in step 2, a numerical integration algorithm is used to calculate the speed change during the integration period.
[0006] Furthermore, in step 2, the numerical integration algorithm formula for calculating the integral period speed change is: ; In the above formula, a 、 b is the integration interval of the integration period, n is the number of equal parts of the integration period,h is the integration interval and is 1 / the integration period n , h =( b - a ) / n , x k For the k The points of the integration interval, , k =0, 1, ..., n .
[0007] Furthermore, in step 2, the velocity changes in the X, Y, and Z directions are calculated simultaneously.
[0008] Furthermore, the velocity change is the vector sum of the three-axis acceleration signals of the three-axis acceleration sensor, and the calculation formula is: ; In the above formula, Δ v is the vector sum of velocity changes, Δ v x is the acceleration change in the X-axis direction, Δ v y is the acceleration change in the Y-axis direction, Δ v z is the acceleration change in the Z-axis direction.
[0009] Furthermore, the three-axis acceleration sensor includes a piezoresistive MEMS sensitive element and a single crystal silicon chip processed using a bulk silicon MEMS process.
[0010] Furthermore, the piezoresistive MEMS sensitive element is provided with movable beams that inherit sensitive resistance in the X, Y, and Z directions. When subjected to acceleration, the resistance on the beam is deformed, and the piezoresistive effect causes the resistance value to change, causing the constructed Wheatstone bridge to lose balance and generate output, and the output value is proportional to the acceleration.
[0011] Furthermore, the Wheatstone bridge is provided with a balancing circuit for making its output zero in an initial state.
[0012] Furthermore, the balancing circuit includes a resistor R1, a resistor R2, a resistor R3, a resistor R4, a compensation resistor R X1 and compensation resistor R X2 ; In the static state, the three-axis acceleration sensor is powered by a DC power supply. After power supply, the output voltage of the Wheatstone bridge is measured and the compensation resistor R is continuously adjusted. X2 The resistance value is used to find the resistance point that makes the output voltage zero or close to zero, and the balancing is completed, where R X1Provides basic compensation, R X2 Provides final fine zeroing.
[0013] Furthermore, the compensation resistor R X1 The compensation resistor R X2 It is an adjustable resistor.
[0014] Compared with the prior art, the technical solution of the present invention has the following beneficial effects: The trigger recognition algorithm of the present invention achieves efficient and stable trigger event detection in discrete acceleration signal processing by combining sliding window integration with a real-time update mechanism. Its core lies in using a fixed-length integration period as a dynamic analysis window, replacing the oldest value in the window with new data after each sampling, and quickly updating the integration result, thereby calculating the acceleration change in real time.
[0015] Compared to traditional integration methods, this trigger recognition algorithm significantly improves real-time responsiveness. The calculation is updated immediately after each sampling, eliminating the need to wait for a full cycle to complete. This ensures the system can quickly capture transient changes, making it particularly suitable for latency-sensitive emergency scenarios such as collision detection and fall alarms. Furthermore, the sliding window structure, combined with incremental computation optimization, significantly reduces resource consumption. A fixed window length reduces memory usage and computational complexity, making the algorithm more efficient and extending battery life in embedded devices or low-power terminals. Furthermore, the integration process inherently exhibits noise suppression properties. By accumulating acceleration within a time window, it smooths high-frequency random noise and focuses on sustained trends. Incorporating a velocity change threshold rather than relying on instantaneous acceleration further enhances interference resistance and reduces the risk of false triggering. Furthermore, the algorithm's parameters are flexible, allowing for adjustable integration window lengths. Shorter windows increase sensitivity but may introduce fluctuations, while longer windows enhance stability but slightly increase latency, allowing for a balanced choice tailored to specific scenarios. The trigger threshold can also be dynamically set or adaptively adjusted, expanding the algorithm's applicability in complex environments.
[0016] The trigger recognition algorithm of the present invention provides a lightweight solution for dynamic signal trigger detection that takes into account both response speed and reliability through the coordinated optimization of real-time performance, noise immunity and resource efficiency. BRIEF DESCRIPTION OF THE DRAWINGS
[0017] Figure 1 This is a flow chart of a trigger recognition algorithm based on a three-axis acceleration sensor of the present invention; Figure 2 This is the principle diagram of the constant period acceleration integration method; Figure 3 This is the trim circuit diagram. DETAILED DESCRIPTION
[0018] The following will clearly and completely describe the technical solutions in the embodiments of the present invention in conjunction with the accompanying drawings. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without making creative efforts are within the scope of protection of the present invention.
[0019] The embodiment of the present invention provides a trigger recognition algorithm based on a three-axis acceleration sensor, the flow chart of which is as follows: Figure 1 As shown, its principle diagram is as follows Figure 2 As shown, the sensitive element of the three-axis acceleration sensor adopts a piezoresistive MEMS sensitive element. The core part of the three-axis acceleration sensor is a single crystal silicon chip processed by the bulk silicon MEMS process. After the acceleration sensor collects the acceleration signal, it uses a reasonable predetermined sampling period as an integration period to integrate each axial acceleration of the acceleration sensor using a numerical integration algorithm. At the same time, the new acceleration signal collected replaces the first acceleration signal in the integration period, and the velocity change is continuously calculated. After obtaining the velocity change in each direction, the vector sum of the three-axis acceleration change is calculated according to the calculation formula to obtain the total velocity change, which is compared with the set velocity change threshold. If the velocity change is greater than the set velocity change threshold, it is considered that the trigger signal is recognized and the trigger signal is output. Otherwise, the new acceleration signal collected this time replaces the old acceleration signal, and the new velocity change is calculated, which is then compared with the set velocity change threshold.
[0020] In the above embodiment, the numerical integration algorithm formula for calculating the integral period speed change is: ; In the above formula, a 、 b is the integration interval of the integration period, n is the number of equal parts of the integration period, h is the integration interval and is 1 / the integration period n , h =( b - a ) / n , x k For the k The points of the integration interval, , k =0, 1, ..., n .
[0021] When calculating the velocity change during the integration period, the velocity changes in the X, Y, and Z directions must be calculated simultaneously. The formula for calculating the vector sum of the three-axis acceleration signals of the sensor is: ; In the above formula, Δ v is the vector sum of velocity changes, Δ v x , Δ v y , Δ v z is the velocity change in the three-axis direction of acceleration.
[0022] Taking the X-axis direction of the three-axis accelerometer as an example, the following formula is obtained:
[0023] In the above formula, Δ v x Time window T The speed change of the acceleration sensor on the X axis; а 0 is the time window T The acceleration value sampled at the start time; а m Time window T The acceleration value sampled at the end time; а k Time window T The acceleration value within; f s The sampling frequency of the accelerometer is in Hz, which means the number of samples per second. m Time window T The number of sampling intervals within represents the number of intervals from the starting point to the end point. m The value of is related to the time window size and sampling rate and satisfies T = m / f s .
[0024] The calculation method for the velocity change of the Y and Z axes of the triaxial acceleration sensor is the same as the calculation method for the velocity change of the X axis.
[0025] The three-axis accelerometer is used to collect acceleration signals. It uses a piezoresistive MEMS sensitive element. The core part is a single-crystal silicon chip processed using bulk silicon MEMS technology. Movable beams with inherited sensitive resistors are set in the X-axis, Y-axis, and Z-axis directions. When the device is subjected to acceleration, the resistors on the beams deform, and the piezoresistive effect causes the resistance value to change. The Wheatstone bridge loses balance and produces an output. The output value is proportional to the applied acceleration. The Wheatstone bridge is designed with a balancing circuit so that its output is zero in the initial state. The balancing circuit diagram is shown below. Figure 3 As shown, resistors R1, R2, R3 and R4 are internal resistors of the Wheatstone bridge, R X1 and R X2 To compensate for the resistance, the accelerometer is powered by a DC power supply in a stationary state. After power supply, the output voltage of the Wheatstone bridge is measured and the compensation resistor R is continuously adjusted. X2 The resistance value is used to find the resistance point that makes the output voltage zero or close to zero, and the balancing is completed, where R X1 Provides basic compensation, R X2 Provides final fine zero adjustment; R X1 The chip resistor is 51KΩ / ±1%, that is, R X1 The resistance is 51KΩ, and the error range between the actual resistance and the nominal resistance is within ±1% of the nominal resistance; R X2 It is an adjustable resistor.
[0026] The trigger recognition algorithm described above achieves efficient and stable trigger event detection in discrete acceleration signal processing by combining sliding window integration with a real-time update mechanism. Its core lies in using a fixed-length integration period as a dynamic analysis window. After each sampling, the oldest value in the window is replaced by new data, and the integration result is quickly updated, thereby calculating the acceleration change in real time.
[0027] Compared to traditional integration methods, this trigger recognition algorithm significantly improves real-time responsiveness. The calculation is updated immediately after each sampling cycle, eliminating the need to wait for a full cycle to complete. This ensures the system can quickly capture transient changes, making it particularly suitable for latency-sensitive emergency scenarios such as collision detection and fall alarms. Furthermore, the sliding window structure, combined with incremental computation optimization, significantly reduces resource consumption. A fixed window length reduces memory usage and computational complexity, making the algorithm more efficient and extending battery life in embedded devices or low-power terminals. Furthermore, the integration process inherently exhibits noise suppression properties. By accumulating acceleration within a time window, it smooths high-frequency random noise and focuses on sustained trends. Incorporating a velocity change threshold rather than relying on instantaneous acceleration further enhances interference resistance and reduces the risk of false triggering. Furthermore, the algorithm's parameters are flexible, allowing for adjustable integration window lengths. Shorter windows increase sensitivity but may introduce fluctuations, while longer windows enhance stability but slightly increase latency, allowing for a balanced choice tailored to specific scenarios. The trigger threshold can also be dynamically set or adaptively adjusted, expanding the algorithm's applicability in complex environments.
[0028] The trigger recognition algorithm mentioned above provides a lightweight solution for dynamic signal trigger detection that takes into account both response speed and reliability through the coordinated optimization of real-time performance, noise immunity and resource efficiency.
[0029] Obviously, those skilled in the art may make various changes and modifications to the embodiments of the present invention without departing from the spirit and scope of the present invention. Thus, if such modifications and variations of the present invention fall within the scope of the claims and their equivalents, the present invention is intended to include such modifications and variations.
Claims
1. A trigger recognition algorithm based on a three-axis acceleration sensor, characterized in that: The following steps are involved: Step 1: The acceleration signal collected by the three-axis acceleration sensor is integrated into an integration period according to a predetermined sampling period; Step 2, calculate the speed change during the integration period; Step 3, comparing the speed change with a set speed change threshold; Step 4: If the velocity change is less than the velocity change threshold, the new acceleration value collected by the three-axis acceleration sensor replaces the first acceleration value of the integration period, and the velocity change is recalculated, and the process returns to step 3; if the velocity change is greater than or equal to the velocity change threshold, it is determined that the trigger signal is recognized and the trigger signal is output.
2. The trigger recognition algorithm according to claim 1, wherein: In step 2, a numerical integration algorithm is used to calculate the velocity variation during the integration period.
3. The trigger recognition algorithm according to claim 2, wherein: In step 2, the numerical integration algorithm formula for calculating the integral period velocity change is: ; In the above formula, a 、 b is the integration interval of the integration period, n is the number of equal parts of the integration period, h is the integration interval and is 1 / the integration period n , h =( b - a ) / n , x k For the k The points of the integration interval, , k =0, 1, ..., n .
4. The trigger recognition algorithm according to claim 3, wherein: In step 2, the velocity changes in the X, Y, and Z directions are calculated simultaneously.
5. The trigger recognition algorithm according to claim 4, characterized in that: The velocity change is the vector sum of the three-axis acceleration signals of the three-axis acceleration sensor, and the calculation formula is: ; In the above formula, Δ v is the vector sum of velocity changes, Δ v x is the acceleration change in the X-axis direction, Δ v y is the acceleration change in the Y-axis direction, Δ v z is the acceleration change in the Z-axis direction.
6. The trigger recognition algorithm according to claim 1, wherein: The three-axis acceleration sensor includes a piezoresistive MEMS sensitive element and a single crystal silicon chip processed by a bulk silicon MEMS process.
7. The trigger recognition algorithm according to claim 6, characterized in that: The piezoresistive MEMS sensitive element is provided with movable beams with inherited sensitive resistors in the X, Y, and Z directions. When subjected to acceleration, the resistors on the beams deform, and the piezoresistive effect causes the resistance value to change. The formed Wheatstone bridge loses balance and generates output, and the output value is proportional to the acceleration.
8. The trigger recognition algorithm according to claim 7, wherein: The Wheatstone bridge is provided with a balancing circuit for making its output zero in an initial state.
9. The trigger recognition algorithm according to claim 8, wherein: The balancing circuit includes resistors R1, R2, R3, R4, and compensation resistor R X1 and compensation resistor R X2 ; In the static state, the three-axis acceleration sensor is powered by a DC power supply. After power supply, the output voltage of the Wheatstone bridge is measured and the compensation resistor R is continuously adjusted. X2 The resistance value is used to find the resistance point that makes the output voltage zero or close to zero, and the balancing is completed, where R X1 Provides basic compensation, R X2 Provides final fine zeroing.
10. The trigger recognition algorithm according to claim 9, wherein: The compensation resistor R X1 The compensation resistor R X2 It is an adjustable resistor.