Target device operation control method and apparatus, electronic device, and storage medium
Patent Information
- Application Number
- CN202211294523.2
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-10-21
- Publication Date
- 2026-08-18
- Estimated Expiration
- 2042-10-21
AI Technical Summary
[0004]本申请实施例的目的在于提供一种目标设备的运行控制方法、装置、电子设备和存储介质,以解决人工驾驶车辆不能严格沿既定路线行驶的问题
[0044] This application provides a method for controlling the operation of a target device. The controller, based on the offset angle and distance of the target device relative to the target travel line, employs a PID control scheme to output PID parameter values, thereby adjusting the speeds of the drive components on both sides to adjust the running direction and distance of the target device from the target travel line. Compared to existing technologies, this application, using a PID control scheme, ensures that the target device operates strictly along the target travel line. Furthermore, it eliminates the need for manual driving, reducing personnel costs through unmanned operation.
Smart Images

Figure CN115973147B_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of automatic control technology, and in particular to a method, apparatus, electronic device and storage medium for controlling the operation of a target device. Background Technology
[0002] In some industries, vehicles need to operate along predetermined routes, requiring strict manual control of their travel. Drivers often need to adjust the vehicle's direction, which can easily lead to deviations from the intended route. For example, a paving machine needs to travel a certain distance from and along a baseline. During the paving process, potholes or bumps may appear on the pavement due to speed and angle, causing the paving machine to deviate from the baseline. This results in changes in the distance between the paving machine and the baseline, requiring the driver to rely on experience to adjust the machine's direction. However, manual adjustment also involves many uncertainties.
[0003] There is currently no good solution to the problem that manually driven vehicles cannot strictly follow a predetermined route in existing technologies. Summary of the Invention
[0004] The purpose of this application is to provide a method, apparatus, electronic device, and storage medium for controlling the operation of a target device, in order to solve the problem that manually driven vehicles cannot strictly follow a predetermined route. The specific technical solution is as follows:
[0005] Firstly, a method for controlling the operation of a target device is provided, the method comprising:
[0006] Based on the target device's operating path, determine the target device's offset angle and offset distance relative to the target travel line;
[0007] The angle change value is obtained based on the difference between every two adjacent offset angles, and the distance change value is obtained based on the difference between every two phase offset distances;
[0008] By using multiple angle change values, multiple distance change values, target offset angle, and target offset distance, a PID control scheme is employed to output PID parameter values.
[0009] The speeds of the drive components on both sides of the target device are adjusted by the PID parameter values to adjust the running path of the target device until the offset angle of the target device relative to the target travel line matches the target offset angle and the offset distance matches the target offset distance.
[0010] Optionally, the step of outputting PID parameter values using a PID control scheme based on multiple angle change values, multiple distance change values, target offset angle, and target offset distance includes:
[0011] By adjusting the preset initial PID parameter values using multiple angle change values, multiple distance change values, target offset angle, and target offset distance, intermediate parameter values are obtained.
[0012] The deviation angle is obtained by the difference between two adjacent angle changes, and the deviation distance is obtained by the difference between two adjacent distance changes.
[0013] The PID parameter value is obtained by adjusting the intermediate parameter value based on the difference between the deviation angles and the difference between the deviation distances.
[0014] Optionally, adjusting the intermediate parameter value to obtain the PID parameter value based on the difference between the deviation angles and the difference between the deviation distances includes:
[0015] The difference between the two most recent deviation angles is determined as the deviation angle difference, and the difference between the two most recent deviation distances is determined as the deviation distance difference.
[0016] Based on the relationship between the deviation angle difference and the preset angle range, or the relationship between the deviation distance difference and the preset distance range, the intermediate ratio parameter in the intermediate parameter value is adjusted.
[0017] Optionally, adjusting the intermediate ratio parameter in the intermediate parameter value according to the relationship between the deviation angle difference and the preset angle range includes:
[0018] If the deviation angle difference is greater than the maximum endpoint of the preset angle range, then the intermediate ratio parameter is adjusted to the target ratio parameter value; or,
[0019] If the deviation angle difference is less than the maximum endpoint of the preset angle range, the intermediate ratio parameter is increased to the target ratio parameter value.
[0020] Optionally, adjusting the intermediate ratio parameter in the intermediate parameter value according to the relationship between the deviation distance difference and the preset distance range includes:
[0021] If the deviation distance difference is greater than the maximum endpoint of the preset distance range, then the intermediate ratio parameter is adjusted to the target ratio parameter value; or,
[0022] If the deviation distance difference is less than the maximum endpoint of the preset distance range, the intermediate ratio parameter is increased to the target ratio parameter value.
[0023] Optionally, adjusting the speeds of the drive components on both sides of the target device using the PID parameter values includes:
[0024] The first drive component and the second drive component of the target device are determined based on the offset distance, wherein the distance of the first drive component from the target travel line is less than the distance of the second drive component from the target travel line;
[0025] The speeds of the first drive component and the second drive component are adjusted respectively using the PID parameter values.
[0026] Optionally, determining the offset angle and offset distance of the target device relative to the target travel line based on the target device's operating path includes:
[0027] The preset distance between the shooting device and the head of the target device is obtained according to the input command, wherein the shooting device is set on the side of the target device;
[0028] The offset angle of the target device and the first distance between the shooting device and the target's travel line are obtained by the shooting device, wherein the straight line containing the first distance forms a 90-degree angle with the running direction of the target device.
[0029] Based on trigonometric functions, the offset distance of the target device relative to the target driving line is obtained through the preset distance, the first distance, and the offset angle, wherein the offset distance is the distance between the head of the target device and the target driving line.
[0030] Optionally, based on trigonometric functions, the offset distance of the target device relative to the target travel line is obtained using the preset distance, the first distance, and the offset angle, including:
[0031] Based on the cosine function, a second distance is obtained by using the first distance and the offset angle, wherein the line containing the second distance is perpendicular to the target driving line;
[0032] The third distance is obtained based on the sin function and the preset distance;
[0033] The difference between the second distance and the third distance is used as the offset distance.
[0034] Secondly, a target device for operation control is provided, the device comprising:
[0035] The determination module is used to determine the offset angle and offset distance of the target device relative to the target travel line based on the running path of the target device;
[0036] The module is used to obtain the angle change value based on the difference between every two adjacent offset angles, and to obtain the distance change value based on the difference between every two phase offset distances;
[0037] The output module is used to output PID parameter values using a PID control scheme based on multiple angle change values, multiple distance change values, target offset angle, and target offset distance.
[0038] The adjustment module is used to adjust the speed of the drive components on both sides of the target device according to the PID parameter values, so as to adjust the running path of the target device until the offset angle between the target device and the target travel line matches the target offset angle and the offset distance matches the target offset distance.
[0039] Thirdly, an electronic device is provided, including a processor, a communication interface, a memory, and a communication bus, wherein the processor, the communication interface, and the memory communicate with each other through the communication bus;
[0040] Memory, used to store computer programs;
[0041] The processor, when executing a program stored in memory, implements the operation control method steps of any of the aforementioned target devices.
[0042] Fourthly, a computer-readable storage medium is provided, wherein a computer program is stored therein, and when the computer program is executed by a processor, it implements the operation control method steps of any of the aforementioned target devices.
[0043] Beneficial effects of the embodiments in this application:
[0044] This application provides a method for controlling the operation of a target device. The controller, based on the offset angle and distance of the target device relative to the target travel line, employs a PID control scheme to output PID parameter values, thereby adjusting the speeds of the drive components on both sides to adjust the running direction and distance of the target device from the target travel line. Compared to existing technologies, this application, using a PID control scheme, ensures that the target device operates strictly along the target travel line. Furthermore, it eliminates the need for manual driving, reducing personnel costs through unmanned operation.
[0045] Of course, implementing any product or method of this application does not necessarily require achieving all of the above advantages at the same time. Attached Figure Description
[0046] To more clearly illustrate the technical solutions in the embodiments of this application or the prior art, the drawings used in the description of the embodiments or the prior art will be briefly introduced below. Obviously, for those skilled in the art, other drawings can be obtained based on these drawings without creative effort.
[0047] Figure 1 A flowchart illustrating a method for controlling the operation of a target device, as provided in an embodiment of this application;
[0048] Figure 2 A schematic diagram illustrating the operation of a paving machine as provided in an embodiment of this application;
[0049] Figure 3 This is a schematic diagram of the offset of the paving machine provided in an embodiment of this application;
[0050] Figure 4 A schematic diagram of the actual trajectory and target trajectory of the target device provided in an embodiment of this application;
[0051] Figure 5 This is yet another schematic diagram illustrating the actual trajectory of the target device and the target trajectory provided in the embodiments of this application;
[0052] Figure 6 Another schematic diagram illustrating the actual trajectory and target trajectory of the target device provided in the embodiments of this application;
[0053] Figure 7 A flowchart illustrating the operation control process of the target device provided in this application embodiment;
[0054] Figure 8 A system block diagram for adjusting the running direction of the target device provided in the embodiments of this application;
[0055] Figure 9 A schematic diagram of a device for adjusting the running direction of a target device provided in an embodiment of this application.
[0056] Figure 10 This is a schematic diagram of the structure of an electronic device provided in an embodiment of this application. Detailed Implementation
[0057] To make the objectives, technical solutions, and advantages of the embodiments of this application clearer, the technical solutions of the embodiments of this application will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of this application, not all embodiments. Based on the embodiments of this application, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of this application.
[0058] In the following description, the use of suffixes such as "module," "part," or "unit" to denote elements is solely for the purpose of illustration and has no specific meaning in itself. Therefore, "module" and "part" may be used interchangeably.
[0059] To address the problems mentioned in the background art, according to one aspect of the embodiments of this application, an embodiment of a method for controlling the operation of a target device is provided.
[0060] One embodiment of this application provides a target device operation control method that can be executed by a controller to control the target device to operate in accordance with a target travel line. The target device can be a paving machine or other equipment that needs to run along a target travel line.
[0061] The following will describe in detail, with reference to specific embodiments, a method for controlling the operation of a target device provided in this application, such as... Figure 1 As shown, the specific steps are as follows:
[0062] Step 101: Based on the target device's running path, determine the offset angle and offset distance of the target device relative to the target travel line.
[0063] In this embodiment of the application, the target driving line can be a real driving line or a straight line parallel to the baseline. Under normal circumstances, the target device should run along the target driving line, but inevitably it will deviate. Therefore, a shooting device is provided on the side of the target device. The shooting device obtains the offset angle of the target device relative to the target driving line and the first distance of the shooting device relative to the target driving line. The controller calculates the offset distance of the target device relative to the target driving line based on the offset angle and the first distance.
[0064] Figure 2 This diagram illustrates the operation of a road paver. During construction, only one road paver is in operation at a time. The baseline is to the right of the road paver, which is required to travel in a straight line along the baseline for a fixed distance L. This creates a travel line parallel to the baseline. Generally, the road paver is required to travel along this travel line. Figure 2 As shown in A, but an offset will occur during actual operation, such as... Figure 2 The four cases are B, C, D, and E.
[0065] Figure 3 This is a schematic diagram of the paving machine's offset. It can be seen that the offset angle between the paving machine's running direction and its travel line is... The offset distance of the paving machine head relative to the driving line is L1.
[0066] Step 102: Obtain the angle change value based on the difference between every two adjacent offset angles, and obtain the distance change value based on the difference between every two phase offset distances.
[0067] In this embodiment, each time the target device changes its running direction, the controller obtains a new offset angle and offset distance. The controller subtracts two adjacent offset angles to obtain the angle change value and subtracts two adjacent offset distances to obtain the distance change value, thus obtaining multiple angle change values. And multiple distance change values ΔL11, ΔL12, ΔL13, ΔL14...
[0068] Step 103: Using multiple angle change values, multiple distance change values, target offset angle, and target offset distance, a PID control scheme is adopted to output PID parameter values.
[0069] In this embodiment of the application, the purpose is to make the target device run along the target travel line, so the target offset angle between the target device and the target travel line is 0, and the target offset distance is also 0.
[0070] The controller employs an adaptive PID algorithm, which calculates a preset number of angle change values. The system presets a number of distance change values ΔL11, ΔL12, ΔL13, ΔL14...ΔL1n, target offset angle 0, and target offset distance 0, and outputs PID parameter values.
[0071] Specifically, unmanned target equipment employs an automatic control system. The basic requirements of this system are stability, accuracy, and speed. The role of PID control in this system is as follows:
[0072] • Stability (P and I parameter values decrease system stability, while D parameter values increase system stability): In equilibrium, after a certain disturbance, the controlled variable of the system can reach a certain stable state after a period of time.
[0073] • Accuracy (P and I parameter values improve steady-state accuracy, D parameter value has no effect): The steady-state error of the system when it is in steady state;
[0074] • Speed (P and D parameter values increase response speed, I parameter value decreases response speed): The system's requirements for dynamic response are generally measured by the length of the transition time.
[0075] When performing PID tuning on a control system, the following principles should be followed:
[0076] 1) Adjust the P parameter value first, then the I parameter value, and finally the D parameter value.
[0077] 2) When the output does not oscillate, increase the proportional parameter value P to make the final trajectory close to the set trajectory.
[0078] 3) When the output does not oscillate (as long as the static error can be eliminated), reduce the value of the integral parameter I to speed up the convergence speed.
[0079] 4) When the output does not oscillate, increase the value of the differential parameter D to reduce the settling time.
[0080] The PID control process is as follows: First, adjust the P parameter value to ensure that the final deviation value can converge; then adjust the I parameter value to ensure the convergence speed; the D parameter value is basically not adjusted.
[0081] Figure 4 This is a schematic diagram showing the actual trajectory of the target device and the target trajectory. The curve with fewer bends represents the target trajectory, and the curve with more bends represents the actual trajectory. It can be seen that the actual trajectory never truly follows the target trajectory, and its deviation never converges. This indicates that the P parameter value of the PID controller is too small and needs to be increased.
[0082] Figure 5 This is another schematic diagram of the actual trajectory and the target trajectory of the target device. The curve with fewer bends represents the target trajectory, and the curve with more bends represents the actual trajectory. It can be seen that the actual trajectory and the target trajectory are always in an overshoot state, and their deviation value is always fluctuating up and down and cannot converge. This indicates that the P parameter value of the PID is too large and needs to be reduced.
[0083] Figure 6 This is another schematic diagram of the actual trajectory and the target trajectory of the target device. The curve with fewer bends represents the target trajectory, and the curve with more bends represents the actual trajectory. It can be seen that the actual trajectory and the target trajectory eventually become consistent, but the deviation converges too slowly. This indicates that the P parameter value of the PID controller has been set to a suitable value, and the I parameter value needs to be reduced.
[0084] Step 104: Adjust the speed of the drive components on both sides of the target device by adjusting the PID parameter values to adjust the running path of the target device until the offset angle between the target device and the target travel line matches the target offset angle and the offset distance matches the target offset distance.
[0085] In this embodiment, after obtaining the PID parameter values, the controller adjusts the speeds of the drive components on both sides of the target device to create a difference in speed, thereby generating steering and adjusting the running direction of the target device and the distance between it and the target travel line. Each time the target device adjusts its running direction, the controller obtains a new offset angle and offset distance. Based on the new offset angle and offset distance, it generates new PID parameter values to adjust the speed of the drive components until the offset angle between the target device and the target travel line matches the target offset angle and the offset distance matches the target offset distance.
[0086] In this application, the controller, based on the offset angle and distance of the target device relative to the target travel line, employs a PID control scheme to output PID parameter values, thereby adjusting the speed of the drive components on both sides to adjust the running direction and distance of the target device from the target travel line. Compared to existing technologies, this application, using a PID control scheme, ensures that the target device operates strictly along the target travel line. Furthermore, it eliminates the need for manual driving, reducing personnel costs through unmanned operation.
[0087] As an optional implementation, the PID control scheme outputs PID parameter values using multiple angle change values, multiple distance change values, target offset angle, and target offset distance. This includes: adjusting a preset initial PID parameter value using multiple angle change values, multiple distance change values, target offset angle, and target offset distance to obtain an intermediate parameter value; obtaining the deviation angle based on the difference between two adjacent angle change values, and obtaining the deviation distance based on the difference between two adjacent distance change values; and adjusting the intermediate parameter value based on the difference between the deviation angle and the difference between the deviation distance to obtain the PID parameter value.
[0088] The controller first acquires the initial PID parameter values set in the VPLC. These initial PID parameter values include initial proportional, initial integral, and initial derivative parameter values. The controller then determines the initial PID parameter values based on a preset number of angle change values. Preset a number of distance change values ΔL11, ΔL12, ΔL13, ΔL14...ΔL1n, target offset angle 0, and target offset distance 0 to obtain intermediate proportional parameter values, intermediate integral parameter values, and intermediate differential parameter values. Then, obtain the deviation angle based on the difference between two adjacent angle change values. And obtain the deviation distances ΔΔL1 and ΔΔL2 based on the difference between two adjacent distance change values, and then based on... The difference between ΔL1 and ΔL2 is used to adjust the intermediate proportional parameter value to the target proportional parameter value. Finally, the target proportional parameter value, intermediate integral parameter value, and intermediate derivative parameter value are used as the PID parameter values.
[0089] The technical problem this application aims to further solve is how to more accurately adjust the motion path of the target device. This application adjusts the initial PID parameter values to intermediate parameter values using multiple angle change values, multiple distance change values, target offset angle, and target offset distance. Based on the differences between offset angles and offset distances, the intermediate parameter values are adjusted to obtain the PID parameter values. By using the differences between offset angles and offset distances, this application can adjust the PID parameter values at a more granular level, improving the accuracy of the PID parameter values and thus obtaining a more accurate motion path.
[0090] The deviation angle difference can be the difference between any two consecutive deviation angles from the most recent range, and the deviation distance difference can be the difference between any two consecutive deviation distances from the most recent range. In this scheme, the controller determines the two most recent deviation angles. The difference is the deviation angle difference, and the difference between the two most recent deviation distances ΔΔL1 and ΔΔL2 is the deviation distance difference.
[0091] Based on the two most recent deviation angles and the two most recent deviation distances, the intermediate scale parameter values are adjusted to the target scale parameter values, including:
[0092] 1. If the difference in deviation angle is within the preset angle range and the difference in deviation distance is within the preset distance range, then the intermediate ratio parameter value and the target ratio parameter value are determined to be the same.
[0093] 2. If the deviation angle difference exceeds the preset angle range, the intermediate ratio parameter will be adjusted first by adjusting the deviation angle difference. The relationship between the deviation angle difference and the endpoints of the preset angle range is opposite to the direction of adjustment of the intermediate ratio parameter.
[0094] 2.1 If the deviation angle difference is greater than the maximum endpoint of the preset angle range, the intermediate ratio parameter is adjusted to the target ratio parameter value;
[0095] 2.2 If the deviation angle difference is less than the maximum endpoint of the preset angle range, the intermediate ratio parameter is increased to the target ratio parameter value.
[0096] 3. If the deviation angle difference is within the preset angle range, but the deviation distance difference exceeds the preset distance range, then the intermediate proportional parameter is adjusted by the deviation distance difference. The magnitude relationship between the deviation distance difference and the endpoints of the preset distance range is inversely related to the direction of adjustment of the intermediate proportional parameter.
[0097] 3.1 If the deviation distance difference is greater than the maximum endpoint of the preset distance range, the intermediate ratio parameter is adjusted to the target ratio parameter value;
[0098] 3.2 If the deviation distance difference is less than the maximum endpoint of the preset distance range, the intermediate ratio parameter is increased to the target ratio parameter value.
[0099] The technical problem to be further solved by this application is how to make the operation of the target equipment conform to the target travel line. By adjusting the relationship between the deviation angle difference and the maximum endpoint of the preset angle range, or by adjusting the relationship between the deviation distance difference and the maximum endpoint of the preset distance range, the intermediate proportional parameter (proportional parameter value P) is adjusted to the target proportional parameter value. The proportional parameter value P ensures that the final deviation value can converge. This application achieves the matching of the movement direction and interval distance of the target equipment with the target travel line by adjusting the deviation value, so as to make the operation of the target equipment conform to the target travel line.
[0100] As an optional implementation, adjusting the speeds of the drive components on both sides of the target device using PID parameter values includes: determining the first drive component and the second drive component of the target device based on the offset distance, wherein the distance between the first drive component and the target driving line is less than the distance between the second drive component and the target driving line; and adjusting the speeds of the first drive component and the second drive component using PID parameter values.
[0101] In the embodiments of this application, such as Figure 2 As shown, the controller determines the offset distance of the target device relative to the target travel line. The controller can determine whether the target device is to the left or right of the target travel line based on this offset distance, specifically determined by the distance between the target device and the baseline. A fixed distance L is set between the target travel line and the baseline. If the target device is more than L from the baseline, it indicates that the target device is to the left of the baseline, and the offset distance can be represented by L1. If the target device is less than L from the baseline, it indicates that the target device is to the right of the baseline, and the offset distance can be represented by -L1. The controller determines the first and second drive components of the target device based on the offset distance. The distance of the first drive component from the target travel line is less than the distance of the second drive component from the target travel line. Figure 2 As shown, the right wheel of target device B is the first driving component, and the left wheel is the second driving component.
[0102] The controller determines the offset angle of the target equipment relative to the target travel line through the imaging device, such as... Figure 2 and Figure 3 As shown, if the target device is B, then the angle between the driving line and L3 is... If the target device is D, then the angle between the baseline and L3 is... (Not shown in the diagram). The controller can distinguish between the four target devices A, B, C, and D by the offset distance and the angle between the travel line and L3.
[0103] If the offset distance is greater than the distance threshold, it indicates that the target device is far from the target driving line. In this case, the offset angle is not changed to bring the target device closer to the driving line. If the offset distance is less than the distance threshold, it indicates that the target device is close to the target driving line. In this case, the offset angle and offset distance are adjusted to make the target device run along the target driving line.
[0104] Specifically, when adjusting the offset angle and offset distance, increasing the speed of the first drive component and decreasing the speed of the second drive component will cause the head of the target device to adjust away from the travel line. Figure 2 B and C in the diagram apply to this method; by reducing the speed of the first drive component and increasing the speed of the second drive component, the head of the target device will adjust towards the direction of travel, such as... Figure 2 D and E in the text are used for this method.
[0105] As an optional implementation, determining the offset angle and offset distance of the target device relative to the target travel line based on the running direction of the target device includes: obtaining a preset distance between the shooting device and the head of the target device according to an input command, wherein the shooting device is disposed on the side of the target device; obtaining the offset angle of the target device and a first distance between the shooting device and the target travel line through the shooting device, wherein the line containing the first distance forms a 90-degree angle with the running direction of the target device; and obtaining the offset distance of the target device relative to the target travel line based on trigonometric functions, using the preset distance, the first distance, and the offset angle, wherein the offset distance is the distance between the head of the target device and the target travel line.
[0106] The camera is positioned on the side of the target device. The user measures and inputs a preset distance between the camera and the head of the target device. Figure 3 As shown, the imaging device determines the offset angle. The imaging device determines the first distance L3 between itself and the target's travel line, with the line containing L3 forming a 90-degree angle with the target device's direction of travel. This is achieved using trigonometric formulas. *L3 gives the second distance L2, and the line containing L2 is perpendicular to the target driving line.
[0107] The offset distance L1 can then be obtained.
[0108] Optionally, embodiments of this application also provide a flowchart of the operation control process for the target device, such as... Figure 7 As shown, the specific steps are as follows.
[0109] The controller obtains the offset angle. The offset distance L1 is used to output intermediate parameter values through an adaptive PID algorithm. Then, PID parameter values are obtained through a PID algorithm. Finally, based on the motion control algorithm, the speed of the drive devices on the left and right sides is controlled by the PID parameter values, thereby adjusting the direction and distance between the target equipment and the target travel line. The controller continues to acquire the offset angle. Perform PID calculations on the offset distance L1 until the offset angle between the target device and the target driving line matches the target offset angle and the offset distance matches the target offset distance.
[0110] Optionally, embodiments of this application also provide a system block diagram for adjusting the running direction of the target device, such as... Figure 8 As shown, the security camera sends the offset distance and offset angle to the edge controller. The edge controller determines the PID parameter value based on the offset distance and offset angle, and sends control commands to the target device through electromechanical control information. The target device adjusts the speed of the drive components on both sides based on the PID parameter value.
[0111] Based on the same technical concept, embodiments of this application also provide an operation control device for a target device, such as... Figure 9 As shown, the device includes:
[0112] The determination module 901 is used to determine the offset angle and offset distance of the target device relative to the target travel line based on the running path of the target device.
[0113] Module 902 is used to obtain the angle change value based on the difference between every two adjacent offset angles, and to obtain the distance change value based on the difference between every two phase offset distances;
[0114] Output module 903 is used to output PID parameter values using a PID control scheme based on multiple angle change values, multiple distance change values, target offset angle, and target offset distance.
[0115] The adjustment module 904 is used to adjust the speed of the drive components on both sides of the target device by using PID parameter values, so as to adjust the running path of the target device until the offset angle between the target device and the target travel line matches the target offset angle and the offset distance matches the target offset distance.
[0116] Optionally, the output module 903 is used for:
[0117] By adjusting the preset initial PID parameter values using multiple angle change values, multiple distance change values, target offset angle, and target offset distance, intermediate parameter values are obtained.
[0118] The deviation angle is obtained by the difference between two adjacent angle changes, and the deviation distance is obtained by the difference between two adjacent distance changes.
[0119] The PID parameter values are obtained by adjusting the intermediate parameter values based on the difference between the deviation angles and the difference between the deviation distances.
[0120] Optionally, the output module 903 is used for:
[0121] The difference between the two most recent deviation angles is determined as the deviation angle difference, and the difference between the two most recent deviation distances is determined as the deviation distance difference.
[0122] Based on the relationship between the deviation angle difference and the preset angle range, or the relationship between the deviation distance difference and the preset distance range, the intermediate ratio parameter in the intermediate parameter value is adjusted.
[0123] Optionally, the adjustment module 904 is used for:
[0124] If the deviation angle difference is greater than the maximum endpoint of the preset angle range, the intermediate scale parameter is adjusted to the target scale parameter value; or,
[0125] If the deviation angle difference is less than the maximum endpoint of the preset angle range, the intermediate ratio parameter is increased to the target ratio parameter value.
[0126] Optionally, the adjustment module 904 is used for:
[0127] If the deviation distance difference is greater than the maximum endpoint of the preset distance range, the intermediate ratio parameter is adjusted to the target ratio parameter value; or,
[0128] If the deviation distance difference is less than the maximum endpoint of the preset distance range, the intermediate ratio parameter is increased to the target ratio parameter value.
[0129] Optionally, the adjustment module 904 is used for:
[0130] The first and second drive components of the target device are determined based on the offset distance, wherein the distance of the first drive component from the target driving line is less than the distance of the second drive component from the target driving line.
[0131] The speeds of the first and second drive components are adjusted by using PID parameter values.
[0132] Optionally, the determining module 901 is used for:
[0133] The preset distance between the shooting device and the head of the target device is obtained according to the input command, wherein the shooting device is set on the side of the target device;
[0134] The offset angle of the target device and the first distance between the shooting device and the target driving line are obtained by the shooting device, wherein the straight line containing the first distance is at a 90-degree angle to the running direction of the target device;
[0135] Based on trigonometric functions, the offset distance of the target device relative to the target driving line is obtained by using a preset distance, a first distance, and an offset angle. The offset distance is the distance between the head of the target device and the target driving line.
[0136] Optionally, the determining module 901 is also used for:
[0137] Based on the cosine function, the second distance is obtained by using the first distance and the offset angle, wherein the line containing the second distance is perpendicular to the target driving line;
[0138] The third distance is obtained based on the sin function and a preset distance;
[0139] The difference between the second and third distances is used as the offset distance.
[0140] According to another aspect of the embodiments of this application, this application provides an electronic device, such as... Figure 10 As shown, the system includes a memory 1003, a processor 1001, a communication interface 1002, and a communication bus 1004. The memory 1003 stores a computer program that can run on the processor 1001. The memory 1003 and the processor 1001 communicate through the communication interface 1002 and the communication bus 1004. When the processor 1001 executes the computer program, it implements the steps of the above method.
[0141] The memory and processor in the aforementioned electronic devices communicate with each other via a communication bus and a communication interface. The communication bus can be a Peripheral Component Interconnect (PCI) bus or an Extended Industry Standard Architecture (EISA) bus, etc. This communication bus can be divided into an address bus, a data bus, a control bus, etc.
[0142] The memory may include random access memory (RAM) or non-volatile memory, such as at least one disk storage device. Optionally, the memory may also be at least one storage device located remotely from the aforementioned processor.
[0143] The processors mentioned above can be general-purpose processors, including central processing units (CPUs), network processors (NPs), etc.; they can also be digital signal processors (DSPs), application-specific integrated circuits (ASICs), field-programmable gate arrays (FPGAs), or other programmable logic devices, discrete gate or transistor logic devices, or discrete hardware components.
[0144] According to another aspect of the embodiments of this application, a computer-readable medium having processor-executable non-volatile program code is also provided.
[0145] Optionally, in embodiments of this application, the computer-readable medium is configured to store program code for the processor to execute the above-described method.
[0146] Optionally, specific examples in this embodiment can refer to the examples described in the above embodiments, and will not be repeated here.
[0147] In specific implementation, the embodiments of this application can be referred to the above embodiments and have corresponding technical effects.
[0148] It is understood that the embodiments described herein can be implemented in hardware, software, firmware, middleware, microcode, or a combination thereof. For hardware implementation, the processing unit can be implemented in one or more application-specific integrated circuits (ASICs), digital signal processors (DSPs), digital signal processing devices (DSPDs), programmable logic devices (PLDs), field-programmable gate arrays (FPGAs), general-purpose processors, controllers, microcontrollers, microprocessors, other electronic units for performing the functions described herein, or combinations thereof.
[0149] For software implementation, the techniques described herein can be implemented by units that perform the functions described herein. The software code can be stored in memory and executed by a processor. The memory can be implemented in the processor or external to the processor.
[0150] Those skilled in the art will recognize that the units and algorithm steps of the various examples described in conjunction with the embodiments disclosed herein can be implemented in electronic hardware, or a combination of computer software and electronic hardware. Whether these functions are implemented in hardware or software depends on the specific application and design constraints of the technical solution. Those skilled in the art can use different methods to implement the described functions for each specific application, but such implementation should not be considered beyond the scope of this application.
[0151] Those skilled in the art will understand that, for the sake of convenience and brevity, the specific working processes of the systems, devices, and units described above can be referred to the corresponding processes in the foregoing method embodiments, and will not be repeated here.
[0152] In the embodiments provided in this application, it should be understood that the disclosed apparatus and methods can be implemented in other ways. For example, the apparatus embodiments described above are merely illustrative. For instance, the division of modules is only a logical functional division, and in actual implementation, there may be other division methods. For example, multiple modules or components may be combined or integrated into another system, or some features may be ignored or not executed. Furthermore, the coupling or direct coupling or communication connection shown or discussed may be an indirect coupling or communication connection through some interfaces, devices, or units, and may be electrical, mechanical, or other forms.
[0153] The units described as separate components may or may not be physically separate. The components shown as units may or may not be physical units; that is, they may be located in one place or distributed across multiple network units. Some or all of the units can be selected to achieve the purpose of this embodiment according to actual needs.
[0154] In addition, the functional units in the various embodiments of this application can be integrated into one processing unit, or each unit can exist physically separately, or two or more units can be integrated into one unit.
[0155] If the aforementioned function is implemented as a software functional unit 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 the embodiments of this application, or the part that contributes to the prior art, or a 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 various media capable of storing program code, such as USB flash drives, portable hard drives, ROM, RAM, magnetic disks, or optical disks. 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 entity or operation, 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. In the absence of further restrictions, an element defined by the phrase "comprising a..." does not exclude the presence of other identical elements in the process, method, article, or apparatus that includes said element.
[0156] The above description is merely a specific embodiment of this application, enabling those skilled in the art to understand or implement this application. Various modifications to these embodiments will be readily apparent to those skilled in the art, and the general principles defined herein may be implemented in other embodiments without departing from the spirit or scope of this application. Therefore, this application is not to be limited to the embodiments shown herein, but is to be accorded the widest scope consistent with the principles and novel features claimed herein.
Claims
1. A method for controlling the operation of a target device, characterized in that, The method includes: Based on the target device's operating path, determine the target device's offset angle and offset distance relative to the target travel line; The angle change value is obtained based on the difference between every two adjacent offset angles, and the distance change value is obtained based on the difference between every two phase offset distances; By using multiple angle change values, multiple distance change values, target offset angle, and target offset distance, a PID control scheme is employed to output PID parameter values. Based on the motion control algorithm, the speed of the drive components on both sides of the target device is adjusted by the PID parameter values to adjust the running path of the target device until the offset angle between the target device and the target travel line matches the target offset angle and the offset distance matches the target offset distance. The step of using multiple angle change values, multiple distance change values, target offset angle, and target offset distance to output PID parameter values through a PID control scheme includes: By adjusting the preset initial PID parameter values using multiple angle change values, multiple distance change values, target offset angle, and target offset distance, intermediate parameter values are obtained. The deviation angle is obtained by the difference between two adjacent angle changes, and the deviation distance is obtained by the difference between two adjacent distance changes. The PID parameter value is obtained by adjusting the intermediate parameter value based on the difference between the deviation angles and the difference between the deviation distances; The PID parameter value is obtained by adjusting the intermediate parameter value based on the difference between the deviation angles and the difference between the deviation distances, including: The difference between the two most recent deviation angles is determined as the deviation angle difference, and the difference between the two most recent deviation distances is determined as the deviation distance difference. Based on the relationship between the deviation angle difference and the preset angle range, or the relationship between the deviation distance difference and the preset distance range, adjust the intermediate ratio parameter in the intermediate parameter value.
2. The method according to claim 1, characterized in that, Adjusting the intermediate ratio parameter in the intermediate parameter value according to the relationship between the deviation angle difference and the preset angle range includes: If the deviation angle difference is greater than the maximum endpoint of the preset angle range, then the intermediate ratio parameter is adjusted to the target ratio parameter value; or, If the deviation angle difference is less than the maximum endpoint of the preset angle range, the intermediate ratio parameter is increased to the target ratio parameter value.
3. The method according to claim 1, characterized in that, Adjusting the intermediate ratio parameter in the intermediate parameter value according to the relationship between the deviation distance difference and the preset distance range includes: If the deviation distance difference is greater than the maximum endpoint of the preset distance range, then the intermediate ratio parameter is adjusted to the target ratio parameter value; or, If the deviation distance difference is less than the maximum endpoint of the preset distance range, the intermediate ratio parameter is increased to the target ratio parameter value.
4. The method according to claim 1, characterized in that, Adjusting the speed of the drive components on both sides of the target device by the PID parameter values includes: The first drive component and the second drive component of the target device are determined based on the offset distance, wherein the distance of the first drive component from the target travel line is less than the distance of the second drive component from the target travel line; The speeds of the first drive component and the second drive component are adjusted respectively using the PID parameter values.
5. The method according to claim 1, characterized in that, Based on the target device's operating path, determining the target device's offset angle and offset distance relative to the target travel line includes: The preset distance between the shooting device and the head of the target device is obtained according to the input command, wherein the shooting device is set on the side of the target device; The offset angle of the target device and the first distance between the shooting device and the target's travel line are obtained by the shooting device, wherein the straight line containing the first distance forms a 90-degree angle with the running direction of the target device. Based on trigonometric functions, the offset distance of the target device relative to the target driving line is obtained through the preset distance, the first distance, and the offset angle, wherein the offset distance is the distance between the head of the target device and the target driving line.
6. The method according to claim 5, characterized in that, Based on trigonometric functions, the offset distance of the target device relative to the target travel line is obtained using the preset distance, the first distance, and the offset angle, including: Based on the cosine function, a second distance is obtained by using the first distance and the offset angle, wherein the line containing the second distance is perpendicular to the target driving line; The third distance is obtained based on the sin function and the preset distance; The difference between the second distance and the third distance is used as the offset distance.
7. An operation control device for a target device, characterized in that, The device includes: The determination module is used to determine the offset angle and offset distance of the target device relative to the target travel line based on the running path of the target device; The module is used to obtain the angle change value based on the difference between every two adjacent offset angles, and to obtain the distance change value based on the difference between every two phase offset distances; The output module is used to output PID parameter values using a PID control scheme based on multiple angle change values, multiple distance change values, target offset angle, and target offset distance. The adjustment module is used to adjust the speed of the drive components on both sides of the target device according to the motion control algorithm and the PID parameter values, so as to adjust the running path of the target device until the offset angle between the target device and the target travel line matches the target offset angle and the offset distance matches the target offset distance. The output module is used for: By adjusting the preset initial PID parameter values using multiple angle change values, multiple distance change values, target offset angle, and target offset distance, intermediate parameter values are obtained. The deviation angle is obtained by the difference between two adjacent angle changes, and the deviation distance is obtained by the difference between two adjacent distance changes. The PID parameter value is obtained by adjusting the intermediate parameter value based on the difference between the deviation angles and the difference between the deviation distances; Specifically, the output module is used for: The difference between the two most recent deviation angles is determined as the deviation angle difference, and the difference between the two most recent deviation distances is determined as the deviation distance difference. Based on the relationship between the deviation angle difference and the preset angle range, or the relationship between the deviation distance difference and the preset distance range, adjust the intermediate ratio parameter in the intermediate parameter value.
8. An electronic device, characterized in that, It includes a processor, a communication interface, a memory, and a communication bus, wherein the processor, the communication interface, and the memory communicate with each other through the communication bus; Memory, used to store computer programs; A processor, when executing a program stored in memory, implements any of the method steps of claims 1-6.
9. A computer-readable storage medium, characterized in that, The computer-readable storage medium stores a computer program that, when executed by a processor, implements any of the method steps of claims 1-6.
Citation Information
Patent Citations
Lane keeping control method and system, electronic equipment and storage medium
CN113788017A
Vehicle transverse control method and device, equipment and storage medium
CN113848899A