METHOD AND ELECTRONIC DEVICE FOR RETRIEVING EXTERNAL DEVICE THROUGH POSITIONING ANGLE ADJUSTMENT

Various embodiments of the disclosure disclose a method and a device including a display, a communication module, a memory, and a processor configured to be operatively connected to at least one of the display, the communication module, or the memory. The processor may be configured to perform ultra-wideband (UWB) communication through the communication module, retrieve at least one external device corresponding to a perceivable range of the UWB communication, based at least in part on the UWB communication, determine whether a configured condition is satisfied by a retrieved external device of the retrieved one or more external devices, perform an operation related to the retrieved external device when the retrieved external device satisfies the configured condition, and re-retrieve the at least one external device by changing the positioning angle when the retrieved external device does not correspond to the configured condition. Various embodiments are possible.

BACKGROUND

Various embodiments of the disclosure relate to a method and a device for efficiently retrieving an external device through positioning angle adjustment.

2. Description of Related Art

With the advancement of digital technology, various types of electronic devices, such as a mobile communication terminal, a personal digital assistant (PDA), an electronic organizer, a smartphone, a tablet, a personal computer (PC), or a wearable device, are widely used. In order to support and improve the functions of electronic devices, hardware and/or software of electronic devices are continuously being developed.

For example, an electronic device may retrieve an external device (or a target device or a peripheral device) located near the electronic device through communication, such as Bluetooth, wireless fidelity (Wi-Fi), or ultra-wideband (UWB). For example, the external device may be an Internet of Things (IoT) device, such as a refrigerator, a washing machine, a TV, a set-top box, a printer, or a scanner. The electronic device may select at least one external device from among retrieved external devices to transmit a file or message to the external device. The electronic device may select an external device to transmit data (e.g., a file or a message), based on a distance (or location) or angle to the external device. For example, the electronic device may measure the distance or angle to the external device through UWB communication.

SUMMARY

Conventionally, an electronic device may select an external device positioned at a specific angle (e.g., 0°) or may select an external device included in a fixed angle range or a fixed distance range. When a range for selecting an external device is fixed, a user may have difficulty in selecting a desired external device. Since the user does not know the location of a UWB antenna included in the electronic device or the external device, even though the user points to a location where the first external device601actually exists, a UWB signal may be output from a different location of the external device, and thus the desired external device may not be selected.

Various embodiments may disclose a method and a device for retrieving an external device through UWB communication, determining whether the retrieved external device corresponds to a configured condition, and variably controlling a positioning angle, based on a determination result.

An electronic device according to various embodiments of the disclosure may include a display, a communication module, a memory, and a processor configured to be operatively connected to at least one of the display, the communication module, or the memory. The processor may be configured to perform ultra-wideband (UWB) communication through the communication module. The processor may be configured to retrieve at least one external device corresponding to a perceivable range of the UWB communication, based on the UWB communication, determine whether a configured condition including at least one of whether the retrieved external device is within a positioning angle smaller than the perceivable range, whether a number of retrieved external devices corresponds to a configured number, or whether a distance between the electronic device and the retrieved external device is a configured distance is satisfied, perform an operation related to the retrieved external device when the retrieved external device corresponds to the configured condition, and re-retrieve the at least one external device by changing the positioning angle when the retrieved external device does not correspond to the configured condition.

An operating method of an electronic device according to various embodiments of the disclosure may include performing ultra-wideband (UWB) communication through a communication module of the electronic device. The method may include retrieving at least one external device corresponding to a perceivable range of the UWB communication, based at least in part on the UWB communication, determining whether a configured condition including at least one of whether the retrieved external device is within a positioning angle smaller than the perceivable range, whether a number of retrieved external devices corresponds to a configured number, or whether a distance between the electronic device and the retrieved external device is a configured distance. The method may include performing an operation related to the retrieved external device when the retrieved external device satisfies the configured condition, and re-retrieving an external device by changing the positioning angle when the retrieved external device does not correspond to the configured condition.

According to various embodiments, whether an external device retrieved through UWB communication corresponds to a configured condition may be determined, and a positioning angle may be variably controlled based on a determination result, thereby controlling selection of an external device desired by a user.

According to various embodiments, a positioning angle may be dynamically changed according to a distance to an external device retrieved through UWB communication, thereby increasing accuracy in selecting an external device.

According to various embodiments, when there is no distance information about an external device, a distance to the external device may be inferred based at least in part on the strength (e.g., a received signal strength indication (RSSI) or a signal-to-noise ratio (SNR)) of a UWB signal received from the external device, thereby dynamically changing a positioning angle according to the distance to the external device.

According to various embodiments, when there are at least two external devices having similar angles, a location change of an electronic device may be reported to a user, and information obtained after the location change of the electronic device may be compared with information obtained before the location change, thereby providing more accurate information about a distance or angle of an external device.

According to various embodiments, the external device may be identified in further consideration of context information in addition to the positioning angle or the number or distance of external devices.

DETAILED DESCRIPTION

FIG.1is a block diagram illustrating an electronic device101in a network environment100according to certain embodiments.

FIG.2is a block diagram of hardware of an electronic device according to various embodiments.

Referring toFIG.2, the electronic device (e.g., the electronic device101ofFIG.1) according to various embodiments may include a processor120, a Bluetooth Low Energy (BLE) module210, a BLE antenna211, a ultra-wideband (UWB) module220, UWB antenna 1221, UWB antenna 2223, and/or an embedded secure element (eSE) module230. According to various embodiments, at least one (e.g., UWB antenna 2213) among the components included inFIG.2may be omitted from the electronic device101, or one or more other components may be added thereto. The BLE module210, the UWB module220, and/or the eSE module230may be operatively connected to the processor120. The BLE module210or the UWB module220may be included in the communication module190ofFIG.1. The BLE module210may transmit or receive a BLE signal under control of the processor120. The BLE module210may transmit or receive the BLE signal through the BLE antenna211.

The UWB module220may include a transmitter (TX) module to transmit a UWB signal (e.g., poll, response, or final) for positioning from an external electronic device (e.g., the electronic device102or the electronic device104ofFIG.1) and a receiver (RX) module to receive a UWB signal. The UWB signal may be transmitted or received through UWB antenna 1221and/or UWB antenna 2223. There may be a greater number of UWB antennas than shown inFIG.2. For example, the UWB signal may be switched to be transmitted and/or received via UWB antenna 1221and/or UWB antenna 2223, based on control of the UWB module220and/or the processor120. The UWB module220may operate under control of the processor120, and may transmit a received UWB signal to the processor120or may form a communication path (e.g., a serial peripheral interface) for receiving a control signal from the processor120.

The eSE module230may be a module that generates or stores credential information according to circumstances. The eSE module230may transmit the generated credential information to the UWB module220. The eSE module230may be connected to the UWB module220through I2C communication. The eSE module230may be included in or may be disposed outside the UWB module220.

FIG.3is a block diagram of a program module of an electronic device supporting a UWB function according to various embodiments.

Referring toFIG.3, the electronic device (e.g., the electronic device101ofFIG.1) may include an operating system (OS) that controls a resource related to the electronic device101and/or a program module310including various applications and hardware320that run on the operating system. The operating system may be, for example, an operating system including Android, iOS, Windows, Symbian, Tizen, or Bada.FIG.3may show the program module310and the hardware320supporting a UWB function in the electronic device101employing an Android operating system.

The program module310may include a kernel330, a platform340, an application framework350, or an application370. At least part of the program module310may be preloaded onto the electronic device101or may be downloaded from an external electronic device (e.g., the electronic device102or104or the server108). The kernel330may include a device driver for driving the hardware320(e.g., a Bluetooth chip321, a UWB chip323, an NFC chip325, or an eSE chip327) of the electronic device101. The NFC chip325and the eSE chip327may be configured as one. For example, the device driver may include at least one of a Bluetooth driver331, a UWB driver333, an NFC driver335, or an eSE SPI driver337. The platform340may include at least one of a Bluetooth hal341, a UWB hal343, an NFC hal345, or an eSE SPI hal347for controlling the device driver of the kernel330.

The application framework350may provide a function commonly required by the application370or may provide various functions to the application370so that the application370may efficiently use limited system resources inside the electronic device101. For example, the application framework350may include a Bluetooth framework351, a UWB framework352, an open multimedia applications platform (OMAP) API353, a Bluetooth service354, a secure element service361, and a UWB service362. The UWB service362may include a connectivity manager355, a UWB adapter356, security357, distance measurement358, localization359, or handover360for supporting a UWB-related API. The electronic device101may measure the positions of a plurality of external electronic devices using the UWB adapter356, the distance measurement358, or the localization359.

The application370may include a UWB payment/loyalty application371, a UWB positioning application373, and a UWB smart key application375.

FIG.4illustrates an example in which an electronic device retrieves an external device according to various embodiments.

Referring toFIG.4, the electronic device (e.g., the electronic device101ofFIG.1) according to various embodiments may retrieve an external device located nearby through UWB communication according to a user’s request. The external device may be referred to as an external electronic device, a target device, or a peripheral device. For example, the external device may be an Internet of Things (IoT) device capable of receiving and controlling wired and wireless signals, such as a refrigerator, a washing machine, a TV, a set-top box, a printer, or a scanner. In another example, the external device may be a device that transmits a wireless signal including data, such as a POS, an electronic board, a menu board, or an advertisement board provided in a store. In still another example, the external device may be a device capable of transmitting a wireless signal including data and changing the data, such as a UWB tag/anchor. According to an embodiment, the external device may store SSID/password information for Wi-Fi connection and may be located near a router to help the connection. The external device may include a first external device401, a second external device403, or a third external device405.

For example, the first external device401may be an air conditioner, the second external device403may be a TV, and the third external device405may be a set-top box. These examples are provided only to assist understanding of the disclosure, and do not limit the disclosure. For UWB communication with the external device, the electronic device101may receive a data transmission request from the user. The data transmission request means that the user of the electronic device101selects data (e.g., a file, an image, a document, or a control command to change the state of the external device) desired to be transmitted and selects a transmission button. Alternatively, the data transmission request may mean executing an application related to data transmission and selecting data desired to be transmitted.

Alternatively, when executing an application using UWB communication, the electronic device101may start communication with the external device using UWB communication. Alternatively, the electronic device101may execute an application using UWB communication, may identify a UWB communication method of the external device through in-band communication, and may start communication with the external device based at least in part on the UWB communication method. Alternatively, the electronic device101may transmit a UWB communication start request to the external device or may receive a UWB communication start request from the external device through external communication (Bluetooth). Alternatively, the electronic device101may start UWB communication when the external device is located within a specified range while a UWB module is being activated.

According to various embodiments, the electronic device101may broadcast a message including UWB configuration information through a BLE module (e.g., the BLE module210ofFIG.2) in order to connect UWB communication. The UWB configuration information may include whether the electronic device101supports UWB communication (e.g., UWB communication support information configured to 1 or 0) or a UWB communication type (or method). For example, when the electronic device101supports UWB communication, the electronic device101may configure the UWB communication support information to 1, and when the electronic device101does not support UWB communication, the electronic device101may configure the UWB communication support information to 0. Since the message is broadcast, the message may be transmitted to the first external device401to the third external device405existing near the electronic device101. The electronic device101may periodically transmit the message (e.g., BLE advertising).

