Method for determining orientation of equipment and electronic equipment

Through the optical flow method and signal phase difference calculation device orientation, the relative orientation of the device is automatically determined, which solves the problem of poor experience after the user manually input position changes, and improves the accuracy and efficiency of the multi-screen collaboration function.

CN120275943APending Publication Date: 2025-07-08HISILICON (SHANGHAI) TECH CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202311873065.2
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2023-12-29
Publication Date
2025-07-08

AI Technical Summary

Technical Problem

In the prior art, the electronic device needs to manually enter the relative orientation after the position of the electronic device changes, which affects the user experience, especially on devices such as tablets and laptops.

Method used

By determining the position information and phase difference information of the electronic device, the relative orientation of the device is automatically determined by using the optical flow method and the signal phase difference calculation device.

Benefits of technology

It improves the accuracy and efficiency of device orientation determination in multi-screen collaboration function, reduces the user's need for manual input, and improves the user experience.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120275943A_ABST
    Figure CN120275943A_ABST
Patent Text Reader

Abstract

The invention provides a method for determining a device orientation and an electronic device, the method is applied to a first electronic device, and the method comprises the steps that first position information is determined, the first position information comprises at least one piece of displacement information, and the at least one piece of displacement information comprises displacement of the first electronic device moving between two adjacent moments in a plurality of first moments; first phase difference information is obtained, the first phase difference information comprises at least one first phase difference, and the first phase difference is the phase difference between phases of first signals which are received by the first electronic equipment at the adjacent moment and come from second electronic equipment; and determining the orientation of the second electronic equipment relative to the first electronic equipment according to the first position information and the first phase difference information. And determining the orientation of the second electronic equipment relative to the first electronic equipment based on the at least one piece of displacement information and the at least one first phase difference, thereby improving the interaction experience of a user when the first electronic equipment and the second electronic equipment execute a multi-screen cooperation function.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of terminals, and more particularly, to a method for determining the orientation of a device and an electronic device. Background Art

[0002] In daily life or work, users use a variety of electronic devices. During the process of using an electronic device by a user, the user experience of the electronic device can be improved by means of a multi-screen collaboration function. Among them, multi-screen collaboration may refer to connecting the screens of multiple electronic devices together through a network to achieve information sharing and collaborative operations between multiple screens.

[0003] The device that executes the multi-screen collaboration function knows in advance the relative orientation with other electronic devices. One existing solution is to let the user manually input the relative orientation between the current respective screens. However, since the positions of electronic devices are often not fixed (especially tablets and laptops), if the user manually inputs the relative orientation between the electronic devices every time the position of the electronic device changes, it may affect the user experience. Summary of the Invention

[0004] This application provides a method for determining the orientation of a device and an electronic device, which can determine the orientation of a device that executes the multi-screen collaboration function relative to the electronic device.

[0005] In a first aspect, a method for determining the orientation of a device is provided, which is applied to a first electronic device. The method includes: determining first position information, where the first position information includes at least one displacement information, and the at least one displacement information includes the displacement of the first electronic device between two adjacent moments among a plurality of first moments; obtaining first phase difference information, where the first phase difference information includes at least one first phase difference, and the first phase difference is the phase difference between the phases of the first signals received by the first electronic device from a second electronic device at the adjacent moments; determining the orientation of the second electronic device relative to the first electronic device according to the first position information and the first phase difference information.

[0006] Based on the above solution, the first electronic device can determine the orientation of the second electronic device relative to the first electronic device based on at least one displacement information and at least one first phase difference, so as to improve the user's interaction experience when the first electronic device and the second electronic device execute the multi-screen collaboration function.

[0007] In combination with the first aspect, in a possible implementation, an image sequence is obtained, where the image sequence includes the images obtained by the first electronic device at the at least one first moment; the first position information is determined based on the change of pixels in the image sequence at the at least one first moment.

[0008] In combination with the first aspect, in a possible implementation, the orientation of the third electronic device relative to the first electronic device is determined according to the second position information and the second phase difference information. The second position information includes the displacement of the first electronic device between two adjacent moments among at least one second moment. The second phase difference information includes at least one second phase difference, and the second phase difference is the phase difference between the phases of the second signals received by the first electronic device from the third electronic device at the at least one second moment. The relative orientation between the second electronic device and the third electronic device is determined according to the orientation of the second electronic device relative to the first electronic device and the orientation of the third electronic device relative to the first electronic device.

[0009] In combination with the first aspect, in a possible implementation, the arrival angle of the first signal is determined according to the at least one displacement information and the at least one first phase difference, and the arrival angle is used to characterize the orientation.

[0010] In combination with the first aspect, in a possible implementation, the following relationship is satisfied between the at least one displacement information, the at least one first phase difference, and the arrival angle:

[0011] θ = sin -1 ((φ i λ) / (2πd i ));

[0012] where θ represents the arrival angle, d i represents the i-th displacement information in the at least one displacement information, and φ i represents the i-th first phase difference in the at least one first phase difference.

[0013] In a second aspect, a method for determining the orientation of a device is provided, which is applied to a first electronic device. The method includes: determining first position information, where the first position information includes at least one displacement information, and the at least one displacement information includes the displacement of the first electronic device between two adjacent moments among at least one moment; receiving third phase difference information from a second electronic device, where the third phase difference information includes at least one third phase difference, and the third phase difference includes the phase difference between the phases of the third signals received by the second electronic device from the first electronic device at the at least one moment; and determining the orientation of the second electronic device relative to the first electronic device according to the first position information and the third phase difference information.

[0014] Based on the above solution, the orientation of the second electronic device relative to the first electronic device can be determined by the phase difference between the displacement of the first electronic device between two adjacent moments among at least one moment and the phase of the third signal received by the second electronic device from the first electronic device at the at least one moment, so as to enhance the user's interaction experience when the first electronic device and the second electronic device execute the multi-screen collaboration function.

[0015] In combination with the second aspect, in a possible implementation, an image sequence is obtained, and the image sequence includes images obtained by the first electronic device at the at least one first moment; the first position information is determined based on the change of pixels in the image sequence at the at least one first moment.

[0016] In combination with the second aspect, in a possible implementation, before determining the orientation of the second electronic device relative to the first electronic device according to the first position information and the third phase difference information, the third signal is sent to at least one electronic device at the at least one moment, and the at least one electronic device includes the second electronic device.

[0017] In combination with the second aspect, in a possible implementation, fourth phase difference information is received from a third electronic device, the fourth phase difference information includes at least one fourth phase difference, the fourth phase difference includes the phase difference between the phases of the third signal received by the third electronic device from the first electronic device at the at least one moment, and the at least one electronic device includes the third electronic device; the orientation of the third electronic device relative to the first electronic device is determined according to the first position information and the fourth phase difference information; the relative orientation between the second electronic device and the third electronic device is determined according to the orientation of the second electronic device relative to the first electronic device and the orientation of the third electronic device relative to the first electronic device.

[0018] In combination with the second aspect, in a possible implementation, the departure angle of the third signal is determined according to the at least one displacement information and the at least one third phase difference, and the departure angle is used to characterize the orientation.

[0019] In combination with the second aspect, in a possible implementation, the following relationship is satisfied between the at least one displacement information, the at least one third phase difference and the departure angle:

[0020] θ = sin -1 ((φ i λ) / (2πd i ));

[0021] Wherein, θ represents the departure angle, d i represents the i-th displacement information in the at least one displacement, φ iDenote the i-th third phase difference among the at least one third phase difference.

