Measurement method, terminal device, electronic device, and readable storage medium
By establishing wireless communication between the UWB module and the electronic device, measurement data is acquired to determine the distance and angle, solving the problem of low accuracy in AR measurement methods and achieving high-precision measurement results and simple operation.
Patent Information
- Application Number
- CN202111462565.8
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2021-12-02
- Publication Date
- 2025-11-25
- Estimated Expiration
- 2041-12-02
AI Technical Summary
Existing AR measurement methods rely on computer vision algorithms, resulting in low measurement accuracy.
By establishing wireless communication between the terminal device and the first and second electronic devices using the UWB module, communication data is acquired to determine the distance, relative angle, and parameter information of the target circle between the measurement start and end points.
It improves measurement accuracy, simplifies the operation process, and reduces equipment power consumption.
Smart Images

Figure CN116233292B_ABST
Abstract
Description
TECHNICAL FIELD
[0001] The present application relates to the technical field of communication, and in particular to a measurement method, a terminal device, an electronic device and a readable storage medium. BACKGROUND
[0002] At present, the measurement method based on a terminal device (such as a mobile phone) is usually an AR (Augmented Reality) measurement method. It is found in practice that the AR measurement method mostly relies on computer vision algorithm to realize the identification of image features, so the measurement accuracy is relatively low. SUMMARY
[0003] The embodiments of the present application provide a measurement method, a terminal device, an electronic device and a readable storage medium, which can improve the measurement accuracy.
[0004] The first aspect of the embodiments of the present application provides a measurement method, which is applicable to a terminal device, the terminal device establishes a communication connection with a first electronic device and a second electronic device, the first electronic device comprises a first UWB module, the second electronic device comprises a second UWB module, and the method comprises the following steps:
[0005] When a measurement operation is detected, control instructions are sent to the first electronic device and the second electronic device respectively, so that the first electronic device and the second electronic device respectively perform wireless communication through the respective UWB modules; wherein the first electronic device and the second electronic device are respectively placed at a measurement starting point and a measurement ending point;
[0006] Communication data is acquired, the communication data is generated by the communication between the first electronic device and the second electronic device and the terminal device, or the communication data is generated by the communication between the first electronic device and the second electronic device;
[0007] A first measurement result is determined according to the communication data; wherein the first measurement result comprises at least one of the following: a distance value between the measurement starting point and the measurement ending point, a relative angle of the measurement starting point and the measurement ending point, and parameter information of a target circle passing through the measurement starting point and the measurement ending point.
[0008] The second aspect of the embodiments of the present application provides a terminal device, which establishes a communication connection with a first electronic device and a second electronic device, the first electronic device comprises a first UWB module, the second electronic device comprises a second UWB module, and the method comprises the following steps:
[0009] a sending unit configured to send a control instruction to the first electronic device and the second electronic device respectively when the measurement operation is detected, so that the first electronic device and the second electronic device respectively perform wireless communication through the respective UWB modules; wherein the first electronic device and the second electronic device are respectively placed at a measurement starting point and a measurement ending point;
[0010] an obtaining unit configured to obtain communication data, the communication data being generated by the first electronic device and the second electronic device respectively communicating with the terminal device, or the communication data being generated by the first electronic device communicating with the second electronic device;
[0011] a processing unit configured to determine a first measurement result according to the communication data; wherein the first measurement result comprises at least one of the following: a distance value between the measurement starting point and the measurement ending point, a relative angle of the measurement starting point and the measurement ending point, and parameter information of a target circle passing through the measurement starting point and the measurement ending point.
[0012] A third aspect of the embodiments of the present application discloses a terminal device, comprising:
[0013] a memory storing executable program codes;
[0014] and a processor coupled with the memory;
[0015] The processor invokes the executable program codes stored in the memory, and the executable program codes are executed by the processor to make the processor implement the method disclosed in the first aspect.
[0016] A fourth aspect of the embodiments of the present application provides a measurement method, the method is suitable for a first electronic device, the first electronic device is in communication connection with a terminal device, and the terminal device is also in communication connection with a second electronic device; the first electronic device comprises a first UWB module, and the second electronic device comprises a second UWB module, and the method comprises:
[0017] receiving a control instruction sent by the terminal device, and the first electronic device and the second electronic device are respectively placed at a measurement starting point and a measurement ending point;
[0018] According to the control instruction, a first signal is transmitted to the second UWB module of the second electronic device through the first UWB module, so that the second electronic device feeds back communication data to the terminal device according to the first signal; the communication data is used to determine a first measurement result; wherein the first measurement result includes at least one of the following: a distance value between the measurement starting point and the measurement ending point, a relative angle of the measurement starting point and the measurement ending point, and parameter information of a target circle passing through the measurement starting point and the measurement ending point.
[0019] The fifth aspect of the embodiment of the present application provides a first electronic device, which is in communication connection with a terminal device, and the terminal device is also in communication connection with a second electronic device; the first electronic device comprises a first UWB module, and the second electronic device comprises a second UWB module,
[0020] The first electronic device comprises:
[0021] An instruction receiving unit is configured to receive a control instruction sent by the terminal device, and the first electronic device and the second electronic device are respectively placed at a measurement starting point and a measurement ending point.
[0022] A signal transmitting unit is configured to transmit a first signal to the second UWB module of the second electronic device through the first UWB module according to the control instruction, so that the second electronic device feeds back communication data to the terminal device according to the first signal; the communication data is used to determine a first measurement result; wherein the first measurement result includes at least one of the following: a distance value between the measurement starting point and the measurement ending point, a relative angle of the measurement starting point and the measurement ending point, and parameter information of a target circle passing through the measurement starting point and the measurement ending point.
[0023] The sixth aspect of the embodiment of the present application discloses a first electronic device, comprising:
[0024] A memory in which an executable program code is stored;
[0025] and a processor coupled with the memory;
[0026] The processor invokes the executable program code stored in the memory, and the executable program code is executed by the processor, so that the processor implements the method disclosed in the fourth aspect.
[0027] The seventh aspect of the embodiment of the present application discloses a computer readable storage medium, which stores a computer program, wherein the computer program causes a computer to execute the steps of any one of the methods in the first aspect or the fourth aspect of the present application.
[0028] The eighth aspect of the embodiments of the present application discloses a computer program product, when the computer program product runs on a computer, causes the computer to execute the steps of any one of the methods in the first aspect or the fourth aspect.
[0029] The ninth aspect of the embodiments of the present application discloses an application publishing platform, the application publishing platform is used for publishing a computer program product, wherein when the computer program product runs on a computer, causes the computer to execute the steps of any one of the methods in the first aspect or the fourth aspect.
[0030] From the above technical solutions, the embodiments of the present application have the following advantages:
[0031] In the embodiments of the present application, when the measurement operation is detected, control instructions are sent to the first electronic device and the second electronic device respectively, so that the first electronic device and the second electronic device respectively perform wireless communication through the respective UWB modules; wherein the first electronic device and the second electronic device are respectively placed at the measurement starting point and the measurement ending point; communication data is obtained, which is generated by the first electronic device and the second electronic device respectively communicating with the terminal device, or is generated by the first electronic device and the second electronic device communicating; according to the communication data, a first measurement result is determined, the first measurement result includes at least one of the following: distance value between the measurement starting point and the measurement ending point, relative angle of the measurement starting point and the measurement ending point, and parameter information of a target circle passing through the measurement starting point and the measurement ending point. By implementing the method, when the user needs to measure, the first electronic device and the second electronic device are only needed to be placed at the measurement starting point and the measurement ending point respectively, and the measurement result can be accurately obtained by wireless communication ranging, the measurement accuracy is improved, and the operation is simple. BRIEF DESCRIPTION OF DRAWINGS
[0032] In order to more clearly illustrate the technical solutions of the embodiments of the present application, the following will briefly introduce the drawings needed to be used in the embodiments and the prior art description. Obviously, the drawings in the following description are only some embodiments of the present application, and other drawings can also be obtained from these drawings.
[0033] Figure 1A is a scene schematic diagram disclosed by the embodiments of the present application;
[0034] Figure 1B is another scene schematic diagram disclosed by the embodiments of the present application;
[0035] Figure 2A is a flowchart of a measurement method disclosed by the embodiments of the present application;
[0036] Figure 2B is a measurement type selection interface disclosed by the embodiments of the present application;
[0037] Figure 3 is a flow diagram of another measurement method disclosed by embodiments of the present application;
[0038] Figure 4 is a flow diagram of another measurement method disclosed by embodiments of the present application;
[0039] Figure 5A is a flow diagram of another measurement method disclosed by embodiments of the present application;
[0040] Figure 5B is an output interface of a first measurement result disclosed by embodiments of the present application;
[0041] Figure 5C is another output interface of a first measurement result disclosed by embodiments of the present application;
[0042] Figure 5D is another output interface of a first measurement result disclosed by embodiments of the present application;
[0043] Figure 6 is a structural block diagram of a terminal device disclosed by embodiments of the present application;
[0044] Figure 7 is a structural block diagram of a terminal device disclosed by embodiments of the present application;
[0045] Figure 8 is a structural block diagram of a first electronic device disclosed by embodiments of the present application;
[0046] Figure 9 is a structural block diagram of a first electronic device disclosed by embodiments of the present application. DETAILED DESCRIPTION
[0047] The embodiments of the present application provide a measurement method, a terminal device, an electronic device and a readable storage medium, and the measurement accuracy can be improved.
[0048] In order for those skilled in the art to better understand the present application, the technical solutions in the embodiments of the present application will be described in conjunction with the drawings in the embodiments of the present application. Obviously, the described embodiments are only a part of the embodiments of the present application, not all. Based on the embodiments in the present application, all should belong to the scope of protection of the present application.
[0049] It can be understood that the terminal device involved in the embodiments of the present application can include a general handheld screen electronic terminal device, such as a mobile phone, a smart phone, a portable terminal, a terminal, a personal digital assistant (PDA), a portable multimedia player (PMP) device, a notebook computer, a notebook (NotePad), a wireless broadband (Wibro) terminal, a tablet computer (PC), a smart PC, a point of sales (POS) terminal, and a vehicle-mounted computer, etc.
[0050] The terminal device can also include a wearable device. The wearable device can be directly worn on the user, or integrated into the user's clothes or accessories. The wearable device is not only a hardware device, but also can realize powerful intelligent functions such as computing function, positioning function, alarm function through software support and data interaction, cloud server interaction, and can also be connected with a mobile phone and various terminals. The wearable device can include but is not limited to watch type (such as watch, wrist, etc.) supported by wrist, shoes type (such as shoes, socks or other leg-wearing products) supported by foot, Glass type (such as glasses, helmet, headband, etc.) supported by head, and smart clothes, backpack, walking stick, accessories and various non-mainstream product forms.
[0051] The electronic device (including the first electronic device and the second electronic device) mentioned in the embodiments of the present application is in communication connection with the terminal device, wherein the communication connection manner of the electronic device and the terminal device can include but is not limited to at least one of the following manners: Bluetooth connection, WIFI (Wireless-Fidelity) connection, UWB (Ultra Wideband) connection, etc. The electronic device includes a UWB module, that is, the first electronic device includes a first UWB module, and the second electronic device includes a second UWB module. The electronic device can be a handheld screen electronic terminal device, a wearable device or a headset, etc., which is not limited in the embodiments of the present application. It can be understood that if the electronic device is a headset, the first electronic device can be a first headset, and the second electronic device can be a second headset, and the first headset and the second headset belong to the same headset device.
[0052] The technical solutions of the present application will be further described below in the form of embodiments.
[0053] Please refer to Figure 1A and Figure 1B , Figure 1A and 1B are scene schematic diagrams disclosed in the embodiments of the present application,Figure 1A and Figure 1B Both include a mobile phone 10, a first earphone 20 and a second earphone 30.
[0054] Please refer to Figure 2A , Figure 2A is a flowchart of a measurement method disclosed in embodiments of the present application. As shown in Figure 2A , the measurement method can be applied to Figure 1A and / or Figure 1B the scenarios shown. As shown in Figure 2A , the flowchart can include the following steps:
[0055] 201. When a measurement operation is detected, the terminal device sends control instructions to the first electronic device and the second electronic device, respectively, to make the first electronic device and the second electronic device respectively perform wireless communication through their respective UWB modules.
[0056] Among them, the first electronic device and the second electronic device are respectively placed at the measurement starting point and the measurement ending point. The measurement starting point refers to the starting point of the object to be measured, and the measurement ending point refers to the end point of the object to be measured. In some embodiments, the measurement operation can include but is not limited to any one of the following: voice operation, gesture operation and touch operation, etc. indicating to start measurement.
[0057] In some embodiments, when the measurement operation is detected, a measurement type selection interface can also be displayed on the display screen of the terminal device. The measurement type selection interface can include multiple selection labels, and different selection labels are used to trigger measurement of different types of measurement results.
[0058] In some embodiments, the above-mentioned multiple selection labels can include a label for triggering measurement of the distance value between the measurement starting point and the measurement ending point, a label for triggering measurement of the relative angle of the measurement starting point and the measurement ending point, and a label for triggering measurement of the parameter information of the target circle passing through the measurement starting point and the measurement ending point.
[0059] For example, please refer to Figure 2B , Figure 2B is a measurement type selection interface disclosed in embodiments of the present application, Figure 2B The measurement type selection interface shown includes three selection labels, and the texts corresponding to each selection label are "distance value measurement", "angle measurement" and "circle measurement", respectively.
[0060] In some embodiments, the terminal device sending control instructions to the first electronic device and the second electronic device can include but is not limited to the following ways:
[0061] Manner 1, the terminal device sends control instructions to the first electronic device and the second electronic device respectively through the Bluetooth module of the terminal device; it can be understood that the first electronic device and the second electronic device both include Bluetooth modules.
[0062] Manner 2, the terminal device sends control instructions to the first electronic device and the second electronic device respectively through the WIFI module of the terminal device; it can be understood that the first electronic device and the second electronic device both include WIFI modules.
[0063] Manner 3, the terminal device sends control instructions to the first electronic device and the second electronic device respectively through the UWB module of the terminal device; it can be understood that the first electronic device and the second electronic device both include UWB modules.
[0064] Among them, when the first electronic device receives the control instruction sent by the terminal device, it can emit or receive wireless signals through the first UWB module of the first electronic device, and when the second electronic device receives the control instruction sent by the terminal device, it can emit or receive wireless signals through the second UWB module of the second electronic device.
[0065] 202, the terminal device obtains communication data, which is generated by the first electronic device and the second electronic device respectively communicating with the terminal device, or is generated by the first electronic device and the second electronic device communicating.
[0066] In some embodiments, if the communication data is generated by the first electronic device and the second electronic device respectively communicating with the terminal device, after receiving the control instruction, the first electronic device and the second electronic device can emit wireless signals through their respective UWB modules according to the control instruction, and the terminal device receives the wireless signals sent by the first electronic device through the first UWB module and the second electronic device through the second UWB module respectively through the third UWB module of the terminal device, and obtains the communication data according to the received wireless signals. It can be understood that the communication data can include the flight time between the third UWB module and the first UWB module, and the flight time between the third UWB module and the second UWB module.
[0067] In some embodiments, if the communication data is generated by the first electronic device and the second electronic device communicating, the terminal device obtaining the communication data can include the following cases:
[0068] The first case: the first electronic device transmits a wireless signal through the first UWB module of the first electronic device when receiving the control instruction, the second electronic device receives the wireless signal through the second UWB module of the second electronic device when receiving the control instruction, and obtains the flight time between the first UWB module and the second UWB module according to the received wireless signal, and sends the flight time to the terminal device.
[0069] The second case: the second electronic device transmits a wireless signal through the second UWB module of the second electronic device when receiving the control instruction, the first electronic device receives the wireless signal through the first UWB module of the first electronic device when receiving the control instruction, and obtains the flight time between the first UWB module and the second UWB module according to the received wireless signal, and sends the flight time to the terminal device.
[0070] It can be understood that the communication data obtained by the terminal device includes the flight time between the first UWB module and the second UWB module
[0071] 203. The terminal device determines the first measurement result according to the communication data.
[0072] The first measurement result includes at least one of the following: a distance value between the measurement start point and the measurement end point, a relative angle of the measurement start point and the measurement end point, and parameter information of a target circle passing through the measurement start point and the measurement end point.
[0073] In some embodiments, determining the first measurement result according to the communication data can include but is not limited to the following ways:
[0074] Way 1: determining the first measurement result according to the flight time between the third UWB module and the first UWB module, and the flight time between the third UWB module and the second UWB module;
[0075] Way 2: determining the first measurement result according to the flight time between the first UWB module and the second UWB module.
[0076] The parameter information of the target circle can include the circumference and / or area of the target circle, etc.
[0077] By implementing the above method, when the user needs to measure, the first electronic device and the second electronic device are only needed to be placed at the measurement start point and the measurement end point respectively, and the measurement result can be accurately obtained through wireless communication ranging, the measurement accuracy is improved, and the operation is simple.
[0078] Please refer to Figure 3 , Figure 3 is a flowchart of another measurement method disclosed in the embodiments of the present application. Wherein, Figure 3The flowchart shown can be applicable to Figure 1A The scenario diagram shown, Figure 3 The measurement method shown can include the following steps:
[0079] 301. The terminal device sends a first control instruction to the first electronic device.
[0080] 302. The first electronic device, upon receiving the first control instruction, transmits a first signal through a first UWB module.
[0081] In some embodiments, the first electronic device can pre-establish a Bluetooth connection with the terminal device. The terminal device can send a first data packet carrying the first control instruction to the first electronic device through the Bluetooth module of the terminal device. The first electronic device can receive the first data packet through the Bluetooth module of the first electronic device, and parse the first data packet to extract the first control instruction from the first data packet, and respond to the first control instruction to transmit the first signal through the first UWB module.
[0082] 303. The terminal device sends a second control instruction to the second electronic device.
[0083] 304. The second electronic device, upon receiving the second control instruction, receives the first signal through a second UWB module, and obtains a first flight time between the second UWB module and the first UWB module according to the first signal.
[0084] Similarly, the second electronic device can pre-establish a Bluetooth connection with the terminal device. The terminal device can send a second data packet carrying the second control instruction to the second electronic device through the Bluetooth module of the terminal device. The second electronic device can receive the second data packet through the Bluetooth module of the second electronic device, and parse the second data packet to extract the second control instruction from the second data packet, and respond to the second control instruction to receive the first signal transmitted by the first electronic device through the second UWB module.
[0085] 305. The second electronic device sends the first flight time to the terminal device.
[0086] In some embodiments, the second electronic device can send the first flight time to the terminal device through the Bluetooth module of the second electronic device. It should be noted that the sending method of the first flight time is the same as the sending method of the first control instruction and the second control instruction, and the embodiments of the present application will not be repeated.
[0087] 306. The terminal device, upon receiving the first flight time, determines a first measurement result according to the first flight time.
[0088] The first flight time represents a time required from the first UWB module transmitting the first signal to receiving the return signal of the first signal by the second UWB module.
[0089] In a case where the first measurement result includes a distance value between the measurement start point and the measurement end point, the terminal device determining the first measurement result according to the first flight time can include: the terminal device obtaining half of the first flight time, and multiplying the half of the first flight time by a signal propagation speed to obtain the distance value between the measurement start point and the measurement end point.
[0090] In a case where the first measurement result includes parameter information of a target circle passing through the measurement start point and the measurement end point, the terminal device determining the first measurement result according to the first flight time can include: the terminal device obtaining a distance value between the measurement start point and the measurement end point according to the first flight time; taking the distance value as a diameter of the target circle passing through the measurement start point and the measurement end point; and obtaining the parameter information of the target circle according to the diameter of the target circle.
[0091] The distance value between the measurement start point and the measurement end point can be obtained in the manner described above, which will not be described herein again. The parameter information of the target circle can be obtained according to the diameter of the target circle, which can include: obtaining a radius of the target circle according to the diameter of the target circle, and obtaining the parameter information of the target circle according to the radius and a first relationship. The first relationship can include a circumference formula and / or an area formula.
[0092] In a case where the first measurement result includes the distance value between the measurement start point and the measurement end point, and / or the parameter information of the target circle passing through the measurement start point and the measurement end point, the first UWB module and the second UWB module can each include an antenna for receiving / transmitting a wireless signal.
[0093] In a case where the first measurement result includes a relative angle between the measurement start point and the measurement end point, the second UWB module includes a first antenna array, and the first flight time includes a flight time between each antenna in the first antenna array and the first UWB module.
[0094] Further, the terminal device determining the first measurement result according to the first flight time can include: obtaining a first target phase difference between a first antenna and a second antenna of the first antenna array according to respective flight times of the first antenna and the second antenna in the first flight time, and obtaining the relative angle between the measurement start point and the measurement end point according to the first target phase difference, where the first antenna and the second antenna are any two antennas of the first antenna array. It can be understood that the first antenna array can include at least two antennas.
[0095] The first target phase difference is obtained by subtracting the flight time corresponding to the second antenna from the flight time corresponding to the first antenna. It should be noted that the first target phase difference is greater than 0. Further, obtaining the relative angle of the measurement start point and the measurement end point according to the first target phase difference can include: obtaining a first distance difference value according to the first target phase difference, the first distance difference value representing the difference between the distance value between the first antenna and the first UWB module and the distance value between the second antenna and the first UWB module; and obtaining the relative angle of the measurement start point and the measurement end point according to the first distance difference value, a first interval distance value, and a preset angle calculation formula, the first interval distance value indicating the distance between the first antenna and the second antenna of the first antenna array. The first distance difference value can be obtained by multiplying the first target phase difference by the signal propagation speed.
[0096] In the embodiments of the present application, the angle calculation formula can be represented as: θ = arccos (d1 / d2), where d1 represents the first distance difference value, d2 represents the first interval distance value, and θ represents the relative angle of the measurement start point and the measurement end point.
[0097] By implementing the above method, the second electronic device first receives the first signal transmitted by the first electronic device, and obtains the first flight time of the first electronic device and the second electronic device according to the first signal, and then transmits the first flight time to the terminal device, so that the terminal device determines the first measurement result according to the first flight time. The first flight time obtained by the terminal device is directly transmitted by the second electronic device, and therefore, in this measurement method, the terminal device does not need to participate in the analysis of the UWB signal, which greatly reduces the device power consumption of the terminal device.
[0098] Please refer to Figure 4 , Figure 4 is a flowchart of another measurement method disclosed in the embodiments of the present application. Figure 4 The flowchart shown in the figure can be applied to Figure 1B The scene diagram shown in the figure, such as Figure 4 The measurement method shown in the figure can include the following steps:
[0099] 401. The terminal device sends a third control instruction to the first electronic device.
[0100] 402. The first electronic device transmits a first signal through the first UWB module when receiving the third control instruction.
[0101] 403. The terminal device sends a third control instruction to the second electronic device.
[0102] 404. The second electronic device transmits a second signal through the second UWB module when receiving the third control instruction.
[0103] In the embodiments of the present application, for the specific implementation of the terminal device sending the first control instruction, the first electronic device and the second electronic device receiving the first control instruction, please refer to the description in the embodiments shown in the above Figure 3 The above description is not repeated here.
[0104] 405、The terminal device receives a first signal through the third UWB module, and obtains a second flight time between the third UWB module and the first UWB module according to the first signal.
[0105] The third UWB module can include a second antenna array, and the second antenna array includes at least two antennas. The second flight time includes a flight time between each antenna in the second antenna array and the first UWB module.
[0106] 406、The terminal device receives a second signal through the third UWB module, and obtains a third flight time between the third UWB module and the second UWB module according to the second signal.
[0107] The third flight time includes a flight time between each antenna in the second antenna array and the second UWB module.
[0108] 407、The terminal device determines a first measurement result according to the second flight time and the third flight time.
[0109] In some embodiments, the terminal device determines the first measurement result according to the second flight time and the third flight time can include: the terminal device obtains a second target phase difference between the third antenna and the fourth antenna according to the corresponding flight time of the third antenna and the fourth antenna in the second flight time, and obtains first relative position information of the terminal device and the first electronic device according to the second target phase difference; the third antenna and the fourth antenna are any two antennas of the second antenna array; obtains a third target phase difference between the third antenna and the fourth antenna according to the corresponding flight time of the third antenna and the fourth antenna in the third flight time, and obtains second relative position information of the terminal device and the second electronic device according to the third target phase difference; and obtains the first measurement result according to the first relative position information and the second relative position information.
[0110] The second target phase difference can be obtained by subtracting the flight time corresponding to the fourth antenna from the flight time corresponding to the third antenna. The third target phase difference is the same, and is not repeated here. It should be noted that the second target phase difference and the third target phase difference are both greater than 0.
[0111] Further, the first relative position information can include a first distance value and a first relative angle of the terminal device and the first electronic device, and the second relative position information can include a second distance value and a second relative angle of the terminal device and the second electronic device.
[0112] Further, the terminal device obtaining the first relative position information between the terminal device and the first electronic device according to the second target phase difference can include: the terminal device obtaining a first relative angle between the terminal device and the first electronic device according to the second target phase difference, and obtaining a first distance value between the terminal device and the first electronic device according to the flight time corresponding to the third antenna and / or the flight time corresponding to the fourth antenna.
[0113] In some embodiments, the terminal device obtaining the first relative angle between the terminal device and the first electronic device according to the second target phase difference can include: the terminal device obtaining a second distance difference value representing a difference between a distance value between the third antenna and the first UWB module and a distance value between the fourth antenna and the first UWB module according to the second target phase difference; and obtaining the first relative angle between the terminal device and the first electronic device according to the second distance difference value, a second interval distance value, and a preset angle calculation formula. The second interval distance value indicates a distance between the third antenna and the fourth antenna. It can be understood that in the preset angle calculation formula θ = arccos (d1 / d2), θ represents the first relative angle, d1 represents the second distance difference value, and d2 represents the second interval distance value. The second distance difference value can be obtained by multiplying the second target phase difference by the signal propagation speed.
[0114] In some embodiments, the terminal device obtaining the first distance value between the terminal device and the first electronic device according to the flight time corresponding to the third antenna and / or the flight time corresponding to the fourth antenna can include, but is not limited to, the following manners:
[0115] Manner 1: The terminal device multiplies half of the flight time corresponding to the third antenna by the signal propagation speed to obtain a distance value between the third antenna and the first UWB module, and takes the distance value as the first distance value between the terminal device and the first electronic device.
[0116] Manner 2: The terminal device multiplies half of the flight time corresponding to the fourth antenna by the signal propagation speed to obtain a distance value between the fourth antenna and the first UWB module, and takes the distance value as the first distance value between the terminal device and the first electronic device.
[0117] Manner 3: The terminal device multiplies half of the flight time corresponding to the third antenna by the signal propagation speed to obtain a distance value between the third antenna and the first UWB module, multiplies half of the flight time corresponding to the fourth antenna by the signal propagation speed to obtain a distance value between the fourth antenna and the first UWB module, and averages the distance values between the third antenna and the first UWB module and between the fourth antenna and the first UWB module to obtain the first distance value between the terminal device and the first electronic device.
[0118] The second relative angle and the second distance value are acquired in the same manner as the first relative angle and the first distance value, which will not be described herein again. The first UWB module and the second UWB module can include only one antenna.
[0119] In some embodiments, the terminal device obtains the first measurement result according to the first relative position information and the second relative position information can include: taking the terminal device as the origin, determining a first coordinate according to the first relative position information, determining a second coordinate according to the second relative position information, and determining the first measurement result according to the first coordinate and the second coordinate.
[0120] In some embodiments, the distance value between the measurement starting point and the measurement ending point is determined according to the first coordinate and the second coordinate can include: obtaining a horizontal coordinate difference value of the first coordinate and the second coordinate, obtaining a vertical coordinate difference value of the first coordinate and the second coordinate, and obtaining a first calculation value by squaring the horizontal coordinate difference value and adding the square of the vertical coordinate difference value, and obtaining the distance value between the measurement starting point and the measurement ending point by taking the square root of the first calculation value.
[0121] It should be noted that the acquisition of the parameter information of the target circle passing through the measurement starting point and the measurement ending point is calculated on the basis of the distance value between the measurement starting point and the measurement ending point. After the distance value between the measurement starting point and the measurement ending point is known, the manner of acquiring the parameter information of the target circle is described in the embodiments shown in Figure 3 and will not be described herein again.
[0122] In some embodiments, the relative angle between the measurement starting point and the measurement ending point is determined according to the first coordinate and the second coordinate can include: obtaining an absolute value of a horizontal coordinate difference value of the first coordinate and the second coordinate, obtaining an absolute value of a vertical coordinate difference value of the first coordinate and the second coordinate, and obtaining a second calculation value by dividing the absolute value of the vertical coordinate difference value by the absolute value of the horizontal coordinate difference value, and obtaining the relative angle between the measurement starting point and the measurement ending point by performing an inverse tangent function on the second calculation value.
[0123] By implementing the method, the terminal device obtains the second flight time and the third flight time according to the first signal transmitted by the first electronic device and the second signal transmitted by the second electronic device, and further determines the first measurement result according to the second flight time and the third flight time. In this measurement manner, the first electronic device and the second electronic device only need to transmit signals and do not need to participate in the analysis of the UWB signal, which greatly reduces the device power consumption of the first electronic device and the second electronic device.
[0124] Please refer to Figure 5A , Figure 5A is a flowchart of another measurement method disclosed in the embodiments of the present application, and a measurement method shown in Figure 5A may include the following steps:
[0125] 501、In response to detecting the measurement operation, the terminal device outputs indication information indicating a placement posture of the first electronic device and the second electronic device.
[0126] In the embodiments of the present application, in order to improve the measurement accuracy, the first UWB module needs to be as close as possible to the measurement starting point, and the second UWB module needs to be as close as possible to the measurement ending point. In practice, it is found that the distance of the first UWB module from the measurement starting point is usually limited by the placement posture of the first electronic device, and the distance of the second UWB module from the measurement starting point is usually limited by the placement posture of the second electronic device. In order to ensure that the first UWB module and the second UWB module are as close as possible to the measurement starting point and the measurement ending point respectively, indication information indicating the placement posture of the first electronic device and the second electronic device can be output. It can be understood that the indication information is used to prompt the user to correctly place the first electronic device and the second electronic device, so that the first UWB module is as close as possible to the measurement starting point, and the second UWB module is as close as possible to the measurement ending point.
[0127] In some embodiments, the indication information can include, but is not limited to, at least one of the following: text, voice, animation, etc.
[0128] 502、The terminal device sends control instructions to the first electronic device and the second electronic device respectively, so that the first electronic device and the second electronic device respectively perform wireless communication through the respective UWB modules.
[0129] 503、The terminal device acquires communication data generated by the first electronic device and the second electronic device respectively communicating with the terminal device, or generated by the first electronic device communicating with the second electronic device.
[0130] For detailed description of steps 502-503, please refer to the description of steps 201-202 in the embodiment shown in FIG. 2, which will not be repeated here.
[0131] 504、The terminal device determines the first measurement result according to the communication data and the compensation information.
[0132] The compensation information includes distance value compensation information and / or angle compensation information.
[0133] In some embodiments, determining the first measurement result according to the communication data and the compensation information can include: determining a second measurement result according to the communication data; and correcting the second measurement result by using the compensation information to obtain the first measurement result. The distance value compensation information is used to indicate a compensation distance value between the measurement starting point and the measurement ending point, and the angle compensation information is used to indicate a compensation angle value between the measurement starting point and the measurement ending point.
[0134] The following describes the acquisition method of the distance value compensation information and the angle compensation information:
[0135] The first electronic device and the second electronic device are respectively placed at the calibration measurement start point and the calibration measurement end point. The terminal device sends control instructions to the first electronic device and the second electronic device, so that the first electronic device and the second electronic device respectively perform wireless communication through the respective UWB modules. The communication data generated by the communication between the first electronic device and the terminal device, the communication between the second electronic device and the terminal device, or the communication between the first electronic device and the second electronic device is acquired. The third measurement result is obtained according to the communication data. The third measurement result includes the measured distance value and the measured relative angle between the calibration measurement start point and the calibration measurement end point. The distance value compensation information is obtained according to the measured distance value between the calibration measurement start point and the calibration measurement end point and the actual distance value between the calibration measurement start point and the calibration measurement end point. The angle compensation information is obtained according to the measured relative angle between the calibration measurement start point and the calibration measurement end point and the actual relative angle between the calibration measurement start point and the calibration measurement end point.
[0136] In some embodiments, after step 504, the following steps can also be performed:
[0137] When the first measurement result includes the distance value between the measurement start point and the measurement end point, the terminal device displays the target line segment and the distance value between the measurement start point and the measurement end point on the display screen of the terminal device. The first end of the target line segment represents the measurement start point, and the second end of the target line segment represents the measurement end point. For example, please refer to Figure 5B , Figure 5B is an output interface of a first measurement result disclosed by an embodiment of the present application. In Figure 5B , the line segment AB and the distance value a are included. The point A represents the measurement start point, the point B represents the measurement end point, and the distance value a represents the distance value between the measurement start point and the measurement end point.
[0138] When the first measurement result includes the relative angle between the measurement start point and the measurement end point, the terminal device displays the target included angle and the included angle value of the target included angle on the display screen of the terminal device. The first directional vector of the target included angle passes through the first point and is parallel to the horizontal direction, and the second directional vector of the target included angle passes through the first point and the second point. The first point represents the measurement start point, and the second point represents the measurement end point. For example, please refer to Figure 5C , Figure 5C is another output interface of a first measurement result disclosed by an embodiment of the present application. Figure 5C includes the target included angle OAB and the included angle value θ of the target included angle OAB. The point A represents the first point, the point B represents the second point, the vector AO represents the first directional vector, and the vector AB represents the second directional vector.
[0139] When the first measurement result comprises the parameter information of the target circle including the measurement start point and the measurement end point, the terminal device displays the target circle, the first point and the second point on the target circle, and the parameter information of the target circle on the display screen of the terminal device; wherein the first point represents the measurement start point and the second point represents the measurement end point. Please refer to Figure 5D , Figure 5D is another output interface of the first measurement result disclosed by the embodiments of the present application. In Figure 5D , the target circle O, the first point A and the second point B on the target circle O, and the circumference L of the target circle O are included.
[0140] By implementing the above method, on the one hand, when the user needs to measure, the first electronic device and the second electronic device are only needed to be placed at the measurement start point and the measurement end point respectively, and the measurement result can be accurately obtained through the wireless communication ranging, the measurement accuracy is improved, and the operation is simple; on the other hand, before starting the measurement, the indication information prompting the user to correctly place the first electronic device and the second electronic device is output, which can further reduce the measurement error; on the other hand, the first measurement result is corrected by using the compensation information, which can further reduce the measurement error.
[0141] Please refer to Figure 6 , Figure 6 is a structural block diagram of a terminal device disclosed by the embodiments of the present application. It can include a sending unit 601, an obtaining unit 602 and a processing unit 603; wherein:
[0142] The sending unit 601 is configured to send control instructions to the first electronic device and the second electronic device respectively when a measurement operation is detected, so that the first electronic device and the second electronic device respectively perform wireless communication through the respective UWB modules; wherein the first electronic device and the second electronic device are placed at the measurement start point and the measurement end point respectively.
[0143] The obtaining unit 602 is configured to obtain communication data, wherein the communication data is generated by the communication between the first electronic device and the terminal device and the communication between the second electronic device and the terminal device, or the communication data is generated by the communication between the first electronic device and the second electronic device.
[0144] The processing unit 603 is configured to determine the first measurement result according to the communication data; wherein the first measurement result comprises at least one of the following: the distance value between the measurement start point and the measurement end point, the relative angle of the measurement start point and the measurement end point, and the parameter information of the target circle passing through the measurement start point and the measurement end point.
[0145] In some embodiments, the communication data can include the first flight time;
[0146] Further, the sending unit 601 is configured to send control instructions to the first electronic device and the second electronic device respectively, so that the first electronic device and the second electronic device respectively communicate wirelessly through respective UWB modules. Specifically, the sending unit 601 is configured to send a first control instruction to the first electronic device, so that the first electronic device transmits a first signal through a first UWB module; send a second control instruction to the second electronic device, so that the second electronic device receives the first signal through a second UWB module, and obtains a first flight time between the second UWB module and the first UWB module according to the first signal, and send the first flight time to the terminal device.
[0147] In some embodiments, the first measurement result can include a relative angle between the measurement starting point and the measurement ending point, the second UWB module includes a first antenna array, and the first flight time includes a flight time between each antenna in the first antenna array and the first UWB module.
[0148] Further, the processing unit 603 is configured to obtain a first target phase difference between the first antenna and the second antenna according to the respective flight times of the first antenna and the second antenna in the first flight time, and obtain the relative angle between the measurement starting point and the measurement ending point according to the first target phase difference, the first antenna and the second antenna being any two antennas of the first antenna array.
[0149] In some embodiments, the first measurement result can include parameter information of a target circle passing through the measurement starting point and the measurement ending point.
[0150] Further, the processing unit 603 is configured to determine the first measurement result according to the communication data. Specifically, the processing unit 603 is configured to obtain a distance value between the measurement starting point and the measurement ending point according to the first flight time; take the distance value as a diameter of a target circle passing through the measurement starting point and the measurement ending point; and obtain the parameter information of the target circle according to the diameter of the target circle.
[0151] In some embodiments, the terminal device includes a third UWB module, and the communication data can include a second flight time and a third flight time.
[0152] Further, the sending unit 601 is configured to send control instructions to the first electronic device and the second electronic device respectively, so that the first electronic device and the second electronic device respectively perform wireless communication through respective UWB modules. Specifically, the sending unit 601 is configured to send third control instructions to the first electronic device and the second electronic device respectively, so that the first electronic device transmits a first signal through the first UWB module, the second electronic device transmits a second signal through the second UWB module, and the third UWB module receives the first signal and the second signal, and obtains a second flight time between the third UWB module and the first UWB module according to the first signal, and obtains a third flight time between the third UWB module and the second UWB module according to the second signal.
[0153] In some embodiments, the third UWB module can include a second antenna array, and the second flight time includes a flight time between each antenna in the second antenna array and the first UWB module; and the third flight time includes a flight time between each antenna in the second antenna array and the second UWB module.
[0154] Further, the processing unit 603 is configured to determine the first measurement result according to the communication data. Specifically, the processing unit 603 is configured to obtain a second target phase difference between the third antenna and the fourth antenna according to respective flight times of the third antenna and the fourth antenna in the second flight time, and obtain first relative position information between the terminal device and the first electronic device according to the second target phase difference; the third antenna and the fourth antenna are any two antennas in the second antenna array; obtain a third target phase difference between the third antenna and the fourth antenna according to respective flight times of the third antenna and the fourth antenna in the third flight time, and obtain second relative position information between the terminal device and the second electronic device according to the third target phase difference; and obtain the first measurement result according to the first relative position information and the second relative position information.
[0155] In some embodiments, the processing unit 603 is further configured to, before the sending unit 601 sends the control instructions to the first electronic device and the second electronic device respectively, output indication information indicating a placement posture of the first electronic device and the second electronic device when a measurement operation is detected.
[0156] In some embodiments, the processing unit 603 is configured to determine the first measurement result according to the communication data. Specifically, the processing unit 603 is configured to determine the first measurement result according to the communication data and compensation information; and the compensation information includes distance value compensation information and / or angle compensation information.
[0157] In some embodiments, the processing unit 603 is further configured to, according to the communication data, determine that the first measurement result comprises a distance value between the measurement start point and the measurement end point, and display, on the display screen of the terminal device, a target line segment and the distance value between the measurement start point and the measurement end point, a first end of the target line segment representing the measurement start point and a second end of the target line segment representing the measurement end point.
[0158] The processing unit 603 is further configured to, when the first measurement result comprises a relative angle between the measurement start point and the measurement end point, display, on the display screen of the terminal device, a target angle and an angle value of the target angle, a first directional vector of the target angle passing through a first point and being parallel to a horizontal direction, and a second directional vector of the target angle passing through the first point and a second point, wherein the first point represents the measurement start point and the second point represents the measurement end point.
[0159] The processing unit 603 is further configured to, when the first measurement result comprises parameter information of a target circle of the measurement start point and the measurement end point, display, on the display screen of the terminal device, the target circle, a first point and a second point on the target circle, and the parameter information of the target circle, wherein the first point represents the measurement start point and the second point represents the measurement end point.
[0160] Please refer to Figure 7 , Figure 7 is a structural block diagram of a terminal device disclosed by an embodiment of the present application. It can include:
[0161] a memory 701 storing executable program codes;
[0162] and a processor 702 coupled with the memory 701;
[0163] The processor 702 invokes the executable program codes stored in the memory 701, and the executable program codes, when executed by the processor 702, cause the processor 702 to implement part or all of the steps performed by the terminal device in the above embodiments.
[0164] Please refer to Figure 8 , Figure 8 is a structural block diagram of a first electronic device disclosed by an embodiment of the present application. It can include:
[0165] an instruction receiving unit 801 configured to receive a control instruction sent by a terminal device, the first electronic device and a second electronic device being respectively placed at a measurement start point and a measurement end point;
[0166] The signal transmitting unit 802 is configured to transmit, according to a control instruction, a first signal to a second UWB module of a second electronic device through a first UWB module, so that the second electronic device feeds back communication data to the terminal device according to the first signal; the communication data is used to determine a first measurement result; wherein the first measurement result includes at least one of the following: a distance value between a measurement starting point and a measurement ending point, a relative angle of the measurement starting point and the measurement ending point, and parameter information of a target circle passing through the measurement starting point and the measurement ending point.
[0167] Please refer to Figure 9 , Figure 9 is a structural block diagram of a first electronic device disclosed by the embodiment of the present application. It can include:
[0168] a memory 901 storing executable program codes;
[0169] and a processor 902 coupled with the memory 901;
[0170] The processor 902 invokes the executable program codes stored in the memory 901, and the executable program codes are executed by the processor 902, so that the processor 902 implements part or all of the steps performed by the electronic device in the above-mentioned embodiments.
[0171] The embodiment of the present application discloses a computer readable storage medium storing a computer program, wherein the computer program causes a computer to execute part or all of the steps performed by the terminal device in the above-mentioned embodiments.
[0172] The embodiment of the present application discloses another computer readable storage medium storing a computer program, wherein the computer program causes a computer to execute part or all of the steps performed by the electronic device in the above-mentioned embodiments.
[0173] The embodiment of the present application discloses a computer program product, which causes a computer to execute part or all of the steps performed by the terminal device in the above-mentioned embodiments when the computer program product runs on the computer.
[0174] The embodiment of the present application discloses another computer program product, which causes a computer to execute part or all of the steps performed by the electronic device in the above-mentioned embodiments when the computer program product runs on the computer.
[0175] The embodiment of the present application discloses an application publishing platform, which is used to publish a computer program product, wherein the computer program product causes a computer to execute part or all of the steps performed by the terminal device in the above-mentioned embodiments when the computer program product runs on the computer.
[0176] The application discloses another application publishing platform for publishing a computer program product, wherein when the computer program product runs on a computer, the computer is caused to perform part or all of the steps performed by the electronic device in the above-mentioned embodiments.
[0177] In the above-mentioned embodiments, the system, device and unit can be implemented by software, hardware, firmware or any combination thereof. When implemented by software, the system, device and unit can be implemented in the form of a computer program product.
[0178] The computer program product includes one or more computer instructions. When the computer program instructions are loaded and executed on a computer, part or all of the processes or functions described in the embodiments of the application are generated. The computer can be a general-purpose computer, a special-purpose computer, a computer network or other programmable devices. The computer instructions can be stored in a computer-readable storage medium or transmitted from one computer-readable storage medium to another, for example, the computer instructions can be transmitted from one website, computer, server or data center to another website, computer, server or data center through wired (such as coaxial cable, optical fiber, digital subscriber line (DSL)) or wireless (such as infrared, wireless, microwave, etc.) mode. The computer-readable storage medium can be any available medium that can be stored by the computer or a data storage device such as a server, data center, etc. integrated with one or more available media. The available media can be magnetic media (for example, floppy disk, hard disk, magnetic tape), optical media (for example, DVD), or semiconductor media (for example, solid state disk (SSD)) and the like.
[0179] Those skilled in the art can clearly understand that, for the convenience and brevity of description, the specific working process of the above-mentioned system, device and unit can refer to the corresponding process in the foregoing method embodiments, which will not be repeated here.
[0180] In several embodiments provided in the application, it should be understood that the disclosed system, device and method can be implemented in other ways. For example, the above-mentioned device embodiments are only schematic, for example, the division of the units is only a logical function division, and actual implementation can have another division manner, for example, a plurality of units or components can be combined or integrated into another system, or some features can be ignored or not executed. In addition, the coupling or direct coupling or communication connection between the units or components shown or discussed can be indirect coupling or communication connection through some interfaces, devices or units, and can be electrical, mechanical or other forms.
[0181] The units described as separate components may or may not be physically separate, and the components displayed as units may or may not be physical units, i.e. may be located in one place, or may be distributed on multiple network units. Part or all of the units may be selected according to actual needs to achieve the purpose of the embodiment scheme.
[0182] In addition, the functional units in each embodiment of the present application can be integrated in one processing unit, or each unit can be physically present separately, or two or more units can be integrated in one unit. The integrated unit can be realized in the form of hardware or in the form of a software functional unit.
[0183] The integrated unit, if realized in the form of a software functional unit and sold or used as an independent product, can be stored in a computer readable storage medium. Based on this understanding, the technical solutions of the present application essentially or the part that contributes to the prior art or the whole or part of the technical solutions can be embodied in the form of a software product. The computer software product is stored in a storage medium and includes a number of instructions for causing a computer device (which can be a personal computer, a server, or a network device, etc.) to execute all or part of the steps of the method described in each embodiment of the present application. The aforementioned storage medium includes: a U disk, a mobile hard disk, a read-only memory (Read-Only Memory, ROM), a random access memory (Random Access Memory, RAM), a magnetic disk or an optical disk, and various program code storage media.
[0184] The above-described embodiments are only used to illustrate the technical solutions of the present application, but not to limit them; although the present application has been described in detail with reference to the foregoing embodiments, those skilled in the art should understand that they can modify the technical solutions recorded in the foregoing embodiments, or make equivalent replacements to some technical features; and these modifications or replacements do not make the corresponding technical solutions deviate from the spirit and scope of the technical solutions of the embodiments of the present application.
Claims
1. A measurement method, characterized in that, The method is applicable to a terminal device, which establishes a communication connection with a first electronic device and a second electronic device. The first electronic device includes a first UWB module, and the second electronic device includes a second UWB module. The method includes: When a measurement operation is detected, control commands are sent to the first electronic device and the second electronic device respectively, so that the first electronic device and the second electronic device can communicate wirelessly through their respective UWB modules; wherein the first electronic device and the second electronic device are respectively placed at the measurement start point and the measurement end point; Acquire communication data, wherein the communication data is generated by the first electronic device and the second electronic device communicating with the terminal device respectively, or the communication data is generated by the first electronic device communicating with the second electronic device; Based on the communication data, a first measurement result is determined; wherein the first measurement result includes at least one of the following: the distance between the measurement start point and the measurement end point, the relative angle between the measurement start point and the measurement end point, and parameter information of the target circle passing through the measurement start point and the measurement end point.
2. The method according to claim 1, characterized in that, The communication data includes the first flight duration; Sending control commands to the first electronic device and the second electronic device respectively, so that the first electronic device and the second electronic device can respectively perform wireless communication through their respective UWB modules, includes: Send a first control command to the first electronic device to cause the first electronic device to transmit a first signal through the first UWB module; Send a second control command to the second electronic device so that the second electronic device receives the first signal through the second UWB module, and obtains the first flight duration between the second UWB module and the first UWB module based on the first signal, and sends the first flight duration to the terminal device.
3. The method according to claim 2, characterized in that, The first measurement result includes the relative angle between the measurement start point and the measurement end point; the second UWB module includes a first antenna array; and the first flight duration includes the flight duration between each antenna in the first antenna array and the first UWB module. Determining the first measurement result based on the communication data includes: Based on the flight durations of the first antenna and the second antenna in the first flight duration, the first target phase difference between the first antenna and the second antenna is obtained, and based on the first target phase difference, the relative angle between the measurement starting point and the measurement ending point is obtained, wherein the first antenna and the second antenna are any two antennas of the first antenna array.
4. The method according to claim 2, characterized in that, The first measurement result includes parameter information of the target circle passing through the measurement starting point and the measurement ending point; Determining the first measurement result based on the communication data includes: Based on the first flight duration, the distance between the measurement starting point and the measurement ending point is obtained; The distance value is used as the diameter of the target circle passing through the measurement start point and the measurement end point; Based on the diameter of the target circle, the parameter information of the target circle is obtained.
5. The method according to claim 1, characterized in that, The terminal device includes a third UWB module, and the communication data includes a second flight duration and a third flight duration; Sending control commands to the first electronic device and the second electronic device respectively, so that the first electronic device and the second electronic device can respectively perform wireless communication through their respective UWB modules, includes: A third control command is sent to the first electronic device and the second electronic device respectively, so that the first electronic device transmits a first signal through the first UWB module and the second electronic device transmits a second signal through the second UWB module; The third UWB module receives the first signal and the second signal, and obtains the second flight duration between the third UWB module and the first UWB module based on the first signal, and obtains the third flight duration between the third UWB module and the second UWB module based on the second signal.
6. The method according to claim 5, characterized in that, The third UWB module includes a second antenna array, and the second flight duration includes the flight duration between each antenna in the second antenna array and the first UWB module; the third flight duration includes the flight duration between each antenna in the second antenna array and the second UWB module; The step of determining the first measurement result based on the communication data includes: Based on the flight durations corresponding to the third and fourth antennas in the second flight duration, the second target phase difference between the third and fourth antennas is obtained, and based on the second target phase difference, the first relative position information between the terminal device and the first electronic device is obtained; the third antenna and the fourth antenna are any two antennas of the second antenna array; Based on the flight durations corresponding to the third antenna and the fourth antenna in the third flight duration, the third target phase difference between the third antenna and the fourth antenna is obtained, and based on the third target phase difference, the second relative position information between the terminal device and the second electronic device is obtained; The first measurement result is obtained based on the first relative position information and the second relative position information.
7. The method according to any one of claims 1-6, characterized in that, Before sending control commands to the first electronic device and the second electronic device respectively, the method further includes: When a measurement operation is detected, indication information is output to indicate the placement orientation of the first electronic device and the second electronic device.
8. The method according to any one of claims 1-6, characterized in that, Determining the first measurement result based on the communication data includes: Based on the communication data and compensation information, a first measurement result is determined; wherein the compensation information includes distance compensation information and / or angle compensation information.
9. The method according to any one of claims 1-6, characterized in that, After determining the first measurement result based on the communication data, the method further includes: When the first measurement result includes the distance value between the measurement start point and the measurement end point, the target line segment and the distance value between the measurement start point and the measurement end point are displayed on the display screen of the terminal device, wherein the first end of the target line segment represents the measurement start point and the second end of the target line segment represents the measurement end point; When the first measurement result includes the relative angle between the measurement start point and the measurement end point, the target angle and the angle value of the target angle are displayed on the display screen of the terminal device. The first direction vector of the target angle passes through the first point and is parallel to the horizontal direction, and the second direction vector of the target angle passes through the first point and the second point; wherein, the first point represents the measurement start point and the second point represents the measurement end point. When the first measurement result includes parameter information of the target circle passing through the measurement start point and the measurement end point, the display screen of the terminal device displays the target circle, a first point and a second point on the target circle, and parameter information of the target circle; wherein, the first point represents the measurement start point and the second point represents the measurement end point.
10. The method according to any one of claims 1-6, characterized in that, The first electronic device includes a first earphone, and the second electronic device includes a second earphone, wherein the first earphone and the second earphone belong to the same earphone device.
11. A measurement method, characterized in that, The method is applicable to a first electronic device, which is communicatively connected to a terminal device, and the terminal device is also communicatively connected to a second electronic device; the first electronic device includes a first UWB module, and the second electronic device includes a second UWB module; the method includes: The device receives control commands sent by the terminal device, and the first electronic device and the second electronic device are respectively placed at the measurement start point and the measurement end point; According to the control command, the first UWB module transmits a first signal to the second UWB module of the second electronic device, so that the second electronic device feeds back communication data to the terminal device according to the first signal; the communication data is used to determine a first measurement result; wherein, the first measurement result includes at least one of the following: the distance value between the measurement start point and the measurement end point, the relative angle between the measurement start point and the measurement end point, and parameter information of the target circle passing through the measurement start point and the measurement end point.
12. A terminal device, characterized in that, The terminal device establishes a communication connection with the first electronic device and the second electronic device. The first electronic device includes a first UWB module, and the second electronic device includes a second UWB module. The terminal device includes: The transmitting unit is configured to send control commands to the first electronic device and the second electronic device respectively when a measurement operation is detected, so that the first electronic device and the second electronic device can communicate wirelessly through their respective UWB modules; wherein the first electronic device and the second electronic device are respectively placed at the measurement start point and the measurement end point; An acquisition unit is used to acquire communication data, wherein the communication data is generated by the first electronic device and the second electronic device communicating with the terminal device respectively, or the communication data is generated by the first electronic device communicating with the second electronic device; The processing unit is configured to determine a first measurement result based on the communication data; wherein the first measurement result includes at least one of the following: the distance between the measurement start point and the measurement end point, the relative angle between the measurement start point and the measurement end point, and parameter information of the target circle passing through the measurement start point and the measurement end point.
13. A first electronic device, characterized in that, The first electronic device is communicatively connected to a terminal device, and the terminal device is also communicatively connected to a second electronic device; the first electronic device includes a first UWB module, and the second electronic device includes a second UWB module. The first electronic device includes: The instruction receiving unit is used to receive control instructions sent by the terminal device, wherein the first electronic device and the second electronic device are respectively placed at the measurement start point and the measurement end point; A signal transmitting unit is configured to transmit a first signal from the first UWB module to the second UWB module of the second electronic device according to the control command, so that the second electronic device can feed back communication data to the terminal device according to the first signal; the communication data is used to determine a first measurement result; wherein the first measurement result includes at least one of the following: the distance value between the measurement start point and the measurement end point, the relative angle between the measurement start point and the measurement end point, and parameter information of the target circle passing through the measurement start point and the measurement end point.
14. A terminal device, characterized in that, include: Memory containing executable program code; and the processor coupled to the memory; The processor calls the executable program code stored in the memory, and when the executable program code is executed by the processor, the processor implements the method as described in any one of claims 1-10.
15. A first electronic device, characterized in that, include: Memory containing executable program code; and the processor coupled to the memory; The processor calls the executable program code stored in the memory, and when the executable program code is executed by the processor, the processor implements the method as described in claim 11.
16. A computer-readable storage medium storing a computer program, wherein, The computer program causes the computer to perform the method as described in any one of claims 1-10 or 11.
Citation Information
Patent Citations
Method for searching intelligent equipment and intelligent equipment
CN112098935A
User positioning method and device, storage medium and electronic equipment
CN112163061A