The UWB communication type may include at least one of single-sided TWR (SS-TWR), double-sided TWR (DS-TWR), advertisement, uplink (UL) time difference of arrival (TDoA), or downlink (DL) TDoA. These examples are provided only to assist understanding of the disclosure, and the disclosure is not limited by the description. In addition to the above-listed UWB communication types, the disclosure may further include other UWB communication types (e.g., an existing UWB communication method and a UWB communication method to be newly added). SS-TWR is a method for identifying the distance or angle between the electronic device101and the external device (or the location of the external device) by the electronic device101transmitting a ranging poll message (or ranging poll data) to the external device and the external device transmitting a ranging response message to the electronic device101. DS-TWR is a method, when for identifying the distance or angle between the electronic device101and the external device by the electronic device101transmitting a ranging poll message, the external device transmitting a ranging response message to the electronic device101, and the electronic device101transmitting a ranging final message to the external device.

The electronic device101may receive a response to the message from at least one of the first external device401to the third external device405. The response may include whether the first external device401to the third external device405support UWB communication or a UWB communication type (or method). The electronic device101may establish UWB communication with the first external device401to the third external device405, based at least in part on the response received from the first external device401to the third external device405. When the UWB communication is completely established, the electronic device101may activate the UWB communication (e.g., activate (or turn on) the RX module of the UWB module220), thereby performing the UWB communication with the first external device401to the third external device405. When the UWB communication type is SS-TWR or DS-TWR, the electronic device101may establish UWB communication using BLE or Wi-Fi before activating the RX module of the UWB module220.

When the UWB communication type is advertisement, UL TDoA, or DL TDoA, the electronic device101may start UWB communication using a predefined (or pre-agreed) configuration. Advertisement is a method in which the external device transmits a UWB signal (e.g., an advertisement) but the external device may not receive a UWB signal from the electronic device101. In the advertisement, the electronic device101may measure only the angle with the external device, but may not measure the distance to the external device.

TDoA may measure the distance or angle to the external device using a difference in propagation time of a signal of a location tag (e.g., a transmitter) measured by a location anchor (e.g., a receiver). The external device corresponding to the location tag may transmit a broadcast message (e.g., an advertisement) to the electronic device101corresponding to the location anchor, and the electronic device101may generate a time of arrival (ToA) stamp for the received message and may calculate a TDoA from the ToA. The electronic device101may report the ToA stamp to a location server (e.g., the server108ofFIG.1) through wired or wireless communication, and the server108may calculate a TDoA from the ToA. UL TDoA may refer to calculating the distance or angle to the external device by the server108, and DL TDoA may refer to calculating the distance or angle to an external device by the electronic device101. The electronic device101may directly receive a broadcast message transmitted by the location tag without going through the server, thus obtaining a relative angle with the location tag.

For example, the first external device401is capable of performing UWB communication through SS-TWR, and the second external device401and the third external device405are capable of performing UWB communication through advertisement. For example, the electronic device101may be configured to perform UWB communication with the first external device401through SS-TWR and may be configured to perform UWB communication with the second external device401and the third external device405through advertisement. These examples are provided only to assist understanding of the disclosure, and do not limit the disclosure.

The electronic device101may retrieve an external device included in a UWB communication-perceivable range (e.g., a field of view (FoV)), based at least in part on a UWB signal received from the first external device401to the third external device405, e.g., retrieve one or more external devices corresponding to a field of view of the UWB communication, based at least in part on the UWB communication. The UWB signal may correspond to a poll, a response, a final, or an advertisement. The UWB signal may include at least one of time information, a timestamp, angle information (e.g., an azimuth and an elevation), a received signal strength indication (RSSI), signal-to-noise ratio (SNR) information (e.g., a first SNR, a main SNR, and a total SNR), or a transmit power (e.g., TX power). The time information may include at least one of a UWB signal transmission time, a UWB signal reception time, or a UWB signal processing time.

When the UWB communication type is at least one of SS-TWR, DD-TWR, UL TDoA, or DL TDOA, the electronic device101may measure the distance to the external device, based at least in part on the time information included in the UWB signal. The electronic device101may transmit or receive the UWB signal 360 degrees. Since the user intends to transmit data to the external device located in front, the electronic device101may retrieve an external device included in the UWB communication-perceivable range (e.g., -60° to +60°) corresponding to the front of the electronic device101.

According to various embodiments, the electronic device101may retrieve the external device included in the UWB communication-perceivable range for a configured time or a configured number of times. When a UWB signal transmitted from an external device not located in front of the electronic device101is reflected by an obstacle (e.g., a wall or an object) and received by the electronic device101, the electronic device101may determine that the UWB signal is transmitted from the front. For example, the first external device401may exist behind the electronic device101, and the second external device403and the third external device405may exist in front of the electronic device101. When a UWB signal transmitted from the first external device401is reflected by a wall and received by the electronic device101, the electronic device101may determine that the first external device401exists in front of the electronic device101. To mitigate the effect of reflected signals, the electronic device101may determine that the external device included in the UWB communication-perceivable range for the configured time or the configured number of times is located in front of the electronic device101.

The electronic device101may trigger UWB communication using other communication (e.g., Bluetooth communication, BLE communication, or Wi-Fi communication) than UWB communication. The electronic device101may determine whether the retrieved external device corresponds to a configured condition, e.g., determine whether the configured condition is satisfied by a retrieved external device of the retrieved one or more external devices. The electronic device101may retrieve the external device through various communications, such as UWB communication or BLE communication, and when the distance measured by UWB communication is not correct, the electronic device101may measure the distance to the external device through a different communication. The configured condition may relate to whether at least one of a positioning angle410(e.g., whether the retrieved external device is within a positioning angle smaller than the field of view), the number of external devices (e.g., whether a number of the retrieved one or more external devices corresponds to a configured number), or a distance to an external device (e.g., whether a distance between the electronic device and the retrieved external device is a configured distance) is satisfied. The positioning angle410may be different from the UWB communication-perceivable range. For example, the positioning angle410(e.g., -10° to +10°) may be smaller than the UWB communication-perceivable range, and may be configured in the electronic device101to efficiently retrieve (or identify) an external device desired by the user. The positioning angle410may be configured based at least in part on a table generated with a distance value, an RSSI, and an SNR, and may include an azimuth and an elevation. Although the positioning angle410is conventionally fixed, the positioning angle410may be changed (or adjusted) in the disclosure.

The electronic device101may retrieve the external device in further consideration of context information in addition to the number or distance of retrieved external devices. The context information may be identifying an external device (e.g., a speaker) required for an actual service (e.g., music playback). The electronic device101may adjust an angle range in consideration of the context information.

When the retrieved external device does not satisfy the configured condition, the electronic device101may change at least one of the azimuth or the elevation of the positioning angle, e.g., adjust the positioning angle when the retrieved one or more external devices do not satisfy the configured condition, in order to re-retrieve the one or more external devices. Changing (or adjusting) the positioning angle410may be for filtering external devices until only a predetermined number of external devices is retrieved when a plurality of external devices is retrieved, or for re-retrieving an external device.

For example, to transmit data to an external device, at least one external device needs to be retrieved, and thus the electronic device101may determine that the configured condition is satisfied when a configured number (e.g., one or two) of external devices included in the positioning angle410are retrieved. The configured number may be configured by the user or may be configured by default in the electronic device101. Alternatively, when the number (e.g., three or more) of external devices included in the positioning angle410exceeds the configured number (e.g., one or two), the electronic device101may determine that the configured condition is not satisfied. When any external device included in the positioning angle410is not retrieved (e.g., when the number of external devices is less than the configured number), the electronic device101may determine that the configured condition is not satisfied.

According to various embodiments, the configured number used to reduce or increase the positioning angle may vary. For example, the electronic device101may increase the positioning angle when the number of external devices included in the positioning angle410is 0, and may increase the positioning angle even when the number of external devices included in the positioning angle410is one or two.

Alternatively, when an external device included in the UWB communication-perceivable range and not included in the positioning angle410is retrieved and the distance to the retrieved external device is a configured distance (e.g., within 1 m), the electronic device101may determine that the configured condition is not satisfied. Alternatively, when an external device (e.g., the second external device403) included in the positioning angle410is retrieved and the distance to an external device (e.g., the first external device401or the third external device405) not included in the positioning angle410is the configured distance, the electronic device101may determine that the configured condition is not satisfied. Alternatively, when the distance to an external device within the positioning angle410is greater than the distance to an external device outside the positioning angle410, the electronic device101may determine that the configured condition is not satisfied.

According to various embodiments, the electronic device101may obtain (or measure) the distance to an external device to determine whether the configured condition is satisfied. Measuring the distance or angle to an external device by different method according to the foregoing UWB communication types pertains to the prior art, and thus a detailed description thereof may be omitted. Among the foregoing UWB communication types, SS-TWR, DS-TWR, UL TDoA, or DL TDoA may be capable of measuring the distance or angle to an external device. Advertisement may measure the angle with an external device, but may not be capable of distance measurement. When an external device performs UWB communication supporting distance information (e.g., at least one of SS-TWR, DS-TWR, UL TDoA, or DL TDoA), the electronic device101may measure information about the distance to the external device, based at least in part on time information included in a UWB signal, and may measure (or obtain) information about the angle (e.g., angle of arrival (AoA)) to the external device from angle information (e.g., an azimuth and/or an elevation) included in the UWB signal.

When an external device performs UWB communication not supporting distance information (e.g., the advertisement method), the electronic device101may estimate (or calculate) the distance to the external device, based at least in part on signal strength (e.g., RSSI or SNR information) included in a UWB signal. The electronic device101may estimate (or calculate) the distance to the external device, based at least in part on a Friis formula (e.g., Friis’s path loss formula).

PR (dBm) may denote the signal strength (e.g. RSSI or SNR) of the received UWB signal, PT (dBm) may denote transmitted power, G (dB) may denote the gain of a UWB antenna (e.g., UWB antenna 1221or UWB antenna 2223ofFIG.2), L (dB) may denote a path loss, c may denote the speed of light (2.99792458 x 108 m/s), fc may denote the center frequency of a channel, and d may denote the distance between the electronic device101and the external device.

The electronic device101may also estimate the distance to the external device, based at least in part on the signal strength included in the UWB signal, through an equation other than the Friis formula.

When the retrieved external device satisfies the configured condition, the electronic device101may display the retrieved external device on a display (e.g., the display module160ofFIG.1) (e.g., perform an operation related to the retrieved external device when the retrieved external device satisfies the configured condition). The electronic device101may display a user interface including information (e.g., a name (e.g., product name), a serial number, and a distance) about the external device on the display module160. The user may select the displayed external device and may transmit data to the selected external device. For data transmission, Bluetooth or Wi-Fi may be used.

When the retrieved external device does not satisfy the configured condition, the electronic device101may change the positioning angle410. For example, when there is no external device included in the positioning angle410, or when an external device not included in the positioning angle is retrieved and the distance to the retrieved external satisfies the configured distance, the electronic device101may increase or reduce the positioning angle410by stages. For example, the electronic device101may increase the positioning angle410by applying a first offset to the positioning angle410. Alternatively, when the number of external devices included in the positioning angle410exceeds the configured number, the electronic device101may reduce the positioning angle410by applying a second offset to the positioning angle410.

Alternatively, the electronic device101may adjust (e.g., increase or reduce) the positioning angle410, based at least in part on the distance to an external device. For example, when an external device included in the positioning angle410is retrieved and the distance to an external device not included in the positioning angle410corresponds to the configured distance, the electronic device101may adjust the positioning angle410, based at least in part on the distance to the external device. Alternatively, the electronic device101may change the positioning angle410differently for each external device. For example, when the distance to an external device within the positioning angle410is greater than the distance to an external device outside the positioning angle410, the electronic device101may adjust the positioning angle.