[0022] In a third aspect, a device is provided. The device is included in a first electronic device and has a function of implementing the actions involved in the above-mentioned first aspect and second aspect, and any possible implementation manners of the first aspect and second aspect.

[0023] This function can be implemented by hardware or by hardware executing corresponding software. The hardware or software includes one or more modules or units corresponding to the above function. For example, a display module or unit, a detection module or unit, a processing module or unit, etc.

[0024] In a fourth aspect, an electronic device is provided, including one or more processors; one or more memories; the one or more memories store one or more computer programs, and the one or more computer programs include instructions. When the instructions are executed by the one or more processors, the electronic device is caused to execute the methods in the above-mentioned first aspect and second aspect, and any possible implementation manners of the first aspect and second aspect.

[0025] In a fifth aspect, a computer-readable storage medium is provided, including computer instructions. When the computer instructions run on an electronic device, the electronic device is caused to execute the methods in the above-mentioned first aspect and second aspect, and any possible implementation manners of the first aspect and second aspect.

[0026] In a sixth aspect, a computer program product including instructions is provided. When the computer program product runs on a computer, the computer is caused to execute the methods in the above-mentioned first aspect and second aspect, and any possible implementation manners of the first aspect and second aspect.

[0027] In a seventh aspect, a chip is provided. The chip includes a processor and a data interface. The processor reads instructions stored on a memory through the data interface and executes the methods in the above-mentioned first aspect and second aspect, and any possible implementation manners of the first aspect and second aspect.

[0028] Optionally, as an implementation manner, the chip may further include a memory. Instructions are stored in the memory, and the processor is configured to execute the instructions stored on the memory. When the instructions are executed, the processor is configured to execute the methods in the above-mentioned first aspect and second aspect, and any possible implementation manners of the first aspect and second aspect.

[0029] The above-mentioned chip may specifically be a field-programmable gate array or an application-specific integrated circuit.

[0030] In an eighth aspect, a system is provided, including a second electronic device and the electronic device described in the fourth aspect, where the second electronic device is connected to the electronic device described in the fourth aspect via Bluetooth.

[0031] The beneficial effects of the devices described in the third to eighth aspects can refer to the beneficial effects of the method described in the first aspect, which will not be elaborated here. Description of the Drawings

[0032] Figure 1 It is a schematic structural diagram of a device provided by this application.

[0033] Figure 2 It is a schematic diagram of multi-screen collaboration between electronic devices.

[0034] Figure 3 It is a schematic diagram of the angle-of-arrival positioning principle.

[0035] Figure 4 It is a schematic flowchart of a method 400 for determining the orientation of a device provided by this application.

[0036] Figure 5 It is a schematic diagram of the phase of the signal received by the electronic device provided by this application.

[0037] Figure 6 It is a schematic flowchart of a method 600 for determining the orientation of a device provided by this application.

[0038] Figure 7 It is a schematic block diagram of an electronic device 700 provided by this application.

[0039] Figure 8 It is a schematic block diagram of an electronic device 800 provided by this application. Detailed Embodiments

[0040] Next, the technical solutions in this application will be described with reference to the drawings.

[0041] The positioning method in the embodiments of this application can be applied to electronic devices such as smart phones, tablet computers, laptop computers, personal computers (PCs), ultra-mobile personal computers (UMPCs), netbooks, personal digital assistants (PDAs), in-vehicle devices, wearable devices, and foldable devices.

[0042] Figure 1A schematic structural diagram of the electronic device 100 is shown. The electronic device 100 may include a processor 110, an external memory interface 120, an internal memory 121, a universal serial bus (USB) interface 130, a charging management module 140, a power management module 141, a battery 142, an antenna 1, an antenna 2, a mobile communication module 150, a wireless communication module 160, an audio module 170, a speaker 170A, a receiver 170B, a microphone 170C, a headphone jack 170D, a sensor module 180, a button 190, a motor 191, an indicator 192, a camera 193, a display screen 194, and a subscriber identification module (SIM) card interface 195, etc. The sensor module 180 may include a pressure sensor 180A, a gyroscope sensor 180B, a barometric pressure sensor 180C, a magnetic sensor 180D, an acceleration sensor 180E, a distance sensor 180F, a proximity light sensor 180G, a fingerprint sensor 180H, a temperature sensor 180J, a touch sensor 180K, an ambient light sensor 180L, a bone conduction sensor 180M, etc.

[0043] It can be understood that the structure schematically shown in the embodiments of the present application does not constitute a specific limitation on the electronic device 100. In other embodiments of the present application, the electronic device 100 may include more or fewer components than shown in the figure, or combine certain components, or split certain components, or have different component arrangements. The components shown in the figure may be implemented in hardware, software, or a combination of software and hardware.

[0044] The processor 110 may include one or more processing units. For example, the processor 110 may include an application processor (AP), a modem processor, a graphics processing unit (GPU), an image signal processor (ISP), a controller, a memory, a video codec, a digital signal processor (DSP), a baseband processor, and / or a neural-network processing unit (NPU), etc. Among them, different processing units may be independent devices or integrated in one or more processors.

[0045] Among them, the controller may be the nerve center and command center of the electronic device 100. The controller may generate operation control signals according to the instruction operation code and timing signals to complete the control of fetching instructions and executing instructions.

[0046] A memory may also be provided in the processor 110 for storing instructions and data. In some embodiments, the memory in the processor 110 is a cache memory. This memory can hold the instructions or data that the processor 110 has just used or recycled. If the processor 110 needs to use the instruction or data again, it can be directly called from the said memory. This avoids repeated accesses, reduces the waiting time of the processor 110, and thus improves the efficiency of the system.

[0047] In some embodiments, the processor 110 may include one or more interfaces. The interfaces may include an inter-integrated circuit (I2C) interface, an inter-integrated circuit sound (I2S) interface, a pulse code modulation (PCM) interface, a universal asynchronous receiver / transmitter (UART) interface, a mobile industry processor interface (MIPI), a general-purpose input / output (GPIO) interface, a subscriber identity module (SIM) interface, and / or a universal serial bus (USB) interface, etc.

[0048] The I2C interface is a bidirectional synchronous serial bus, including a serial data line (SDA) and a serial clock line (SCL).

[0049] The I2S interface can be used for audio communication. In some embodiments, the processor 110 may include multiple groups of I2S buses. The processor 110 can be coupled to the audio module 170 through the I2S bus to enable communication between the processor 110 and the audio module 170.

[0050] The PCM interface can also be used for audio communication to sample, quantize, and encode analog signals. In some embodiments, the audio module 170 and the wireless communication module 160 can be coupled through the PCM bus interface.

[0051] The UART interface is a general-purpose serial data bus for asynchronous communication. This bus can be a two-way communication bus. It converts the data to be transmitted between serial communication and parallel communication. In some embodiments, the UART interface is typically used to connect the processor 110 and the wireless communication module 160.

[0052] The MIPI interface can be used to connect the processor 110 with peripheral devices such as the display screen 194 and the camera 193.

[0053] The GPIO interface can be configured by software. The GPIO interface can be configured as a control signal or a data signal. In some embodiments, the GPIO interface can be used to connect the processor 110 with the camera 193, the display screen 194, the wireless communication module 160, the audio module 170, the sensor module 180, etc.

[0054] The USB interface 130 is an interface compliant with the USB standard specification, which can specifically be a Mini USB interface, a Micro USB interface, a USB Type C interface, etc. The USB interface 130 can be used to connect a charger to charge the electronic device 100, and can also be used to transfer data between the electronic device 100 and peripheral devices.

