Disclosure of Invention
The invention aims to provide a trailer gesture detection method and system, which aim to detect the running gesture of a trailer and give out running advice, can provide real-time and accurate data support for drivers, help the drivers to better control the trailer under complex road conditions and reduce the risk of traffic accidents.
In order to achieve the above object, in a first aspect, the present invention provides a method for detecting a posture of a trailer, including monitoring a posture parameter of the trailer in real time by using a sensor, wherein the posture parameter includes an angular velocity, an acceleration and a vertical height;
Classifying the road surface states according to the historical vertical height data of the left side and the right side of the trailer;
Confirming the current road surface state according to the vertical height data collected in real time;
calculating a recommended steering speed and a maximum steering angle according to the angular speed, the acceleration and the load of the trailer under the current road surface state;
and when the steering speed and the maximum steering angle exceed the preset values, an alarm is sent out.
The specific steps of monitoring the attitude parameters of the trailer in real time by adopting the sensor comprise the following steps:
selecting a corresponding sensor group according to the monitoring requirement;
Fixing the sensor group at the corresponding position of the trailer according to the design layout;
All the sensors are connected to the central processing unit in a wireless mode and calibrated;
and collecting the attitude parameters of the trailer by adopting a sensor group.
The specific step of classifying the road surface state according to the historical vertical height data of the left side and the right side of the trailer comprises the following steps:
Marking the historical vertical height data by adopting a pavement label, wherein the pavement label comprises flatness, pits and slopes;
extracting classification features from the marked historical vertical height data, wherein the classification features comprise difference values of heights of the left side and the right side, average heights, standard deviation and deflection;
dividing the marked data set into a training set and a verification set;
And training the linear support vector machine model by using the training set to obtain a pavement judgment model.
The specific steps of confirming the current road surface state according to the vertical height data collected in real time comprise the following steps:
acquiring vertical height data collected by a sensor;
preprocessing vertical height data;
and applying the road surface judging model to the data acquired in real time, and identifying the current road surface state.
The specific steps of preprocessing the vertical height data comprise:
Checking whether an abnormal height value exists in the vertical height data, and deleting the abnormal height value if the abnormal height value exists;
If there are missing values in the vertical height data, interpolation is used for filling.
The specific steps of calculating the recommended steering speed and the maximum steering angle according to the angular speed, the acceleration and the load of the trailer in the current road surface state include:
Setting a dynamic model according to the angular speed, acceleration and load of the trailer and the road surface state;
calculating the speed of the trailer capable of safely steering under the current road surface condition through a dynamics model;
and calculating a corresponding safe steering angle based on the safe steering vehicle speed.
The specific steps of setting the dynamic model according to the angular speed, the acceleration and the load of the trailer and the road surface state comprise the following steps:
defining basic parameters and a coordinate system;
establishing a kinetic equation based on angular velocity, acceleration and load and road surface state;
acceleration in the x-axis and y-axis is corrected by the rotation dynamics equation.
In a second aspect, the invention also provides a trailer attitude detection system, which comprises a parameter acquisition module, a road classification module, a road detection module, a speed calculation module and an alarm module;
The parameter acquisition module is used for monitoring the attitude parameters of the trailer in real time by adopting a sensor, wherein the attitude parameters comprise angular speed, acceleration and vertical height;
The road surface classification module is used for classifying road surface states according to historical vertical height data of the left side and the right side of the trailer;
the road surface detection module is used for confirming the current road surface state according to the vertical height data collected in real time;
The speed calculation module is used for calculating a recommended steering speed and a maximum steering angle according to the angular speed, the acceleration and the load of the trailer under the current road surface state;
and the alarm module is used for giving an alarm when the steering speed and the maximum steering angle exceed preset values.
According to the trailer attitude detection method and system, the attitude parameters of the trailer are monitored in real time by adopting the high-precision sensor. These attitude parameters mainly include the angular velocity, acceleration and vertical height of the trailer. The angular velocity is used to measure the speed at which the trailer rotates about its axis, the acceleration is used to measure the acceleration of the trailer, and the vertical height is used to monitor the change in distance between the trailer and the ground. Historical vertical height data of the left and right sides of the trailer is collected and analyzed to classify the road surface condition. By this means, different conditions of the road surface, such as a flat road surface, a sloping road surface or a rough road surface, etc., can be identified. And further confirming the current road surface state according to the vertical height data collected in real time. By combining the historical data and the real-time data, the road condition can be judged more accurately, and corresponding driving advice is provided. On the basis of confirming the current road surface state, calculating the recommended steering speed and the maximum steering angle according to the angular speed, the acceleration and the load condition of the trailer. These parameters are critical to ensure safe running of the trailer. The recommended steering speed can help the driver to know the highest speed at which the trailer can safely travel under the current road conditions. The maximum steering angle helps the driver avoid oversteering during cornering, resulting in a runaway trailer. The steering vehicle speed and the maximum steering angle are monitored in real time, and the system will immediately give an alarm as soon as their values exceed a preset safety threshold. Thus, the driver can take measures in time to ensure the safe running of the trailer. By the method, the trailer posture detection system can provide real-time and accurate data support for drivers, help the drivers to better control the trailer under complex road conditions, and reduce the risk of traffic accidents.
Detailed Description
Embodiments of the present invention are described in detail below, examples of which are illustrated in the accompanying drawings, wherein like or similar reference numerals refer to like or similar elements or elements having like or similar functions throughout. The embodiments described below by referring to the drawings are illustrative and intended to explain the present invention and should not be construed as limiting the invention.
Referring to fig. 1 to 7, the invention provides a trailer gesture detection method, which includes:
S101, adopting a sensor to monitor attitude parameters of a trailer in real time, wherein the attitude parameters comprise angular speed, acceleration and vertical height;
the method comprises the following specific steps:
s201, selecting a corresponding sensor group according to the monitoring requirement;
And carefully selecting a proper sensor combination according to actual monitoring requirements. This process involves performance assessment of different types of sensors (such as MEMS gyroscopes, accelerometers, and sophisticated lidar or ultrasonic sensors), ensuring that the selected sensor is capable of satisfying both the capture of subtle changes in trailer attitude and adapting to a variety of complex road environments and weather conditions. For example, in areas where rain or fog is frequent, the waterproof and dust-proof rating and tamper resistance of the sensor can be important considerations.
S202, fixing a sensor group at a corresponding position of a trailer according to a design layout;
The professional team will accurately install the selected sensor group to the trailer in a predetermined location based on the earlier system design drawings. These locations typically include the front, middle and rear of the trailer, as well as the left and right bottoms of particular concern, to cover the change in attitude of the trailer entirely. In the installation process, it is necessary to ensure that the sensor is stable and does not interfere with the normal operation of the trailer, while taking into account its durability and maintenance convenience.
S203, all the sensors are connected to a central processing unit in a wireless mode and calibrated;
All deployed sensors establish a stable data transmission link with a Central Processing Unit (CPU) via a reliable wireless communication protocol such as Wi-Fi, bluetooth or LoRaWAN. This connection not only allows for seamless transmission of real-time data streams, but also provides for remote monitoring and fault diagnosis. After connection is completed, fine sensor calibration work is performed, so that data output by all sensors are ensured to be accurate, and errors caused by installation positions, angles or individual differences are eliminated.
S204, acquiring attitude parameters of the trailer by adopting a sensor group.
With the full activation of the sensor group, the attitude parameters of the trailer begin to be acquired in real time and continuously. These parameters include, but are not limited to, the angular velocity of the trailer about three axes, the acceleration in three directions, and the vertical height of the bottom of the trailer relative to the ground. The data not only provides real-time road condition feedback for the driving assistance system, but also can be used for analyzing the dynamic balance state of the trailer, predicting potential suspension system problems, and providing precious information for subsequent road maintenance and traffic planning. Through continuous data collection and analysis, the whole system lays a solid foundation for improving the transportation efficiency and the safety.
S102, classifying road surface states according to historical vertical height data of the left side and the right side of the trailer;
the method comprises the following specific steps:
S301, marking historical vertical height data by adopting a pavement label, wherein the pavement label comprises flatness, pits and slopes;
This step requires expertise or manual review, and each piece of travel data is given road marking data, such as "flat", "pothole" or "grade", depending on the actual experience of the trailer traveling or subsequent road inspection reports. Such labels provide learned target variables for subsequent machine learning models, which are the basis for building effective models.
S302, extracting classification features from marked historical vertical height data, wherein the classification features comprise difference values of heights of the left side and the right side, average heights, standard deviation and skewness;
The height difference value of the left side and the right side intuitively reflects whether the road surface is flat or not.
Average height-a horizontal plane position that can be used to identify the overall road surface.
Standard deviation, namely measuring the difference between data points, and helping to identify the irregularity degree of the pavement.
And (3) skewness, namely evaluating the asymmetry of data distribution, and identifying the inclination or special form of the pavement. By extraction of these features, the system is able to describe different road surface states in a quantized manner.
S303, dividing the marked data set into a training set and a verification set;
to verify the validity of the model and avoid overfitting, the original labeled dataset would be divided into two parts, a training set and a verification set. The training set is used for model learning and parameter adjustment, and the verification set is used for evaluating the performance of the model on unseen data. Reasonable data partitioning ratios (e.g., 80% training, 20% validation) are key to ensuring model generalization ability.
S304, training the linear support vector machine model by using the training set to obtain a pavement judgment model.
The support vector machine is a powerful supervised learning method, and is particularly suitable for solving the classification problem, especially for scenes with clear boundaries between data categories. By training the model with the training set, the system can learn complex relationships between different features and road surface states and finally output a judging model capable of predicting the road surface states according to new vertical height data. In the training process, the optimization of model parameters can be involved so as to achieve the classification effect.
S103, confirming the current road surface state according to the vertical height data collected in real time;
the method comprises the following specific steps:
S401, acquiring vertical height data collected by a sensor;
vertical height data is received in real-time from sensors on the trailer via wireless communication technology (e.g., bluetooth, wi-Fi, or cellular network). The data reflect the real-time relative height change of the trailer and the ground during driving, and are basic information for evaluating the pavement state.
S402, preprocessing vertical height data;
the method comprises the following specific steps:
s501, checking whether an abnormal height value exists in the vertical height data, and deleting the abnormal height value if the abnormal height value exists;
Statistical methods (e.g., Z-score or IQR) are used to identify and reject outliers in the data. Outliers are caused by sensor misreading, extreme road surface events, or external disturbances, which distort the judgment of the model. Once the vertical height value is found outside the normal range, the system automatically deletes it to reduce the negative impact on the analysis results.
S502, if there is a missing value in the vertical height data, interpolation is used for filling.
In order to solve the problem of the lack or loss of data, interpolation methods (such as linear interpolation, nearest neighbor interpolation or time sequence prediction methods) are adopted to fill in the missing values. Thus, not only the continuity of data is maintained, but also the information loss caused by directly neglecting missing data is avoided.
S403, applying the road surface judging model to the data acquired in real time, and identifying the current road surface state.
After finishing the data preprocessing, inputting the real-time data into a road surface judgment model trained before. The model rapidly classifies the state of the current driving road surface according to the characteristics (such as difference value, average height and the like) of the real-time vertical height data so as to facilitate the subsequent speed control.
S104, calculating a recommended steering speed and a maximum steering angle according to the angular speed, the acceleration and the load of the trailer under the current road surface state;
the method comprises the following specific steps:
S601, setting a dynamic model according to the angular speed, acceleration and load of the trailer and the road surface state;
the method comprises the following specific steps:
S701, defining basic parameters and a coordinate system;
Basic parameters of the dynamic model of the trailer need to be determined, including but not limited to mass, centroid position, coefficient of friction of the tire with the ground, etc. At the same time, a suitable coordinate system (usually a world coordinate system fixed to the ground or a vehicle body coordinate system rotating with the vehicle body) is defined to accurately describe the displacement, speed and acceleration of the trailer.
The mass m of the trailer;
The load M of the trailer;
The mass m w of each wheel of the trailer;
the friction coefficient f between the road surface and the wheels;
Angular velocity ω of the trailer;
acceleration a of the trailer.
S702, establishing a dynamics equation based on angular velocity, acceleration and load and road surface state;
In the x-axis direction, the forces to which the trailer is subjected include the friction force fm w g (downward) and the driving force (if any), where g is the gravitational acceleration. The kinetic equation is thus ma=fm w g-T, where T is the driving force experienced by the trailer.
In the y-axis direction, the forces to which the trailer is subjected are mainly gravity Mg and road supporting force N, and thus the kinetic equation is n=mg+mg.
In the z-axis direction, the forces experienced by each wheel of the trailer are the same, mainly the weight mg of the trailer, which is the component in the z-axis, and thus the kinetic equation is m w g=nz, where z is the height of the trailer relative to the road surface.
S703 corrects the accelerations in the x-axis and the y-axis by the rotation dynamics equation.
The acceleration calculation in the x axis (transverse direction) and the y axis (longitudinal direction) is corrected through a rotation dynamics equation, so that the model can accurately reflect the road surface unevenness or the vehicle response under specific conditions.
The specific implementation steps comprise:
initial state (speed, direction, suspension state, etc.) of the vehicle and road surface unevenness data are acquired.
Based on the current vehicle state and road conditions, suspension forces and tire forces are calculated.
The suspension force is mainly dependent on the displacement, speed, stiffness and damping of the suspension system. The following calculation steps are as follows:
Determining suspension displacement:
The amount of compression (or extension) of the suspension is determined based on the relative movement between the wheel and the body.
S=s wheel-sbody where s is the suspension displacement, s wheel is the displacement of the wheel, and s body is the displacement of the body.
Calculating a suspension speed:
the suspension velocity is the derivative of suspension displacement with respect to time, v s =ds/dt
Calculating the suspension force:
The suspension force is calculated using the stiffness (k) and damping (c) coefficients of the suspension.
Fs= -k·s-c·v s where Fs is the suspension force and the negative sign indicates that the direction of the force is always opposite to the displacement direction.
Tire force calculations typically involve longitudinal, lateral and lateral forces of the tire. The following calculation steps are as follows:
Determining the slip ratio and slip angle of the tire;
slip ratio (lambda) is the ratio of the difference between the longitudinal speed of the tire and the rotational speed of the wheel to the rotational speed of the wheel.
The slip angle (α) is the angle between the direction of the speed of the tire's ground contact point and the longitudinal axis of the tire.
Using a tire model:
tire models (e.g., magic formulas (MagicFormula), brush models, etc.) are selected to describe the mechanical behavior of the tire.
Calculate longitudinal force (Fx):
The longitudinal force is calculated from the slip ratio and the tire model.
Fx=f (λ), where F (λ) is the longitudinal force given by the tire model versus slip ratio.
Calculate lateral force (Fy):
the lateral force is calculated from the slip angle and the tire model.
Fy=f (α), where F (α) is the relationship of lateral force to slip angle given by the tire model.
And substituting the suspension force and the tire force into a rotation dynamics equation, and calculating the acceleration and the angular acceleration of the vehicle body.
Linear equation of motion:
transverse (x-axis):
longitudinal (y axis):
Angular equation of motion:
around the z-axis (vehicle pitch):
around the x-axis (vehicle yaw):
around the y-axis (vehicle roll):
Where m is the mass of the vehicle, AndAcceleration in the lateral and longitudinal directions, respectively, fx and Fy are the corresponding forces, I is the moment of inertia,Pitch, yaw and roll accelerations, respectively, M being the moment.
The position, speed and direction of the vehicle are updated based on the calculated acceleration and angular acceleration.
S602, calculating the speed of the trailer capable of safely steering under the current road surface condition through a dynamics model;
On the basis of establishing a perfect dynamic model, calculating the steering speed which can be safely maintained by the trailer under the current road surface condition through numerical solution or simulation analysis. This step takes into account the physical limits of the vehicle, the stability requirements and the limits of the road grip, ensuring that no sideslip or runaway occurs. Specifically including setting initial conditions such as initial speed, steering angle, etc. The road surface friction coefficient was assumed to be 0.7 (dry asphalt road surface). Numerical integration was performed using the fourth-order Longgy-Kutta method. And (3) giving different vehicle speeds, and solving a vehicle motion equation through numerical integration.
S603 calculates a corresponding safe steering angle based on the safe steering vehicle speed.
Based on the calculated safe steering vehicle speed, the maximum steering angle at which the trailer can safely execute is further determined. The calculation needs to consider the direct influence of the vehicle speed on the vehicle operation stability, and factors such as the size of the trailer, the wheelbase and the like, so that the vehicle can maintain enough lateral stability when steering at the recommended vehicle speed, and the excessive yaw or overturning risk is avoided. Specifically, a series of different steering angles thetai can be given, and a vehicle motion equation can be solved through numerical integration. For each steering angle θi, it is checked whether the limit of the lateral acceleration (for example, 0.4 g) is exceeded. The maximum steering angle θmax that just satisfies the safety condition is found.
S105, when the steering speed and the maximum steering angle exceed preset values, an alarm is sent out.
The method comprises the following specific steps:
At this stage, real-time driving data of the trailer, in particular the vehicle speed, steering angle and acceleration, are continuously collected and transmitted to the central processing unit through the sensor network. The data is subjected to preliminary cleaning and formatting, so that the accuracy and timeliness of the information are ensured.
The central processing unit receives the real-time data and immediately compares the real-time data with the previously calculated safe steering vehicle speed and the maximum steering angle. This process involves complex algorithms for calculating the actual steering rate and angle of the vehicle in real time, ensuring an exact match with the preset safety values.
And triggering the risk assessment logic immediately once the system detects that the actual steering speed of the trailer exceeds a preset safety value or the actual steering angle exceeds a calculated maximum safety steering angle. This logic not only considers the exceeding of a single parameter, but also comprehensively evaluates the degree of influence of the two factors on the stability and safety of the vehicle.
When the risk assessment confirms that a potential safety hazard exists, the system immediately triggers an alarm mechanism. The alert may be an audible alert, issued through a speaker inside the vehicle, a visual alert, such as a flashing warning light on the dial, or even a tactile feedback, such as a vibration of the steering wheel, to ensure that the driver is quickly aware. In addition, in the event of an emergency, the system also transmits an alarm message to the fleet manager or the emergency service center via the in-vehicle communication device in order to take further action.
After each alarm trigger, the system automatically records related running data and alarm details, including time, place, speed, steering angle and the like.
The invention further provides a trailer attitude detection system, which comprises a parameter acquisition module, a road surface classification module, a road surface detection module, a speed calculation module and an alarm module, wherein the parameter acquisition module is used for monitoring attitude parameters of a trailer in real time by adopting a sensor, the attitude parameters comprise angular speed, acceleration and vertical height, the road surface classification module is used for classifying road surface states according to historical vertical height data of the left side and the right side of the trailer, the road surface detection module is used for confirming the current road surface states according to the vertical height data collected in real time, the speed calculation module is used for calculating recommended steering speed and maximum steering angle according to the angular speed, the acceleration and the load of the trailer in the current road surface states, and the alarm module is used for giving an alarm when the steering speed and the maximum steering angle exceed preset values.
The parameter acquisition module monitors the attitude parameters of the trailer in real time using sensor technology (such as gyroscopes, accelerometers, and altitude sensors). These parameters include the angular velocity of the trailer about three axes, the acceleration in three directions, and the real-time vertical height change of the trailer bottom relative to the ground. The high-frequency acquisition and high precision of the sensor data ensure the reliability and real-time performance of the monitoring data. The pavement classification module adopts a machine learning algorithm to carry out deep analysis on the vertical height data on the left side and the right side, and then classifies different types of pavement states. Through the steps of data marking, feature extraction, model training and the like, the system can identify various states such as flatness, potholes, gradient and the like of the pavement, and provides basis for subsequent decisions. The road surface detection module receives and processes the latest vertical height data from the sensor in real time, and accurately judges the road surface state of the current trailer by combining historical data and real-time environment information. Through the steps of data preprocessing, outlier rejection, missing value filling and the like, the accuracy of judging the current road surface condition is ensured, and instant road surface feedback is provided for a driver. The speed calculation module utilizes a dynamics model to comprehensively consider the angular speed, acceleration and actual load condition of the trailer, and calculates the recommended safest steering speed and the recommended safest steering angle. The calculation process is highly dependent on an accurate physical model and real-time data processing capability, and aims to help a driver to make an optimal driving decision under various road conditions and reduce risks caused by improper operation. The alarm module is responsible for monitoring actual driving parameters of the trailer, and once the steering speed or steering angle is detected to exceed a preset safety threshold, the alarm module immediately gives a warning to a driver in a sound, visual or tactile mode and the like, so that the driver is prompted to adjust driving behaviors in time, and potential dangerous situations are avoided. Meanwhile, the system records the detailed information of each alarm, and data support is provided for later driving behavior analysis and system optimization.
In summary, the trailer attitude detection system provides omnibearing safety guarantee for daily operation of the trailer through integrated monitoring, analyzing, calculating and early warning functions, and obviously improves the safety and efficiency of road transportation.
The above disclosure is only a preferred embodiment of the present invention, and it should be understood that the scope of the invention is not limited thereto, and those skilled in the art will appreciate that all or part of the procedures described above can be performed according to the equivalent changes of the claims, and still fall within the scope of the present invention.