According to various embodiments, when pieces of angle information (e.g., azimuths and/or elevations) about at least two external devices are similar within a configured reference value, the electronic device101may request a change of the location of the electronic device101. The electronic device101may provide a user interface for requesting a change of the location (or angle) of the electronic device101. The electronic device101may request the change of the location of the electronic device101using at least one of text, an image, a video, or a voice. When the user changes the location of the electronic device101according to a location change request, the electronic device101may receive a UWB signal from an external device and may determine whether the configured condition is satisfied, based at least in part on the received UWB signal. The electronic device101may provide a user interface for selecting the external device, may adjust the positioning angle410, or may request a change of the location of the electronic device101according to the determination result.

An electronic device (e.g., the electronic device101ofFIG.1) according to various embodiments of the disclosure may include a display (e.g., the display module160ofFIG.1), a communication module (e.g., the communication module190ofFIG.1), a memory (e.g., the memory130ofFIG.1), and a processor (e.g., the processor120ofFIG.1) operatively connected to at least one of the display, the communication module, or the memory, wherein the processor may be configured to perform ultra-wideband (UWB) communication through the communication module, retrieve at least one external device corresponding to a perceivable range of the UWB communication, based at least in part on the UWB communication, determine whether a configured condition including at least one of whether the retrieved external device is within a positioning angle smaller than the perceivable range, whether a number of retrieved external devices corresponds to a configured number, or whether a distance between the electronic device and the retrieved external device is a configured distance is satisfied, perform an operation related to the retrieved external device when the retrieved external device corresponds to the configured condition, and re-retrieve an external device by changing the positioning angle when the retrieved external device does not correspond to the configured condition.

According to an embodiment, the positioning angle may be configured based at least in part on a table generated with a distance value, an RSSI, and an SNR, and may include an azimuth and an elevation, and the processor may be configured to change at least one of the azimuth or the elevation of the positioning angle when the retrieved external device does not correspond to the configured condition.

According to an embodiment, the processor may be configured to increase the positioning angle when the number of retrieved external devices does not correspond to the configured number, and reduce the positioning angle when the number of retrieved external devices exceeds the configured number, and the configured number used to increase or reduce the positioning angle may be configured to be the same or different.

According to an embodiment, the processor may be configured to determine that the retrieved external device satisfies the configured condition when the retrieved external device is within the positioning angle and the number of retrieved external devices within the positioning angle corresponds to the configured number.

According to an embodiment, the processor may be processor is configured to determine that the retrieved external device does not satisfy the configured condition when the retrieved external device is not within the positioning angle and the distance between the electronic device and the retrieved external device corresponds to the configured distance.

According to an embodiment, the processor may be configured to determine that the configured condition is not satisfied when a distance of a first external device within the positioning angle is longer than a distance of a second external device outside the positioning angle.

According to an embodiment, the processor may be configured to obtain information about the distance to the retrieved external device by a different method depending on a type of the UWB communication.

According to an embodiment, the processor may be configured to perform the UWB communication when receiving a data transmission request from a user.

According to an embodiment, the processor may be configured to adjust the positioning angle in further consideration of context information about the electronic device, and select one of the at least one retrieved external device within the positioning angle, and the context information may be generated based at least in part on an application executed in the electronic device.

According to an embodiment, the processor may be configured to adjust the positioning angle, based at least in part on a distance to a second external device when a first external device within the positioning angle is identified and the distance to the second external device not within the positioning angle corresponds to the configured distance.

According to an embodiment, the processor may be configured to change the positioning angle differently corresponding to a first external device and a second external device when a distance of the first external device within the positioning angle is longer than a distance of the second external device outside the positioning angle.

According to an embodiment, the processor may be configured to request a change of a location of the electronic device when two or more external devices are retrieved, pieces of angle information between the electronic device and the two or more retrieved external devices are similar within a configured reference value, receive a UWB signal from the two or more retrieved external devices as detecting the change of the location of the electronic device, and determine whether the configured condition is satisfied, based at least in part on the received UWB signal.

According to an embodiment, the processor may be configured to increase the positioning angle by applying a first offset to the positioning angle when the retrieved external device is not within the positioning angle, reduce the positioning angle by applying a second offset to the positioning angle when the number of retrieved external devices within the positioning angle exceeds the configured number, and identify whether the configured condition is satisfied by repeating an operation of applying the first offset or the second offset to the positioning angle a specified number of times.

FIG.5is a flowchart500illustrating an operating method of an electronic device according to various embodiments.

Referring toFIG.5, the electronic device (e.g., the electronic device101ofFIG.1) according to various embodiments may retrieve an external device through UWB communication, may determine whether the retrieved external device satisfies a configured condition (whether the external device is retrieved within a positioning angle, the number of retrieved external devices, a distance to the external device, and/or context information), and may perform an operation related to the retrieved external device when the configured condition is satisfied, or may change (e.g., increase or reduce) the positioning angle when the configured condition is not satisfied.

In operation501, a processor (e.g., the processor120ofFIG.1) of the electronic device101may perform UWB communication through a communication module (e.g., the communication module190ofFIG.1or the UWB module220ofFIG.2). The processor120may use communication other than UWB communication to establish UWB communication with an external device. For example, the processor120may broadcast a message including UWB configuration information through a BLE module (e.g., the BLE module210ofFIG.2). Alternatively, the processor120may perform UWB communication by exchanging information necessary to establish UWB communication through an operation, such as accessing an access point (AP) at a specific location. Since the message is broadcast, the message may be transmitted to an external device (e.g., the first external device401to the third external device405ofFIG.4) existing near the electronic device101. The UWB configuration information may include whether the electronic device101supports UWB communication or a UWB communication type. For example, when the electronic device101supports UWB communication, the processor120may configure the UWB communication support information to 1, and when the electronic device101does not support UWB communication, the processor120may configure the UWB communication support information to 0. The UWB communication type may include at least one of SS-TWR, DS-TWR, advertisement, UL TDoA, or DL TDoA.

The processor120may receive a response to the message from at least one external device. The response may include whether the at least one external device supports UWB communication or a UWB communication type (or method). The processor120may establish UWB communication with the at least one external device, based at least in part on the response received from the at least one external device. When the UWB communication is completely established, the processor120may activate the UWB communication (e.g., activate (or turn on) the RX module of the UWB module220), thereby performing the UWB communication with the at least one external device. According to an embodiment, the electronic device101may periodically broadcast the message including the UWB configuration information for a predetermined time or a predetermined number of times or more, and may perform the UWB communication with the at least one external device when receiving a response message from the at least one external device.

According to various embodiments, when the UWB communication type is SS-TWR or DS-TWR, the electronic device101may establish UWB communication using BLE or Wi-Fi before activating the RX module of the UWB module220. When the UWB communication type is advertisement, UL TDoA, or DL TDoA, the electronic device101may start UWB communication using a predefined (or pre-agreed) configuration.

In operation503, the processor120may retrieve at least one external device corresponding to a UWB communication-perceivable range. The processor120may retrieve an external device included in the UWB communication-perceivable range (e.g., a field of view (FoV)), based at least in part on a UWB signal received from the at least one external device. The UWB signal may correspond to a poll, a response, a final, or an advertisement. The UWB signal may include at least one of time information, a timestamp, angle information (e.g., an azimuth and an elevation), an RSSI, SNR information, or a transmit power (e.g., TX power).

For example, when the UWB communication type is SS-TWR, the time information may include at least one of a time when a poll message is received, a time when a response message is transmitted, or a processing time required to receive the poll message and to transmit the response message. The processor120may measure the distance to the at least one external device, based at least in part on the time information. The processor120may retrieve an external device included in the UWB communication-perceivable range (e.g., -60° to +60°) corresponding to the front of the electronic device101.

According to various embodiments, the processor120may retrieve the external device included in the UWB communication-perceivable range for a configured time or a configured number of times. When a UWB signal transmitted from an external device not located in front of the electronic device101is reflected by an obstacle (e.g., a wall or an object) and received by the electronic device101, the processor120may determine that the UWB signal is transmitted from the front. For example, the first external device401may exist behind the electronic device101, and the second external device403may exist in front of the electronic device101. When a UWB signal transmitted from the first external device401is reflected by a wall and received by the electronic device101, the processor120may determine that the first external device401exists in front of the electronic device101. To mitigate the effect of reflected signals, the processor120may retrieve the external device included in the UWB communication-perceivable range for the configured time or the configured number of times.

In operation505, the processor120may determine whether the retrieved external device satisfies a configured condition including at least one of whether the retrieved external device is included in a positioning angle smaller than the perceivable range, whether the number of retrieved external devices corresponds to a configured number, or whether the distance between the electronic device101and the retrieved external device is a configured distance. The configured condition may relate to whether at least one of the positioning angle, the number of external devices, or the distance to an external device is satisfied. The positioning angle may be different from the UWB communication-perceivable range, and may be, for example, smaller than the UWB communication-perceivable range.

The positioning angle may be configured based at least in part on a table generated with a distance value, an RSSI, and an SNR, and may include an azimuth (e.g., a horizontal angle) and an elevation (e.g., a vertical angle). The positioning angle may be configured such that the azimuth and the elevation have the same range, or the azimuth or the elevation may be separately configured. Although the positioning angle is conventionally fixed, the positioning angle may be changed (or adjusted) in the disclosure. When the positioning angle is changed, the processor120may change at least one of the azimuth or the elevation of the positioning angle.

According to an embodiment, when only one of the azimuth or the elevation needs to be identified, the processor120may retrieve an external device, based at least in part on the azimuth. However, when two or more external devices dynamically exist at the positioning angle, the processor120may identify azimuth distribution and elevation distribution of the two external devices, and may identify a wider distribution. Alternatively, the processor120may identify a conical range by identifying the azimuth and the elevation.

When a configured number (e.g., one or two) of external devices included in the positioning angle are retrieved, the processor120may determine that the configured condition is satisfied. The configured number may be configured by a user, or may be configured by default in the electronic device101. The context information may be identifying an external device (e.g., a speaker) required for an actual service (e.g., music playback).

According to various embodiments, when the number of external devices included in the positioning angle exceeds the configured number, the processor120may determine that the configure condition is not satisfied. Alternatively, when an external device included in the UWB communication-perceivable range and not included in the positioning angle is retrieved and the distance to the retrieved external device is the configured distance (e.g., within 1 m), the processor120may determine that the configured condition is not satisfied. Alternatively, when an external device included in the positioning angle is retrieved and the distance to an external device not included in the positioning angle is the configured distance, the processor120may determine that the configured condition is not satisfied. Alternatively, when the distance to an external device within the positioning angle410is greater than the distance to an external device outside the positioning angle410, the processor120may determine that the configured condition is not satisfied.

According to various embodiments, the angle information (e.g., the azimuth and/or elevation) may have a significant value when a UWB antenna (e.g., UWB antenna 1221or UWB antenna 2223ofFIG.2) included in the electronic device101faces an external device. The processor120may measure the slope of the electronic device101, based at least in part on sensor data obtained through an acceleration sensor or a gyro sensor (e.g., the sensor module176ofFIG.1) included in the electronic device101, and may use the slope of the electronic device101for reference when obtaining the angle information (e.g., the azimuth and/or elevation).

According to various embodiments, the processor120may analyze an image obtained through a camera (e.g., the camera module180ofFIG.1) included in the electronic device101, thereby determining whether the external device corresponds to the configured condition. Alternatively, the processor120may determine whether the external device corresponds to the configured condition in consideration of the angle of view of the camera module180along with the analyzed image. When the external device is included in a preview image obtained from the camera module180, the processor120may determine that the external device corresponds to the configured condition.