[0055] It can be understood that the interface connection relationships between the modules illustrated in the embodiments of the present application are only illustrative descriptions and do not constitute a structural limitation on the electronic device 100. In other embodiments of the present application, the electronic device 100 can also adopt different interface connection methods in the above embodiments, or a combination of multiple interface connection methods.

[0056] The charging management module 140 is used to receive a charging input from a charger. Among them, the charger can be a wireless charger or a wired charger. In some embodiments of wired charging, the charging management module 140 can receive the charging input from a wired charger through the USB interface 130. In some embodiments of wireless charging, the charging management module 140 can receive the wireless charging input through the wireless charging coil of the electronic device 100. While charging the battery 142, the charging management module 140 can also supply power to the electronic device through the power management module 141.

[0057] The power management module 141 is used to connect the battery 142, the charging management module 140, and the processor 110.

[0058] The wireless communication function of the electronic device 100 can be implemented through antenna 1, antenna 2, the mobile communication module 150, the wireless communication module 160, the modulation and demodulation processor, and the baseband processor, etc.

[0059] The mobile communication module 150 can provide solutions for wireless communications such as 2G / 3G / 4G / 5G applied to the electronic device 100.

[0060] The modem processor may include a modulator and a demodulator. Among them, the modulator is used to modulate the low-frequency baseband signal to be transmitted into a medium-high frequency signal. The demodulator is used to demodulate the received electromagnetic wave signal into a low-frequency baseband signal. Subsequently, the demodulator transmits the demodulated low-frequency baseband signal to the baseband processor for processing. After being processed by the baseband processor, the low-frequency baseband signal is transmitted to the application processor. The application processor outputs sound signals through an audio device (not limited to the speaker 170A, the receiver 170B, etc.), or displays images or videos through the display screen 194. In some embodiments, the modem processor may be an independent device. In other embodiments, the modem processor may be independent of the processor 110 and be provided in the same device as the mobile communication module 150 or other functional modules.

[0061] The wireless communication module 160 can provide solutions for wireless communications applied to the electronic device 100, including wireless local area networks (WLAN) (such as wireless fidelity (Wi-Fi) networks), Bluetooth (BT), Bluetooth low energy (BLE), global navigation satellite system (GNSS), frequency modulation (FM), near field communication (NFC), infrared technology (IR), etc.

[0062] In some embodiments, the antenna 1 of the electronic device 100 is coupled to the mobile communication module 150, and the antenna 2 is coupled to the wireless communication module 160, so that the electronic device 100 can communicate with the network and other devices through wireless communication technologies.

[0063] The electronic device 100 realizes the display function through the GPU, the display screen 194, and the application processor, etc. The GPU is a microprocessor for image processing, connected to the display screen 194 and the application processor. The GPU is used to perform mathematical and geometric calculations for graphics rendering. The processor 110 may include one or more GPUs, which execute program instructions to generate or change display information.

[0064] The display screen 194 is used to display images, videos, etc. The display screen 194 includes a display panel. The display panel can be a liquid crystal display (LCD), or can be a display panel made of one of materials such as organic light-emitting diode (OLED), active-matrix organic light emitting diode (AMOLED), flex light-emitting diode (FLED), Miniled, MicroLed, Micro-oLed, or quantum dot light emitting diodes (QLED). In some embodiments, the electronic device 100 may include one or N display screens 194, where N is a positive integer greater than 1.

[0065] The electronic device 100 can implement the shooting function through the ISP, camera 193, video codec, GPU, display screen 194, and application processor, etc.

[0066] The ISP is used to process the data fed back by the camera 193. The camera 193 is used to capture static images or videos.

[0067] The digital signal processor is used to process digital signals. In addition to processing digital image signals, it can also process other digital signals.

[0068] The video codec is used to compress or decompress digital videos. The electronic device 100 can support one or more video codecs.

[0069] The external memory interface 120 can be used to connect an external memory card, such as a Micro SD card, to expand the storage capacity of the electronic device 100.

[0070] The internal memory 121 can be used to store computer-executable program codes, and the executable program codes include instructions. The processor 110 executes various functional applications and data processing of the electronic device 100 by running the instructions stored in the internal memory 121.

[0071] The electronic device 100 can implement audio functions through the audio module 170, speaker 170A, receiver 170B, microphone 170C, headphone jack 170D, and application processor, etc. Such as music playback, recording, etc.

[0072] The audio module 170 is used to convert digital audio information into an analog audio signal for output, and is also used to convert an analog audio input into a digital audio signal.

[0073] The speaker 170A, also known as the "loudspeaker", is used to convert an audio electrical signal into a sound signal.

[0074] The receiver 170B, also known as the "earpiece", is used to convert an audio electrical signal into a sound signal.

[0075] The microphone 170C, also known as the "microphone" or "transmitter", is used to convert a sound signal into an electrical signal.

[0076] The headphone jack 170D is used to connect a wired headphone.

[0077] The pressure sensor 180A is used to sense a pressure signal and can convert the pressure signal into an electrical signal. In some embodiments, the pressure sensor 180A can be disposed on the display screen 194.

[0078] The gyroscope sensor 180B can be used to determine the motion posture of the electronic device 100.

[0079] The barometric pressure sensor 180C is used to measure barometric pressure. In some embodiments, the electronic device 100 calculates the altitude based on the barometric pressure value measured by the barometric pressure sensor 180C to assist in positioning and navigation.

[0080] The acceleration sensor 180E can detect the magnitude of the acceleration of the electronic device 100 in various directions (generally three axes).

[0081] The distance sensor 180F is used to measure distance.

[0082] The fingerprint sensor 180H is used to collect fingerprints.

[0083] The touch sensor 180K, also known as the "touch panel". The touch sensor 180K can be disposed on the display screen 194, and the touch sensor 180K and the display screen 194 form a touch screen, also known as the "touch display screen".

[0084] The bone conduction sensor 180M can acquire a vibration signal. In some embodiments, the bone conduction sensor 180M can acquire the vibration signal of the vibrating bone mass of the human vocal tract. The bone conduction sensor 180M can also contact the human pulse to receive the blood pressure pulsation signal.

[0085] The keys 190 include a power-on key, volume keys, etc.

[0086] The motor 191 can generate a vibration prompt.

[0087] The indicator 192 can be an indicator light, which can be used to indicate the charging status, power change, and can also be used to indicate messages, missed calls, notifications, etc.

[0088] The SIM card interface 195 is used to connect the SIM card.

[0089] Figure 2 It is a schematic diagram of multi-screen collaboration between electronic devices. To improve the user's office efficiency, many current office electronic devices (such as tablets) support the "multi-screen collaboration" function. That is, the screens of multiple electronic devices can be connected together through the network to achieve information sharing and collaborative operations between multiple screens. As Figure 2 shown, when the user is working, they can simultaneously use the screens of three tablets (electronic devices 111 to 113) and a computer (electronic device 114) for multi-screen collaboration. Multi-screen collaboration can include multiple modes: mirror mode, sharing mode, and extended mode.

[0090] Among them, the mirror mode can mean that the screen content of one electronic device is completely displayed on the screen of another electronic device. In this way, no matter which electronic device the user operates on, the same content can be seen on other devices in real time. For example, the user can watch a movie on the mobile phone and at the same time mirror the movie content to the TV for viewing, realizing the sharing of the display content between the mobile phone and the TV.

