Wi-Fi P2P connection method, electronic device, program product, and medium
AssigneeHonor Device Co., Ltd.
InventorShenghui Yan
Life of this patent
Estimating the term…
Abstract
This application provides a Wi-Fi P2P connection method, an electronic device, a program product, and a readable storage medium. A first device and a second device access a network by using different channels in a same band. The first device determines a device with a weaker switching capability by using Wi-Fi module intra-band inter-channel switching capability values of the first device and the second device, and establishes a P2P connection by using a STA channel through which the device with the weaker switching capability accesses the network.
Claims20
A Wireless Fidelity (Wi-Fi) Peer-To-Peer (P2P) connection method, applied to a first device, wherein the first device and a second device access a network by using different channels in a same band, and the Wi-Fi P2P connection method comprises:
- obtaining, by the first device, a first Wi-Fi module intra-band inter-channel switching capability of the first device, and establishing a connection channel with the second device;
- receiving, by the first device, a second Wi-Fi module intra-band inter-channel switching capability of the second device and a station (STA) channel through which the second device accesses the network that are sent by the second device through the connection channel established with the first device;
- determining, by the first device, which of the first device and the second device has a weaker switching capability according to the first Wi-Fi module intra-band inter-channel switching capability and the second Wi-Fi module intra-band inter-channel switching capability;
- and
- establishing, by the first device, a Wi-Fi P2P connection with the second device according to the STA channel through which the second device accesses the network when it is determined that the second device has the weaker switching capability than the first device.
An electronic device, configured to act as a first device, and the electronic device comprising:
- one or more processors, a memory, and a wireless communications interface, wherein
- the memory and the wireless communications interface are coupled to the one or more processors, the memory is configured to stores computer program code, the computer program code comprises computer instructions, and when the one or more processors execute the computer instructions, the electronic device performs the following:
- obtaining a first Wireless Fidelity (Wi-Fi) module intra-band inter-channel switching capability of the first device, and establishing a connection channel with a second device;
- receiving a second Wi-Fi module intra-band inter-channel switching capability of the second device and a station (STA) channel through which the second device accesses a network that are sent by the second device through the connection channel established with the first device;
- determining which of the first device and the second device has a weaker switching capability according to the first Wi-Fi module intra-band inter-channel switching capability and the second Wi-Fi module intra-band inter-channel switching capability;
- and
- establishing a Wi-Fi Peer-To-Peer (P2P) connection with the second device according to the STA channel through which the second device accesses the network when it is determined that the second device is the device has the weaker switching capability than the first device.
Dependencies are inferred from the claim text.