The processor120may select at least one external device in further consideration of context information of the electronic device101in addition to the positioning angle, the number, or the distance. The context information may be generated based at least in part on an application executed in the electronic device. The processor120may select an external device corresponding to an application being executed in the electronic device101. For example, when playing music in the electronic device101, the processor120may select a speaker when a TV, the speaker, and an air conditioner are retrieved as external devices.

When at least one of whether the retrieved external device is included in the positioning angle smaller than the perceivable range, whether the number of retrieved external devices corresponds to the configured number, or whether the distance between the electronic device and the retrieved external device is the configured distance is satisfied, the processor120may perform an operation associated with the retrieved external device in operation507. For example, when one external device is retrieved, the processor120may execute a function interworking with the retrieved external device, may display an application screen, or may access a site. For example, when only a TV is selected as the retrieved external device, the processor120may drive and display a TV remote control application. Alternatively, when an electronic board is selected and a product/menu is displayed on the electronic board, the processor120may execute and display a URL for ordering the product.

Alternatively, the processor120may display a user interface including information (e.g., a name (e.g., product name), a serial number, and/or a distance) about the external device on a display (e.g., the display module160). When there is a plurality of external devices to be displayed, the processor120may display only a configured number of external devices by configuring a high priority in order of closeness to the electronic device101or closeness to a reference angle (e.g., 0°). Alternatively, the processor120may display a relative positional relationship between external devices to be displayed or a distance to the electronic device101. The user may select the displayed external device and may transmit data to the selected external device. For data transmission, Bluetooth, Wi-Fi, or UWB may be used.

When at least one of whether the retrieved external device is included in the positioning angle smaller than the perceivable range, whether the number of retrieved external devices corresponds to the configured number, or whether the distance between the electronic device and the retrieved external device is the configured distance is not satisfied, the processor120may change the positioning angle in operation509. For example, the processor120may increase or reduce the positioning angle by stages. After changing the positioning angle, the processor120may return to operation503and may re-retrieve an external device included in the changed positioning angle.

When changing the positioning angle, the processor120may change at least one of the azimuth or the elevation of the positioning angle. According to an embodiment, when two or more external devices dynamically exist at the positioning angle, the processor120may identify azimuth distribution and elevation distribution of the two external devices, and may identify a wider distribution. Alternatively, the processor120may identify a conical range by identifying the azimuth and the elevation.

When there is no external device included in the positioning angle (e.g., when an external device not included in the positioning angle is retrieved and the distance to the retrieved external device corresponds to the configured distance), the processor120may increase the positioning angle by applying a first offset to the positioning angle. Alternatively, when the number of external devices included in the positioning angle exceeds the configured number, the processor120may reduce the positioning angle by applying a second offset to the positioning angle. The positioning angle to which the first offset is applied may be greater than the positioning angle to which the second offset is applied. The processor120may repeat an operation of applying the first offset or the second offset to the positioning angle a specified number of times, thereby identifying whether the configured condition is satisfied.

According to various embodiments, the processor120may adjust (e.g., increase or reduce) the positioning angle, based at least in part on the distance to an external device. For example, when an external device included in the positioning angle is retrieved and the distance to an external device not included in the positioning angle corresponds to the configured distance, the processor120may adjust the positioning angle410, based at least in part on the distance to the external device. Alternatively, the processor120may change the positioning angle410differently for each external device. For example, when the distance to an external device within the positioning angle410is greater than the distance to an external device outside the positioning angle410, the processor120may adjust the positioning angle.

According to various embodiments, when pieces of angle information (e.g., azimuths and/or elevations) about at least two external devices are similar within a configured reference value, the processor120may request a change of the location of the electronic device101. The processor120may provide a user interface for requesting a change of the location (or angle) of the electronic device101. The user interface may be configured as at least one of text, an image, a video, or a voice. The processor120may display the user interface (e.g., text, image, and/or video) through the display module160, and may output a sound (e.g., an audio of a video and/or a voice) through a sound output module155. When the user changes the location of the electronic device101according to a location change request, the processor120may transmit a UWB signal to the external device, may receive a UWB signal from the external device, and may determine whether the configured condition is satisfied, based at least in part on the received UWB signal. The processor120may provide a user interface for selecting the external device, may adjust the positioning angle, or may request a change of the location of the electronic device101according to the determination result.

When the direction of the electronic device101is changed, a predetermined number of times, a predetermined time, a positioning angle range, an FoV, and the like which are previously identified may deviate from criteria, in which case the processor120moves to operation503and may receive a UWB signal again.

The processor120may identify whether the FoV is satisfied with respect to each retrieved external device, may identify whether each retrieved external device is retrieved five times or more, may calculate a variance in each of the azimuth/elevation of each retrieved external device when each retrieved external device is retrieved five times or more, may update the last identification time of each retrieved external device, and may update each retrieved external device to “pointing being made” when sensor information from the electronic device101is received five times or more, the pitch of the electronic device101ranges between -115° and -45°, and the variance is less than 5. When the last identification time of an external device exceeds five seconds, the processor120may delete the external device from a selection candidate list.

When pointing is being made, the FoV is satisfied, an azimuth and an elevation are 10 degrees or less, and variances in the azimuth and the elevation are less than 5 with respect to retrieved external devices, the processor120may add the retrieved external devices to a first selection candidate list. When pointing is being made, the FoV is satisfied, an azimuth and an elevation are 10 degrees ± value predetermined for each RSSI signal or less, and variances in the azimuth and the elevation are less than 5 with respect to retrieved external devices, the processor120may add the retrieved external devices to a second selection candidate list.

The processor120may arrange the sum of the absolute values of azimuth and elevation of external devices in the first selection candidate list and the second selection candidate list in ascending order, and may arrange RSSI values in descending order when the sums are the same. When only one retrieved external device is included in the first selection candidate list, the processor120may select the retrieved external device, and when two or more retrieved external devices are included, the processor120may select an arranged first external device and an arranged second external device. When there is no retrieved external device in the first selection candidate list, if only one retrieved external device is included in the second selection candidate list, the processor120may select the retrieved external device, and if two or more retrieved external devices are included, the processor120may select an arranged first external device and an arranged second external device. The processor120may identify data transmitted from a selected external device, and may perform an associated operation. For example, the processor120may execute a remote control application, or may access a URL.

FIG.6AtoFIG.6Dillustrate examples in which an electronic device retrieves an external device according to various embodiments.

FIG.6Aillustrates an example in which an electronic device retrieves an external device corresponding to a configured condition.

Referring toFIG.6A, a processor (e.g., the processor120ofFIG.1) of the electronic device (e.g., the electronic device101ofFIG.1) according to various embodiments may retrieve at least one external device performing UWB communication, and may determine whether the retrieved external device satisfies a configured condition. The external device may be referred to as an external electronic device, a target device, or a peripheral device. For example, the external device may be an Internet of Things (IoT) device, such as a refrigerator, a washing machine, a TV, a set-top box, a printer, or a scanner. The configured condition may relate to whether at least one of a positioning angle, the number of external devices, or a distance to an external device is satisfied.

When the external device is included in the positioning angle θ and the number of external devices included in the positioning angle θ is a configured number (e.g., one or two), the processor120may determine that the configured condition is satisfied. Referring to a first reference numeral610, when a first external device601corresponds to the configured condition, the processor120may select the first external device601. Alternatively, when the first external device601is included in the positioning angle θ, the processor120may provide a user interface630for selecting the first external device601.

Referring to a second reference numeral620, the processor120may retrieve the first external device601, a second external device603, and a third external device605which are included in a UWB communication-perceivable range (e.g., the front of the electronic device101). Referring to the second reference numeral620, the processor120may retrieve the second external device603included in the positioning angle θ among the retrieved external devices (e.g., the first external device601to the third external device605), and may determine that the configured condition is satisfied when the number of external devices included in the positioning angle θ is the configured number. Referring to the second reference numeral620, when the second external device603corresponds to the configured condition, the processor120may select the second external device603. Alternatively, when the second external device603is included in the positioning angle θ, the processor120may provide the user interface630for selecting the second external device603.

FIG.6Billustrates an example in which an electronic device changes a positioning angle when an external device does not correspond to a configured condition.

Referring toFIG.6B, a processor120may retrieve at least one external device performing UWB communication, and may determine whether the retrieved external device satisfies a configured condition. The processor120may retrieve a first external device601and a second external device603included in a UWB communication-perceivable range (e.g., the front of the electronic device101). The first external device601and the second external device603may be included in the UWB communication-perceivable range. The first external device601may not be included in a positioning angle θ, and the second external device603may be included in the positioning angle θ. When the two external devices are included within the UWB communication-perceivable range, since the external devices are at different distances, the processor120may perform re-retrieval by applying a narrower angle than a reference to the second external device603and applying a wide angle than the reference to the first external device601.

Since a user does not know the location of a UWB antenna included in the electronic device101or the first external device601, even though pointing to the location where the first external device601actually exists, the first external device601may not be included in the positioning angle θ. Referring to a third reference numeral650and a fourth reference numeral660, position A of the first external device601may be a position at which a UWB signal is output from the first external device601. Referring to the third reference numeral650and the fourth reference numeral660, position B of the second external device603may be a position at which a UWB signal is output from the second external device603.

When an antenna of the first external device601is disposed toward one side, the processor120may recognize the first external device601being toward one side and may correct the positioning angle. In addition to angle correction, the processor120may select an external device using context information, or may compare information of an external device in the UWB communication-perceivable range and information of an external device included in the positioning angle.

Referring to the third reference numeral650, the processor120may select only the first external device601. Referring to the fourth reference numeral660, the processor120may select both the first external device601and the second external device603, and the user may select one of the first external device601and the second external device603.

FIG.6Cillustrates an example in which an electronic device controls a positioning angle when an external device does not correspond to a configured condition.

Referring toFIG.6C, a processor120may retrieve at least one external device performing UWB communication, and may determine whether the retrieved external device satisfies a configured condition. Referring to a fifth reference numeral670, the processor120may retrieve a first external device601, a second external device603, and a third external device605included in a positioning angle θ. Referring to the fifth reference numeral670, when the number of external devices included in the positioning angle θ does not correspond to a configured number, the processor120may determine that the configured condition is not satisfied. When the number of external devices included in the positioning angle θ exceeds the configured number (670), the processor120may control (or change) the positioning angle θ. The processor120may decrease (or reduce) the positioning angle θ by applying a second offset to the positioning angle θ.

Referring to a sixth reference numeral680, after changing the positioning angle θ, the processor120may retrieve the second external device603within the changed positioning angle θ′. When the second external device603is included in the changed positioning angle θ′ and the number of external devices included in the changed positioning angle θ′ is the configured number (e.g., one or two), the processor120may determine that the configured condition is satisfied. Referring to the sixth reference numeral680, when the second external device603corresponds to the configured condition, the processor120may select the second external device603.

FIG.6Dillustrates an example in which an electronic device changes a positioning angle when an external device does not correspond to a configured condition.

Referring toFIG.6D, a processor120may retrieve at least one external device performing UWB communication, and may determine whether the retrieved external device satisfies a configured condition. Referring to a seventh reference numeral690, the processor120may retrieve a first external device601and a second external device603included in a UWB communication-perceivable range (e.g., the front of the electronic device101). The first external device601and the second external device603may be included in the UWB communication-perceivable range, but may not be included in a positioning angle θ. When an external device is not included in the positioning angle θ, the processor120may increase the positioning angle θ.