[0091] The extended mode can mean extending the screens of multiple electronic devices to form a larger display area. The user can display more content on the extended screen at the same time, improving work and learning efficiency. For example, after the tablet and the computer are connected, the tablet can be used as the second screen of the computer to expand the operation space and method of the computer, share the keyboard and mouse of the computer, and the tablet can be reversely controlled through the touch screen (finger / stylus) for dual-screen operation, making the office more efficient.

[0092] The sharing mode can mean that two electronic devices each have their own independent screens, but the screens are related to each other. For example, files can be transferred between electronic devices by dragging and dropping files.

[0093] To support the above-mentioned extended mode and sharing mode, the device that executes the multi-screen collaboration function (denoted as device #1) needs to know the relative orientations between various electronic devices in advance. For example, in the extended mode, assume that the user sees the screen of electronic device 114 directly above in front of himself / herself, while the mouse cursor is in the screen of electronic device 112 below in front of himself / herself. At this time, if the user wants to move the mouse cursor to the screen of electronic device 114, he / she needs to move the mouse cursor upward, move it out from the upper edge of the screen of electronic device 112, and expect the mouse cursor to enter from the lower edge of electronic device 114. This requires knowing in advance that electronic device 114 is above electronic device 112 (i.e., needs to know the relative orientation between electronic device 112 and electronic device 114) so that the device that executes the multi-screen collaboration function knows that the mouse cursor needs to appear from the lower edge of the screen of electronic device 114 (instead of from the upper edge of the screen of electronic device 114, nor in another electronic device). Similarly, for the sharing mode, it is also necessary for the device that executes the multi-screen collaboration function to know the relative orientations between various electronic devices in advance.

[0094] To enable device #1 to know in advance the "relative orientations between various terminal devices", an existing solution is to let the user manually input the relative orientations between the current screens, and then device #1 records the relative orientations between the various electronic devices input by the user. However, since the positions of electronic devices are often not fixed (especially for tablets and laptops), if the user manually inputs the relative orientations between electronic devices every time the position of an electronic device changes, it may affect the user experience.

[0095] It should be understood that the "device (device #1) that executes the multi-screen collaboration function" in this application can be any one of the multiple electronic devices participating in the multi-screen collaboration function. For example, any one of electronic devices 111 to 114; or, this device #1 can also be an electronic device that does not participate in the multi-screen collaboration function. For example, device #1 can control multiple electronic devices among electronic devices 111 to 114 to execute the multi-screen collaboration function, while device #1 does not participate in this multi-screen collaboration function; or, this device #1 can also be a module (such as a chip or circuit) or a controller that executes the multi-screen collaboration function.

[0096] For ease of understanding, before introducing the method and electronic device for determining the device orientation provided in this application, the relevant terms and their principles involved in the embodiments of this application are briefly introduced.

[0097] 1. Angle of arrival (AoA) system

[0098] As Figure 3For the AoA system shown, the transmitting end can be a single antenna, and the receiving end can be multiple antennas. When performing orientation, the transmitting end can transmit a Bluetooth signal with a baseband of a sine wave, which is called the constant tone extension (CTE); when the receiving end receives the CTE, it will continuously switch between antennas, and at the same time sample the in-phase / quadrature (IQ) signals of the baseband of each antenna. These IQ signals will be reported from the chip to the Bluetooth Host for calculating the transmission angle.

[0099] 2. AoA Orientation Principle

[0100] For example, as Figure 3 shown, θ is the incident angle, λ is the wavelength, and d is the ratio of the spacing between the receiving end antennas to the wavelength. It can be seen from Figure 3 that the transmission distance of the signal received by the left antenna is larger than that of the signal received by the right antenna by d·λ·sinθ. This transmission distance difference causes the phase of the signal of the left antenna to be smaller than the phase of the signal of the right antenna by Therefore, by sampling and collecting the phase information of the two antennas and calculating their phase difference the incident angle θ can be deduced.

[0101] 3. Angle of Departure (AoD) System

[0102] For the AoD system, the transmitting end is multiple antennas, and the receiving end is a single antenna. When performing orientation, the transmitting end will transmit a CTE with a baseband of a sine wave and continuously switch between antennas at the same time; when the AoD receiving end receives, it will determine the transmitting antenna corresponding to each part of the CTE signal and sample and collect the baseband IQ signal corresponding to each antenna. The principle of AoD is similar to Figure 3 the AoA orientation principle shown, the difference being that AoD is a reverse process of AoA.

[0103] It should be understood that the above AoA system or AoD system can be an AoA system or AoD system that supports the Bluetooth protocol, but this application is not limited thereto. The solutions provided in the embodiments of this application can also be applied to AoA systems or AoD systems that support other protocols.

[0104] 4. Constant Tone Extension (CTE)

[0105] The CTE can be a single - tone signal with a length of 160 μs. When the rate is 1 Mbps, the baseband frequency of the CTE is 250 KHz (when the rate is 2 Mbps, the baseband frequency is 500 KHz). The receiving end performs regular sampling during the reference period and each sample slot. During the reference period, the receiving end collects an IQ sample every 1 μs and reports it; the Host will use these 8 samples to optimize reception, including possible gain, synchronization, or detection adjustments. After the Reference period, the receiving end of the AoA system (or the transmitting end of the AoD system) will perform an antenna switch once during each switch slot. At the same relative position in each sample slot, the receiving end collects an IQ sample and reports it to the Host; the Host can use the phase information contained in these IQ samples for angle estimation. The default supported antenna switch frequency of the protocol is 250 KHz, which is equivalent to performing an antenna switch every 4 μs after the Reference period (i.e., 2 μs for the switch slot and 2 μs for the sample slot).

[0106] It should be understood that in this application, the signal transmitted between the transmitting end and the receiving end can be a single - tone signal, such as a CTE signal, and this signal can also be a multi - tone signal, without limitation.

[0107] 5. Optical flow method

[0108] Generally speaking, optical flow is the projection of the motion of an object in three - dimensional space onto a two - dimensional image plane. It is generated by the relative velocity between the object and the camera, and reflects the motion direction and speed of the corresponding image pixels of the object in an extremely short time. When the time interval is small, it is also equivalent to the displacement of the target point. The optical flow method is a method that uses the change of pixels in the time domain in an image sequence and the correlation between adjacent frames to find the corresponding relationship between the previous frame and the current frame, so as to calculate the motion information of the object between adjacent frames. That is, the distance that the object moves in a short time can be determined through the optical flow method.

[0109] The following combines with Figure 3 to introduce the schematic diagram of identifying the device orientation through the antenna array. As Figure 3 shown, device 1 has an antenna array (or device 1 has the AOA calculation ability). Device 1 can calculate the orientation of device 2. The antenna array of device 1 can receive the wireless signal of device 2 and calculate the orientation of device 2 relative to device 1 according to formulas (1) and (2):

[0110] φ=(2πdsin(θ)) / λ (1)

[0111] θ = sin -1 ((φλ) / (2πd)) (2)

[0112] Wherein, d is the distance between antenna 1 and antenna 2 in the antenna array of device 1, φ is the phase difference between the signals received by antenna 1 and antenna 2 in the antenna array of device 1, λ is the wavelength of the signal transmitted by device 2, and θ is the angle of arrival. The orientation of device 2 relative to device 1 can be determined by the angle of arrival θ.

[0113] The above calculation of the orientation of device 2 by device 1 can also be understood as device 1 calculating the orientation of the antenna connection line between the antenna array of device 1 and device 2.

[0114] Although the relative orientation between electronic devices can be obtained through AoA or AoD orientation technology, the angle calculation accuracy of this method is limited by the number of antennas and the consistency of antenna patterns. Specifically, due to the multipath reflection phenomenon in the indoor environment, the signal will reach the receiving end from different directions after multipath reflection. Therefore, theoretically, the more antennas at the receiving end, the better the resolution of the arriving signals from different directions, that is, the higher the accuracy of the calculated emission angle of the signal. For example, the receiving end for indoor positioning generally uses 10 or more antennas currently. However, for electronic devices such as tablets or laptops, due to the limited internal space of the electronic device, generally at most 3 antennas can be supported, which results in poor angle accuracy measured in the indoor multipath environment.

[0115] In addition, according to the above AoA orientation principle, the magnitude of the incident angle determines the phase difference between the antennas. Therefore, based on the measured phase difference between the antennas, the incident angle can be deduced inversely. However, in the engineering implementation, the design pattern of the antenna itself will also affect the measured value of the phase. Therefore, the antennas at the receiving end need to ensure the consistency of the pattern. In this way, when calculating the phase difference between the antennas, the influence of each antenna on the phase measurement can be offset from each other, so that the phase difference value is only affected by the incident angle, and thus the incident angle can be correctly deduced inversely based on the phase difference. For office electronic devices such as tablets or laptops, the internal space is very limited, and it is difficult to ensure the consistency of the patterns of each antenna in the engineering implementation, which may affect the accuracy of angle estimation.

[0116] In view of this, the present application provides a method for determining the orientation of a device and a positioning device, which is beneficial to the improvement and solution of the above problems.

[0117] Figure 4 It is a schematic flowchart of a method for determining the orientation of a device provided by the present application. This method can be executed by a device (such as the first electronic device, that is, the above device #1) or a controller that executes the multi-screen collaboration function. This method may include the following steps.

[0118] S410, the first electronic device determines the first position information.

[0119] The first position information can indicate at least one displacement information.

[0120] Specifically, the at least one displacement information includes the displacement that the first electronic device moves relative to the initial moment at the first moment; or, the at least one displacement information includes the displacement that the first electronic device moves between two adjacent moments among the at least one first moment.

[0121] For example, as Figure 5 shown, assuming that the initial position of the first electronic device is the position of the first electronic device at the t0 moment (initial moment), the at least one displacement information may include the displacement d1 that the first electronic device moves relative to the t0 moment at the t1 moment (an example of the first moment), and the displacement d3 that the first electronic device moves relative to the t0 moment at the t2 moment (an example of the first moment); or, the at least one displacement information includes the displacement d1 that the position of the first electronic device at the t1 moment moves relative to the t0 moment, and the displacement d2 that the first electronic device moves relative to the t1 moment at the t2 moment.

[0122] Exemplarily, the first electronic device can calculate the at least one displacement information in combination with the optical flow method, that is, calculate the displacement of the first electronic device at at least one first moment according to the optical flow method. Exemplarily, an image sequence can be obtained, the image sequence includes the images obtained by the first electronic device at the at least one first moment, and the corresponding relationship existing between two adjacent images is found according to the change of pixels in the time domain in the image sequence and the correlation between the images obtained at adjacent moments, so as to calculate the displacement that the first electronic device moves at adjacent moments. The specific implementation of determining the displacement that the first electronic device moves at two adjacent moments based on the optical flow method can refer to the existing relevant descriptions. Determining the at least one displacement information based on the optical flow method can improve the calculation accuracy, the error of this method can be less than 0.1mm, and the refresh rate of this method for displacement calculation can be greater than 1.5KHz. Optionally, the first electronic device can receive the at least one displacement information measured by other devices. For example, the other device determines the at least one displacement information based on the optical flow method and feeds it back to the first electronic device.

[0123] S420, the first electronic device determines the first phase difference information.

[0124] Wherein, the first phase difference information includes at least one first phase difference. The at least one first phase difference corresponds to the at least one displacement information.

[0125] Exemplarily, the first phase difference includes the phase difference between the phase of the first signal received by the first electronic device at each of at least one first moment and the phase of the first signal received at the initial moment; alternatively, the first phase difference includes the phase difference between the phases of the first signals received by the first electronic device at two adjacent moments among the initial moment and at least one first moment.

[0126] Wherein, the first signal may come from a transmitting device (an example of the second electronic device), and the transmitting device may also be referred to as a transmitter, a transmitting electronic device. For ease of description, the transmitting device is denoted as device #1. Exemplarily, the first signal may be a CTE.

[0127] For example, as Figure 5 shown, the phase of the first signal received by the first electronic device at the initial moment is φ0, and the phases of the first signals received at t1 and t2 are φ1 and φ2 respectively. The at least one first phase difference may include Δφ1 and Δφ2, where Δφ1 = φ1 - φ0, Δφ2 = φ2 - φ0, or Δφ1 = φ1 - φ0, Δφ2 = φ2 - φ1.

[0128] Optionally, before determining the first phase difference information, the method further includes: determining the at least one first moment, that is, determining the transmission moment of the first signal.

[0129] Exemplarily, the first electronic device may negotiate with device #1 to determine the at least one first moment, that is, determine the transmission moment of the first signal.

[0130] It should be understood that this application does not limit the timing and specific implementation manner of negotiating the at least one first moment. For example, the first electronic device may negotiate the at least one first moment with device #1 before starting to determine the at least one position information or before the initial moment. The first electronic device may send the starting moment to device #1, as well as the time interval required for device #1 to send the first signal; device #1 may send confirmation information to the first electronic device and determine the at least one first moment according to the initial moment and the time interval. For example, the time interval may be 4 μs.

[0131] S430, the first electronic device determines the orientation of device #1 relative to the first electronic device according to the first position information and the first phase difference information.

[0132] Wherein, "orientation" may also be replaced by "direction", "position", etc.

[0133] Exemplarily, the first electronic device may determine the orientation of Device #1 relative to the first electronic device according to Formula (2), the at least one displacement information, and the at least one first phase difference. Specifically, the first electronic device may determine at least one angle of arrival at which Device #1 sends a first signal to the first electronic device according to Formula (2), the at least one displacement information, and the at least one first phase difference; the first electronic device determines the orientation of Device #1 relative to the first electronic device according to the at least one angle of arrival. That is, the orientation of Device #1 relative to the first electronic device may be represented by the angle of arrival of the signal sent by Device #1 to the first electronic device.

[0134] For Figure 5 example, the at least one angle of arrival may be represented as θ, where θ = sin -1 ((Δφ1λ) / (2πd1)), or θ = sin -1 ((Δφ2λ) / (2πd2)), λ represents the wavelength of the first signal, Δφ1 = φ1 - φ0, Δφ2 = φ2 - φ1, and the meanings of d1 and d2 may be referred to above. Exemplarily, the first electronic device may determine the average value of the determined multiple θs to determine the angle of arrival of the first signal sent by Device #1.

[0135] According to the positioning method provided by the embodiments of the present application, by moving the first electronic device to obtain at least one displacement information and the phase difference information of the first signal received at the at least one first moment, the orientation of the sending device that sends the first signal relative to the first electronic device can be determined, improving the accuracy of determining the orientation of the sending device. Among them, obtaining at least one displacement information by moving the first electronic device can be understood as the first electronic device creating an antenna array, and the at least one displacement information can be understood as the distance between antennas, so that the relative orientation between devices can be determined using the AoA and / or AoD principle.

[0136] Optionally, the method further includes S440 to S460:

[0137] S440, the first electronic device determines second position information and second phase difference information.

[0138] The second position information includes at least one displacement information, and the at least one displacement information includes the displacement of the first electronic device between two adjacent moments in at least one second moment.

[0139] Among them, the second moment may be different from the first moment. For example, in the case where the at least one second moment and the at least one first moment are equally spaced moments, the time interval between the first moments and the time interval between the second moments may be the same, and the starting moment of the at least one moment and the starting moment of the at least one second moment may be different; or, the time interval between the first moments and the time interval between the second moments may be different.

[0140] The second phase difference information includes at least one second phase difference.

[0141] Exemplarily, the first phase difference includes the phase difference between the phase of the second signal received by the first electronic device at each of the at least one second moment and the phase of the second signal received at the initial moment; or, the second phase difference includes the phase difference between the phases of the second signals received by the first electronic device at two adjacent moments among the initial moment and the at least one second moment. Among them, the second signal may come from other transmitting device (an example of the third electronic device) other than device #1, and for the sake of convenience of description, it is denoted as device #2. That is, device #1 and device #2 can respectively send the first signal and the second signal to the first electronic device for the first electronic device to measure the first phase difference information and the second phase difference information. For example, device #1 and device #2 alternately send the first signal and the second signal to the first electronic device in a time-division manner.

[0142] The specific implementation manner of this step can refer to the descriptions in S410 and S420.

[0143] S450, the first electronic device determines the orientation of device #2 relative to the first electronic device according to the second position information and the second phase difference information.

[0144] This step is similar to S430 and will not be elaborated here.

[0145] S460, the first electronic device determines the orientation of device #1 relative to device #2 according to the orientation of device #1 relative to the first electronic device and the orientation of device #2 relative to the first electronic device.

[0146] Exemplarily, it is assumed that through the above steps, it is determined that device #1 is on the left side of the first electronic device and device #2 is on the right side of the second electronic device, so that the relative positions between device #1 and device #2 can be obtained.

[0147] According to the positioning method provided by the embodiments of the present application, by moving the first electronic device to obtain the orientation of each of the two transmitting devices relative to the first electronic device, the relative orientation between the two transmitting devices can be determined, improving the accuracy of determining the orientation of the transmitting device.

[0148] Optionally, the method further includes: the first electronic device determines the relative orientation between each of at least one device #3 and the first electronic device; and determines the relative orientation between device #1, device #2, and each of the at least one device #3 according to the relative orientation between each of the at least one device #3 and the first electronic device.

[0149] Wherein, the specific manner of determining the relative orientation between each of the at least one device #3 and the first electronic device may refer to the description in S440 to S450. The specific manner of determining the relative orientation between device #1, device #2, and each of the at least one device #3 may refer to the specific manner in S460 of determining the orientation between device #1 and device #2 according to the orientation of device #1 relative to the first electronic device and the orientation of device #2 relative to the first electronic device.

[0150] According to the positioning method provided in the embodiments of the present application, by moving the first electronic device to obtain the orientation of each of the multiple sending-end devices relative to the first electronic device, the relative orientation between the multiple sending-end devices can be determined, improving the accuracy of determining the orientation of the sending-end device.

[0151] The above introduces a positioning method provided by the present application in combination with the AOA orientation principle. It can be understood that this method is also applicable to the AoD system. That is, the sending-end device is the above-mentioned first electronic device, and the receiving-end device may include at least one of the above-mentioned device #1, device #2, and at least one device #3.

[0152] Figure 6 It is a schematic flowchart of a positioning method 600 provided by the present application, and the method may include the following steps.

[0153] S610, the first electronic device determines the first position information.

[0154] The first position information includes at least one displacement information corresponding to at least one moment, and this step may refer to the description in S410.

[0155] S620, the first electronic device receives the third phase difference information from the second electronic device.

[0156] The third phase difference information includes at least one third phase difference, and the third phase difference includes the phase difference between the phases of the third signals received by each of the receiving-end devices (including the second electronic device) at at least one moment.

[0157] For example, after the second electronic device determines the third phase difference, it may send the third phase difference to the first electronic device; correspondingly, the first electronic device receives the third phase difference from the second electronic device.

[0158] Optionally, before S620, the first electronic device sends the third signal to at least one electronic device at each of the at least one moment.

[0159] Exemplarily, the third phase difference includes the phase difference between the phase of the third signal received by the second electronic device at at least one moment and the phase of the third signal received by the second electronic device at the initial moment; or, the third phase difference includes the phase difference between the phases of the third signals received by the second electronic device at two adjacent moments among the at least one first moment. The second electronic device is any one of the at least one electronic device.

[0160] Optionally, before sending the third signal to the at least one electronic device, the first electronic device can also negotiate the at least one moment with the at least one electronic device. For details, reference can be made to the description in S420.

[0161] S630, the first electronic device determines the orientation of the second electronic device relative to the first electronic device according to the third phase difference and the first position information.

[0162] Among them, the at least one third phase difference corresponding to the first receiving device can be understood as the third phase difference determined by the second electronic device based on the received third signal.

[0163] This step can refer to the description in S430 where the first electronic device determines the orientation of device #1 relative to the first electronic device.

[0164] Optionally, S640, the first electronic device sends the first position information to the second electronic device.

[0165] The first position information is used for the second electronic device to determine the orientation of the second electronic device relative to the first electronic device. Exemplarily, the second electronic device can determine the orientation of the second electronic device relative to the first electronic device based on at least one displacement information and the determined at least one third phase difference.

[0166] Alternatively, the first electronic device can also send the first position information to other devices, and the second electronic device can send at least one third phase difference determined by the second electronic device to the other devices, so that the other devices can determine the orientation of the second electronic device relative to the first electronic device. Among them, the other devices can be understood as other devices except the first electronic device and the second electronic device. The specific manner for the other devices to determine the orientation of the second electronic device relative to the first electronic device can refer to the manner for the first electronic device to determine the relative orientation.

[0167] The method for determining the orientation of other electronic devices in the at least one electronic device relative to the first electronic device refers to the method for determining the orientation of the second electronic device relative to the first electronic device.

[0168] Optionally, the method includes: determining the relative orientation between each of the at least one electronic device.

[0169] The specific determination method can refer to the description in S460.

[0170] Alternatively, after S640, the orientation of each of the electronic devices relative to the first electronic device can be exchanged between each of the electronic devices, and the relative orientation between each of the electronic devices can be determined based on the orientation of each of the electronic devices relative to the first electronic device.

[0171] Alternatively, the relative orientation between each of the electronic devices can also be determined by other devices based on the orientation of each of the electronic devices relative to the first electronic device. Wherein, the relative orientation between each of the electronic devices can be understood as the orientation of one electronic device relative to another electronic device in every two electronic devices.

[0172] According to the positioning method provided by the embodiments of the present application, through at least one displacement information of the movement of the positioning device and at least one phase difference determined by the electronic device, the orientation of each of the multiple electronic devices relative to the first electronic device, and the relative orientation between the at least one electronic device can be determined, which can improve the accuracy of determining the orientation of the electronic device. Secondly, through this method, the first electronic device can simultaneously send the signal for measuring the phase difference to multiple electronic devices, which can shorten the positioning duration.

[0173] In the present application, "at least one" means one or more, and "multiple" means two or more. " / ", describes the association relationship of the associated objects, indicating that three relationships can exist. For example, A and / or B can represent: A exists alone, A and B exist simultaneously, and B exists alone, where A and B can be singular or plural. The character " / " generally represents an "or" relationship between the front and rear associated objects. "At least one (item)" or its similar expression refers to any combination of these items, including any combination of single item (item) or plural items (items). For example, at least one (item) of a, b, or c can represent: a, b, c, a - b, a - c, b - c, or a - b - c, where a, b, c can be single or multiple.

[0174] It should be understood that the magnitudes of the sequence numbers of the above processes do not mean the order of execution. The order of execution of each process should be determined according to its function and internal logic, and should not constitute any limitation to the implementation process of the embodiments of the present application.

[0175] The example of the positioning method provided by the present application is introduced in detail above. It can be understood that in order for the positioning device to implement the above functions, it includes the corresponding hardware structure and / or software module for executing each function. Those of ordinary skill in the art can realize that the units and algorithm steps of each example described in combination with the embodiments disclosed in this article can be implemented by electronic hardware, or by a combination of computer software and electronic hardware. Whether these functions are executed in a hardware or software manner depends on the specific application and design constraints of the technical solution. Professional technicians can use different methods to implement the described functions for each specific application, but such implementation should not be considered to exceed the scope of the present application.

[0176] Next, in combination with Figures 7 to 8 the electronic device related to the present application will be introduced in detail.

[0177] Figure 7 FIG. is a schematic block diagram of an electronic device 700 provided by an embodiment of the present application.

[0178] The electronic device 700 can correspond to the first electronic device in the above method embodiment, or a chip configured in the first electronic device. The electronic device 700 can execute Figure 7 each step executed by the first electronic device and / or the second electronic device in

[0179] The electronic device 700 may optionally further include a storage unit, which can be used to store instructions and / or data. The processing unit 720 can read the instructions and / or data in the storage unit to enable the first electronic device to implement the actions executed by the first electronic device and / or the second electronic device in the foregoing method embodiments.

[0180] Among them, the communication unit 710 can be used to execute the operations related to the sending and receiving of the first electronic device and / or the second electronic device in the above method embodiment, such as Figure 4 and Figure 6 the operations related to the sending and receiving of the first electronic device and / or the second electronic device in the illustrated embodiments; the processing unit 720 can be used to execute the operations related to the processing of the first electronic device and / or the second electronic device in the above method embodiment, such as Figure 4 and Figure 6 the operations related to the processing of the first electronic device and / or the second electronic device in the illustrated embodiments.

[0181] Figure 8 FIG. is a schematic block diagram of an electronic device 800 provided by an embodiment of the present application.

[0182] The electronic device 800 includes a processor 810, and the processor 810 is coupled to a memory 820. Optionally, a memory 820 is further included. The memory 820 is used to store computer programs or instructions and / or data, and the processor 810 is used to execute the computer programs or instructions stored in the memory 820, or read the data stored in the memory 820, so as to execute the methods in the above method embodiments.

[0183] Optionally, the processor 810 is one or more.

[0184] Optionally, the memory 820 is one or more.

[0185] Optionally, the memory 820 is integrated with the processor 810 or is separately provided.

[0186] Optionally, as Figure 8 shown, the electronic device 800 further includes a transceiver 830, and the transceiver 830 is used for receiving and / or sending signals. For example, the processor 810 is used to control the transceiver 830 to receive and / or send signals.

[0187] As a solution, the electronic device 800 is used to implement the operations performed by the first electronic device in the above method embodiments.

[0188] For example, the processor 810 is used to execute the computer programs or instructions stored in the memory 820 to implement the related operations of the first electronic device in the above method embodiments. For example, as Figure 4 and Figure 6 shown in the embodiments, the methods performed by the first electronic device.

[0189] As another solution, the electronic device 800 is used to implement the operations performed by the sending-end device (for example, at least one of device #1, device #2, and device #3) or the receiving-end device (for example, at least one electronic device, the second electronic device) in the above method embodiments.

[0190] For example, the processor 810 is used to execute the computer programs or instructions stored in the memory 820 to implement the related operations of the sending-end device (for example, at least one of device #1, device #2, and device #3) or the receiving-end device in the above method embodiments.

[0191] In the implementation process, each step of the above method can be completed by the integrated logic circuit of the hardware in the processor 810 or the instructions in the form of software. The method combining the embodiments of the present application can be directly embodied as being executed and completed by the hardware processor, or executed and completed by the combination of the hardware and software modules in the processor. The software module can be located in a mature storage medium in the art such as random access memory, flash memory, read-only memory, programmable read-only memory, or electrically erasable programmable memory, register, etc. This storage medium is located in the memory 820, and the processor 810 reads the information in the memory 820 and combines its hardware to complete the steps of the above method. To avoid repetition, it will not be described in detail here.

[0192] It should be understood that in the embodiments of the present application, the processor can be one or more integrated circuits for executing relevant programs to execute the method embodiments of the present application.

[0193] The processor (for example, the processor 810) can include one or more processors and be implemented as a combination of computing devices. The processor can respectively include one or more of the following: microprocessor, microcontroller, digital signal processor (DSP), digital signal processing device (DSPD), application specific integrated circuit (ASIC), field programmable gate array (FPGA), programmable logic device (PLD), gated logic, transistor logic, discrete hardware circuit, processing circuit, or other suitable hardware, firmware, and / or a combination of hardware and software, for executing various functions described in the present disclosure. The processor can be a general-purpose processor or a special-purpose processor. For example, the processor 810 can be a baseband processor or a central processing unit. The baseband processor can be used to process communication protocols and communication data. The central processing unit can be used to cause the device to execute software programs and process the data in the software programs. In addition, a part of the processor can also include non-volatile random access memory. For example, the processor can also store information about the device type.

[0194] The program in the present application is generally used to represent software. Non-limiting examples of software include: program code, program, subroutine, instruction, instruction set, code, code segment, software module, application program, or software application, etc. The program can run on the processor and / or computer, so that the device can execute various functions and / or processes described in the present application.

[0195] A memory (e.g., memory 820) may store data required for a processor (e.g., processor 810) to execute software. The memory may be implemented using any suitable storage technology. For example, the memory may be any available storage medium accessible by the processor and / or computer. Non-limiting examples of storage media include: random access memory (RAM), read-only memory (ROM), electrically erasable programmable read-only memory (EEPROM), compact disc read-only memory (CD-ROM), static random access memory (SRAM), dynamic random access memory (DRAM), synchronous dynamic random access memory (SDRAM), double data rate synchronous dynamic random access memory (DDR SDRAM), enhanced synchronous dynamic random access memory (ESDRAM), synchlink dynamic random access memory (SLDRAM), and direct rambus random access memory (DR RAM), removable media, optical disc memory, disk storage media, magnetic storage devices, flash memory, registers, status memory, remotely mounted memory, local or remote memory components, or any other medium capable of carrying or storing software, data, or information and accessible by the processor / computer. It should be noted that the memory described herein is intended to include, but is not limited to, these and any other suitable types of memory.

[0196] The memory (e.g., memory 820) and the processor (e.g., processor 810) may be separately provided or integrated together. The memory may be used to connect to the processor such that the processor can read information from the memory, store and / or write information in the memory. The memory may be integrated in the processor. The memory and the processor may be provided in an integrated circuit.

[0197] Embodiments of this application also provide a computer-readable storage medium, on which computer instructions for implementing the methods executed by the first electronic device in the above method embodiments are stored.

[0198] Embodiments of this application also provide a computer program product, including instructions that, when executed by a computer, implement the methods executed by the first electronic device in the above method embodiments.

[0199] An embodiment of the present application further provides a system for determining the orientation of a device, which system includes one or more of the first electronic device and the second electronic device in the above embodiments.

[0200] For the explanations and beneficial effects of the relevant content in any of the above-provided devices, reference may be made to the corresponding method embodiments provided above, and details are not described herein again.

[0201] In several embodiments provided in the present application, it should be understood that the disclosed devices and methods can be implemented in other ways. For example, the device embodiments described above are merely illustrative. For example, the above division of units is only a logical function division. In actual implementation, there may be other division methods. For example, multiple units or components can be combined or integrated into another system, or some features can be ignored or not executed. In addition, the displayed or discussed couplings or direct couplings or communication connections to each other can be through some interfaces. The indirect couplings or communication connections of the devices or units can be in electrical, mechanical or other forms.

[0202] The units described above as separate components may or may not be physically separated. The components shown as units may or may not be physical units, that is, they may be located in one place, or may be distributed to multiple network units. Some or all of the units can be selected according to actual needs to implement the solution provided by the present application.

[0203] In addition, in each embodiment of the present application, the functional units can be integrated into one unit, or each unit can exist physically alone, or two or more units can be integrated into one unit.

[0204] Those of ordinary skill in the art can realize that the units and algorithm steps of each example described in combination with the embodiments disclosed herein can be implemented by electronic hardware, or by a combination of computer software and electronic hardware. Whether these functions are executed in hardware or software depends on the specific application and design constraints of the technical solution. Professionals can use different methods for each specific application to implement the described functions, but such implementation should not be considered to exceed the scope of the present application.

[0205] When implemented using software, it can be implemented in the form of a computer program product in whole or in part. The computer program product includes one or more computer instructions. When the computer program instructions are loaded and executed on a computer, the processes or functions described in the embodiments of the present application are generated in whole or in part. The computer can be a general-purpose computer, a special-purpose computer, a computer network, or other programmable devices. For example, the computer can be a personal computer, a server, or a network device, etc. 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 a website, a computer, a server, or a data center to another website, a computer, a server, or a data center by wire (such as coaxial cable, optical fiber, digital subscriber line (DSL)) or wirelessly (such as infrared, wireless, microwave, etc.). Regarding the computer-readable storage medium, reference can be made to the above description.

[0206] As described above, the above are only specific embodiments of the present application, but the protection scope of the present application is not limited thereto. Any person skilled in the art within the technical scope disclosed by the present application can easily think of changes or substitutions, which should all be covered within the protection scope of the present application. Therefore, the protection scope of the present application should be subject to the protection scope of the claims.

Claims

1. A method for determining the orientation of a device, characterized in that, Applied to a first electronic device, the method includes: Determine first position information, the first position information including at least one displacement information, the at least one displacement information including the displacement of the first electronic device between two adjacent moments among a plurality of first moments; Obtain first phase difference information, the first phase difference information including at least one first phase difference, the first phase difference being the phase difference between the phases of a first signal received by the first electronic device from a second electronic device at the adjacent moments; Determine the orientation of the second electronic device relative to the first electronic device according to the first position information and the first phase difference information.

2. The method according to claim 1, wherein The determining the first position information includes: Obtain an image sequence, the image sequence including images acquired by the first electronic device at the at least one first moment; Determine the first position information based on the change of pixels in the image sequence at the at least one first moment.

3. The method according to claim 1 or 2, wherein The method further includes: Determine the orientation of a third electronic device relative to the first electronic device according to the second position information and second phase difference information, the second position information including the displacement of the first electronic device between two adjacent moments among at least one second moment, the second phase difference information including at least one second phase difference, the second phase difference being the phase difference between the phases of a second signal received by the first electronic device from the third electronic device at the at least one second moment; Determine the relative orientation between the second electronic device and the third electronic device according to the orientation of the second electronic device relative to the first electronic device and the orientation of the third electronic device relative to the first electronic device.

4. The method according to any one of claims 1 to 3, characterized in that, The determining the orientation of the second electronic device relative to the first electronic device according to the first position information and the first phase difference information includes: Determine the angle of arrival of the first signal according to the at least one displacement information and the at least one first phase difference, the angle of arrival being used to characterize the orientation.

5. The method according to claim 4, wherein The following relationship is satisfied between the at least one displacement information, the at least one first phase difference and the angle of arrival: θ = sin -1 ((φ i λ) / (2πd i )); where θ represents the angle of arrival, and d i represents the i-th displacement information among the at least one displacement information, and φ i represents the i-th first phase difference among the at least one first phase difference.

6. A method for determining the orientation of a device, characterized in that, Applied to a first electronic device, the method includes: Determine first position information, the first position information including at least one displacement information, the at least one displacement information including the displacement of the first electronic device between two adjacent moments among at least one moment; Receive third phase difference information from a second electronic device, the third phase difference information including at least one third phase difference, the third phase difference including the phase difference between the phases of a third signal received by the second electronic device from the first electronic device at the at least one moment; Determine the orientation of the second electronic device relative to the first electronic device according to the first position information and the third phase difference information.

7. The method according to claim 6, wherein The determining the first position information includes: Obtain an image sequence, the image sequence including images acquired by the first electronic device at the at least one first moment; Determine the first position information based on the change of pixels in the image sequence at the at least one first moment.

8. The method according to claim 6 or 7, characterized in that, Before determining the orientation of the second electronic device relative to the first electronic device according to the first position information and the third phase difference information, the method further includes: Sending the third signal to at least one electronic device at the at least one moment, where the at least one electronic device includes the second electronic device.

9. The method according to claim 8, wherein The method further includes: Receiving fourth phase difference information from a third electronic device, the fourth phase difference information including at least one fourth phase difference, the fourth phase difference including the phase difference between the phases of the third signal received by the third electronic device from the first electronic device at the at least one moment, and the at least one electronic device includes the third electronic device; Determining the orientation of the third electronic device relative to the first electronic device according to the first position information and the fourth phase difference information; Determining the relative orientation between the second electronic device and the third electronic device according to the orientation of the second electronic device relative to the first electronic device and the orientation of the third electronic device relative to the first electronic device.

10. The method according to any one of claims 6 to 9, characterized in that The determining the orientation of the second electronic device relative to the first electronic device according to the first position information and the third phase difference information includes: Determining the departure angle of the third signal according to the at least one displacement information and the at least one third phase difference, where the departure angle is used to characterize the orientation.

11. The method according to claim 10, wherein The following relationship is satisfied between the at least one displacement information, the at least one third phase difference and the departure angle: θ = sin -1 ((φ i λ) / (2πd i )); where θ represents the departure angle, d i represents the i-th displacement information among the at least one displacement, φ i represents the i-th third phase difference among the at least one third phase difference.

12. An electronic device, characterized in that, Including: One or more processors; One or more memories; And one or more computer programs, where the one or more computer programs are stored in the one or more memories, and the one or more computer programs include instructions, and when the instructions are executed by the one or more processors, the electronic device is caused to execute the method according to any one of claims 1 to 11.

13. A computer-readable storage medium, characterized in that: Computer instructions are stored in the computer-readable storage medium, and when the computer instructions run on a computer, the method according to any one of claims 1 to 11 is caused to be executed.

14. A computer program product, characterized in that: Computer instructions are stored in the computer program product, and when the computer instructions run on a computer, the method according to any one of claims 1 to 11 is caused to be executed.

15. A chip, characterized in that, Including at least one processor and an interface circuit, the interface circuit is used to provide program instructions or data for the at least one processor, and the at least one processor is used to execute the program instructions to implement the method according to any one of claims 1 to 11.