主权项 |
1. A method of discovering and connecting devices to form a network, the method comprising:
temporarily renaming a first device, by a wireless personal area network (WPAN) module executed on the first device, with a temporary device name in a WPAN name field of the first device; making, by the WPAN module, the first device discoverable based on the temporary device name; performing, by the WPAN module, a WPAN scan for nearby devices with the same temporary device name in their WPAN name fields; based on the WPAN scan, saving, by the WPAN module, MAC address of any of the nearby devices found with the same temporary device name in its respective WPAN name field so that the first device knows which of the found nearby devices are to take part in forming a network; changing, by the WPAN module, the temporary device name in the WPAN name field of the first device to another device name; and connecting, by a Wi-Fi module executed on the first device, the first device to a second device in the found nearby devices to form the network. |