Referring to an eighth reference numeral695, after changing the positioning angle θ, the processor120may retrieve the first external device601and the second external device603within the changed positioning angle θ′. Referring to the eighth reference numeral695, when the first external device601and the second external device603are included in the changed positioning angle θ′ and the number of external devices included in the changed positioning angle θ′ is a configured number (e.g., two), the processor120may determine that the configured condition is satisfied. Referring to the eighth reference numeral695, when the first external device601and the second external device603correspond to the configured condition, the processor120may select the first external device601and the second external device603. For example, the processor120may provide a user interface (not shown) for selecting the first external device601and the second external device603.

FIG.7is a flowchart700illustrating a positioning angle adjustment method of an electronic device according to various embodiments.

Referring toFIG.7, in operation701, a processor (e.g., the processor120ofFIG.1) of the electronic device (e.g., the electronic device101ofFIG.1) according to various embodiments may identify the UWB communication type of the external device. The external device refers to a first external device401, a second external device403, or a third external device405ofFIG.4, and may be a device that performs UWB communication with the electronic device101. The processor120may identify a configured UWB communication type when establishing UWB communication with the external device. The UWB communication type may include at least one of SS-TWR, DS-TWR, advertisement, UL TDoA, or DL TDoA.

According to various embodiments, when the UWB communication type is SS-TWR or DS-TWR, the processor120may establish UWB communication using BLE or Wi-Fi before activating an RX module of a UWB module220. When the UWB communication is completely established, the processor120may activate the UWB communication, thereby performing the UWB communication with the at least one external device. When the UWB communication type is advertisement, UL TDoA, or DL TDoA, the processor120may start UWB communication using a predefined (or pre-agreed) configuration.

In operation703, the processor120may determine whether measurement of the distance to the external device is possible, based at least in part on the identified UWB communication type. For example, among the UWB communication types, SS-TWR, DS-TWR, UL TDoA, or DL TDoA may enable measurement of the distance or angle with an external device. Advertisement enables measurement of the angle with an external device, but may not enable measurement of the distance.

When the UWB communication type of the external device corresponds to a type not supporting distance information (e.g., advertisement), the processor120may determine that the measurement of the distance is not possible. When the measurement of the distance to the external device is impossible, the processor120may perform operation705. When the UWB communication type of the external device corresponds to a type supporting distance information (e.g., any one of SS-TWR, DS-TWR, UL TDoA, or DL TDoA), the processor120may determine that the measurement of the distance is possible. When the measurement of the distance to the external device is possible, the processor120may perform operation709.

When the measurement of the distance is impossible, the processor120may infer the distance to the external device, based at least in part on a UWB signal in operation705. The processor120may obtain or estimate and support the distance to the external device through communication with a device providing a relative or absolute location, such as Bluetooth, Wi-Fi, Radar, and an indoor GPS. When the UWB communication type is a type not supporting distance information, the UWB signal may include at least one of a timestamp, angle information (e.g., an azimuth and/or an elevation), an RSSI, SNR information (e.g., a first SNR, a main SNR, and a total SNR), or a transmit power (e.g., TX Power).

When the UWB communication type is a type not supporting distance information, the processor120may estimate (or calculate) the distance to the external device, based at least in part on signal strength (e.g., RSSI or SNR information) included in the UWB signal. The processor120may infer the distance to the external device, based at least in part on a Friis formula (e.g., Friis’s path loss formula). Since a time difference occurs in received timestamp according to a difference in distance from each external device, the processor120may infer the distance to the external device, based at least in part on the time difference in the received timestamp.

To measure the distance using a timestamp, time synchronization between the electronic device101and the external device needs to be performed first. However, in a type not supporting distance information, the electronic device101only receives a UWB signal from the external device and cannot transmit a UWB signal thereto, making it difficult to achieve time synchronization. When the UWB communication type is a type not supporting distance information, the processor120may estimate the distance to the external device, based at least in part on the signal strength included in the UWB signal. According to various embodiments, the processor120may control (or change or adjust) a measurement angle, based at least in part on the signal strength without estimating the distance through the signal strength.

When the measurement of the distance is possible, the processor120may measure the distance to the external device, based at least in part on the UWB signal in operation709. When the UWB communication type is a type supporting distance information (e.g., SS-TWR or DS-TWR), the UWB signal may include at least one of time information, angle information (e.g., an azimuth and an elevation), an RSSI, SNR information, or a transmit power. When the UWB communication type is SS-TWR, the time information may include at least one of a time when a poll message is received, a time when a response message is transmitted, or a processing time required to receive the poll message and to transmit the response message. The processor120may measure the distance to the external device, based at least in part on a time in which the external device receives a poll message and transmits a response message.

When the UWB communication type is a type supporting distance information (e.g., UL TDoA or DL TDoA), the UWB signal may include at least one of a timestamp, angle information (e.g., an azimuth and an elevation), an RSSI, SNR information, or a transmit power. The processor120may measure the distance to the external device, based at least in part on the timestamp included in the UWB signal. The timestamp may include time information about transmission of the UWB signal or reception of the UWB signal.

In operation707, the processor120may adjust a positioning angle, based at least in part on the distance information. The positioning angle is different from a UWB communication-perceivable range, and may be, for example, may be smaller than the UWB communication-perceivable range. The positioning angle may include an azimuth (e.g., a horizontal angle) and an elevation (e.g., a vertical angle). The positioning angle may be configured such that the azimuth and the elevation have the same range, or the azimuth or the elevation may be separately configured. When the positioning angle is changed, the processor120may change at least one of the azimuth or the elevation of the positioning angle. The processor120may adjust the positioning angle differently, based at least in part on the distance to the external device.

For example, when the distance to the external device is a first distance, the processor120may change the positioning angle by applying a first offset. When the distance to the external device exceeds the first distance and is less than or equal to a second distance, the processor120may change the positioning angle by applying a second offset. When the distance to the external device exceeds the second distance, the processor120may change the positioning angle by applying a third offset. The first offset to the third offset may be different angles. The first offset may have the narrowest angle range, and the third offset may have the widest angle range. The processor120may repeat an operation of applying the first offset to the third offset to the positioning angle a specified number of times, thereby identifying whether a configured condition is satisfied.

For example, to transmit data to an external device, at least one external device may need to be retrieved. When an external device included in the positioning angle is not retrieved or a retrieved external device does not satisfy the configured condition, the processor120may adjust the positioning angle. The processor120may differently adjust the adjustment range or frequency of the positioning angle, based at least in part on the distance to the external device. For example, the processor120may adjust the positioning angle to a first angle (e.g., -10° to 10°) when the external device is at a distance of 50 cm, may adjust the positioning angle to a second angle (e.g., -20° to 20°) when the external device is at a distance of 1 m, and may adjust the positioning angle to a third angle (e.g., -30° to 30°) when the external device is at a distance of 10 m. Further, when external devices at different distances are in the same angle range, the processor120may request a change of the location of the electronic device according to angle information (e.g., an azimuth and/or an elevation) or distance information of the external devices, or a user may select one external device.

FIG.8AtoFIG.8Cillustrate correlations between signal strength and a distance according to various embodiments.FIG.8AtoFIG.8Cshow results obtained when the Friis formula is actually measured, and when a UWB communication method by which a distance cannot be obtained is used, a distance may be estimated based at least in part on this formula.

FIG.8Ais a table810showing a correlation between signal strength and a distance.

Referring toFIG.8A, the table810may be divided into indoor values or outdoor values. Indoors or outdoors, correlations between signal strength (e.g., an SNR and an RSSI) and a distance may be the same or similar. For example, as the signal strength increases, the distance between an electronic device (e.g., the electronic device101ofFIG.1) and an external device (e.g., the first external device401ofFIG.4) decreases.

FIG.8Bis a graph illustrating a correlation between signal strength and a distance.

Referring toFIG.8B, a first graph830illustrates a correlation between an SNR and the distance. As the SNR increases, the distance between the electronic device101and the first external device401decreases. The first graph830shows a main SNR and a total SNR in the table810, and the main SNR and the total SNR have similar patterns such that the values thereof decrease as the distance increases. A second graph850illustrates a correlation between an RSSI and the distance. As the RSSI increases, the distance between the electronic device101and the first external device401decreases.

FIG.8Cis a graph illustrating a correlation between signal strength and a distance.

Referring toFIG.8C, a third graph870illustrates a correlation between an SNR and the distance. As the SNR increases, the distance between the electronic device101and the first external device401decreases. The third graph870shows a main SNR and a total SNR in the table810, and the main SNR and the total SNR have similar patterns such that the values thereof decrease as the distance increases. A fourth graph890illustrates a correlation between an RSSI and the distance. As the RSSI increases, the distance between the electronic device101and the first external device401decreases.

FIG.9is a flowchart900illustrating a method for selecting or re-retrieving an external device by an electronic device according to various embodiments.FIG.9may specify operation505and operation507ofFIG.5.

Referring toFIG.9, in operation901, a processor (e.g., the processor120ofFIG.1) of the electronic device (e.g., the electronic device101ofFIG.1) according to various embodiments may determine whether an external device is included in a positioning angle. The positioning angle may be smaller than a UWB communication-perceivable range corresponding to the front of the electronic device101. The positioning angle may be configured based at least in part on a table generated with a distance value, an RSSI, and an SNR, and may include an azimuth (e.g., a horizontal angle) and an elevation (e.g., a vertical angle). The positioning angle may be configured such that the azimuth and the elevation have the same range, or the azimuth or the elevation may be separately configured. When the positioning angle is changed, the processor120may change at least one of the azimuth or the elevation of the positioning angle. The processor120may determine whether there is an external device included in the positioning angle among external devices retrieved to be included in the UWB communication-perceivable range. Operation901may be performed when at least one external device is retrieved within the UWB communication-perceivable range.

The processor120may perform operation903when the external device is included in the positioning angle, and may perform operation902when the external device is not included in the positioning angle.

When the external device is included in the positioning angle, the processor120may determine whether the number of external devices included in the positioning angle is a configured number in operation903. For a user to transmit data through the electronic device101, at least one external device may need to be retrieved. The configured number may be configured by the user, or may be configured by default in the electronic device101.

When the number of external devices included in the positioning angle is the configured number, the processor120may perform operation905, and when the number of external devices included in the positioning angle is not the configured number, the processor120may perform operation904.

When the number of external devices included in the positioning angle is the configured number, the processor120may perform an operation related to the retrieved external device in operation905. For example, when there is only one retrieved external device, the processor120may execute a function interworking with the retrieved external device, may display an application screen, or may access a site. For example, when only a TV is selected as the retrieved external device, the processor120may drive and display a TV remote control application. Alternatively, when an electronic board is selected and a product/menu is displayed on the electronic board, the processor120may execute and display a URL for ordering the product.

According to various embodiments, the processor120may display the retrieved external device on a display (e.g., the display module160ofFIG.1). When the number of external devices included in the positioning angle is the configured number, the processor120may determine that the retrieved external device satisfies (or corresponds to) a configured condition. When the retrieved external device satisfies the configured condition, the processor120may provide a user interface for selecting an external device. The processor120may display a user interface including information (e.g., a name (e.g., product name), a serial number, and/or a distance) about the external device on the display module160.

The processor120may select an external device, based at least in part on a user input. For example, when there is one retrieved external device, the user may select the retrieved external device. Alternatively, when the number of retrieved external devices exceeds one, the user may select any one external device from an external device list. The processor120may transmit data requested by the user to the selected external device. For data transmission, Bluetooth or Wi-Fi may be used. According to an embodiment, when there is one retrieved external device, the processor120may execute or perform a program or function agreed with the selected device without displaying the external device list. According to an embodiment, the user may request re-retrieval instead of selecting an external device.

