Distance determination method, system and device and storage medium
Through the coordinated work of the vehicle controller and the vehicle-mounted drone, the distance between the vehicle and the target object is calculated using the principle of trigonometry, the problem of distance measurement difficulties caused by occlusion is solved, and the accurate distance measurement in the presence of occlusion is achieved.
Patent Information
- Application Number
- CN202510742408.4
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-06-05
- Publication Date
- 2025-09-05
AI Technical Summary
In the prior art, when there is a shading or space dislocation between the vehicle and the target object, the distance between the vehicle and the target object cannot be accurately determined.
The vehicle controller sends flight instructions to the vehicle-mounted drone, and the vehicle-mounted drone captures the picture during the flight and determines the first position information, the first angle and the first distance. The vehicle controller combines the position information of the drone and the vehicle to calculate the target distance using the principle of trigonometry.
Even in the presence of a occlusion, the distance between the vehicle and the target object can be accurately calculated, which expands the application scenario of vehicle distance measurement.
Smart Images

Figure CN120593729A_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of vehicle technology, and in particular to a distance determination method, system, device, and storage medium. Background Art
[0002] Vehicle ranging is mainly used to determine the distance between the vehicle and the target object. Vehicle ranging can be applied to surveying and mapping scenarios, such as terrain surveying and mapping, architectural surveying and mapping, etc. It can also be applied to other scenarios, such as autonomous driving scenarios.
[0003] In related technologies, vehicle ranging is mainly measured by laser ranging or visual ranging. However, when there are obstructions or spatial misalignment between the vehicle and the target object, the distance between the vehicle and the target object cannot be determined by the above methods. Summary of the Invention
[0004] The present invention provides a distance determination method, system, device, and storage medium, which can determine the distance between a vehicle and a target object when there is an obstruction between the vehicle and the target object. The technical solution is as follows:
[0005] In one aspect, a distance determination method is provided. The method is applied to a distance determination system, wherein the distance determination system includes a vehicle controller and an onboard drone, wherein the vehicle controller and the onboard drone are electrically connected. The method includes:
[0006] In the event that there is an obstruction between the vehicle and the target object, the vehicle controller sends a flight instruction to the vehicle-mounted UAV;
[0007] The vehicle-mounted drone captures images during the flight based on the flight instruction; when the target object exists in the image, determines first position information, a first angle, and a first distance; and sends a notification message to the vehicle controller, the notification message carrying the first position information, the first angle, and the first distance; wherein the first position information is used to indicate the current position of the vehicle-mounted drone, the first angle is used to indicate the angle between the shooting angle and the vertical direction when the vehicle-mounted drone captures the target object, and the first distance is used to indicate the distance between the vehicle-mounted drone and the target object;
[0008] The vehicle controller determines second position information based on the notification message; determines a second distance and a second angle based on the first position information and the second position information; and determines a target distance based on the first distance, the second distance, the first angle, and the second angle; wherein the second distance is used to represent the distance between the vehicle and the vehicle-mounted drone, the second angle is used to represent the angle between the line between the vehicle and the vehicle-mounted drone and the vertical direction, and the target distance is used to represent the distance between the vehicle and the target object.
[0009] In one possible implementation, the first location information includes the x-coordinate, y-coordinate, and z-coordinate of the vehicle, and the second location information includes the x-coordinate, y-coordinate, and z-coordinate of the vehicle-mounted drone;
[0010] The process of determining the second distance and the second angle by the vehicle controller based on the first position information and the second position information includes:
[0011] The vehicle controller determines the square of the difference between the x-coordinate of the vehicle and the x-coordinate of the vehicle-mounted drone to obtain a first value;
[0012] Determining the square of the difference between the y-coordinate of the vehicle and the y-coordinate of the vehicle-mounted drone to obtain a second value;
[0013] Determining an absolute value of a difference between a z-coordinate of the vehicle and a z-coordinate of the vehicle-mounted drone to obtain a third value;
[0014] The second distance and the second angle are determined based on the first value, the second value, and the third value.
[0015] In another possible implementation, the process of determining, by the vehicle controller, the second distance and the second angle based on the first value, the second value, and the third value includes:
[0016] The vehicle controller determines the square of the third value to obtain a fourth value;
[0017] determining a square root of the sum of the first value, the second value, and the fourth value to obtain the second distance;
[0018] determining a square root of a sum of the first value and the second value to obtain a fifth value;
[0019] An arc tangent value of the ratio of the fifth value to the third value is determined to obtain the second angle.
[0020] In another possible implementation, the process of determining, by the vehicle controller, the target distance based on the first distance, the second distance, the first angle, and the second angle includes:
[0021] The vehicle controller determines a sum of the first angle and the second angle to obtain a third angle;
[0022] The target distance is determined by the law of cosines based on the first distance, the second distance, and the third angle.
[0023] In another possible implementation, the process of determining the target distance by the vehicle controller using the law of cosines based on the first distance, the second distance, and the third angle includes:
[0024] The vehicle controller determines a cosine value of the third angle to obtain a sixth value;
[0025] determining twice the product of the first distance, the second distance, and the sixth value to obtain a seventh value;
[0026] The target distance is determined based on the first distance, the second distance, and the seventh value.
[0027] In another possible implementation, when the target object exists in the image, the process of the vehicle-mounted drone determining the first position information, the first angle, and the first distance includes:
[0028] When the target object exists in the picture, the vehicle-mounted drone stops flying, determines the first position information through the positioning module, determines the first angle through the gimbal system, and determines the first distance through the lidar system.
[0029] In another aspect, a distance determination system is provided, the system comprising: a vehicle controller and a vehicle-mounted drone, the vehicle controller and the vehicle-mounted drone being electrically connected;
[0030] The vehicle controller is configured to send flight instructions to the vehicle-mounted UAV when there is an obstruction between the vehicle and the target object;
[0031] The vehicle-mounted drone is configured to capture images during flight based on the flight instruction; determine first position information, a first angle, and a first distance when the target object exists in the image; and send a notification message to the vehicle controller, the notification message carrying the first position information, the first angle, and the first distance; wherein the first position information is used to indicate the current position of the vehicle-mounted drone, the first angle is used to indicate the angle between the shooting angle and the vertical direction when the vehicle-mounted drone captures the target object, and the first distance is used to indicate the distance between the vehicle-mounted drone and the target object;
[0032] The vehicle controller is further used to determine second position information based on the notification message; determine a second distance and a second angle based on the first position information and the second position information; and determine a target distance based on the first distance, the second distance, the first angle, and the second angle; wherein the second distance is used to represent the distance between the vehicle and the vehicle-mounted drone, the second angle is used to represent the angle between the line between the vehicle and the vehicle-mounted drone and the vertical direction, and the target distance is used to represent the distance between the vehicle and the target object.
[0033] In one possible implementation, the first location information includes the x-coordinate, y-coordinate, and z-coordinate of the vehicle, and the second location information includes the x-coordinate, y-coordinate, and z-coordinate of the vehicle-mounted drone;
[0034] The vehicle controller is further used to determine the square of the difference between the x-coordinate of the vehicle and the x-coordinate of the vehicle-mounted drone to obtain a first value; determine the square of the difference between the y-coordinate of the vehicle and the y-coordinate of the vehicle-mounted drone to obtain a second value; determine the absolute value of the difference between the z-coordinate of the vehicle and the z-coordinate of the vehicle-mounted drone to obtain a third value; and determine the second distance and the second angle based on the first value, the second value, and the third value.
[0035] In another possible implementation, the vehicle controller is further used to determine the square of the third value to obtain a fourth value; determine the square root of the sum of the first value, the second value and the fourth value to obtain the second distance; determine the square root of the sum of the first value and the second value to obtain a fifth value; determine the arc tangent value of the ratio of the fifth value to the third value to obtain the second angle.
[0036] In another possible implementation, the vehicle controller is further used to determine the sum of the first angle and the second angle to obtain a third angle; and determine the target distance using the law of cosines based on the first distance, the second distance and the third angle.
[0037] In another possible implementation, the vehicle controller is also used to determine the cosine value of the third angle to obtain a sixth value; determine twice the product of the first distance, the second distance and the sixth value to obtain a seventh value; and determine the target distance based on the first distance, the second distance and the seventh value.
[0038] In another possible implementation, the vehicle-mounted drone is used to stop flying when the target object exists in the picture, determine the first position information through a positioning module, determine the first angle through a gimbal system, and determine the first distance through a lidar system.
[0039] On the other hand, an electronic device is provided, comprising a processor and a memory, wherein the memory stores at least one program code, and the at least one program code is loaded and executed by the processor to implement the distance determination method described in any one of the above-mentioned vehicle-mounted drones or vehicle controllers.
[0040] On the other hand, a computer-readable storage medium is provided, wherein at least one program code is stored in the computer-readable storage medium, and the at least one program code is loaded and executed by a processor to implement any of the above distance determination methods.
[0041] On the other hand, a computer program product is provided, wherein at least one program code is stored in the computer program product, and the at least one program code is loaded and executed by a processor to implement any of the above distance determination methods.
[0042] An embodiment of the present application provides a distance determination method, in which, when there is an obstruction between a vehicle and a target object, the vehicle controller sends a flight instruction to a vehicle-mounted drone, and the vehicle-mounted drone takes a picture of the flight process based on the flight instruction. When the target object exists in the picture, the current position of the vehicle-mounted drone, the angle at which the vehicle-mounted drone takes the picture of the target object, and the distance between the vehicle-mounted drone and the target object are determined, and the position, angle, and distance are sent to the vehicle controller. The vehicle controller determines the distance between the vehicle and the target object based on the position, angle, and distance sent by the vehicle-mounted drone, combined with its own position. It can be seen that this method determines the distance between the vehicle and the target object based on the spatial positional relationship between the vehicle-mounted drone, the vehicle, and the target object. In this way, even if there is an obstruction between the vehicle and the target object, the distance between the vehicle and the target object can be determined, thereby greatly expanding the application scenarios of vehicle ranging.
[0043] It should be understood that the foregoing general description and the following detailed description are exemplary only and are not restrictive of the present disclosure. BRIEF DESCRIPTION OF THE DRAWINGS
[0044] Figure 1 is a schematic diagram of a distance determination system provided in an embodiment of the present application;
[0045] Figure 2 is a flow chart of a distance determination method provided in an embodiment of the present application;
[0046] Figure 3 is a schematic diagram of the positional relationship between a vehicle, a vehicle-mounted drone, and a target object provided in an embodiment of the present application;
[0047] Figure 4 This is a structural block diagram of a vehicle controller provided in an embodiment of the present application;
[0048] Figure 5 This is a structural block diagram of a vehicle-mounted drone provided in an embodiment of the present application. DETAILED DESCRIPTION
[0049] In order to make the technical solutions and advantages of the present application clearer, the implementation methods of the present application are described in further detail below.
[0050] The terms "first," "second," "third," and "fourth," etc. in the specification and claims of this application and the accompanying drawings are used to distinguish different objects, not to describe a specific order. In addition, the terms "including" and "having," and any variations thereof, are intended to cover non-exclusive inclusions. For example, a process, method, system, product, or apparatus comprising a series of steps or elements is not limited to the listed steps or elements, but may optionally include steps or elements not listed, or may optionally include other steps or elements inherent to the process, method, product, or apparatus.
[0051] It should be noted that the information (including but not limited to user device information, user personal information, etc.), data (including but not limited to data used for analysis, stored data, displayed data, etc.), and signals involved in this application are all authorized by the user or fully authorized by all parties, and the collection, use, and processing of relevant data must comply with the relevant laws, regulations, and standards of the relevant countries and regions. For example, the location information and images involved in this application are all obtained with full authorization.
[0052] Figure 1 This is a schematic diagram of a distance determination system provided in an embodiment of the present application, see Figure 1 The system includes: a vehicle controller 101 and a vehicle-mounted drone 102, wherein the vehicle controller 101 and the vehicle-mounted drone 102 are electrically connected;
[0053] The vehicle controller 101 is used to send flight instructions to the vehicle-mounted drone 102 when there is an obstruction between the vehicle and the target object;
[0054] The vehicle-mounted drone 102 is configured to capture images during flight based on flight instructions; when a target object is present in the image, determine first position information, a first angle, and a first distance; and send a notification message to the vehicle controller 101, the notification message carrying the first position information, the first angle, and the first distance; wherein the first position information is used to indicate the current position of the vehicle-mounted drone 102, the first angle is used to indicate the angle between the shooting angle and the vertical direction when the vehicle-mounted drone 102 captures the target object, and the first distance is used to indicate the distance between the vehicle-mounted drone 102 and the target object;
[0055] The vehicle controller 101 is also used to determine the second position information based on the notification message; determine the second distance and the second angle based on the first position information and the second position information; determine the target distance based on the first distance, the second distance, the first angle and the second angle; wherein the second distance is used to represent the distance between the vehicle and the vehicle-mounted drone 102, the second angle is used to represent the angle between the line between the vehicle and the vehicle-mounted drone 102 and the vertical direction, and the target distance is used to represent the distance between the vehicle and the target object.
[0056] In the embodiments of the present application, the electrical connection may be a circuit connection or a wireless connection, and this is not specifically limited. If the electrical connection is a circuit connection, the connection method may be a cable connection. If the electrical connection is a wireless connection, the connection method may be a wireless local area network or WiFi (Wireless Fidelity) network connection. In the embodiments of the present application, this is not specifically limited.
[0057] The vehicle controller 101 may be a body controller, a domain controller, an audio head unit controller, or other controllers, without specific limitation. The vehicle may be an electric vehicle, a fuel vehicle, or a hybrid vehicle, without specific limitation.
[0058] In one possible implementation, the first location information includes the x-coordinate, y-coordinate, and z-coordinate of the vehicle, and the second location information includes the x-coordinate, y-coordinate, and z-coordinate of the vehicle-mounted drone 102 ;
[0059] The vehicle controller 101 is further used to determine the square of the difference between the vehicle's x-coordinate and the vehicle-mounted drone 102's x-coordinate to obtain a first value; determine the square of the difference between the vehicle's y-coordinate and the vehicle-mounted drone 102's y-coordinate to obtain a second value; determine the absolute value of the difference between the vehicle's z-coordinate and the vehicle-mounted drone 102's z-coordinate to obtain a third value; and determine a second distance and a second angle based on the first value, the second value, and the third value.
[0060] In another possible implementation, the vehicle controller 101 is also used to determine the square of the third value to obtain a fourth value; determine the square root of the sum of the first value, the second value and the fourth value to obtain a second distance; determine the square root of the sum of the first value and the second value to obtain a fifth value; determine the arc tangent value of the ratio of the fifth value to the third value to obtain a second angle.
[0061] In another possible implementation, the vehicle controller 101 is further configured to determine the sum of the first angle and the second angle to obtain a third angle; and determine the target distance using the law of cosines based on the first distance, the second distance, and the third angle.
[0062] In another possible implementation, the vehicle controller 101 is also used to determine the cosine value of the third angle to obtain a sixth value; determine twice the product of the first distance, the second distance and the sixth value to obtain a seventh value; and determine the target distance based on the first distance, the second distance and the seventh value.
[0063] In another possible implementation, the vehicle-mounted drone 102 is configured to stop flying when a target object appears in the image, determine first position information through a positioning module, determine a first angle through a gimbal system, and determine a first distance through a lidar system.
[0064] An embodiment of the present application provides a distance determination system. In this system, when there is an obstruction between a vehicle and a target object, the vehicle controller sends a flight instruction to a vehicle-mounted drone. The vehicle-mounted drone takes a picture of the flight process based on the flight instruction. When the target object exists in the picture, the current position of the vehicle-mounted drone, the angle at which the vehicle-mounted drone takes the picture of the target object, and the distance between the vehicle-mounted drone and the target object are determined, and the position, angle, and distance are sent to the vehicle controller. The vehicle controller determines the distance between the vehicle and the target object based on the position, angle, and distance sent by the vehicle-mounted drone and its own position. It can be seen that the system determines the distance between the vehicle and the target object based on the spatial positional relationship between the vehicle-mounted drone, the vehicle, and the target object. In this way, even if there is an obstruction between the vehicle and the target object, the distance between the vehicle and the target object can be determined, thereby greatly expanding the application scenarios of vehicle ranging.
[0065] The embodiments of the distance determination system and distance determination method provided in this application belong to the same concept. The specific implementation process can be found in the method embodiment and will not be described here in detail.
[0066] Figure 2 This is a flow chart of a distance determination method provided in an embodiment of the present application, which is executed by a vehicle controller and a vehicle-mounted drone. The method includes:
[0067] Step 201: When there is an obstruction between the vehicle and the target object, the vehicle controller sends a flight instruction to the vehicle-mounted drone.
[0068] The vehicle controller and the vehicle-mounted drone correspond to the same vehicle, which may further include a central control unit, the central control unit including a central display screen. A user may install a distance measurement application via the central display screen. In response to logging into the distance measurement application, the central control unit displays a distance measurement interface via the central display screen, wherein the distance measurement interface displays a distance measurement option. In response to detecting a trigger operation in which the distance measurement option is triggered, the central control unit sends a distance measurement instruction to the vehicle controller.
[0069] Upon receiving the ranging command, the vehicle controller can first determine the distance between the vehicle and the target object through laser ranging or visual ranging. If the distance between the vehicle and the target object cannot be determined through laser ranging or visual ranging, it indicates that there is an obstruction or spatial misalignment between the vehicle and the target object. In this case, the vehicle controller can send flight commands to the onboard drone to control the drone's flight. The flight commands can carry an image or features of the target object to facilitate subsequent identification of the target object by the onboard drone. The target object can be static or dynamic, without specific limitation. For example, the target object can be another vehicle, pedestrian, animal, object, etc.
[0070] Step 202: The vehicle-mounted UAV takes pictures of the flight process based on the flight instructions.
[0071] The vehicle also features a drone cabin, which houses the vehicle-mounted drone. The drone is equipped with a camera to capture footage during flight. Upon receiving flight commands, the drone emerges from the cabin, capturing footage via the camera during flight.
[0072] The vehicle-mounted drone can identify the captured image to determine whether the target object exists in the image. The vehicle-mounted drone can identify the captured image based on the image of the target object or based on the characteristics of the target object to determine whether the target object exists in the image. If the target object exists, step 203 is executed. If the target object does not exist, the drone flies to a higher altitude and / or a position closer to the target object until the target object appears in the captured image.
[0073] For example, see Figure 3 ,When the vehicle-mounted drone is at position B, there is a target object in the captured image. Position C is used to indicate the location of the target object, and position A is used to indicate the location of the vehicle.
[0074] Step 203: When a target object exists in the image, the vehicle-mounted drone determines first position information, a first angle, and a first distance.
[0075] When a target object exists in the picture taken by the vehicle-mounted drone, the vehicle-mounted drone can stop flying, determine the first position information through the positioning module, determine the first angle through the gimbal system, and determine the first distance through the lidar system.
[0076] The vehicle-mounted drone is equipped with a positioning module, a gimbal system, and a lidar system. The positioning module may integrate RTK (Real-Time Kinematic) technology to determine the first position information through RTK; alternatively, the positioning module may integrate GPS (Global Positioning System) to determine the first position information through GPS, without specific limitation. The first position information includes the vehicle's x-coordinate, y-coordinate, and z-coordinate.
[0077] The vehicle-mounted drone can adjust the gimbal's position through the gimbal system, including adjusting parameters such as pitch angle, roll angle, and yaw angle, so that the camera can capture the target object more clearly and accurately. Accordingly, the vehicle-mounted drone determines the gimbal's orientation angle at this time, which is also known as the first angle.
[0078] The vehicle-mounted UAV transmits a laser signal through the lidar system, and determines the distance between the vehicle-mounted UAV and the target object according to the time difference between the emission time and the reception time of the laser signal, thereby obtaining the first distance.
[0079] Step 204: The vehicle-mounted drone sends a notification message to the vehicle controller.
[0080] After determining the first position information, the first angle, and the first distance, the vehicle-mounted drone sends a notification message to the vehicle controller, where the notification message carries the first position information, the first angle, and the first distance.
[0081] Step 205: The vehicle controller determines second location information based on the notification message.
[0082] After receiving the notification message sent by the on-board drone, the vehicle controller determines the current position of the vehicle, i.e., the second position information, through the positioning module configured in the vehicle. The second position information includes the x-coordinate, y-coordinate, and z-coordinate of the on-board drone.
[0083] Step 206 : The vehicle controller determines a second distance and a second angle based on the first position information and the second position information.
[0084] The second distance is used to represent the distance between the vehicle and the vehicle-mounted UAV, and the second angle is used to represent the angle between the line between the vehicle and the vehicle-mounted UAV and the vertical direction.
[0085] This step can be achieved by following the steps (1) to (4), including:
[0086] (1) The vehicle controller determines the square of the difference between the x-coordinate of the vehicle and the x-coordinate of the onboard drone to obtain a first value.
[0087] The first value can be expressed as (x1-x2)2 , where x1 represents the x-coordinate of the vehicle and x2 represents the x-coordinate of the vehicle-mounted drone.
[0088] (2) The vehicle controller determines the square of the difference between the y-coordinate of the vehicle and the y-coordinate of the onboard drone to obtain a second value.
[0089] The second value can be expressed as (y1-y2) 2 , where y1 represents the y coordinate of the vehicle and y2 represents the y coordinate of the vehicle-mounted drone.
[0090] (3) The vehicle controller determines the absolute value of the difference between the z coordinate of the vehicle and the z coordinate of the onboard drone to obtain a third value.
[0091] The third value can be expressed as |z1-z2|, where z1 represents the z coordinate of the vehicle and z2 represents the z coordinate of the vehicle-mounted drone.
[0092] (4) The vehicle controller determines a second distance and a second angle based on the first value, the second value, and the third value.
[0093] The vehicle controller determines the second distance based on the first value, the second value and the third value. The process can be: the vehicle controller determines the square of the third value to obtain the fourth value; determines the square root of the sum of the first value, the second value and the fourth value to obtain the second distance.
[0094] Among them, the second distance can be expressed as: L2 represents the second distance, see Figure 3 .
[0095] The process of the vehicle controller determining the second angle based on the first value, the second value and the third value can be: the vehicle controller determines the square root of the sum of the first value and the second value to obtain the fifth value; determines the arc tangent value of the ratio of the fifth value to the third value to obtain the second angle.
[0096] The second angle can be expressed as: Continue to see Figure 3 .
[0097] The process of the vehicle controller determining the second angle based on the first value, the second value and the third value may also be: the vehicle controller determines the arc sine value of the ratio of the fifth value and the second distance to obtain the second angle.
[0098] The second angle can be expressed as:
[0099] Step 207: The vehicle controller determines a target distance based on the first distance, the second distance, the first angle, and the second angle.
[0100] The target distance is used to indicate the distance between the vehicle and the target object.
[0101] This step can be achieved by following the steps (1) to (2), including:
[0102] (1) The vehicle controller determines the sum of the first angle and the second angle to obtain a third angle.
[0103] The third angle can be expressed as α+θ.
[0104] (2) The vehicle controller determines the target distance using the law of cosines based on the first distance, the second distance, and the third angle.
[0105] Step (2) can be achieved by the following steps (2-1) to (2-3), including:
[0106] (2-1) The vehicle controller determines the cosine value of the third angle to obtain a sixth value.
[0107] The sixth value can be expressed as cos(α+θ).
[0108] (2-2) The vehicle controller determines twice the product of the first distance, the second distance, and the sixth value to obtain a seventh value.
[0109] The seventh value can be expressed as 2L1L2cos(α+θ), where L1 represents the first distance.
[0110] (2-3) The vehicle controller determines a target distance based on the first distance, the second distance, and the seventh value.
[0111] The vehicle controller determines the sum of the square of the first distance and the square of the second distance to obtain a first sum, and determines the square root of the difference between the first sum and the seventh value to obtain a target distance.
[0112] The target distance can be expressed as Among them, L AC Indicates the target distance.
[0113] In an embodiment of the present application, after the vehicle controller determines the target distance, it can send the target distance to the central control vehicle computer, and the central control vehicle computer displays the target distance through the central control display screen, so that the user can clearly know the distance between the vehicle and the target object by watching the central control display screen. Alternatively, after the vehicle controller determines the target distance, it broadcasts the target distance through the voice equipment in the vehicle, so that the user can clearly know the distance between the vehicle and the target object without watching the central control display screen. It can be seen that even if there are obstructions or spatial misalignment between the vehicle and the target object, the distance between the vehicle and the target object can be determined by the method provided by the present application, which can not only improve the distance measurement accuracy, but also greatly expand the application scenarios of vehicle distance measurement.
[0114] An embodiment of the present application provides a distance determination method, in which, when there is an obstruction between a vehicle and a target object, the vehicle controller sends a flight instruction to a vehicle-mounted drone, and the vehicle-mounted drone takes a picture of the flight process based on the flight instruction. When the target object exists in the picture, the current position of the vehicle-mounted drone, the angle at which the vehicle-mounted drone takes the picture of the target object, and the distance between the vehicle-mounted drone and the target object are determined, and the position, angle, and distance are sent to the vehicle controller. The vehicle controller determines the distance between the vehicle and the target object based on the position, angle, and distance sent by the vehicle-mounted drone, combined with its own position. It can be seen that this method determines the distance between the vehicle and the target object based on the spatial positional relationship between the vehicle-mounted drone, the vehicle, and the target object. In this way, even if there is an obstruction between the vehicle and the target object, the distance between the vehicle and the target object can be determined, thereby greatly expanding the application scenarios of vehicle ranging.
[0115] Figure 4 1 is a schematic diagram of a controller according to an embodiment of the present application. The controller may be the vehicle controller described above.
[0116] Typically, the controller 400 includes a main control module 401, a CAN interface 402, a hard-wired input interface 403, and a hard-wired output interface 404. The main control module 401 is connected to the CAN interface 402, the hard-wired input interface 403, and the hard-wired output interface 404, respectively.
[0117] The main control module 401 typically includes a processor and memory. The processor may include one or more processing cores, such as a quad-core processor or an octa-core processor. The processor may be implemented in hardware using at least one of a DSP (Digital Signal Processing), an FPGA (Field-Programmable Gate Array), and a PLA (Programmable Logic Array). The processor may also include a main processor and a coprocessor. The main processor is used to process data in the awake state, also known as a CPU (Central Processing Unit); the coprocessor is a low-power processor used to process data in the standby state. In some embodiments, the processor may be integrated with a GPU (Graphics Processing Unit), which is responsible for rendering and drawing content required to be displayed on the vehicle display screen. In some embodiments, the processor may also include an AI (Artificial Intelligence) processor, which is used to handle computational operations related to machine learning. The memory may include one or more computer-readable storage media, which may be non-transitory. The memory may also include high-speed random access memory and non-volatile memory, such as one or more disk storage devices or flash storage devices. In some embodiments, the non-transitory computer-readable storage medium in the memory is used to store at least one computer program, which is used to be executed by the processor to implement the distance determination method provided by the method embodiment of the present application.
[0118] The CAN interface 402 may include a power CAN interface, a motor CAN interface, and a diagnostic CAN interface. The power CAN interface is used to communicate with a vehicle's powertrain module, the motor CAN interface is used to communicate with a vehicle's motor controller, and the diagnostic CAN interface is used to communicate with diagnostic equipment.
[0119] The hardwire input interface 403 is used to receive hardwire control signals. The hardwire output interface 404 is used to send control instructions to the vehicle's electronic control components, causing them to perform corresponding actions. The vehicle's electronic control components include the power management system, motor controller, onboard charger, and body control system.
[0120] The main control module 401 can communicate with the vehicle's power system module, motor controller and diagnostic equipment through the CAN interface 402, and generate control instructions based on the hard-wired control signal received by the hard-wired input interface 403 to send control instructions to the vehicle's electronic control components through the hard-wired output interface 404.
[0121] Those skilled in the art will understand that Figure 4 The structure shown in the figure does not constitute a limitation on the controller 400, and the controller 400 may include more or fewer components than shown in the figure, or combine certain components, or adopt a different component arrangement.
[0122] The structural diagram of the vehicle-mounted drone can be found in Figure 5 The vehicle-mounted drone 500 may vary significantly due to different configurations or performances, and may include a processor (Central Processing Units, CPU) 501 and a memory 502. The memory 502 stores at least one program code, which is loaded and executed by the processor 501 to implement the operations performed by the vehicle-mounted drone in the above-mentioned distance determination method. Of course, the vehicle-mounted drone 500 may also have components such as a wired or wireless network interface, a keyboard, and input / output interfaces for input and output. The vehicle-mounted drone 500 may also include other components for implementing device functions, which will not be detailed here.
[0123] In an exemplary embodiment, a computer-readable storage medium is further provided. The computer-readable medium stores at least one program code. The at least one program code is loaded and executed by a processor to implement the distance determination method in the above embodiment.
[0124] In an exemplary embodiment, a computer program product is further provided. The computer program product stores at least one program code. The at least one program code is loaded and executed by a processor to implement the distance determination method in the above embodiment.
[0125] Those skilled in the art will understand that all or part of the steps to implement the above embodiments may be accomplished by hardware, or may be accomplished by a program to instruct the relevant hardware, and the program may be stored in a computer-readable storage medium, and the above-mentioned storage medium may be a read-only memory, a disk or an optical disk, etc.
[0126] The above description is only for the purpose of facilitating those skilled in the art to understand the technical solution of this application and is not intended to limit this application. Any modifications, equivalent replacements, improvements, etc. made within the spirit and principles of this application shall be included in the scope of protection of this application.
Claims
1. A distance determination method, characterized in that: The method is applied to a distance determination system, the distance determination system including a vehicle controller and a vehicle-mounted drone, the vehicle controller and the vehicle-mounted drone being electrically connected; the method comprising: In the event that there is an obstruction between the vehicle and the target object, the vehicle controller sends a flight instruction to the vehicle-mounted UAV; The vehicle-mounted drone captures images during the flight based on the flight instruction; when the target object exists in the image, determines first position information, a first angle, and a first distance; and sends a notification message to the vehicle controller, the notification message carrying the first position information, the first angle, and the first distance; wherein the first position information is used to indicate the current position of the vehicle-mounted drone, the first angle is used to indicate the angle between the shooting angle and the vertical direction when the vehicle-mounted drone captures the target object, and the first distance is used to indicate the distance between the vehicle-mounted drone and the target object; The vehicle controller determines second position information based on the notification message; determines a second distance and a second angle based on the first position information and the second position information; and determines a target distance based on the first distance, the second distance, the first angle, and the second angle; wherein the second distance is used to represent the distance between the vehicle and the vehicle-mounted drone, the second angle is used to represent the angle between the line between the vehicle and the vehicle-mounted drone and the vertical direction, and the target distance is used to represent the distance between the vehicle and the target object.
2. The method according to claim 1, characterized in that The first position information includes the x-coordinate, y-coordinate, and z-coordinate of the vehicle, and the second position information includes the x-coordinate, y-coordinate, and z-coordinate of the vehicle-mounted drone; The process of determining the second distance and the second angle by the vehicle controller based on the first position information and the second position information includes: The vehicle controller determines the square of the difference between the x-coordinate of the vehicle and the x-coordinate of the vehicle-mounted drone to obtain a first value; Determining the square of the difference between the y-coordinate of the vehicle and the y-coordinate of the vehicle-mounted drone to obtain a second value; Determining an absolute value of a difference between a z-coordinate of the vehicle and a z-coordinate of the vehicle-mounted drone to obtain a third value; The second distance and the second angle are determined based on the first value, the second value, and the third value.
3. The method according to claim 2, characterized in that The process of determining the second distance and the second angle by the vehicle controller based on the first value, the second value, and the third value includes: The vehicle controller determines the square of the third value to obtain a fourth value; determining a square root of the sum of the first value, the second value, and the fourth value to obtain the second distance; determining a square root of a sum of the first value and the second value to obtain a fifth value; An arc tangent value of the ratio of the fifth value to the third value is determined to obtain the second angle.
4. The method according to claim 1, wherein The process of determining the target distance by the vehicle controller based on the first distance, the second distance, the first angle, and the second angle includes: The vehicle controller determines a sum of the first angle and the second angle to obtain a third angle; The target distance is determined by the law of cosines based on the first distance, the second distance, and the third angle.
5. The method according to claim 4, characterized in that The process of determining the target distance by the vehicle controller based on the first distance, the second distance, and the third angle by the law of cosines includes: The vehicle controller determines a cosine value of the third angle to obtain a sixth value; determining twice the product of the first distance, the second distance, and the sixth value to obtain a seventh value; The target distance is determined based on the first distance, the second distance, and the seventh value.
6. The method according to claim 1, characterized in that When the target object exists in the picture, the process of the vehicle-mounted drone determining the first position information, the first angle, and the first distance includes: When the target object exists in the picture, the vehicle-mounted drone stops flying, determines the first position information through the positioning module, determines the first angle through the gimbal system, and determines the first distance through the lidar system.
7. A distance determination system, characterized in that: The system includes: a vehicle controller and a vehicle-mounted drone, wherein the vehicle controller and the vehicle-mounted drone are electrically connected; The vehicle controller is configured to send flight instructions to the vehicle-mounted UAV when there is an obstruction between the vehicle and the target object; The vehicle-mounted drone is configured to capture images during flight based on the flight instruction; determine first position information, a first angle, and a first distance when the target object exists in the image; and send a notification message to the vehicle controller, the notification message carrying the first position information, the first angle, and the first distance; wherein the first position information is used to indicate the current position of the vehicle-mounted drone, the first angle is used to indicate the angle between the shooting angle and the vertical direction when the vehicle-mounted drone captures the target object, and the first distance is used to indicate the distance between the vehicle-mounted drone and the target object; The vehicle controller is further used to determine second position information based on the notification message; determine a second distance and a second angle based on the first position information and the second position information; and determine a target distance based on the first distance, the second distance, the first angle, and the second angle; wherein the second distance is used to represent the distance between the vehicle and the vehicle-mounted drone, the second angle is used to represent the angle between the line between the vehicle and the vehicle-mounted drone and the vertical direction, and the target distance is used to represent the distance between the vehicle and the target object.
8. An electronic device, characterized in that: The electronic device includes a processor and a memory, wherein the memory stores at least one program code, and the at least one program code is loaded and executed by the processor to implement the distance determination method described in any one of the vehicle-mounted drone or vehicle controller according to claims 1 to 6.
9. A computer-readable storage medium, characterized in that The computer-readable storage medium stores at least one program code, and the at least one program code is loaded and executed by the processor to implement the distance determination method according to any one of claims 1 to 6.
10. A computer program product, characterized in that The computer program product stores at least one program code, and the at least one program code is loaded and executed by a processor to implement the distance determination method according to any one of claims 1 to 6.