Abstract:
The present disclosure relates to a sensor network and Internet of Things (IoT) as applied to intelligent services based technologies such as smart home, smart building, smart city, smart car, connected car, health care, digital education, smart retail, security and safety services. 
     An apparatus and method for controlling an electronic device through a mesh network of such electronic devices are provided. In a method for controlling an electronic device, a terminal transmits to the electronic device, a terminal identifier for authenticating the terminal and information for authenticating a user of the terminal. If authentication of the terminal is successfully completed, the terminal transmits control information containing at least one service identifier classified according to service types to the electronic device. The control information is transmitted to another electronic device, based on the service identifier, through a network in which the electronic device is connected to another electronic device.

Description:
PRIORITY 
       [0001]    This application claims priority under 35 U.S.C. §119(a) to a Korean Patent Application filed on Dec. 19, 2014 in the Korean Intellectual Property Office and assigned Serial No. 10-2014-0184861, the entire disclosure of which is incorporated herein by reference. 
       BACKGROUND 
       [0002]    1. Field of the Disclosure 
         [0003]    The present disclosure relates to techniques to control an electronic device, and more particularly, to an apparatus and method for controlling an electronic device capable of communication through a mesh network of such electronic devices. 
         [0004]    2. Description of the Related Art 
         [0005]    The Internet, which is a human centered connectivity network where humans generate and consume information, is now evolving to the Internet of Things (IoT) where distributed entities exchange and process information without human intervention. The Internet of Everything (IoE), which is a combination of the IoT technology and the Big Data processing technology through connection with a cloud server, has emerged. As technology elements, such as “sensing technology”, “wired/wireless communication and network infrastructure”, “service interface technology”, and “security technology” are in demand for IoT implementation, a sensor network, a Machine-to-Machine (M2M) communication, Machine Type Communication (MTC), and so forth have been recently researched. 
         [0006]    Such an IoT environment may provide intelligent Internet technology services that create new value to human life by collecting and analyzing data generated among connected things. IoT may be applied to a variety of fields including smart home, smart building, smart city, smart car or connected cars, smart grid, health care, smart appliances and advanced medical services through the convergence and combination of existing Information Technology (IT) and various industrial applications. 
         [0007]    The Global Positioning System (GPS) provides the ability to identify the current position of a user&#39;s terminal, such as a smart phone or a wearable device, by using a minimum of three satellites. However, GPS has significant limitations in identifying the position of a user&#39;s terminal that resides in the interior of a building or other structure that blocks the reception of the GPS satellite signals. 
         [0008]    Beacon technology, e.g., based on Bluetooth™, makes it possible to identify the position of a user&#39;s terminal by generating and transmitting a signal from a beacon to the terminal located within a specific area. A device that generates such a signal and identifies the position of the terminal is often referred to as a beacon or beacon device. 
         [0009]    Using such beacon technology, it is possible to measure and determine the position of a user&#39;s terminal in the interior of a building or other structure. 
         [0010]    However, the use of beacon technology for indoor positioning has serious security issues since communication using Bluetooth™ is performed with all terminals distributed within signal strength range of the beacon. Furthermore, the communication range of a beacon is limited in area. Power consumption and latency are increased when a terminal for controlling several electronic devices is required to individually transmit control information to the respective devices. 
       SUMMARY 
       [0011]    The present disclosure has been made to address at least the disadvantages described above and to provide at least the advantages described below. 
         [0012]    In order to meet the above needs, the present disclosure provides methods to allow automatic authentication of a user&#39;s terminal and control an electronic device through a mesh network formed of such electronic devices having the ability to communicate with each other. 
         [0013]    According to an embodiment of the present disclosure, a terminal for controlling an electronic device includes a communication unit configured to transmit and receive a signal; and a control unit configured to control the communication unit to transmit, to the electronic device, a terminal identifier for authenticating the terminal and information for authenticating a user of the terminal, and if authentication of the terminal is successfully completed, the communication unit of the terminal transmits control information containing at least one service identifier classified according to service types to the electronic device. In the terminal, the control information is transmitted to another electronic device, based on the service identifier, through a network in which the electronic device is connected to another electronic device. 
         [0014]    According to an embodiment of the present disclosure, an electronic device capable of communication includes a communication unit configured to transmit and receive a signal; and a control unit configured to control the communication unit to receive from a terminal, a terminal identifier for authenticating the terminal and information for authenticating a user of the terminal. If authentication of the terminal is successfully completed, the communication unit of the electronic device receives control information containing at least one service identifier classified according to service types from the terminal. Based on the service identifier, the electronic device decides whether to control the communication unit to transmit the control information to another electronic device through a network in which the electronic device is connected to another electronic device. 
         [0015]    According to an embodiment of the present disclosure, a method for controlling an electronic device from a terminal includes transmitting to the electronic device a terminal identifier for authenticating the terminal and information for authenticating a user of the terminal. If authentication of the terminal is successfully completed, transmitting control information containing at least one service identifier classified according to service types from the terminal to the electronic device. In this method, the control information is transmitted to another electronic device based on the service identifier, through a network in which the electronic device is connected to another electronic device. 
         [0016]    According to embodiment of the present disclosure, a method of operation of an electronic device which is capable of communication includes receiving from a terminal, a terminal identifier for authenticating the terminal and information for authenticating a user of the terminal. If authentication of the terminal is successfully completed the electronic device receives control information containing at least one service identifier classified according to service types from the terminal. The electronic device determines whether to operate, based on the service identifier and transmits the control information to another electronic device through a network in which the electronic device is connected to the another electronic device. 
     
    
     
       BRIEF DESCRIPTION OF THE DRAWINGS 
         [0017]    The above and other aspects, features and advantages of the present disclosure will be more apparent from the following detailed description, taken in conjunction with the accompanying drawings, in which: 
           [0018]      FIG. 1  is a block diagram illustrating the internal structure of a terminal according to an embodiment of the present disclosure; 
           [0019]      FIG. 2  is a block diagram illustrating the internal structure of an electronic device according to an embodiment of the present disclosure; 
           [0020]      FIG. 3  is a block diagram illustrating electronic devices being controlled by a terminal according to an embodiment of the present disclosure; 
           [0021]      FIG. 4A  is a diagram illustrating the method of authenticating a terminal according to an embodiment of the present disclosure; 
           [0022]      FIG. 4B  is a diagram illustrating an example of a terminal authentication request message and an example of an authentication reply message according to an embodiment of the present disclosure; 
           [0023]      FIG. 5  is a flow diagram illustrating the method of authenticating a terminal through an electronic device according to an embodiment of the present disclosure; 
           [0024]      FIG. 6  is a diagram illustrating a method for controlling an electronic device from a terminal according to an embodiment of the present disclosure; 
           [0025]      FIG. 7  is a diagram illustrating a method for controlling electronic devices through a mesh network formed of electronic devices according to an embodiment of the present disclosure; 
           [0026]      FIG. 8  is a flowchart illustrating a method of controlling electronic devices through a mesh network formed of electronic devices according to an embodiment of the present disclosure; 
           [0027]      FIG. 9A  is a diagram illustrating a method of operating electronic devices according to another embodiment of the present disclosure; 
           [0028]      FIG. 9B  is a diagram illustrating the format of a beacon frame contained in control information according to an embodiment of the present disclosure; 
           [0029]      FIG. 10  is a diagram illustrating identifiers and the format of a beacon frame contained in control information according to an embodiment of the present disclosure; 
           [0030]      FIG. 11  is a diagram illustrating services offered by an electronic device according to an embodiment of the present disclosure; 
           [0031]      FIG. 12  is a diagram illustrating services offered by an electronic device according to an embodiment of the present disclosure; 
           [0032]      FIG. 13  is a diagram illustrating a method of operating an electronic device based on the position of a terminal according to an embodiment of the present disclosure; 
           [0033]      FIG. 14  is a diagram illustrating a method of controlling an electronic device according to an embodiment of the present disclosure; and 
           [0034]      FIG. 15  is a diagram illustrating a communication protocol stack configured to control an electronic device through another electronic device and a gateway from a terminal according to an embodiment of the present disclosure. 
       
    
    
     DETAILED DESCRIPTION 
       [0035]    Embodiments of the present disclosure will be described herein below with reference to the accompanying drawings. 
         [0036]    The present disclosure may be embodied in many different forms and should not be construed as limited to the embodiments set forth herein. Rather, the disclosed embodiments are provided so that this disclosure will be thorough and complete, and will fully convey the scope of the disclosure to those skilled in the art. The principles and features of the present disclosure may be employed in varied and numerous embodiments without departing from the scope of the disclosure. 
         [0037]    Furthermore, well known or widely used techniques, elements, structures, and processes may not be described or illustrated in detail to avoid obscuring the essence of the present disclosure. Although the drawings represent particular embodiments, the drawings are not necessarily to scale and certain features may be exaggerated or omitted in order to better illustrate and explain the present disclosure. Through the drawings, the same or similar reference numerals denote corresponding features consistently. 
         [0038]    Unless defined differently, all terms used herein, which include technical terminologies or scientific terminologies, have the same meaning as that understood by a person skilled in the art to which the present disclosure belongs. Singular forms are intended to include plural forms unless the context clearly indicates otherwise. 
         [0039]    Terms such as “comprise”, “include”, “may have” and/or “have” may be construed to denote a certain characteristic, number, step, operation, constituent element, component or a combination thereof, but may not be construed to exclude the existence of or a possibility of addition of one or more other characteristics, numbers, steps, operations, constituent elements, components or combinations thereof. The expression “or” includes any and all combinations of the associated listed words. For example, the expression “A or B” may include A, may include B, or may include both A and B. 
         [0040]    As used herein, expressions including ordinal numbers, such as “first” and “second,” etc., may modify various elements. However, such elements are not limited by the above expressions. For example, the above expressions do not limit the sequence and/or importance of the elements. The above expressions are used merely for the purpose of distinguishing an element from the other elements. For example, a first user device and a second user device indicate different user devices although both of them the first user device and the second user device are user devices. For example, a first element may be referred to as a second element, and similarly, a second element may be referred to as a first element without departing from the scope of the present disclosure. 
         [0041]      FIG. 1  is a block diagram illustrating the internal structure of a terminal according to an embodiment of the present disclosure. 
         [0042]    As shown in  FIG. 1 , the terminal  100  includes a communication unit  110 , an input unit  120 , a memory unit  130 , a display unit  140 , and a control unit  150 . 
         [0043]    The communication unit  110  transmits and receives data for wireless communication of the terminal  100 . Specifically, the communication unit  110  may receive data to be delivered to the control unit  150 , through a wireless channel and also transmit data from the control unit  150 , through a wireless channel. The communication unit  110  may perform short range communication with an electronic device. The short range communication includes Bluetooth™, Zigbee™, ultra wideband (UWB)™, and the like. According to an embodiment of the present disclosure, the communication unit  110  receives a beacon signal from an electronic device. This beacon signal is used for identifying the position of the terminal  100 . 
         [0044]    The input unit  120  receives a user&#39;s inputs for controlling an electronic device, creates a corresponding input signal, and delivers the input signal to the control unit  150 . 
         [0045]    The memory unit  130  stores user account information and a terminal identifier. The user account information refers to specific information used for identifying a user, and the terminal identifier refers to specific information used for identifying the terminal  100 . If the terminal  100  approaches a certain electronic device within a given distance, the terminal  100  may transmit the terminal identifier and the account information stored in the memory unit  130 , to the electronic device through the communication unit  110 . Additionally, the memory unit  130  may store a list of electronic devices which are controllable by the terminal  100 . Therefore, when the authentication of the terminal  100  is successfully completed, the terminal  100  may control the electronic devices specified in the list by using a mesh network. A detailed description associated with the mesh network will be made below. 
         [0046]    The display unit  140  may be formed of liquid crystal display (LCD), organic light emitted diode (OLED), and the like. In case of a touch screen, the display unit  140  may be combined with a touch panel or a touch film. The display unit  140  visually provides to a user, a menu of the terminal  100 , entered data, a list of controllable electronic devices, and/or any other information. 
         [0047]    The control unit  150  controls the operation of the terminal  100 . In particular, when the authentication of the terminal  100  is successfully completed, the control unit  150  transmits control information, containing a service identifier for identifying an electronic device to be controlled, to the electronic device and then controls the electronic device. 
         [0048]      FIG. 2  is a block diagram illustrating the internal structure of an electronic device according to an embodiment of the present disclosure. 
         [0049]    As shown in  FIG. 2 , the electronic device  200  may include a communication unit  210 , a control unit  220 , and a memory unit  230 . 
         [0050]    The communication unit  210  performs communication with the terminal. Particularly, the communication unit  210  performs short range communication with the terminal. The short range communication may include Bluetooth™, Zigbee™, UWB™, and the like. According to an embodiment of the present disclosure, the communication unit  210  transmits a beacon signal to the terminal in order to identify the position of the terminal. 
         [0051]    The control unit  220  controls the operation of the electronic device  200 . In particular, when the authentication of the terminal is successfully completed, the control unit  220  controls a particular operation of the electronic device  200 . For example, if the electronic device  200  is a door lock, the control unit  220  may unlock the door lock. 
         [0052]    Additionally, when the terminal transmits a beacon signal to the electronic device  200 , the control unit  220  determines the position of the terminal on the basis of the beacon signal. 
         [0053]    Additionally, the control unit  220  receives control information containing a service identifier from the terminal. The control unit  220  controls the electronic device  200 , based on the received control information. 
         [0054]    The memory unit  230  stores different terminal identifiers. For example, in the case of a family with four people, each individual person may have one or more terminals. In this case, the memory unit  230  may store identifiers of all terminals in that family. 
         [0055]      FIG. 3  is a diagram illustrating electronic devices being controlled by a terminal according to an embodiment of the present disclosure. 
         [0056]    The terminal  310  may control a plurality of electronic devices that reside in the interior of a building or house (namely, indoor electronic devices). The terminal  310  and the respective indoor electronic devices communicate with each other. For example, the terminal  310  performs at least one of multiple short range communication, such as Bluetooth™, Zigbee™, or UWB™, with each individual electronic device. However, the present disclosure is not limited to the control of indoor electronic devices. 
         [0057]    Referring to  FIG. 3 , the terminal  310  may control a TV  320  and an audio player  330 , for example. The terminal  310  may also control any other electronic device connected through a mesh network. 
         [0058]    In order to control an electronic device, the terminal is required to successfully pass an authentication process for determining whether the terminal is registered in the electronic device. The authentication process will be described in detail. 
         [0059]      FIG. 4A  is a diagram illustrating the process of authenticating a terminal according to an embodiment of the present disclosure. 
         [0060]    When the terminal  401  approaches an electronic device  403  within a given distance, the terminal  401  transmits a terminal identifier for identifying the terminal to the electronic device  403  at step S 410 . 
         [0061]    The terminal  401  directly transmits such a terminal identifier to the electronic device  403  that allows communication. The terminal  401  directly transmits account information for identifying a user to the electronic device  403 . Based on such information for identifying the terminal  401  and the user, it is possible to provide a service or perform authentication according to each terminal and user. 
         [0062]    According to typical beacon technology, a device capable of transmitting a beacon signal sends information containing a specific identifier to a terminal. Then the terminal may execute a specific application based on the received information. According to an embodiment of the present disclosure, the terminal  401  transmits identifiers for identifying the terminal and the user, so that the electronic device  403  independently or in coordination with the authentication server  407  may authenticate such terminals. For example, if the electronic device stores identifiers corresponding to the terminals of four people who belong to a certain family, the electronic device may authenticate each individual person. Also, the electronic device may separately provide services to individual people through the stored identifiers. 
         [0063]    The electronic device  403  may directly communicate with the terminal  401  or communicate with the terminal  401  through another device, e.g., a beacon device, which is attached thereto and capable of communication. For example, the terminal  410  performs at least one of multiple short range communication, such as Bluetooth™, Zigbee™, or UWB™. 
         [0064]    The electronic device  403  may identify the position of the terminal  401  by receiving a beacon signal from the terminal  401  and computing the distance and position of the terminal  401 . 
         [0065]    The electronic device  403  receives beacon data from the terminal  401  and thereby measures the distance and position of the terminal  401 . The electronic device  403  may recognize the terminal  401  approaching the electronic device  403 , based on the measured position of the terminal  401 , and operate without requiring the user to enter a PIN code. 
         [0066]    When the terminal identifier is received from the terminal  401  at step S 410 , the electronic device  403  determines at step S 420  whether the terminal identifier has been registered therein. The electronic device  403  may have several terminal identifiers stored therein, and when a certain terminal identifier is received, compares the received identifier with the stored identifiers to determine whether the terminal  401  has been registered in the electronic device  403 . 
         [0067]    If the received terminal identifier is registered in the electronic device  403 , the electronic device  403  requests account information  417  from the terminal  401  at step S 430 . The account information refers to specific information for identifying the user of the terminal  401 . One or more terminal identifiers may be linked to the account information on a hierarchical level. A single user may sometimes have two or more terminals  401  while always having single account information. Therefore, such terminal identifiers corresponding to respective terminals may be linked to the account information. 
         [0068]    The account information  417  may contain an authentication code, refresh information and access information. The refresh information refers to information for regenerating the access information, and the access information refers to information used for authentication of the terminal. 
         [0069]    When a request for account information is received from the electronic device  403 , the terminal  401  transmits an authentication code to the electronic device  403  at step S 440 . Since user authentication based on the refresh information and the access information both of which are normally used for actual authentication may incur a security problem, the authentication code may be used alternatively. 
         [0070]    The electronic device  403  that receives the authentication code transmits the received authentication code to a gateway  405  at step S 450 . The gateway  405  refers to a device that connects the electronic device  403  with a network. At step S 460 , the gateway  405  transmits the received authentication code to an authentication server  407  and requests the authentication of the terminal. 
         [0071]    Alternatively, the electronic device  403  may transmit the authentication code to the authentication server  407  without passing through the gateway  405  to request the authentication of the terminal. 
         [0072]    The authentication server  407  performs an authentication process for the terminal by using the authentication code received from the gateway  405  or the electronic device  403 . 
         [0073]    When the authentication of the terminal is completed, the authentication server  407  transmits an authentication result to the gateway  405  at step S 470 . The gateway  405  then transmits the received authentication result to the electronic device  403  at step S 480 . Alternatively, the authentication server  407  may directly transmit an authentication result to the electronic device  403 . 
         [0074]    The electronic device  403  that receives the authentication result from the gateway  405  or the authentication server  407  may operate with the terminal at step S 490  depending on whether the authentication fails or succeeds to authenticate and authorize the terminal. For example, let&#39;s suppose that the electronic device  403  is a door lock. If the terminal identifier is registered in the door lock, and if successful authentication is completed using an authentication code transmitted by the terminal, the door lock may be unlocked automatically. 
         [0075]      FIG. 4B  is a diagram illustrating an example of an authentication request message and an example of an authentication result message according to an embodiment of the present disclosure. 
         [0076]    The gateway  405  that receives the authentication code from the electronic device  403  may transmit an authentication request message  410 B containing the received authentication code to the authentication server  407  at step S 460  discussed above with reference to  FIG. 4A . This authentication request message  410 B may include an authentication code  417 B (or may be referred to as an authorization code) and an indication part  413 B which indicates that a message relates to an authentication code. 
         [0077]    In the case of successful user authentication, the authentication server  407  transmits an authentication result message  420 B to the gateway  405  at step S 470  discussed above with reference to  FIG. 4A . The authentication result message  420 B contains 200 OK  421 B that indicates a successful response. In addition, the authentication result message  420 B may include refresh information  423 B and access information  425 B, both of which are provided to prevent the expiration of refresh information and access information contained in the gateway  405 . 
         [0078]      FIG. 5  is a flow diagram illustrating the process of authenticating a terminal through an electronic device according to an embodiment of the present disclosure. 
         [0079]    When the terminal  501  approaches the electronic device  503  within a given distance, the terminal  501  transmits a terminal identifier for identifying the terminal to the electronic device  503  at step S 510 . 
         [0080]    Alternatively, in an embodiment of the present disclosure, the terminal  501  may broadcast a terminal identifier continuously or periodically. When the terminal  501  enters a specific area that allows the electronic device  503  to receive data packets from a certain terminal, the electronic device  503  receives the broadcasted terminal identifier. As will be discussed below, the terminal  501  may also broadcast information for identifying a user. 
         [0081]    Since the terminal  501  transmits information for identifying the terminal and the user thereof, it is possible to separately offer a service or individually perform authentication according to each terminal and user. 
         [0082]    The electronic device  503  may directly communicate with the terminal  501  or communicate with the terminal  501  through a device which is attached thereto and capable of communication. Additionally, the electronic device  503  may identify the distance or position of the terminal  501  by transmitting a beacon signal to the terminal  501 . 
         [0083]    When the terminal identifier is received from the terminal  501 , the electronic device  503  determines at step S 520  whether the terminal identifier has been previously registered therein. The electronic device  503  may have several terminal identifiers stored therein. 
         [0084]    For example, if a family is comprises four people, and if each individual person has one or more terminals, a total of four or more terminal identifiers may be registered in the electronic device  503 . Therefore, when a certain terminal identifier is received, the electronic device  503  compares the received identifier with the stored identifiers and thereby determines whether a corresponding terminal has been previously registered therein. 
         [0085]    If the received terminal identifier is registered in the electronic device  503 , the electronic device  503  requests account information from the terminal  501  at step S 530 . The account information refers to specific information to be used for identifying a user of the terminal  501 . 
         [0086]    In the case of identifying the position of a terminal by using a beacon signal and then offering a service to the terminal, security problem may result. Therefore, in this embodiment, an additional authentication process is performed using the user&#39;s account information. 
         [0087]    As discussed above with reference to  FIG. 4A , one or more terminal identifiers may be linked to the account information on a hierarchical level. Additionally, the account information may contain an authentication code, refresh information and access information. 
         [0088]    When a request for the account information is received from the electronic device  503 , the terminal  501  transmits an authentication code to the electronic device  503  at step S 540 . Since the user authentication is based on the refresh information and the access information both of which are normally used for actual authentication may potentially incur a security problem, the authentication code may be used alternatively. 
         [0089]    The electronic device  503  that receives the authentication code transmits the received authentication code to the gateway  505  at step S 550 . The gateway  505  is a device that connects the electronic device  503  with a network. At step S 560 , the gateway  505  transmits the received authentication code to an authentication server  507  and then requests the authentication of the terminal. 
         [0090]    Alternatively, the electronic device  503  may transmit the authentication code to the authentication server  507  without passing through the gateway  505  and then request the authentication of the terminal. 
         [0091]    At step S 570 , the authentication server  507  performs an authentication process for the terminal  501  by using the authentication code received from the gateway  505  or the electronic device  503 . 
         [0092]    When the authentication of the terminal  501  is completed, the authentication server  507  transmits the authentication result to the gateway  505  at step S 580 . The gateway  505  transmits the received authentication result to the electronic device  503  at step S 590 . Alternatively, the authentication server  507  may directly transmit the authentication result to the electronic device  503 . 
         [0093]    The electronic device  503  that receives the authentication result from the gateway  505  or the authentication server  507  may operate at step S 595  depending on the authentication process results in authorization of the terminal  501 . For example, if the electronic device  503  is a door lock, the terminal identifier is registered in the door lock, and if successful authentication is completed using an authentication code transmitted by the terminal, the door lock may be unlocked automatically. 
         [0094]      FIG. 6  is a diagram illustrating a method for controlling an electronic device at a terminal according to an embodiment of the present disclosure. 
         [0095]    As indicated by reference number  610 , the terminal  611  may control electronic devices such as LEDs as shown. When the terminal  611  approaches such LEDs, the LED may perform an authentication process for the terminal  611 . If an authentication process for the terminal  611  is completed by any other electronic device, the LED may skip an authentication process. When the authentication of the terminal  611  succeeds, the LEDs may be controlled by the terminal  611 . 
         [0096]    The terminal  611  may perform communication with the LEDs so as to control the LEDs. In an embodiment of the present disclosure, the LEDs are a type of electronic device capable of communication, e.g., short range communication. The terminal  611  transmits control information to the LEDs. The control information for controlling LEDs may include a control packet  620  containing an LED location. The control packet  620  may be also referred to as a device control packet, a control data packet, and the like. 
         [0097]    Specifically, the LED location may be mapped to a destination address  621  in the control packet  620 . 
         [0098]    For example, in order to turn on the first LED  613 , the terminal  611  may transmit, to the first LED  613 , the control packet in which the address of the first LED  613 , 00:00:00:00:00:00:AA, is mapped to the destination address  621 . In order to simultaneously turn on three LEDs, the terminal  611  individually transmits control information including three control packets  620  to each LED. 
         [0099]    In case there are two or more electronic devices to be controlled, the problem of having to individually transmit control information to respective electronic devices is created. Unfortunately, transmitting individual control information may result in additional energy consumption and time delay. 
         [0100]    Therefore, a method for solving the energy consumption and time delay problem is needed. 
         [0101]      FIG. 7  is a diagram illustrating a method for controlling another electronic device through a mesh network formed of electronic devices according to an embodiment of the present disclosure. 
         [0102]    In  FIG. 7 , a single electronic device is represented as a single node (e.g., a node A). A solid line between adjacent nodes indicates that adjacent electronic devices are connected to each other. Hereinafter, an electronic device will be also referred to as a node. 
         [0103]    When a terminal approaches a node E within a distance capable of communication, the terminal performs communication, e.g., short range communication, with node E. An electronic device that communicates with the terminal may measure the distance from the terminal by using a beacon signal and measuring the received signal strength of the beacon signal or other method of distance determination. The electronic device may transmit a measured value to the terminal through beacon data, so that the terminal may recognize proximity to the electronic device without requiring the user to enter a PIN code. 
         [0104]    The terminal that recognizes proximity to the electronic device performs an authentication process through the node E. Since this process is discussed above with reference to  FIG. 4A , a related description is omitted herein. 
         [0105]    In case of a successful authentication of the terminal, the node E receives control information that contains a service identifier  731 . Based on a list of electronic devices to be controlled, the control information may contain the service identifier  731  of such electronic devices. 
         [0106]    The list of electronic devices may be created by a user&#39;s selection. Alternatively, the list of electronic devices may be created from frequently used electronic devices, based on information contained in authentication information used in an authentication process for the terminal. 
         [0107]    Each node contains node information  740 , namely, information about a parent node  743  to which control information  730  will be transmitted according to the service identifier  731 , and information about a child node  745  to which response information will be transmitted after a control process. 
         [0108]    If the control information  730  is transmitted to the node E, the node E may transmit the control information  730  to the parent node  743  corresponding to the service identifier  731  contained in the control information  730 . 
         [0109]    For example, node A may contain the node information  740  which is set to transmit the control information to node D in case of a service identifier  0 x  01 , to node B in case of a service identifier  0 x  02 , and a node C in case of a service identifier  0 x  03 . Therefore, if any control information having service identifiers  0 x  01  and  0 x  02  is transmitted to node A, node A may transmit the control information to node D and node B, based on information contained in the node information  740 . 
         [0110]    If a certain user having a terminal arrives at home, a door lock (corresponding to node E) performs an authentication process for the terminal. After successful authentication, the terminal transmits the control information  730  containing a service identifier to the door lock. The door lock then delivers the control information  730  to the gateway used for the authentication of the terminal. If there is no gateway, the door lock may transmit the control information to an entrance lamp, for example. The control information  730  may contain service identifiers  0 x  01 ,  0 x  02  and  0 x  03 , which correspond to an indoor lamp, a TV and an air conditioner, respectively. 
         [0111]    The entrance lamp that receives the control information containing such service identifiers may transmit the received control information to nodes connected to the indoor lamp, the TV and the air conditioner, respectively. As discussed above, information about which node is a parent node is contained in the node information  740  of each node. 
         [0112]    Such a structure in which nodes are connected to each other is referred to as a mesh network. Contrary to typical technique that has to separately transmit control information to respective electronic devices so as to control such devices, an embodiment of the present disclosure using the mesh network can simply control various types of electronic devices through a single transmission of control information that contains several service identifiers. Furthermore, when any electronic device is located at a long distance incapable of directly receiving control data of the terminal, such a device can be controlled through the mesh network. 
         [0113]    Additionally, the node information  740  may further include trigger bit information  741 . If a trigger bit for a specific service identifier is 1, an electronic device will operate when the service identifier is received. 
         [0114]    For example, if node A has the node information  740 , node A may operate when control information containing service identifiers  0 x  01  and  0 x  02  are received. 
         [0115]    The node information  740  includes metric distance information  747  and hop distance information  749 . Such information is used to prevent an infinite loop due to non-operation of intermediate nodes or defective transmission of control information. 
         [0116]    If the hop distance information  749  has a value of 1, this value is increased by one in proportion to an increase in the number of nodes. If an increased value is greater than a predetermined value, the control information is not transmitted any more. The metric distance information  747  refers to a weight value of a path between nodes. For example, if there are two or more paths between node A and node D (e.g., A→C→D and A→B→D), a node having a greater weight value may be used. 
         [0117]      FIG. 8  is a flowchart illustrating the process of controlling another electronic device through a mesh network formed of electronic devices according to an embodiment of the present disclosure. 
         [0118]    When the electronic device completes the authentication of a terminal at step S 810 , the electronic device receives control information having a service identifier at step S 820 . This control information may contain at least one service identifier according to a list of electronic devices to be controlled by a user. 
         [0119]    The electronic device that receives the control information determines at step S 830  whether to operate based on the service identifier contained in the control information. As discussed above, each electronic device (i.e., a node) stores node information, and the node information contains information about a trigger bit to be used for determining whether to operate the electronic device. 
         [0120]    If a trigger bit in the node information has a value of 1 with regard to the received service identifier, the electronic device will operate. 
         [0121]    At step S 840 , the electronic device determines a target electronic device to which the control information will be transmitted. As discussed above, the node information has information about such a target device (i.e., a parent node). Thus, depending on a service identifier, it is possible to determine a specific electronic device to which the control information will be transmitted. 
         [0122]    At step S 850 , the electronic device transmits the control information to the determined device. 
         [0123]    Furthermore, the electronic device that receives the control information may repeat the above steps. 
         [0124]      FIG. 9A  is a diagram illustrating the process of operating electronic devices according to another embodiment of the present disclosure. 
         [0125]    Referring to  FIG. 9A , when a terminal approaches an electronic device and successfully passes authentication, electronic devices of a mesh network may operate based on control information stored in the terminal. A list of such electronic devices that will be controlled by the control information may be formed of electronic devices selected in advance by a user. Alternatively, the list of such electronic devices may be formed from frequently used electronic devices, based on information contained in authentication information used in an authentication process for the terminal. 
         [0126]    For example, in  FIG. 9A , when a terminal is authenticated, the nearest lamp, the next lamps, and the air conditioner may operate sequentially. 
         [0127]      FIG. 9B  is a diagram illustrating the format of a beacon frame contained in control information according to an embodiment of the present disclosure. 
         [0128]    The control information transmitted for controlling the electronic device by the terminal may include a beacon frame  920 , which may contain a space for allocating service identifiers  923 . For example, advertisement data of the beacon frame  920  has manufacturer specific data (MSD), which may contain information about the service identifiers  923 . Therefore, the electronic device that receives the control information may check the service identifier  923  contained in the control information and thereby determine a transmission target of the control information. 
         [0129]      FIG. 10  is a diagram illustrating identifiers and the format of another beacon frame contained in control information according to an embodiment of the present disclosure. 
         [0130]    The control information may include a beacon frame  1010 , which may contain a service identifier. For example, the beacon frame  1010  has an advertising payload  1015  additionally allocated thereto. Therefore, the terminal may transmit the beacon frame  1010  to the electronic device by inserting a service identifier into the advertising payload  1015 . 
         [0131]    Reference number  1020  indicates a change in identifiers over a time period. The terminal may control an electronic device by transmitting different identifiers according to time. 
         [0132]    In the case where the terminal is not authenticated, the terminal may transmit a terminal identifier and an authentication code  1021  to an electronic device so as to authenticate the terminal and a user thereof. 
         [0133]    After authentication is completed, the terminal may transmit control information containing a service identifier  1023  to control an electronic device. 
         [0134]    When the electronic device operates based on the control information, a frequently used service may be provided using a history identifier  1025 . For example, if a user is watching TV, information about a frequently watched channel, information about previously played content, and the like may be stored using the history identifier  1025 . Similarly, if a user is using an audio player, a playlist may be stored using the history identifier  1025 . 
         [0135]    A user who is watching TV may receive information about a frequently watched channel. The terminal identifier  1021  may perform a role in the history identifier  1025 . A related description will be provided further on in the present disclosure. 
         [0136]      FIG. 11  is a diagram illustrating services offered by an electronic device according to an embodiment of the present disclosure. 
         [0137]    Referring to  FIG. 11 , at step S 1120 , a terminal  1111  transmits a terminal identifier to an electronic device  1115 . Then, at step S 1130 , the electronic device  1115  may offer a history of a previously provided services to the user. Namely, the electronic device  1115  may store, using the terminal identifier, previously provided services and, when the terminal identifier is received, may offer the stored services to the user. 
         [0138]    For example, if a user is watching TV  1115 , the terminal  1111  of the user may transmit the terminal identifier to the TV  1115 . The TV  1115  may offer to the user, a list of recently watched channels, a list of played content, a user&#39;s wish list, and a list of content shared with the terminal. 
         [0139]    As indicated by reference number  1150 , a terminal  1151  may transmit a terminal identifier  1153  to an electronic device  1155  at step S 1160 , and the electronic device  1155  may transmit a response to the terminal  1151  at step S 1170 . At step S 1180 , the electronic device  1155  may offer a stored service to the user through the terminal identifier  1153 . For example, the electronic device  1155  may continuously play certain content which has been played by the user. Alternatively, the electronic device  1155  may offer a list of user&#39;s favorite content. Alternatively, certain content being played at the terminal may be continuously played on the TV. 
         [0140]    At step S 1190 , the electronic device  1155  may offer streaming of a user&#39;s selected video. 
         [0141]    At step S 1190 , the electronic device  1155  may offer streaming of a video which has been streamed to the terminal. 
         [0142]      FIG. 12  is a diagram illustrating another services offered by an electronic device according to still another embodiment of the present disclosure. 
         [0143]    Referring to  FIG. 12 , like  FIG. 11 , an electronic device  1210  may store, using the terminal identifier, a previously provided playlist and then offer the stored playlist to the user. 
         [0144]    For example, if the user is using an audio player  1210 , a terminal A  1220  transmits a terminal identifier A  1225  to the audio player  1210 . Then the audio player  1210  may offer to the user, a playlist of the terminal A  1220  stored using the terminal identifier A  1225 . Alternatively, the audio player  1210  may continuously play an audio file which has been played at the terminal A  1220 . Another terminal B  1230  of the same user may transmit a terminal identifier B  1235  to the audio player  1210 , and then the audio player  1210  may receive a playlist, stored in association with the terminal identifier B  1235 , from a server  1240 . The audio player  1210  may sequentially play such playlists received from the terminal A  1220  and the terminal B  1230 . 
         [0145]    While a playlist is transmitted from the server  1240  to the audio player  1210  by using the terminal identifier B  1235  of the terminal B  1230 , information about favorite channels may be transmitted to the TV  1250  by the terminal identifier B  1235  of the terminal B  1230 . 
         [0146]      FIG. 13  is a diagram illustrating a process of operating an electronic device based on the position of a terminal according to an embodiment of the present disclosure. 
         [0147]    The electronic device is capable of communication, e.g., short range communication. 
         [0148]    Step S 1310  shows that a user having a terminal  1311  approaches room A. The terminal  1311  continuously or periodically broadcasts information such as a terminal identifier thereof. 
         [0149]    When the terminal  1311  arrives at a given distance capable of communication with an electronic device  1321  located in the room A, the electronic device  1321  may recognize the position of the terminal  1311  at step S 1320 . The electronic device  1321  recognizes that the terminal  1311  is within a given distance, and then transmits the distance or position of the terminal  1311  to a control device  1331 . 
         [0150]    The control device  1331  may identify the position of the terminal  1311  at step S 1330  and then transmit a signal for controlling the electronic device  1321  to the electronic device  1321  at step S 1340 . Therefore, the electronic device  1321  may operate according to the control signal. 
         [0151]    If the user having the terminal  1311  moves from room A to another room B, the electronic device  1321  located in room A and another electronic device  1351  located in room B may identify the position of the terminal  1311 . If the terminal  1311  is located between room A and room B, each electronic device may compare the signal strength from the terminal  1311  and thereby select a specific electronic device having greater signal strength. In this case, the control device  1331  may control the selected electronic device to operate. 
         [0152]      FIG. 14  is a diagram illustrating the process of controlling an electronic device according to an embodiment of the present disclosure. 
         [0153]    In  FIG. 14 , an electronic device  1411  is capable of communication with a terminal  1401 . In an embodiment of the present disclosure, the electronic device  1411  may communicate with the terminal  1401  through Bluetooth™, for example. 
         [0154]    At step S 1410 , the terminal  1401  transmits identification information for identifying the terminal  1401  to the electronic device  1411 . At this step, the terminal  1401  may further transmit account information for identifying a user thereof. The electronic device  1411  receiving the identification information transmits a scan request packet at step S 1420 . The electronic device  1411  transmits the scan request packet in order to perform communication with the terminal  1401 . For example, using the scan request packet, the electronic device  1411  may be connected to the terminal  1401  through Bluetooth™. 
         [0155]    When the scan request packet is received, the terminal  1401  transmits control information to a server at step S 1430 . At step S 1450 , the server controls an electronic device on the basis of the received control information. 
         [0156]    The control information transmitted by the terminal may contain a service identifier, and electronic devices may form a mesh network and be controlled respectively. 
         [0157]    Alternatively, the control information may contain a destination address of a specific electronic device to be controlled, and the server may control such electronic devices by transmitting the control information to the respective electronic devices. 
         [0158]    The terminal  1401  that receives the scan request packet may transmit a scan response packet to the electronic device  1411  at step S 1440  so as to be connected to the electronic device  1411  through Bluetooth™, for example. 
         [0159]    The electronic device  1411  receiving the scan response packet may perform an authentication process for the terminal  1401  as discussed above. Alternatively, the authentication process may be performed when the electronic device  1411  receives the identification information at step S 1410 . 
         [0160]    At step S 1460 , the electronic device  1411  receiving the scan response packet transmits identification information to a gateway  1431 . Identification information includes identification information about the terminal and identification information about the electronic device. 
         [0161]    The gateway  1431  receiving the identification information transmits a scan request packet to the electronic device  1411  at step S 1470  to communicate with the electronic device  1411 . At step S 1480 , the electronic device  1411  transmits a scan response packet to the gateway  1431  and is connected to the gateway  1431 . 
         [0162]    As discussed above, in the case where communication connections are established between the terminal and the electronic device and between the electronic device and the gateway, the terminal may control electronic devices through the electronic device and the gateway at step S 1490 . Such electronic devices may form a mesh network as discussed above. 
         [0163]      FIG. 15  is a diagram illustrating a protocol stack for control of an electronic device through another electronic device and a gateway at a terminal according to an embodiment of the present disclosure. 
         [0164]    The typical structure of a Bluetooth™ communication stack performs point-to-point communication only between a master stack and a slave stack. When a terminal and a gateway are connected to each other, only a single stack mode is available. 
         [0165]    An electronic device  1520  of the present disclosure operates in a slave mode in the case of communication with the terminal and operates in a master mode in case of communication with the gateway. 
         [0166]    When the electronic device communicates with the terminal, the electronic device operates in slave mode, and the terminal operates in master mode. The electronic device may receive a terminal identifier and an authentication code from the terminal. 
         [0167]    The electronic device should also transmit the authentication code to the gateway in order to perform an authentication process, and also a stackloader and handler  1531  performs a stack load and conversion of a master mode. A message for a connection based on a master mode is transmitted to the gateway, and the electronic device may be connected in master mode to the gateway. The gateway performs authentication by receiving the authentication code from the electronic device and also transmits an authentication result to the electronic device. 
         [0168]    Using the stackloader and handler  1531 , the electronic device may operate as a master stack and a slave stack, and trilateral communication may be performed among the terminal, the electronic device and the gateway. Therefore, the terminal may control electronic devices through the electronic device and the gateway. 
         [0169]    While the present disclosure has been particularly shown and described with reference to embodiments thereof, it will be understood by those skilled in the art that changes in form and details may be made therein without departing from the spirit and scope of the disclosure as defined by the appended claims.