When the external device is not included in the positioning angle, the processor120may change the positioning angle by applying a first offset in operation902. The processor120may change the positioning angle in various manners, for example, sequentially change the positioning angle or changing a unit of changed value (e.g., 10° -> 8° -> 5°). The processor120may change at least one of the azimuth and the elevation of the positioning angle. The retrieved external device may be included in the UWB communication-perceivable range, but may not be included in the positioning angle. In this case, the processor120may increase the positioning angle by applying the first offset to the positioning angle so that the external device not included in the positioning angle is retrieved. The increased positioning angle (e.g., a second positioning angle) may be greater than the previous positioning angle (e.g., a first positioning angle). After changing the positioning angle, the processor120may perform operation909.

When the number of external devices is not the configured number, the processor120may change the positioning angle by applying a second offset in operation904. The processor120may change at least one of the azimuth and the elevation of the positioning angle. The processor120may change the positioning angle in various manners, for example, sequentially change the positioning angle or changing a unit of changed value (e.g., 10° -> 8° -> 5°). The number of external devices included in the positioning angle may be greater than the configured number. In this case, the processor120may reduce the positioning angle to reduce the number of external devices included in the positioning angle. The processor120may reduce the positioning angle by applying the second offset to the positioning angle. The reduced positioning angle (e.g., a third positioning angle) may be smaller than the previous positioning angle (e.g., the first positioning angle). The positioning angle after which the first offset is applied may be greater than the positioning angle after which the second offset is applied. After changing the positioning angle, the processor120may perform operation909. Alternatively, the processor120may determine one external device among previously retrieved external devices instead of performing re-retrieval.

In operation909, the processor120may re-retrieve an external device, based at least in part on the changed positioning angle. The external device may or may not be included in the previous positioning angle. An external device not retrieved in operation901may be retrieved in the positioning angle changed in operation902. Alternatively, the external device retrieved in operation901may not be retrieved in the positioning angle changed in operation904. After performing operation909, the processor120may return to operation901and may determine whether the external device retrieved based at least in part on the changed positioning angle satisfies the configured condition (e.g., operation901and operation903). According to an embodiment, the processor120may repeat an operation of re-retrieving an external device (e.g., an operation of changing the positioning angle (e.g., operation902or operation904) and an operation of determining whether an external device retrieved based at least in part on the changed positioning angle satisfies the configured condition (e.g., operation901and operation903)) a given number of times.

FIG.10is a flowchart1000illustrating a method for changing a positioning angle according to a distance by an electronic device according to various embodiments.FIG.10may be performed when an external device does not correspond to a configured condition.

Referring toFIG.10, in operation1001, a processor (e.g., the processor120ofFIG.1) of the electronic device (e.g., the electronic device101ofFIG.1) according to various embodiments may obtain distance information of an external device. To this end, the processor120may perform the operations ofFIG.7. For example, the processor120may identify the UWB communication type of the external device and may obtain the distance information using different methods according to the identified UWB communication type. When establishing UWB communication with the external device, the processor120may identify the type of the established UWB communication. The UWB communication type may include at least one of SS-TWR, DS-TWR, advertisement, UL TDoA, or DL TDoA.

According to various embodiments, among the UWB communication types, SS-TWR, DS-TWR, UL TDoA, or DL TDoA may enable measurement of the distance or angle with the external device. Advertisement enables measurement of the angle with the external device, but may not enable measurement of the distance. When the UWB communication type of the external device corresponds to a type not supporting distance information (e.g., advertisement), the processor120may determine that distance measurement is not possible. When distance measurement of the external device is impossible, the processor120may estimate (or calculate) the distance to the external device, based at least in part on signal strength (e.g., RSSI or SNR information) included in a UWB signal. When the UWB communication type is a type supporting distance information (e.g., SS-TWR or DS-TWR), the processor120may measure the distance to the external device, based at least in part on time information included in the UWB signal. When the UWB communication type is a type supporting distance information (e.g., UL TDoA or DL TDoA), the processor120may measure the distance to the external device, based at least in part on a timestamp included in the UWB signal.

In operation1003, the processor120may determine whether the distance information of the external device is within a first distance. The processor120may perform operation1005when the distance information of the external device is within the first distance, and may perform operation1011when the distance information of the external device is not within the first distance (e.g., exceeds the first distance).

When the distance information of the external device is within the first distance, the processor120may change a positioning angle by applying a first offset in operation1005. The first distance may be the shortest distance for changing the positioning angle. The processor120may increase or reduce the positioning angle by applying the first offset. A positioning angle after which the first offset is applied (e.g., a second positioning angle) may be greater or smaller than the previous positioning angle (e.g., a first positioning angle). For example, when the retrieved external device is not included in the positioning angle, the positioning angle may be increased by applying the first offset. When the retrieved external device is included in the positioning angle but there is a plurality of retrieved external devices, the positioning angle may be reduced by applying the first offset. After changing the positioning angle, the processor120may perform operation1007.

When the distance information of the external device is not within the first distance (e.g., exceeds the first distance), the processor120may determine whether the distance information of the external device is within a second distance in operation1011. The second distance may refer to a distance greater than the first distance. The processor120may perform operation1013when the distance information of the external device is within the second distance, and may perform operation1015when the distance information of the external device is not within the second distance (e.g., exceeds the second distance).

When the distance information of the external device is within the second distance, the processor120may change the positioning angle by applying a second offset in operation1013. The processor120may increase or reduce the positioning angle by applying the second offset. For example, when the retrieved external device is not included in the positioning angle, the processor120may increase the positioning angle by applying the second offset. When the retrieved external device is included in the positioning angle but there is a plurality of retrieved external devices, the processor120may reduce the positioning angle by applying the second offset. The second offset may be greater than the first offset. For example, when the first offset is -3° to +3°, the second offset may be -4.5° to +4.5°. After changing the positioning angle, the processor120may perform operation1007.

When the distance information of the external device is not within the second distance (e.g., exceeds the second distance), the processor120may change the positioning angle by applying a third offset in operation1015. The processor120may increase or reduce the positioning angle by applying the third offset. For example, when the retrieved external device is not included in the positioning angle, the processor120may increase the positioning angle by applying the third offset. When the retrieved external device is included in the positioning angle but there is a plurality of retrieved external devices, the processor120may reduce the positioning angle by applying the third offset. The third offset may be greater than the second offset. For example, when the second offset is -4.5° to +4.5°, the third offset may be -7.5° to +7.5°. After changing the positioning angle, the processor120may perform operation1007.

After changing the positioning angle, the processor120may re-retrieve an external device, based at least in part on the changed positioning angle in operation1007. The processor120may change the positioning angle by applying different offsets to the positioning angle according to the distance to the external device. An external device that has not been retrieved may be retrieved in the changed positioning angle. Alternatively, the retrieved external device may not be retrieved in the changed positioning angle. The processor120may determine whether the external device retrieved based at least in part on the changed positioning angle satisfies the configured condition (e.g., operation901and operation903ofFIG.9).

The processor120may repeat the operations of applying the first offset to the third offset to the positioning angle a specified number of times, thereby identifying whether the configured condition is satisfied.

AlthoughFIG.10shows that the positioning angle is changed according to the distance, the processor120may change the positioning angle, based at least in part on the strength of a signal with an external device. The strength of the signal may include an RSSI or SNR included in a UWB signal. The processor120may estimate the distance from the signal strength and may adjust the positioning angle according to the estimated distance.

FIG.11illustrates an example in which an electronic device changes a positioning angle according to a distance according to various embodiments.

Referring toFIG.11, a first positioning angle table1110shows an example of changing a positioning angle differently, based at least in part on a distance to an external device. For example, a first positioning angle (-15° to +15°) may be configured as a default in the electronic device (e.g., the electronic device101ofFIG.1). When the distance to the external device is a first distance (e.g., less than 1 m), a processor of the electronic device101(e.g., the processor120ofFIG.1) may change the first positioning angle to a second positioning angle (-18° to +18°) by applying a first offset (e.g., -3° to +3°) to the first positioning angle. Alternatively, when the distance to the external device is a second distance (e.g., greater than 1 m and less than 3 m), the processor120may change the first positioning angle to the second positioning angle (-20° to +20°) by applying a second offset (e.g., -5° to +5°) to the first positioning angle. When the distance to the external device is a third distance (e.g., greater 3 m), the processor120may change the first positioning angle to the second positioning angle (-23° to +23°) by applying a third offset (e.g., -8° to +8°) to the first positioning angle.

A second positioning angle table1130shows an example of changing a positioning angle differently, based at least in part on the strength of a signal with the external device. The strength of the signal may include an RSSI or SNR included in a UWB signal. The processor120may change the positioning angle, based at least in part on the strength of the signal without estimating the distance from the strength of the signal. Although the table illustrates the RSSI, the SNR may equally or similarly apply.

For example, when the strength of the signal with the external device is a first signal strength (e.g., greater than -75 dB), the processor120may change the first positioning angle to the second positioning angle (-18° to +18°) by applying the first offset (e.g., -3° to +3°) to the first positioning angle. Alternatively, when the strength of the signal with the external device is a second signal strength (e.g., greater than -85 dB and less than -75 dB), the processor120may change the first positioning angle to the second positioning angle (-20° to +20°) by applying the second offset (e.g., -5° to +5°) to the first positioning angle. When the strength of the signal with the external device is a third signal strength (e.g., greater than -90 dB and less than -85 dB), the processor120may change the first positioning angle to the second positioning angle (-23° to +23°) by applying the third offset (e.g., -8° to +8°) to the first positioning angle.

Numerical values shown in the first positioning angle table1110or the second positioning angle table1130are only examples to assist understanding of the disclosure, and the disclosure is not limited by the examples. The positioning angle may be configured based at least in part on a table generated with a distance value, an RSSI, and an SNR, and may include an azimuth (e.g., a horizontal angle) and an elevation (e.g., a vertical angle). The positioning angle may be configured such that the azimuth and the elevation have the same range, or the azimuth or the elevation may be separately configured. When the positioning angle is changed, the processor120may change at least one of the azimuth or the elevation of the positioning angle.

FIG.12is a flowchart1200illustrating a method for differently changing a positioning angle for each external device by an electronic device according to various embodiments.

Referring toFIG.12, in operation1201, a processor (e.g., the processor120ofFIG.1) of the electronic device (e.g., the electronic device101ofFIG.1) according to various embodiments may retrieve a first external device outside a positioning angle and a second external device within the positioning angle. The first external device and the second external device may be included in a UWB communication-perceivable range corresponding to the front of the electronic device101. The positioning angle is different from the UWB communication-perceivable range, and may be, for example, smaller than the UWB communication-perceivable range.

The first external device may be included in the UWB communication-perceivable range, but may not be included in the positioning angle. The second external device may be included in both the UWB communication-perceivable range and the positioning angle. The positioning angle may include an azimuth (e.g., a horizontal angle) and an elevation (e.g., a vertical angle).

The positioning angle may be configured such that the azimuth and the elevation have the same range, or the azimuth or the elevation may be separately configured. When the positioning angle is changed, the processor120may change at least one of the azimuth or the elevation of the positioning angle. In UWB communication, the processor120may retrieve an external device using the positioning angle configured as a default in the electronic device101.

According to various embodiments, the processor120may determine whether to select the first external device, based at least in part on whether the first external device out of the positioning angle is within a certain range, whether the first external device is a device providing a service related to an application being executed in the electronic device101, or a user input. The processor120may display that the first external device and the second external device are retrieved, and may report a change of a pointing direction of the electronic device101when the first external device is intended to be selected.

In operation1203, the processor120may determine whether the first external device is closer than the second external device. When the first external device is located outside the positioning angle but is located closer than the second external device, a user may be highly likely to select the first external device. When a plurality of external devices is retrieved (or identified), the processor120may change the positioning angle, based at least in part on the distance between the external device and the electronic device101, in order to increase accuracy in selecting an external device.

The processor120may perform operation1205when the first external device is closer than the second external device, and may perform operation1209when the first external device is not closer than the second external device.

When the first external device is closer than the second external device, the processor120may differently change the positioning angle depending on the external devices in operation1205. For example, the processor120may apply a first positioning angle to the first external device, and may apply a second positioning angle to the second external device. The first positioning angle may be different from the second positioning angle. For example, the processor120may apply the first positioning angle, obtained by increasing positioning angle, to the first external device, and may apply the second positioning angle, obtained by reducing the positioning angle, to the second external device.

In operation1207, the processor120may re-retrieve an external device, based at least in part on the changed positioning angle. The first external device is not included in the previous positioning angle, and the second external device is included in the previous positioning angle. However, after changing the positioning angle, the first external device may be included in the first positioning angle, and the second external device may not be included in the second positioning angle. There may be one first external device or second external device, or a plurality of first external devices or second external devices. For example, there may be one first external device, and two second external devices. In the changed positioning angle, one of the two external devices corresponding to the second external devices may be retrieved, and the other external device may not be retrieved.

When the first external device is not closer than the second external device, the processor120may determine whether the number of the second external devices is a configured number in operation1209. There may be a plurality of first external devices or second external devices. The processor120may perform operation1211when the number of the second external devices is the configured number, and may perform operation1205when the number of the second external devices is not the configured number. When the number of the second external devices is not the configured number (e.g., two or three), the processor120may perform operation1205to change the positioning angle for the second external devices so that second external devices may be retrieved.

When the number of the second external devices is the configured number, the processor120may select the second external devices, based at least in part on a user input in operation1211. The processor120may provide a user interface including the second external devices existing in the positioning angle. The user may select the retrieved second external devices or may request re-retrieval of an external device.

AlthoughFIG.12shows an example in which a positioning angle is differently applied according to a distance, the processor120may change the positioning angle, based at least in part on the strength of a signal with an external device. The strength of the signal may include an RSSI or SNR included in a UWB signal. The processor120may estimate a distance from the strength of the signal, and may adjust the positioning angle according to the estimated distance. Alternatively, the processor120may change the positioning angle, based at least in part on the strength of the signal, without estimating the distance from the strength of the signal.

FIG.13Aillustrates an example in which an electronic device differently changes a positioning angle for each external device according to various embodiments.

Referring toFIG.13A, the electronic device (e.g., the electronic device101ofFIG.1) according to various embodiments may retrieve a first external device601, a second external device603, and a third external device605included in a UWB communication-perceivable range corresponding to the front of the electronic device101. Referring to a first reference numeral1310, the first external device601may located (or present) outside a positioning angle1301, and the second external device603and the third external device605may be located within the positioning angle1301. The positioning angle1301is different from the UWB communication-perceivable range, and may be, for example, smaller than the UWB communication-perceivable range.

Referring to the first reference numeral1310, when the first external device601is located outside the positioning angle1301, and the second external device603and the third external device605are located within the positioning angle1301, the electronic device101may determine whether the first external device601is closer than the second external device603or the third external device605. For example, when the signal strength of the first external device601outside the positioning angle1301is a specified value or greater (e.g., when the first external device601is determined to be super-close), the electronic device101may determine whether the first external device601is closer than the second external device603or the third external device605.

When the first external device601is closer than the second external device603or the third external device605, the electronic device101may differently change the positioning angle depending on the external devices. For example, the electronic device101may apply a first positioning angle1353to the first external device601and may apply a second positioning angle1351to the second external device603or the third external device605. For example, referring to a second reference numeral1350, the electronic device101may apply the first positioning angle1353, increased from the positioning angle1301, to the first external device601that is close to the electronic device101. Referring to the second reference numeral1350, when the second external device603and the third external device605exist at a long distance from the electronic device101, the electronic device101may apply the second positioning angle1351, reduced from the positioning angle1301, to the second external device603and the third external device605. The electronic device101may re-retrieve an external device, based at least in part on the changed (or applied) positioning angle.

The first external device601may not be included in the positioning angle1301(e.g., the previous positioning angle), and the second external device603and the third external device605may be included in the positioning angle1301. Regarding the changed positioning angle, the first external device601may be included in the first positioning angle1353, the second external device603may be included in the second positioning angle1351, and the third external device605may not be included in the second positioning angle1351.

WhenFIG.13Ais applied to an actual service, the processor120may identify the first external device601newly approaching while retrieving the second external device603and the third external device605currently lined up at a bus stop. In this case, the processor120may increase the positioning angle to be changed to the second positioning angle1353, or may transmit a command to move behind the second external device603and the third external device605to the first external device601.

FIG.13BandFIG.13Cillustrate examples in which an electronic device changes a positioning angle according to various embodiments.

Referring toFIG.13B, the electronic device101may retrieve at least one external device performing UWB communication, and may determine whether the retrieved external device satisfies a configured condition. Referring to a third reference numeral1360, the electronic device101may retrieve a first external device601, a second external device603, a third external device605, and a fourth external device607included in a first positioning angle1301. Referring to the third reference numeral1360, since the number of external devices included in the positioning angle1301is a specified number (e.g., one) or greater, the electronic device101may change the positioning angle1301. The electronic device101may change the positioning angle1301by stages.

Referring to a fourth reference numeral1370, the electronic device101may change the positioning angle to a second positioning angle1351, thereby retrieving the second external device603and the fourth external device607. Since two external devices are retrieved in the second positioning angle1351, the electronic device101may change the second positioning angle1351. Referring to a fifth reference numeral1375, the electronic device101may change the positioning angle to the third positioning angle1373, thereby retrieving the second external device603. The electronic device101may change the positioning angle by stages until only one external device is retrieved. The electronic device101may display the second external device603through a display.

Referring to a sixth reference numeral1380ofFIG.13C, the electronic device101retrieve a first external device601, a second external device603, and a third external device605included in a positioning angle1301. A fourth external device607may enter the positioning angle1301. Since a plurality of external devices is included in the positioning angle1301, the electronic device101may change the positioning angle1301by stages. Referring to a seventh reference numeral1390, the electronic device101may change the positioning angle to a second positioning angle1351, thereby retrieving the second external device603and the fourth external device607. The processor120may display the second external device603and the fourth external device607through a display. A user may select one of the second external device603or the fourth external device607.

FIG.14is a flowchart1400illustrating a method for retrieving an external device by moving an electronic device according to various embodiments.

Referring toFIG.14, in operation1401, a processor (e.g., the processor120ofFIG.1) of the electronic device (e.g., the electronic device101ofFIG.1) according to various embodiments may retrieve a plurality of external devices. The processor120may retrieve a plurality of external devices included in a UWB communication-perceivable range corresponding to the front of the electronic device101. Alternatively, the processor120may retrieve a plurality of external devices included in a positioning angle smaller than the UWB communication-perceivable range.

In operation1403, the processor120may obtain angle information or distance information about the plurality of external devices. The angle information (e.g., an azimuth and/or an elevation) may be included in a UWB signal. The UWB signal may include at least one of time information, a timestamp, the angle information (e.g., the azimuth and/or the elevation), an RSSI, SNR information, or a transmit power. The angle information may be included in the UWB signal regardless of the type of UWB communication. The angle information may have a significant value when a UWB antenna (e.g., UWB antenna 1221or UWB antenna 2223ofFIG.2) included in the electronic device101faces an external device. The processor120may measure the slope of the electronic device101, based at least in part on sensor data obtained through an acceleration sensor or a gyro sensor (e.g., the sensor module176ofFIG.1) included in the electronic device101, and may use the slope of the electronic device101for reference when obtaining the angle information.

The distance information may be calculated using the time information or the timestamp included in the UWB signal. When it is difficult to obtain the distance information, the processor120may obtain only the angle information. When the UWB communication type is a type supporting distance information (e.g., SS-TWR or DS-TWR), the UWB signal may include at least one of the time information, the angle information, the RSSI, the SNR information, or the transmit power. The processor120may measure the distance to the external devices, based at least in part on the time information included in the UWB signal. When the UWB communication type is at least one of advertisement, UL TDoA, or DL TDoA, the UWB signal may include at least one of the timestamp, the angle information, the RSSI, the SNR information, or the transmit power.

When the UWB communication type is a type supporting distance information (e.g., UL TDoA or DL TDoA), the processor120may measure the distance to the external device, based at least in part on the timestamp included in the UWB signal. When the UWB communication type is a type not supporting distance information (e.g., advertisement), the processor120may estimate (or calculate) the distance to the external devices, based at least in part on signal strength (e.g., the RSSI or SNR information) included in the UWB signal. The processor120may infer the distance to the external devices, based at least in part on a Friis formula (e.g., Friis’s path loss formula).

In operation1405, the processor120may compare the angle information or the distance information. For example, the plurality of external devices may include a first external device and a second external device. The first external device and the second external device may have different azimuths (e.g., horizontal angles) or elevations (e.g., vertical angles). The processor120may compare first angle information about the first external device with second angle information about the second external device, and may compare first distance information about the first external device with second distance information about the second external device. Information about the angle between the electronic device101and the first external device and information about the distance therebetween are related to the first external device, and may be referred to as the first angle information and the first distance information to distinguish from angle information and distance information related to the second external device. Information about the angle between the electronic device101and the second external device and information about the distance therebetween may be referred to as the second angle information and the second distance information.

In operation1407, the processor120may determine whether pieces of angle information are similar to each other within a reference value. When the first angle information and the second angle information are similar within the reference value (e.g., 1° to 3°), the processor120may determine that the first external device and the second external device are located in the same line based at least in part on the electronic device101. For example, the first external device may be located slightly closer to the electronic device101, and the second external device may be located behind the first external device to be located slightly further away from the electronic device101.

When the pieces of angle information are similar to each other within the reference value, the processor120may perform operation1409, and when the pieces of angle information are not similar to each other within the reference value, the processor120may perform operation1413.

When the pieces of angle information are similar to each other within the reference value, the processor120may report a location change of the electronic device101in operation1409. The processor120may provide a user interface for requesting a change of the location of the electronic device101. The user interface may be configured as at least one of text, an image, a video, or a voice. The processor120may display the user interface for the location change on a display (e.g., the display160ofFIG.1) or may output the user interface to a sound output module (e.g., the sound output module155ofFIG.1). Alternatively, the processor120may further reduce the positioning angle or may identify whether an external device selected by a user is correct.

In operation1411, the processor120may receive a UWB signal from the external devices as the location change of the electronic device101is detected. The processor120may detect the location change of the electronic device101, based at least in part on sensor data obtained through the sensor module176. When the UWB signal is received, the processor120may return to operation1403. The processor120may return to operation1403, and may obtain angle information or distance information, based at least in part on the angle information or time information (or timestamp) included in the UWB signal. The processor120may provide more accurate information about the external devices, based at least in part on the angle information or distance information obtained from the external devices at the changed location of the electronic device101along with the angle information or distance information obtained before the location change of the electronic device101.

When the pieces of angle information are not similar to each other within the reference value, the processor120may display the external devices in operation1413. When the plurality of external devices is retrieved but the pieces of angle information are not similar to each other within the reference value, the processor120may display the external devices to allow the user to select an external device.

In operation1415, the processor120may select an external device, based at least in part on a user input. The user may select at least one external device among the displayed external devices. The processor120may transmit data to the selected external device. For data transmission, Bluetooth or Wi-Fi may be used. Alternatively, the user may request re-retrieval instead of selecting an external device.

According to various embodiments, the processor120may select an external device in further consideration of context information. The context information may be identifying an external device (e.g., a speaker) required for an actual service (e.g., music playback). For example, the first external device (e.g., a TV) and the second external device (e.g., a speaker) may have similar azimuths and different elevations. Alternatively, the first external device (e.g., the TV) and the second external device (e.g., the speaker) may have similar elevations and different azimuths. When a music playback application is being executed in the electronic device101, the processor120may select the speaker as an external device. Alternatively, when a video streaming application is being executed in the electronic device101, the processor120may select the TV as an external device.

According to various embodiments, the processor120may select an external device in further consideration of user preference based at least in part on the context information. For example, in a case where the user has a history of frequently selecting the first external device (e.g., a speaker) when executing the music playback application, if the first external device (e.g., the speaker) and the second external device (e.g., a speaker) have similar azimuths and elevations, the first external device may be selected as an external device.

FIG.15AandFIG.15Billustrate examples of retrieving an external device by changing the location of an electronic device according to various embodiments.

Referring toFIG.15A, a processor (e.g., the processor120ofFIG.1) of the electronic device (e.g., the electronic device101ofFIG.1) according to various embodiments may retrieve a plurality of external devices included in a UWB communication-perceivable range corresponding to the front of the electronic device101. Alternatively, the processor120may retrieve a plurality of external devices included in a positioning angle θ smaller than the UWB communication-perceivable range (1510). The plurality of external devices may include a first external device601and a second external device603. The processor120may compare angle information or distance information about the first external device601and angle information or distance information about the second external device603.

The processor120may compare first angle information about the first external device601with second angle information about the second external device603, and may compare first distance information about the first external device601with second distance information about the second external device603. The processor120may measure the slope of the electronic device101, based at least in part on sensor data obtained through an acceleration sensor or a gyro sensor (e.g., the sensor module176ofFIG.1) included in the electronic device101, and may use the slope of the electronic device101for reference when comparing (or obtaining) the pieces of angle information.

The processor120may determine whether the first angle information σ about the first external device601and the second angle information β about the second external device603are similar to each other within a reference value. When the pieces of angle information are similar to each other within the reference value, the processor120may report a location change of the electronic device101. The processor120may provide a user interface for requesting a change of the location of the electronic device101. The processor120may receive a UWB signal from the external devices as the location change of the electronic device101is detected (1530). When the UWB signal is received, the processor120may obtain angle information or distance information, based at least in part on angle information or time information (or timestamp) included in the UWB signal. The processor120may provide more accurate information about the external devices, based at least in part on the angle information or distance information obtained from the external devices at the changed location of the electronic device101along with the angle information or distance information obtained before the location change of the electronic device101.

For example, the processor120may compare (1550) a timestamp obtained from the first external device601and a timestamp obtained from the second external device603at the changed location of the electronic device101, thereby providing more accurate information about the external devices. Since a time difference occurs between the received timestamps according to a distance difference between the first external device601and the second external device603, the processor120may infer the distance to the first external device601or the second external device603, based at least in part on the difference between times at which the timestamps are received.

Referring toFIG.15B, the processor120may provide a first user interface1570for selecting the plurality of external devices. The processor120may provide the first user interface1570for selecting the plurality of external devices, based at least in part on the angle information or distance information obtained before the location change of the electronic device101. Alternatively, the processor120may provide a second user interface1590for selecting the plurality of external devices, based at least in part on the angle information or distance information obtained from the external devices at the changed location of the electronic device101. The second user interface1590may further include more accurate information than the first user interface1570.

FIG.16AandFIG.16Billustrate examples in which an electronic device selects an external device according to various embodiments.

Referring toFIG.16A, an instructor conducts a question-and-answer session with seated students in a lecture room. Here, the instructor may execute an attendance book application of the electronic device (e.g., the electronic device101ofFIG.1) (e.g., prepare for UWB communication), and may point (1610) at a student1601of a name that the instructor wants to know. The electronic device101may establish and perform UWB communication with external devices (e.g., electronic devices owned by the students) included in a UWB communication-perceivable range corresponding to the front of the electronic device101, and may retrieve and display at least one external device. The electronic device101may retrieve the electronic devices owned by the students, and may display the students' names as information about the external devices.

According to various embodiments, the electronic device101may select a nearby student, based at least in part on distances to the external devices, but may display information enabling a switch to a student behind. The electronic device101may display an external device list including all retrieved external devices (e.g., electronic devices of a plurality of students), and a user may variously select a desired external device from the external device list according to a short distance, a long distance, or context information.

Referring toFIG.16B, the electronic device101may include a first housing1621and a second housing1622disposed on both sides with respect to a folding axis (e.g., A) and formed to be folded with respect to each other. A hinge structure1660may be formed between the first housing1621and the second housing1622so that a front surface of the electronic device101may be folded. The electronic device101may include a flexible display1623spanning the first housing1621and the second housing1622. When an external device included in a UWB communication-perceivable range is not retrieved or an external device included in a positioning angle is not retrieved, the electronic device101may display a user interface for requesting user identification. In a state in which the first housing1621and the second housing1622are open, the electronic device101may display a user interface for a location change in a first display area1631corresponding to the first housing1621and a user interface for identifying whether to cancel retrieval of an external device or re-retrieve an external device in a second display area1633corresponding to the second housing1622.

When the first housing1621and the second housing1622face each other in a closed state (not shown), the electronic device101may report the direction change of the electronic device101.

According to various embodiments, an external device (e.g., an electronic board) within a store broadcasts a BLE signal, and when a user who owns the electronic device101enters the store, the electronic device101may perceive the broadcast BLE signal and may prepare for UWB communication. The user may point at any one ordering menu among a plurality of ordering menus (e.g., an electronic board) in the store with the electronic device101while walking to an ordering counter to place an order. The plurality of ordering menus may include a location tag, and the electronic device101may retrieve the plurality of ordering menus through UWB communication. The electronic device101corresponds to a long distance, based at least in part on distance information obtained from the ordering menus through UWB communication, and may thus repeat UWB communication by repeatedly reducing the positioning angle until any one ordering menu is left. When any one ordering menu is identified, the electronic device101may display information (e.g., a drink menu list) included in the ordering menu.

According to various embodiments, the user who owns the electronic device101may enter a house, and may sit on a sofa to watch TV in a living room. When entering the house, the electronic device101may be connected to Wi-Fi installed in the house, and may be connected to an external device connectable through Bluetooth. The electronic device101may recognize that the user stays in the living room, based at least in part on information about the connected external device or location information about the external device, and may prepare for UWB communication. When the user points the electronic device101at the TV to control the TV, a UWB signal from the TV is transmitted from a lower right corner of the TV, and thus the TV may not be included in a positioning angle. Since the electronic device101corresponds to a short distance, based at least in part on distance information obtained from the TV by performing UWB communication with the TV, the electronic device101may repeat UWB communication by repeatedly increasing the positioning angle until the TV is included in the positioning angle. When the TV is included in the positioning angle, the electronic device101displays the TV so that the user may select the TV.

According to various embodiments, an external device, such as a TV, an air conditioner, a set-top box, or a wall pad, is always supplied with power, and may thus always transmit a UWB advertisement signal. When the user sitting on the sofa in the living room executes an application (e.g., a preset application for UWB advertisement communication) through the electronic device101and points the electronic device101at the TV, the electronic device101may receive an advertisement signal from the TV, and may identify whether the TV is included in the positioning angle. Since the UWB signal is transmitted from the lower right corner of the TV, the TV may not be included in the positioning angle. The electronic device101may gradually increase the positioning angle until one external device is retrieved within the positioning angle. When the TV satisfies a condition for a predetermined time or a predetermined number of times, the application of the electronic device101may provide a screen necessary for TV control to the user.

According to various embodiments, when the user points the electronic device101at the air conditioner, the TV and the air conditioner may be included in the positioning angle due to the already increased positioning angle. After determining that the electronic device101is located at a long distance by referring to signal strength of UWB information received from the air conditioner, the electronic device101may reduce the positioning angle by an offset, may identify whether the TV is excluded from candidates and only the air conditioner is included, and may then provide a screen necessary for controlling the air conditioner to the user.

According to various embodiments, when the user points the electronic device101at the wall pad on a wall of the living room, the electronic device101may display information about a boiler, a light, or a fan and additional information that are controllable on the wall pad. In an embodiment, when the user points the electronic device101at the wall pad on the wall of the living room, the electronic device101may receive a URL related to the foregoing pieces of information from the wall pad, and may display the pieces of information, based on the URL.

According to various embodiments, the user (e.g., an instructor) who owns the electronic device101enters a classroom, and following students may possess an external device that transmits a UWB advertisement signal. Current classroom information, lecture information, instructor information, student information, or information for UWB advertisement communication may be updated to the electronic device101and the external devices through Wi-Fi located in the classroom. When information update is completed, the external devices may transmit an advertisement signal based on the updated information. The instructor may receive a question a student during the class, in which case when the instructor points the instructor’s electronic device101at the inquiring student, the electronic device101may display an external device list, based on external devices of the student and surrounding students. The electronic device101may gradually reduce the positioning angle until one external device is left in the positioning angle range. When the one external device satisfies a condition for a predetermined time or a predetermined number of times, the electronic device101may display information about the corresponding student based on the one external device.

An operating method of an electronic device (e.g., the electronic device101ofFIG.1) according to various embodiments of the disclosure may include performing UWB communication through a communication module (e.g., the communication module190ofFIG.1) included in the electronic device, retrieving at least one external device corresponding to a perceivable range of the UWB communication, based at least in part on the UWB communication, determining whether a configured condition including at least one of whether the retrieved external device is within a positioning angle smaller than the perceivable range, whether a number of retrieved external devices corresponds to a configured number, or whether a distance between the electronic device and the retrieved external device is a configured distance is satisfied, performing an operation related to the retrieved external device when the retrieved external device corresponds to the configured condition, and re-retrieving an external device by changing the positioning angle when the retrieved external device does not correspond to the configured condition.

According to an embodiment, the positioning angle may be configured based at least in part on a table generated with a distance value, an RSSI, and an SNR, and may include an azimuth and an elevation, and the re-retrieving may include re-retrieving the at least one external device by changing at least one of the azimuth or the elevation of the positioning angle when the retrieved external device does not correspond to the configured condition.

According to an embodiment, the changing may include increasing the positioning angle when the number of retrieved external devices does not correspond to the configured number, and reducing the positioning angle when the number of retrieved external devices exceeds the configured number, and the configured number used to increase or reduce the positioning angle may be configured to be the same or different.

According to an embodiment, the determining may include determining that the retrieved external device satisfies the configured condition when the retrieved external device is within the positioning angle and the number of retrieved external devices within the positioning angle corresponds to the configured number.

According to an embodiment, the determining may include determining that the retrieved external device does not satisfy the configured condition when the retrieved external device is not within the positioning angle and the distance to the retrieved external device corresponds to the configured distance.

According to an embodiment, determining may include determining that the configured condition is not satisfied when a distance of a first external device within the positioning angle is longer than a distance of a second external device outside the positioning angle.

According to an embodiment, the changing may include changing the positioning angle differently corresponding to a first external device and a second external device when a distance of the first external device within the positioning angle is longer than a distance of the second external device outside the positioning angle.

The embodiments disclosed in the specification and drawings are only intended to provide specific examples for easily describing the technical content of the disclosure and for assisting understanding of the disclosure, and are not intended to limit the scope of the disclosure. Therefore, it should be interpreted that the scope of the disclosure includes all changes or modifications derived based on the technical idea of the disclosure in addition to the embodiments disclosed herein.