Wireless roaming method and electronic equipment
In a wireless LAN, the site device tries to establish a connection with other access point devices when receiving a roaming request, and re-establishes a connection with the original access point device if it fails, solves the problem of wireless network interruption and improves the user experience .
Patent Information
- Application Number
- CN202310873295.2
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2023-07-17
- Publication Date
- 2025-01-17
AI Technical Summary
In a wireless LAN, when the signal distance between the site device and the access point device increases during the movement, the network signal becomes weaker. The access point device sends a roaming request to the site device to switch to other access point devices, but if If the switch fails or there is no other access point device connected, the site device may be disconnected from the network, affecting the user experience.
When the site device receives a roaming request, it tries to establish a connection with the access point device with the highest signal strength detected. If it fails, it disconnects the connection with the original access point device before the preset time and reconnects with the original. The point device establishes a connection to avoid disconnection and maintains the network connection through reassociation.
It effectively avoids frequent network disconnection of site equipment in wireless networks, improves users' network usage experience, and reduces the impact of multiple roaming requests on site equipment due to access point equipment.
Smart Images

Figure CN119325116A_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of communications, and in particular to a wireless roaming method and electronic equipment. Background Art
[0002] In wireless local area network technology, station devices (STA) such as mobile phones, laptops or wearable devices can achieve wireless network connection through access point devices (AP). Usually, the communication between AP and STA is affected by the transmission distance. Therefore, multiple APs can be deployed in public areas such as shopping malls to achieve network coverage in a larger space.
[0003] Currently, as the STA moves, the distance between the STA and the connected AP increases, and the AP can detect that the STA network signal becomes weaker. In this way, the AP can send a basic service set transfer management (BSS transition management, BTM) roaming request to the STA, instructing the STA to switch to other APs that are closer and have stronger network signals.
[0004] However, when the BTM roaming request sent by the AP to the STA includes information for instructing the STA to disassociate with the AP, if the STA fails to connect to other APs or there are no other connectable APs, the STA may be disconnected from the AP, causing the site device to be disconnected from the network, affecting the user's Internet experience. Summary of the invention
[0005] The present application provides a wireless roaming method and electronic device to avoid the situation where site equipment is disconnected from the network as much as possible and ensure the user's Internet experience.
[0006] In a first aspect, the present application provides a wireless roaming method, which is applied to a site device, where the site device accesses a wireless local area network through a first access point device or a second access point device, and the method includes:
[0007] In the process of connecting with the first access point device, upon receiving a first message sent by the first access point device, determining a second access point device, the first message being used to instruct the site device to perform wireless roaming, and the second access point device being an access point device for which the site device detects that the network signal strength is greater than a first threshold and the network signal strength is the highest;
[0008] Sending a second message to the second access point device, where the second message is used to request to establish a connection with the second access point device;
[0009] Upon receiving a first response message returned by the second access point device based on the second message, determining whether the first message includes first information, the first information being used to instruct the site device to disconnect from the first access point device before the first moment, and the first response message indicating that the second access point device cannot establish a connection with the site device;
[0010] When the first information is included in the first message, a connection is established again with the first access point device before a second time, and the second time is earlier than or equal to the first time.
[0011] In the above method, when receiving the first message for instructing the site device to perform wireless roaming, the site device can determine that the access point device with the highest network signal strength is the second access point device from the access point devices that detect that the network signal is greater than the first threshold, and try to connect with the second access point device through the second message. When the site device fails to establish a connection with the second access point device and the first message includes first information for instructing the site device to disconnect from the first access point device before the first moment, the site device can re-establish a connection with the first access point device before the second moment, that is, before the first access point device actively disconnects from the site device, causing the site device to be disconnected from the network, the site device re-forms a data channel with the first access point device to update the connection status with the first access point device. In this way, the site device is associated with the first access point device again through re-association self-healing, thereby avoiding the site device from being disconnected from the network.
[0012] In combination with the first aspect, in some implementations of the first aspect, when the first information is included in the first message, establishing a connection with the first access point device again before the second time includes:
[0013] When the first information is included in the first message, a first function is disabled, where the first function is a basic service set transfer management roaming function;
[0014] A connection is established again with the first access point device before the second time.
[0015] In the above method, when the site device fails to establish a connection with the second access point device and the first message includes first information for instructing the site device to disconnect from the first access point device before the first moment, the first function can be turned off first, and then the connection with the first access point device can be re-established before the second moment. As a result, the first access point device no longer sends the first message to the site device, thereby reducing the situation where the site device frequently disconnects from the wireless network in a weak network scenario, suppressing the impact of the access point device repeatedly initiating roaming requests on the site device, and improving the user's network usage experience.
[0016] In combination with the first aspect, in some implementations of the first aspect, when the first information is included in the first message, disabling the first function includes:
[0017] When the first information is included in the first message, determining whether the number of failures within the first time period is greater than or equal to a preset number of times, the number of failures being the number of times the station device fails to establish a connection with the second access point device;
[0018] When the number of failures is greater than or equal to the preset number, the first function is turned off.
[0019] In the above method, when the site device fails to establish a connection with the second access point device, the first message includes first information for instructing the site device to disconnect from the first access point device before the first moment, and the number of failures within the first time period is greater than or equal to the preset number of times, it can be more certain that the connection with the second access point device cannot be established. Therefore, the first function can be turned off first, and then the connection with the first access point device can be re-established before the second moment.
[0020] In combination with the first aspect, in some implementations of the first aspect, establishing a connection with the first access point device again before the second moment includes:
[0021] Sending a third message to the first access point device, where the third message is used to request to establish a connection with the first access point device again;
[0022] When receiving the fourth message returned by the first access point device based on the third message, a connection is established with the first access point device, and the fourth message is used to indicate that the first access point device accepts to establish a connection with the first access point device again.
[0023] In the above method, the station device may establish a connection with the first access point device based on a third message used to request to re-establish a connection with the first access point device.
[0024] In combination with the first aspect, in some implementations of the first aspect, the third message includes second information, where the second information is used to indicate that the site device does not support the first function.
[0025] In the above method, if the site device turns off the first function, it can carry the second information when sending the third message, and notify the first access point device through the second information that the site device does not support the first function. Therefore, when the access point device receives the third message, it may no longer send the first message to the site device.
[0026] In combination with the first aspect, in some implementations of the first aspect, when the first information is included in the first message, determining whether the number of failures within the first time period is greater than or equal to a preset number includes:
[0027] When the first information is included in the first message, a basic service set identifier and first time information are recorded, where the basic service set identifier is used to indicate the second access point device, and the first time information is the time when a connection with the second access point device fails;
[0028] It is determined, according to the basic service set identifier and the first time information, whether the number of failures within the first time period is greater than or equal to a preset number.
[0029] In the above method, the site device may record the basic service set identifier corresponding to the second access point device and the time information of the failure each time the connection establishment with the second access point device fails, so as to determine the number of failures according to the basic service set identifier and the time information.
[0030] In combination with the first aspect, in some implementations of the first aspect, the method further includes:
[0031] Determine a second duration according to the time indicated by the first time information and the current time;
[0032] When the second duration is greater than or equal to the preset duration threshold, the first time information and the basic service set identifier corresponding to the first time information are deleted.
[0033] In the above method, when the site device determines that the storage duration of a basic service set identifier and the corresponding time information is greater than or equal to the preset duration threshold based on the moment indicated by the first time information and the current moment, the basic service set identifier and the corresponding time information can be deleted, so that the memory of the site device is partially released.
[0034] In combination with the first aspect, in some implementations of the first aspect, when the first information is included in the first message, establishing a connection with the first access point device again before the second time includes:
[0035] When the first information is included in the first message, determining whether the number of failures within the first time period is greater than or equal to a preset number;
[0036] When the number of failures is less than the preset number, a connection is established with the first access point device again before the second moment.
[0037] In the above method, when the number of failures within the first time period is less than a preset number, the site device may re-establish a connection with the first access point device before the second time.
[0038] In combination with the first aspect, in some implementations of the first aspect, the method further includes:
[0039] After successfully establishing a connection with the second access point device, disconnecting the connection with the first access point device;
[0040] When a fifth message sent by the second access point device is received and it is determined that the first access point device is the access point device whose network signal strength detected by the site device is greater than the first threshold and has the highest network signal strength, a connection is established with the first access point device.
[0041] In the above method, the site device may roam successfully or fail on one access point device, and may roam successfully or fail on another access point device. In this case, if the number of roaming failures of the site device on any access point device before the first moment is less than a preset number, reassociation with the first access point device may be performed; if the number of roaming failures of the site device on any access point device before the first moment is greater than or equal to a preset number, the first function may be disabled first, and then reassociation with the first access point device may be performed.
[0042] In a second aspect, the present application provides a wireless roaming method, which is applied to a first access point device, the first access point device is applied to a wireless roaming system, the wireless roaming system includes a site device, a first access point device, and a second access point device, the site device accesses a wireless local area network through the first access point device or the second access point device, the method comprising:
[0043] When it is detected that the network signal strength of the site device is less than a second threshold, sending a first message to the site device, where the first message is used to instruct the site device to perform wireless roaming;
[0044] When it is detected that the network signal strength of the site device is less than a second threshold, sending a first message to the site device, where the first message is used to instruct the site device to perform wireless roaming;
[0045] receiving a third message sent by the station device to the first access point device when determining that the connection with the second access point device fails, where the third message is used to request to establish a connection with the first access point device again;
[0046] A second response message is sent to the site device, where the second response message is used to indicate that the first access point device accepts to establish a connection with the site device again.
[0047] In the above method, the first access point device accepts to re-establish a connection with the site device, that is, before the first access point device actively disconnects from the site device so that the site device is disconnected from the network, the site device reconnects with the first access point device to update the connection status with the first access point device. In this way, the site device can associate with the access point device again through re-association self-healing, thereby avoiding the site device from being disconnected from the network.
[0048] In combination with the second aspect, in certain implementations of the second aspect, when the site device turns off the first function, the third message includes second information, and the second information is used to indicate that the site device does not support the first function, and the first function is a basic service set transfer management roaming function.
[0049] In the above method, the first access point device may determine that the site device does not support the first function through the second information carried in the received third message, so that the first access point device may no longer send the first message to the site device when receiving the third message.
[0050] In conjunction with the second aspect, in some implementations of the second aspect, the method further includes:
[0051] When the second information is included in the third message, the second information is stored.
[0052] In the above method, when the third message includes the second information, the second information is stored so that the first access point device will no longer send the first message to the site device according to the stored second information when it detects that the network signal strength of the site device is less than the second threshold next time.
[0053] In combination with the second aspect, in some implementations of the second aspect, after sending the second response message to the site device, the method further includes:
[0054] Stop sending a first message to the site device, where the first message is used to instruct the site device to perform wireless roaming.
[0055] In the above method, when the second information is included in the third message, the first access point device stops sending the first message to the site device, which can avoid the first access point device instructing the site device to perform wireless roaming again. This reduces the frequent disconnection of the wireless network of the site device in a weak network scenario, suppresses the impact of the access point device initiating BTM roaming requests multiple times on the site device, and improves the user's network usage experience.
[0056] In a third aspect, the present application provides an electronic device, comprising one or more processors, a memory, and one or more computer programs, wherein the one or more computer programs are stored in the memory, and when the computer programs are executed by the one or more processors, the electronic device executes the wireless roaming method in the first aspect and any possible implementation of the first aspect, and / or the wireless roaming method in the second aspect and any possible implementation of the second aspect.
[0057] In a fourth aspect, the present application provides a chip system, which includes a processor for calling and running a computer program from a memory, so that a site device equipped with the chip system executes the wireless roaming method in the first aspect and any possible implementation of the first aspect, and / or the wireless roaming method in the second aspect and any possible implementation of the second aspect.
[0058] In a fifth aspect, the present application provides a computer-readable storage medium, including a computer program. When the computer program runs on an electronic device, the site device executes the wireless roaming method in the first aspect and any possible implementation of the first aspect, and / or the wireless roaming method in the second aspect and any possible implementation of the second aspect.
[0059] In a sixth aspect, the present application provides a computer program product. When the computer program product runs on a computer, it enables the computer to execute the wireless roaming method in the first aspect and any possible implementation of the first aspect, and / or the wireless roaming method in the second aspect and any possible implementation of the second aspect.
[0060] It can be understood that the beneficial effects of the third to sixth aspects mentioned above can be found in the relevant descriptions in the first and / or second aspects mentioned above, and will not be repeated here. BRIEF DESCRIPTION OF THE DRAWINGS
[0061] Figure 1 A schematic diagram of the relationship between a site device and an access point device provided in an embodiment of the present application;
[0062] Figure 2 A schematic diagram of the structure of a site device provided in one embodiment of the present application;
[0063] Figure 3 A schematic diagram of the software architecture of a site device provided in one embodiment of the present application;
[0064] Figure 4 A flowchart of a wireless roaming method provided in one embodiment of the present application;
[0065] Figure 5 A flowchart of a wireless roaming method provided in one embodiment of the present application;
[0066] Figure 6 A flowchart of a wireless roaming method provided in one embodiment of the present application;
[0067] Figure 7 A flowchart of a wireless roaming method provided in one embodiment of the present application;
[0068] Figure 8 A flowchart of a wireless roaming method provided by an embodiment of the present application is provided. DETAILED DESCRIPTION
[0069] In this application, "at least one" means one or more, and "plurality" means two or more. "And / or" describes the association relationship of associated objects, indicating that three relationships may exist. For example, A and / or B can represent: A exists alone, A and B exist at the same time, and B exists alone, where A and B can be singular or plural. The character " / " generally indicates that the associated objects before and after are in an "or" relationship. "At least one of the following" or similar expressions refers to any combination of these items, including any combination of single items or plural items. For example, at least one of a, b, or c alone can represent: a, b, c, a and b, a and c, or a, b, and c, where a, b, and c can be single or multiple. In addition, the terms "first" and "second" are used for descriptive purposes only and cannot be understood as indicating or implying relative importance.
[0070] Wireless local area network (WLAN) is a local area network used for wireless data transmission.
[0071] like Figure 1 As shown, in a WLAN, each station device (STA) can perform wireless roaming between multiple access point devices (AP), and an access controller (AC) can centrally manage and control multiple APs to ensure smooth switching to different APs during wireless roaming.
[0072] Access controller (AC), also known as wireless controller. AC is a network device responsible for centralized management and control of APs in WLAN. AC provides functions such as access point (AP) configuration, security policy, roaming management and user authentication.
[0073] Access point device (AP), also known as wireless access point. AP is a device that connects station devices to a wireless LAN. As a transmitter and receiver of wireless signals, AP can provide wireless connection and network access for station devices within a specific range.
[0074] A station (STA) is also called a station. A STA can be any terminal device (such as a mobile phone, laptop, or tablet). A STA can access a wireless network and transmit data by establishing a connection with an AP.
[0075] In WLAN, multiple APs are deployed in different locations (for example, multiple stores in a shopping mall) to cover a specific area or range, and there are overlapping signal coverage areas between APs. When a STA enters the network coverage of multiple APs, it scans for available APs and sends a connection request to establish a connection with a new AP. In other words, when a STA leaves the coverage of an AP, the STA can try to establish a connection with other nearby APs to maintain an uninterrupted network connection. This process is called wireless roaming.
[0076] That is to say, as the STA moves, the distance between the AP and the connected STA increases, and the AP can detect that the network signal of the STA becomes weaker. In this way, the AP can send a basic service set transfer management (BSS transition management, BTM) roaming request to the STA, instructing the STA to switch to other APs with better network quality (closer distance and stronger network signal).
[0077] However, frequent switching of APs affects the user's Internet experience. If the BTM roaming request sent by the AP to the STA includes information for instructing the STA to disassociate with the AP, if the STA fails to connect to other APs or there are no other connectable APs, the STA may be disconnected from the AP, causing the site device to be disconnected from the network, affecting the user's Internet experience.
[0078] In view of the above problems, the present application can provide a wireless roaming method, an electronic device, a chip system, a computer-readable storage medium and a computer program product. Considering that the association disconnection tag included in the roaming request received by the site device is 1 (indicating that the site device releases the association with the access point device), if the site device fails to connect to other access point devices or there are no other connectable access point devices, the site device will be disconnected from the access point device, causing the site device to be disconnected from the network. Therefore, when the site device receives the roaming request, the roaming fails, and the association disconnection tag is 1, it can initiate re-association with the originally connected access point device again and associate with the original access point device. Based on this, the site device can associate with the access point device again by re-association self-healing, which can avoid the situation where the site device frequently disconnects from the wireless network as much as possible, thereby ensuring the user's network usage experience.
[0079] The electronic device may be a station device or an access point device. The wireless roaming method is applied to the station device and the access point device. The station device and the access point device may communicate via a network.
[0080] For example, the site device may be a mobile phone, tablet computer, vehicle-mounted device, laptop computer, wearable device, ultra-mobile personal computer (UMPC), netbook, personal digital assistant (PDA), smart car, smart TV, robot, etc.
[0081] For example, the access point device may be a router or other device.
[0082] It should be noted that in some possible implementations, the site device may also be called a terminal device, and the site device may also be called an electronic device, a user equipment (UE), etc., and the embodiments of the present application do not limit this.
[0083] For ease of explanation, Figure 2 In the example, the site device 100 is a mobile phone.
[0084] like Figure 2 As shown, the site device 100 may include a processor 101, a communication module 102, a display screen 103, a camera 104, a sensor 105, an internal memory 106, a USB interface 107, an external memory interface 108, a charging management module 109, a power management module 110, and a battery 111, etc.
[0085] The processor 101 may include one or more processing units, for example, the processor 101 may include an application processor (AP), a modem processor, a graphics processor, an image signal processor (ISP), a controller, a memory, a video stream codec, a digital signal processor (DSP), a baseband processor, and / or a neural-network processing unit (NPU), etc. Different processing units may be independent devices or integrated in one or more processors 101.
[0086] The controller may be the nerve center and command center of the site device 100. The controller may generate an operation control signal according to the instruction operation code and the timing signal to complete the control of fetching and executing instructions.
[0087] The processor 101 may also be provided with a memory for storing instructions and data.
[0088] In some embodiments, the memory in the processor 101 is a cache memory. The memory can store instructions or data that the processor 101 has just used or cyclically used. If the processor 101 needs to use the instruction or data again, it can be directly called from the memory. This avoids repeated access, reduces the waiting time of the processor 101, and thus improves the efficiency of the system.
[0089] In some embodiments, the processor 101 may include one or more interfaces. The interface may include an inter-integrated circuit (I2C) interface, an inter-integrated circuit sound (I2S) interface, a pulse code modulation (PCM) interface, a universal asynchronous receiver / transmitter (UART) interface, a mobile industry processor interface (MIPI), a general-purpose input / output (GPIO) interface, a subscriber identity module (SIM) interface, and / or a universal serial bus (USB) interface, etc.
[0090] The modem processor may include a modulator and a demodulator. Among them, the modulator is used to modulate the low-frequency baseband signal to be sent into a medium-high frequency signal. The demodulator is used to demodulate the received electromagnetic wave signal into a low-frequency baseband signal. The demodulator then transmits the demodulated low-frequency baseband signal to the baseband processor for processing. After the low-frequency baseband signal is processed by the baseband processor, it is passed to the application processor. The application processor outputs a sound signal through an audio device (not limited to a speaker 170A, a receiver 170B, etc.), or displays an image or video through a display screen 103. In some embodiments, the modem processor may be an independent device. In other embodiments, the modem processor may be independent of the processor 101 and be set in the same device as the mobile communication module 150 or other functional modules.
[0091] The communication module 102 may include antenna 1 and antenna 2, a mobile communication module, and / or a wireless communication module.
[0092] Each antenna in the site device 100 can be used to cover a single or multiple communication frequency bands. Different antennas can also be reused to improve the utilization of the antennas. For example, antenna 1 can be reused as a diversity antenna for a wireless local area network. In some other embodiments, the antenna can be used in combination with a tuning switch.
[0093] The mobile communication module can provide solutions for wireless communications including 2G / 3G / 4G / 5G applied to the site device 100. The mobile communication module may include at least one filter, a switch, a power amplifier, a low noise amplifier (LNA), etc. The mobile communication module may receive electromagnetic waves from the antenna 1, and perform filtering, amplification, and other processing on the received electromagnetic waves, and transmit them to the modulation and demodulation processor for demodulation. The mobile communication module may also amplify the signal modulated by the modulation and demodulation processor, and convert it into electromagnetic waves for radiation through the antenna 1. In some embodiments, at least some of the functional modules of the mobile communication module may be arranged in the processor 101. In some embodiments, at least some of the functional modules of the mobile communication module may be arranged in the same device as at least some of the modules of the processor 101.
[0094] The wireless communication module can provide wireless communication solutions including wireless local area networks (WLAN) (such as wireless fidelity (Wi-Fi) networks), bluetooth (BT), global navigation satellite system (GNSS), frequency modulation (FM), near field communication (NFC), infrared (IR), etc., which are applied to the site device 100. The wireless communication module can be one or more devices integrating at least one communication processing module. The wireless communication module receives electromagnetic waves via antenna 2, modulates and filters the electromagnetic wave signals, and sends the processed signals to processor 101. The wireless communication module can also receive the signal to be sent from processor 101, modulate the frequency, amplify it, and convert it into electromagnetic waves for radiation through antenna 2.
[0095] The display screen 103 is used to display images or videos in the human-computer interaction interface. The display screen 103 includes a display panel. The display panel can be a liquid crystal display (LCD), an organic light-emitting diode (OLED), an active-matrix organic light-emitting diode or an active-matrix organic light-emitting diode (AMOLED), a flexible light-emitting diode (FLED), MiniLED, MicroLED, Micro-OLED, quantum dot light emitting diodes (QLED), etc. In some embodiments, the site device 100 may include 1 or N display screens 103, where N is a positive integer greater than 1.
[0096] The camera 104 is used to capture still images or videos. The object generates an optical image through the lens and projects it onto the photosensitive element. The photosensitive element can be a charge coupled device (CCD) or a complementary metal-oxide-semiconductor (CMOS) phototransistor. The photosensitive element converts the optical signal into an electrical signal, and then transmits the electrical signal to the ISP to be converted into a digital image signal. The ISP outputs the digital image signal to the DSP for processing. The DSP converts the digital image signal into an image signal in a standard RGB, YUV or other format. In some embodiments, the site device 100 may include 1 or N cameras 104, where N is a positive integer greater than 1.
[0097] The charging management module 109 is used to receive charging input from a charger, where the charger can be a wireless charger or a wired charger.
[0098] In some wired charging embodiments, the charging management module 109 may receive charging input from a wired charger through the USB interface 107 .
[0099] In some wireless charging embodiments, the charging management module 109 may receive wireless charging input via a wireless charging coil of the station device 100 . While the charging management module 109 charges the battery 111 , it may also power the station device 100 via the power management module 110 .
[0100] The power management module 110 is used to connect the battery 111, the charging management module 109 and the processor 101. The power management module 110 receives input from the battery 111 and / or the charging management module 109, and supplies power to the processor 101, the internal memory 106, the external memory, and the communication module 102. The power management module 110 can also be used to monitor parameters such as battery capacity, battery cycle number, and battery health status (leakage, impedance).
[0101] In some other embodiments, the power management module 110 may also be disposed in the processor 101 .
[0102] In other embodiments, the power management module 110 and the charging management module 109 may also be disposed in the same device.
[0103] The external memory interface 108 can be used to connect an external memory card, such as a Micro SD card, to expand the storage capacity of the site device 100. The external memory card communicates with the processor 101 through the external memory interface 108 to implement a data storage function. For example, files such as music and video streams are stored in the external memory card.
[0104] The internal memory 106 can be used to store computer executable program codes, which include instructions. The processor 101 executes various functional applications and data processing of the station device 100 by running the instructions stored in the internal memory 106. The internal memory 106 can include a program storage area and a data storage area.
[0105] The program storage area may store an operating system, an application required for at least one function (such as a sound playback function, an image playback function, etc.), etc. The data storage area may store data created during the use of the site device 100 (such as audio data, a phone book, etc.), etc. In addition, the internal memory 106 may include a high-speed random access memory, and may also include a non-volatile memory, such as at least one disk storage device, a flash memory device, a universal flash storage (UFS), etc.
[0106] The sensor 105 in the site device 100 may include image sensors, touch sensors, pressure sensors, gyroscope sensors, air pressure sensors, magnetic sensors, acceleration sensors, distance sensors, proximity light sensors, ambient light sensors, fingerprint sensors, temperature sensors, bone conduction sensors and other components to realize sensing and / or acquisition functions for different signals.
[0107] Optionally, the site device 100 may further include peripheral devices, such as a mouse, a button, an indicator light, a keyboard, a speaker, a microphone, and the like.
[0108] The buttons include a power button, a volume button, etc. The buttons may be mechanical buttons or touch buttons. The site device 100 may receive button inputs and generate key signal inputs related to user settings and function controls of the site device 100.
[0109] The indicator may be a light indicator, which may be used to indicate the charging status and the change in the power level, and may also be used to indicate messages, missed calls, and notifications, etc.
[0110] It can be understood that the structure illustrated in this embodiment does not constitute a specific limitation on the site device 100 .
[0111] In other embodiments, the site device 100 may include more or fewer components than shown, or combine some components, or separate some components, or arrange the components differently. The components shown may be implemented in hardware, software, or a combination of software and hardware.
[0112] Please refer to Figure 3 , is a schematic diagram of a software architecture of a site device provided in an embodiment of the present application. The wireless roaming method provided in an embodiment of the present application is applied to Figure 2 When the site device 100 is shown, the software in the site device 100 can be divided into the following Figure 3 The application layer 201, the hardware abstraction layer (HAL) 202 and the driver layer 203 are shown.
[0113] A plurality of applications may be installed in the application layer 201 , which may include a camera application for implementing a shooting function.
[0114] The camera application refers to a computer program that runs on an operating system and can perform a photo-taking task. When the format of the camera application is an Android application package (APK) format, the camera application can run on an Android operating system.
[0115] In the embodiment of the present application, the camera application may be an application with a shooting function. For example, an application with the function of sharing short videos can be used as the camera application in the embodiment of the present application if it has a shooting function.
[0116] The hardware abstraction layer 202 is a software located between the operating system kernel and the hardware circuit, and is generally used to abstract the hardware to enable the interaction between the operating system and the hardware circuit at the logical layer. In the embodiment of the present application, the hardware abstraction layer 202 may include a camera hardware abstraction layer (camera HAL) that enables the interaction between the camera application and the image sensor at the logical layer.
[0117] The driver layer 203 may be installed with a plurality of drivers for driving the hardware.
[0118] It should be noted that the application layer 201, the hardware abstraction layer 202 and the driver layer 203 may also include other contents, which are not specifically limited here.
[0119] Next, combine Figure 4-Figure 6 This application takes a site device and an access point device as an example, and combines the accompanying drawings and application scenarios to elaborate on the wireless roaming method provided in the embodiments of the present application.
[0120] Next, combine Figure 4-Figure 6 , two implementation methods of the wireless roaming method provided in the embodiments of the present application are described in detail respectively.
[0121] Implementation method 1
[0122] Exemplarily, when access point device (AP) 1 sends a roaming request to station device (STA), STA fails to connect to APs other than AP1, and the value of the disassociation imminent tag included in the roaming request is 1, and the number of connection failures of APs other than AP1 reaches a preset number i, STA can turn off the basic service set transfer management (BSS transition management, BTM) roaming function and initiate reassociation to AP1 so that STA can connect to AP1 again; Figure 4 shown.
[0123] Figure 4 FIG. 1 is a flow chart of a wireless roaming method provided by the present application. Figure 4 As shown, the method can be divided into two different stages, namely 1.1 first connection stage and 1.2 second connection stage.
[0124] 1.1 The first connection stage
[0125] The first connection stage can be understood as the stage where the access point device (AP) 1 detects that the network signal strength of the station device (STA) is less than a threshold value 1, and guides the STA to roam, that is, to connect to an AP (such as AP2) other than AP1, and the connection fails; for example, Figure 4 S11-S17 shown.
[0126] S11. The station device sends an extensible authentication protocol start message to access point device 1.
[0127] The extensible authentication protocol start (EAPOL start) message is used to instruct the access point device 1 to start the extensible authentication protocol (EAP) for the station device.
[0128] EAPOL is a protocol for authentication on IEEE 802.x networks. EAPOL is commonly used in wireless LANs to ensure that station devices connected to access point devices have legitimate identities and conduct secure data transmission.
[0129] It is understandable that when a station device connects to a new access point device and needs to perform identity authentication, the station device can send an EAPOL Start message to the access point device to start the authentication process. The EAPOL Start message is used to establish contact with the corresponding access point device and request identity authentication.
[0130] The Extensible Authentication Protocol startup message may include but is not limited to at least one authentication credential parameter such as an identity identification number (Identity, ID), a mobile phone number, a user name, and a digital certificate of the user to which the site device belongs.
[0131] The user name may include but is not limited to the user name of the user of the site device. For example, the user name of the user of the site device may include characters, letters, binary numbers, and the like.
[0132] Furthermore, any two authentication credential parameters in the Extensible Authentication Protocol Start message correspond one to one, that is, any authentication credential parameter in the Extensible Authentication Protocol Start message can be associated with the remaining authentication credential parameters in the Extensible Authentication Protocol Start message.
[0133] For example, the site device may determine identity authentication credential parameters such as a mobile phone number, a user name, and a digital certificate of the corresponding user of the site device based on the ID of the user to which the site device belongs.
[0134] Therefore, the station device sends the Extensible Authentication Protocol Start message to the access point device 1, so that the access point device can authenticate the station device when receiving the Extensible Authentication Protocol Start message.
[0135] S12. The access point device 1 sends an Extensible Authentication Protocol success message to the station device.
[0136] The extensible authentication protocol success (EAP Success) message is part of the authentication process of the extensible authentication protocol (EAP) and is used to indicate that the authentication is successful.
[0137] Based on S11, the access point device 1 may receive the extensible authentication protocol start message, whereby the access point device 1 can interact with the wireless controller according to the authentication credential parameters in the extensible authentication protocol start message to complete the identity authentication.
[0138] Specifically, when the wireless controller effectively verifies the authentication credentials provided by the site device and successfully authenticates the site device, the wireless controller can generate an authentication result indicating successful authentication and send it to the access point device 1. As a result, the access point device 1 can send an extensible authentication protocol success message to the site device as a confirmation based on the authentication result, indicating that the STA has been successfully authorized to access the AP.
[0139] Based on this, the site device can connect with the access point device to establish a secure data channel.
[0140] S13 : The station device establishes a data channel with the access point device 1 .
[0141] The data channel is a communication path or channel between the station device and the access point device 1 for transmitting actual data.
[0142] It is understandable that once the site device completes identity authentication, it can be connected to the access point device 1 . When the connection is successful, a data channel can be established between the site device and the access point device 1 .
[0143] Based on this, after a data channel is established between the station device and the access point device 1, the station device can send and receive data related to the network connection, such as Internet browsing, file downloading, etc., through the data channel.
[0144] S14: Access point device 1 detects that the network signal strength of the site device is less than threshold 1.
[0145] The access point device 1 can detect in real time the network signal strength of the station device connected to the access point device 1. The smaller the distance between the station device and the access point device 1, the stronger the network signal strength of the station device detected by the access point device 1; the greater the distance between the station device and the access point device 1, the lower the network signal strength of the station device detected by the access point device 1.
[0146] As the position of the site device changes, the distance between the site device and the access point device 1 changes accordingly. When the distance between the site device and the access point device 1 is greater than a preset distance, the network signal strength of the site device detected by the access point device 1 is less than a threshold 1.
[0147] Therefore, when the access point device 1 detects that the network signal strength of the site device is less than the threshold 1, it can determine that the network of the current site device is not good, and can send a roaming request to the site device to make the site device switch to other access point devices except the access point device 1.
[0148] S15. Access point device 1 sends a roaming request to the site device.
[0149] The roaming request is a basic service set transition management roaming request (BSS transition management request, BTM Request), which is a management message sent by access point device 1 to the site device, used to instruct the site device to switch to other available access point devices except access point device 1.
[0150] Furthermore, the roaming request may generally include a disassociation imminent tag, and the access point device 1 controls the roaming behavior through the disassociation imminent tag.
[0151] The about-to-disconnect tag is used to indicate whether the access point device 1 forces the site device to disassociate with the access point device 1 .
[0152] For example, the association is about to be broken flag can be set to 1 or 0.
[0153] When the number of site devices associated with the access point device 1 is greater than or equal to a preset number, resulting in network congestion in the access point device, or when the network signal of the site device associated with the access point device 1 is poor, the access point device 1 may set the disassociation imminent tag included in the roaming request sent to the site device to 1.
[0154] The "Association is about to be disconnected" tag is 1, which means that the access point device 1 instructs the site device to disassociate with the access point device 1 within a preset time. If the preset time is exceeded, the site device fails to connect to other access point devices 1 or there are no other connectable access point devices 1, the access point device 1 will be disconnected from the site device, causing the site device to be disconnected from the network. The "Association is about to be disconnected" tag is 1, which is a signal sent by the access point device 1 to the site device, indicating that the site device should find other available access point devices for switching as soon as possible to maintain a good network connection.
[0155] In some embodiments, the preset duration is pre-set, for example, the preset duration is 2s.
[0156] When the number of site devices associated with the access point device 1 is less than a preset number and the network signal of the site device associated with the access point device 1 is good, the access point device 1 may set the disassociation imminent tag included in the roaming request sent to the site device to 0.
[0157] The value of the tag indicating that the association is about to be disconnected is 0, indicating that the access point device 1 notifies the site device to release the association with the access point device 1 .
[0158] In other words, when the association-to-be-disconnected tag is 1, the site device needs to disassociate with the access point device 1 within a preset time period. If the site device does not disassociate with the access point device 1 within the preset time period, and the site device fails to connect to other access point devices or there are no other connectable access point devices, the access point device 1 can be disconnected from the site device; when the association-to-be-disconnected tag is 0, the site device can disassociate with the access point device 1 within the preset time period, and the site device can also continue to associate with the access point device 1. If the site device continues to associate with the access point device 1, the access point device 1 will not be disconnected from the site device.
[0159] S16: The site device sends a roaming response message to the access point device 1.
[0160] The roaming response message (BSS transition management response, BTM Response) is a response message of the BTM roaming request, indicating confirmation of the roaming request, and is used to instruct the site device to accept a request to switch to other access point devices except the access point device 1.
[0161] Based on S15, it can be known that the site device receives a roaming request for requesting the site device to switch to other available access point devices except access point device 1. Therefore, the site device can send a roaming response message to access point device 1 to notify the site device to accept the request to switch to other access point devices except access point device 1.
[0162] S17 . The site device detects the network signal, and determines that the access point device with the highest network quality is access point device 2 from among the access point devices that have detected the network signal.
[0163] Since the site device accepts the request to switch to other access point devices except access point device 1, the site device can perform roaming evaluation and decision, that is, the site device can detect the network signals of the surrounding access point devices and determine the access point device with the highest network quality according to the order of network signal strength from large to small.
[0164] In some embodiments, the access point device with the highest network quality may be the access point device with the highest signal strength.
[0165] For example, when the site device detects network signals of surrounding access point devices, it can detect signals of three access point devices, namely access point device 0, access point device 2, and access point device 3, which are sorted in descending order of strength as access point device 2, access point device 0, and access point device 3. Therefore, the site device can determine that access point device 2 is the access point device with the highest network quality.
[0166] Thus, the site device determines the access point device with the strongest signal and can prepare to establish a data channel between the site device and the access point device with the highest network quality.
[0167] Based on the above description, when it is detected that the network signal strength of the site device is less than threshold 1, the access point device 1 can instruct the site device to switch to other access point devices except the access point device 1 through the wireless roaming process, so that the access point device 1 can send a roaming request to the site device, and the site device can determine that the access point device needs to be switched. In this way, the site device can determine the access point device with the highest network quality from the access point devices that detect the network signal, and prepare for the site device to establish a data channel with the access point device with the strongest signal.
[0168] 1.2 Second connection stage
[0169] The second connection stage can be understood as the stage in which the STA performs roaming processing when determining that the connection with AP2 fails, initiates re-association with AP1 according to the processing result, and makes AP1 no longer send a roaming request to the STA, so that the STA can re-establish a connection with AP1; for example, Figure 4 S18-S24 shown.
[0170] S18. When the station device fails to establish a connection with the access point device 2, the station device performs a roaming process and initiates a re-association according to the process result.
[0171] It is understandable that the connection between the site device and the access point device may fail when there is interference in the network environment, the network signal is weak, the number of site devices connected to the access point device is greater than or equal to a preset number, etc.
[0172] Similarly, when the network environment is good, the network signal is high, the number of site devices connected to the access point device is less than the preset number, the site device can successfully establish a connection with the access point device.
[0173] When the station device successfully establishes a connection with the access point device, a data channel may be formed between the station device and the access point device.
[0174] If, in S17 , the station device detects that among the access point devices of the network signal, the access point device with the highest network quality is the access point device 2 , then the station device may try to establish a connection with the access point device 2 .
[0175] The station device attempts to establish a connection with the access point device 2, and the connection may be established successfully or fail.
[0176] When the station device fails to establish a connection with the access point device 2, the station device may start a roaming process.
[0177] In some embodiments, the roaming process includes:
[0178] When the site device determines that the value of the disassociation imminent tag included in the roaming request is 1, and the number of connection failures with any access point device other than access point device 1 reaches a preset number i, the site device can turn off the basic service set transfer management (disable BTM) roaming function and initiate re-association to facilitate the site device and the access point device to re-establish a data channel.
[0179] When the site device determines that the disassociation imminent tag value included in the roaming request is 1, and the number of connection failures with any access point device other than access point device 1 does not reach the preset number i, the site device can directly initiate reassociation to facilitate the site device and the access point device to re-establish a data channel.
[0180] Specifically, the specific implementation of S18 can be found in Figure 5 See the relevant description of S181-S186 in .
[0181] like Figure 5 As shown, the wireless roaming method provided by the present application may include:
[0182] S181. The site device determines whether a roaming request is received and the BTM roaming fails.
[0183] When the site device receives the roaming request and the site device successfully establishes a connection with the access point device 2, that is, a data channel is formed between the site device and the access point device 2, the electronic device may determine that the site device BTM roams successfully.
[0184] The site device BTM roams successfully, and the site device can continue to use the wireless network, that is, send and receive data related to the network connection.
[0185] Similarly, when the station device receives a roaming request and the station device fails to establish a connection with the access point device 2, the electronic device may determine that the station device BTM roaming fails.
[0186] When a roaming request is received and the BTM roaming fails, the site device may execute S182; when a roaming request is received and the BTM roaming succeeds, the site device may not execute any step, that is, does not execute S182.
[0187] S182. The site device determines whether the association-to-be-disconnected flag is 1.
[0188] Based on S15, it can be known that the association-to-be-disconnected tag may be 1 or 0. When the association-to-be-disconnected tag included in the wireless roaming message is 1, it can be determined that the association-to-be-disconnected tag in the current step is 1. When the association-to-be-disconnected tag included in the wireless roaming message is 0, it can be determined that the association-to-be-disconnected tag in the current step is 0.
[0189] When roaming fails and the association-to-be-disconnected tag is 0, the site device may not need to perform subsequent steps, that is, the site device continues to be connected to the access point device 1 .
[0190] Similarly, when roaming fails and the association-to-be-disconnected tag is 1, the site device may disassociate with the access point device 1 within a preset time period.
[0191] Therefore, when the association-disconnection-to-be-released tag is 1, the site device may execute S183; when the association-disconnection-to-be-released tag is 0, the site device may not execute any step, that is, does not execute S183.
[0192] S183. The site device records the basic service set identifier, time information, and number of times of the access point device where the BTM roaming fails.
[0193] It should be understood that the service set identifier (SSID) is the name of a wireless local area network, which is used to represent a wireless local area network. The basic service set identifier (BSSID) is the unique identifier of each access point device in a wireless local area network, which is used to distinguish different access point devices in a wireless network.
[0194] Suppose a shopping mall has a wireless LAN, which corresponds to three access point devices, namely: access point device 1, access point device 2 and access point device 0. The service set identifier of the wireless LAN is: Market_WiFi, the basic service set identifier of access point device 1 is: Market_WiFi-ec:co:d1, the basic service set identifier of access point device 2 is: Market_WiFi-ec:co:d2, and the basic service set identifier of access point device 3 is: Market_WiFi-ec:co:d0.
[0195] Correspondingly, when the last BTM roaming failure of the site device occurs and the corresponding site device is access point device 1, the basic service set identifier of the access point device recorded by the site device is Market_WiFi-ec:co:d1.
[0196] When the last BTM roaming failure of the site device occurs and the corresponding site device is access point device 2, the basic service set identifier of the access point device recorded by the site device is Market_WiFi-ec:co:d2.
[0197] When the last BTM roaming failure of the site device occurs and the corresponding site device is the access point device 3, the basic service set identifier of the access point device recorded by the site device is Market_WiFi-ec:co:d0.
[0198] The time information is the time corresponding to when the BTM roaming of the site device fails.
[0199] For example, the time corresponding to the last BTM roaming failure of the site device is 16:05:33 on June 31, 2023.
[0200] The number of times is the number of times the site device fails to roam in the same access point device.
[0201] For example, the access point devices corresponding to the first two BTM roaming failures of the site device are both access point device 1, so the number of roaming failures of the site device on access point device 1 is 2.
[0202] Assume that the corresponding site devices when the site device fails in the previous two BTM roaming attempts are both access point devices 2, and the basic service set identifier of access point device 2 is: Market_WiFi-ec:co:d2.
[0203] Correspondingly, the basic service set identifiers of the access point devices of the first two roaming failures recorded by the site device are both Market_WiFi-ec:co:d2. Correspondingly, the time information of the first two roaming failures on access point device 2 recorded by the site device are 16:05:33 on June 31, 2023 and 16:06:12 on June 31, 2023. The number of BTM roaming failures of the site device on access point device 2 recorded by the site device is 2 times.
[0204] In some embodiments, the site device may delete each basic service set identifier, time information and number of times information recorded when the storage duration is greater than or equal to duration 2, so that the memory of the site device is partially released.
[0205] For example, when duration 2 is 24 hours, the site device records a basic service set identifier, the time information and the number of times at 11:34 on June 6, 2023. The time between 11:34 on June 6, 2023 and the current time 11:34 on June 7, 2023 is 24 hours, which is equal to duration 2. Then, the site device can delete the basic service set identifier, the time information and the number of times.
[0206] There is no particular order in timing between S183 and S182. The site device may execute S183 and S182 sequentially or simultaneously.
[0207] S184. The site device determines whether the number of BTM roaming failures of the site device on the same access point device within the duration 1 is greater than or equal to i times, and the first i-1 times all failed.
[0208] Based on S183, the site device can determine the basic service set identifier of the access point device where the site device's BTM roaming fails, the number of BTM roaming failures, and the time of the BTM roaming failure. Thus, the site device can determine whether the number of BTM roaming failures of the site device on the same access point device within a duration of 1 is greater than or equal to i times, and whether the previous i-1 times failed.
[0209] In some embodiments, duration 1 and number i are pre-set, for example, duration 1 is 10 minutes and i is 5.
[0210] For example, the site device fails to perform BTM roaming on access point device 2 five times within 10 minutes.
[0211] When the number of BTM roaming failures of the site device on the same access point device within time length 1 is greater than or equal to i times, and the first i-1 times all failed, the site device can execute S185; when the number of BTM roaming failures of the site device on the same access point device within time length 1 is less than i times, the site device can execute S186.
[0212] From the above description, it can be seen that when the number of BTM roaming failures of the site device on the same access point device within the duration 1 is less than i times, the site device can initiate re-association and execute S19-S24. When the access point device 1 detects that the network signal strength of the site device is less than the threshold 1, S15-S18 is executed again, and the basic service set identifier, time information and number information of the access point device where the BTM roaming failed is recorded again in S183. In S184, the judgment is made again according to the parameters recorded in S183.
[0213] S185. The site equipment turns off the BTM roaming function.
[0214] Among them, the basic service set transfer management (BSS transition management, BTM) roaming function is a mechanism for site devices to perform wireless roaming (i.e., site devices switch from one access point device to another) on multiple access point devices corresponding to the wireless local area network (WLAN). This function allows site devices to automatically select the best access device during movement and achieve seamless connection.
[0215] The basic service set is used to indicate an access point device. The handover management is used to indicate switching among multiple access point devices.
[0216] When the BTM roaming function is turned on, the site device can determine whether to switch to a new access device by scanning the surrounding network signal strength and quality. This switching usually occurs when the site device moves and the signal of the original access point becomes weak. By performing smooth roaming, the BTM function can help provide better network coverage and connection quality, ensuring that users maintain a good wireless connection status during movement.
[0217] In other words, turning off the BTM roaming function means disabling the function of the site device automatically switching to other access point devices.
[0218] S186. The site device initiates reassociation.
[0219] The reassociation is used to instruct the station device to associate with the access point device 1 again, that is, to establish a data channel.
[0220] In some embodiments, the aforementioned steps may be executed by a driver module corresponding to the wireless local area network in the site device. After the driver module turns off the BTM roaming function, a request to start reassociation may be reported to a request module (supplicant), and the request module initiates reassociation.
[0221] Therefore, the request module in the station device initiates the re-association, which can prepare for the request module to send the re-association request to the access point device 1 according to the request to start the re-association.
[0222] For example, when the duration 1 is 10 minutes and i is 5, if the access point device 1 detects that the network signal strength of the site device is less than the threshold 1, a BTM roaming request is sent to the site device. After receiving the BTM roaming request, the site device sends a roaming response message to the access point device 1. The site device detects the network signal and determines that the access point device with the highest network quality is the access point device 2 from the access point devices that detect the network signal. If the site device fails to establish a connection with the access point device 2, the site device determines that the roaming fails. Thus, the site device determines whether the association-to-be-disconnected tag included in the roaming request is 1. If it is 1, the basic service set identifier, time information, and number information are recorded. If it is determined that the site device fails to roam for the first time at the access point device 1 within 10 minutes based on the basic service set identifier, time information, and number information, the site device initiates reassociation.
[0223] In combination with the above description, if the access point device 1 detects again that the network signal strength of the site device is less than the threshold 1, the BTM roaming request is sent to the site device. After receiving the BTM roaming request, the site device sends a roaming response message to the access point device 1. The site device detects the network signal and determines that the access point device with the highest network quality is still the access point device 2 from the access point devices that detect the network signal. If the site device fails to establish a connection with the access point device 2, the site device determines that the roaming fails. Thus, the site device determines whether the association-to-be-disconnected tag included in the roaming request is 1. If it is 1, the basic service set identifier, time information, and number information are recorded. If it is determined that the site device fails to roam on the access point device 1 for the second time within 10 minutes based on the basic service set identifier, time information, and number information, the site device initiates reassociation.
[0224] If the site device determines that the site device has failed to roam on access point device 1 for the fifth time within 10 minutes based on the basic service set identifier, time information and number information, the site device first turns off the roaming function and then initiates reassociation. It can be understood that during the current reassociation, since the site device turns off the BTM roaming function, access point device 1 no longer sends a BTM roaming request to the site device.
[0225] In summary, when the site device fails to establish a connection with the access point device 2, and the association to be disconnected tag included in the roaming request is 1, and the number of times that any other AP except the access point device 1 fails to establish a connection reaches the preset number i, the site device can turn off the BTM roaming function and re-establish a connection with the access point device 1. Based on this, the access point device 1 no longer sends a BTM roaming request to the site device, and the access point device 1 can no longer actively cancel the association with the site device, which reduces the situation where the wireless network Wi-Fi of the site device is frequently disconnected in a weak network scenario, suppresses the impact of multiple BTM-guided roaming initiated by the access point device side on the site device, and improves the user's network usage experience.
[0226] Moreover, regardless of whether the site device turns off the BTM roaming function, the site device reestablishes a connection with the access point device 1. In this way, in a weak network scenario, the site device can reassociate with the access point device through association self-healing, thereby avoiding frequent disconnection of the wireless network Wi-Fi of the site device.
[0227] S19: The station device sends a reassociation request to the access point device 1.
[0228] The reassoc request is used to request the station device to request to reconnect with the access point device 1, that is, to establish a data channel.
[0229] In S18, if the site device turns off the BTM roaming function, the reassociation request may include information indicating that basic service set transition management (BSS transition management, BTM) roaming is not supported, which is used to instruct the access point device 1 to no longer send a basic service set transition management roaming request (BSS transition management request, BTM Request) to the site device.
[0230] Based on this, if the access point device 1 no longer sends a BTM Request to the site device, the access point device 1 may no longer actively disassociate with the site device, that is, no longer disconnect from the site device, which can reduce the frequent disconnection of the wireless network (Wi-Fi) of the site device in a weak network scenario, and can suppress the impact of multiple BTM-guided roaming initiated by the access point device side on the site device.
[0231] In S18, if the site device has not disabled the BTM roaming function, the reassociation request may include information indicating support for basic service set transition management (BSS transition management, BTM) roaming, indicating that the access point device 1 may continue to send a basic service set transition management roaming request (BSS transition management request, BTM Request) to the site device.
[0232] Alternatively, in S18, if the site device does not disable the BTM roaming function, the reassociation request may not include a message indicating that BTM roaming is not supported, nor a message indicating that BTM roaming is supported, and the access point device 1 may continue to send the BTM roaming request to the site device.
[0233] S20. The access point device 1 sends a reassociation response message to the site device.
[0234] The association response message (reassoc response) is a response message of the reassociation request, indicating confirmation of the reassociation request, and is used to instruct the access point device 1 to accept the reassociation with the station device.
[0235] The access point device 1 sends a reassociation response message to the station device to notify the station device to establish a connection with the access point device again.
[0236] S21 . The station device sends an extensible authentication protocol start message to access point device 1 .
[0237] S22. The access point device 1 sends an Extensible Authentication Protocol success message to the site device.
[0238] Among them, S21 and S22 are Figure 4 The implementation of S11 and S12 in the illustrated embodiment is similar and will not be described in detail here.
[0239] In some embodiments, when the station device attempts to establish a connection with any access point device, S21 and S22 need to be executed.
[0240] S23: Access point device 1 updates status information of the site device.
[0241] It is understandable that when any station device is connected to the access point device 1, the access point device may record the status information of the station device, for example, the status information indicates whether the station device supports (not supported) basic service set transition management (BSS transition management) roaming.
[0242] Since the site device does not disable the basic service set transition management (disable BTM) roaming function in the first connection between the site device and the access point device 1, ie, S11-S13, the state information recorded by the access point device 1 indicates that the site device supports basic service set transition management (BSS transition management) roaming.
[0243] Correspondingly, in S18, if the site device turns off the BSS roaming function, the access point device 1 may update the status information indicating that the site device supports BSS roaming to indicate that the site device does not support BSS roaming.
[0244] Similarly, in S18, if the site device does not perform the step of disabling the basic service set transfer management roaming function, the access point device 1 may maintain the state information indicating that the site device supports basic service set transfer management roaming.
[0245] S24 : The station device establishes a data channel with the access point device 1 .
[0246] Among them, S24 and Figure 4 The implementation of S13 in the illustrated embodiment is similar and will not be described in detail here.
[0247] Based on the above description, when the connection establishment with the access point device 2 fails, that is, the STA fails to connect to the APs other than AP1, and the disassociation imminent tag included in the roaming request is 1, and the number of connection failures of the APs other than AP1 reaches a preset number i, the STA can turn off the basic service set transition management (BSSTransition Management, BTM) roaming function and initiate reassociation, so that the access point device 1 sends a reassociation response message to the site device, so that the site device can establish a data channel with the access point device 1 again, so that the site device can send and receive data related to the network connection.
[0248] In the present application, during the process of connecting the site device to the access point device 1, when the access point device 1 detects that the network signal strength of the site device is less than a threshold value 1, the access point device 1 may send a roaming request to the site device, thereby the site device may determine that the access point device with the highest network quality is the access point device 2 from the access point devices that detect the network signal, and connect to the access point device 2. When the site device fails to establish a connection with the access point device 2, the association to be disconnected tag included in the roaming request is 1, and the number of connection failures of any other AP except the access point device 1 is less than a preset number i, a re-association request including a message for indicating that BTM roaming is not supported is sent to the access point device 1, thereby reducing the situation where the site device is disconnected from the wireless network Wi-Fi in a weak network scenario.
[0249] Furthermore, when the site device fails to establish a connection with the access point device 2, the association to be disconnected tag included in the roaming request is 1, and the number of connection failures to any other AP except the access point device 1 exceeds the preset number i, the site device can turn off the BTM roaming function and send a message re-association request including a message indicating that BTM roaming is not supported to the access point device 1. As a result, the access point device 1 no longer sends a BTM roaming request to the site device, and the access point device 1 can no longer actively disassociate with the site device, thereby reducing the situation where the site device frequently disconnects from the wireless network Wi-Fi in a weak network scenario, suppressing the impact of multiple BTM-guided roaming initiated by the access point device side on the site device, and improving the user's network usage experience.
[0250] In this way, regardless of whether the site device turns off the BTM roaming function, the site device sends a restart request to the access point device 1, so that the site device can re-establish a data channel with the access point device 1, and can send and receive data related to the network connection. It can be seen that in a weak network scenario, the site device can associate with the access point device again through association self-healing, avoiding the situation where the site device frequently disconnects from the wireless network Wi-Fi.
[0251] Implementation method 2
[0252] Exemplarily, when access point device (AP) 1 detects that the signal strength of the connection with station device (STA) is less than threshold 1, it can guide STA to roam through a roaming request, and when the connection with access point device 2 fails and the association about to be disconnected tag included in the roaming request is 1, the station device can re-associate with access point device 1, and after successfully re-associating with access point device 1, the station device can initiate roaming again. It should be understood that within a preset time period, the station device can successfully connect to access point device 2, or fail to connect to access point device 2. In one possible case, the number of connection failures between the station device and access point device 2 within time period 1 is n, and the number of successful connections is m, where n is greater than or equal to the preset number threshold i, the station device can turn off the BTM roaming function and initiate re-association to AP1 so that the STA can connect to AP1 again; Figure 6 shown.
[0253] Figure 6 FIG. 1 is a flow chart of a wireless roaming method provided by the present application. Figure 6 As shown, the method can be divided into two different stages, namely 2.1 first failure stage, 2.2 success stage, 2.3 second failure stage and 2.4 re-association stage.
[0254] 2.1 The first failure stage
[0255] The first failure stage can be understood as when the access point device (AP) 1 detects that the signal strength of the connection with the station device (STA) is less than a threshold value 1, the STA is guided to roam, that is, to connect with an AP (such as AP2) other than AP1, and the connection fails, that is, the roaming fails. For example, Figure 6 S31-S34 shown.
[0256] S31 . Access point device 1 detects that the network signal strength of the site device is less than threshold 1 .
[0257] S32: Access point device 1 sends a roaming request to the site device.
[0258] S33: The site device sends a roaming response message to the access point device 1.
[0259] S34 . The site device detects the network signal, and determines that the access point device with the highest network quality is access point device 2 from among the access point devices that have detected the network signal.
[0260] The specific implementation of S31-S34 can be found in Figure 4 The relevant descriptions of S14-S17 in will not be repeated here.
[0261] For example, when i is 5, duration 1 is 10 minutes, S11-S21 has been executed 3 times, and in the 3 times, the association is about to be disconnected label in S18 is 1, and the site device detects that among the access point devices of the network signal, the access point device with the highest network quality is access point device 2, and the connection between the site device and access point device 2 fails (cannot be detected or detection / handshake timeout), in the fourth time, when executing from S31 to S34, among the access point devices of the network signal detected by the site device, the access point device with the highest network quality is still access point device 2, the site device connects to access point device 2, and fails again.
[0262] 2.2 Success Stage
[0263] The success stage can be understood as a stage in which the STA performs roaming processing when the STA fails to establish a connection with AP2 one or more times, re-associates with AP1 according to the processing result, and receives a roaming request again during the connection with AP1, and successfully roams to AP2; for example, Figure 6 S35-S45 shown.
[0264] S35 . When the station device fails to establish a connection with the access point device 2 , the station device performs a roaming process and initiates a re-association according to the process result.
[0265] The specific implementation of S35 can be found in Figure 5 The relevant descriptions of S181-S186 in will not be repeated here.
[0266] S36 : The station device sends a re-association request to the access point device 1 .
[0267] S37. The access point device 1 sends a reassociation response message to the site device.
[0268] S38 : The station device sends an extensible authentication protocol start message to the access point device 1 .
[0269] S39. Access point device 1 sends an Extensible Authentication Protocol success message to the site device.
[0270] S40 : When the station device successfully establishes a connection with the access point device 1 , a data channel is formed between the station device and the access point device 1 .
[0271] The specific implementation of S35-S40 can be found in Figure 4 The relevant descriptions of S18-S24 in will not be repeated here.
[0272] S41 , access point device 1 detects that the network signal strength of the site device is less than threshold 1 .
[0273] S42: Access point device 1 sends a roaming request to the site device.
[0274] S43: The site device sends a roaming response message to the access point device 1.
[0275] S44 , the site device detects the network signal, and determines that the access point device with the highest network quality is access point device 2 from among the access point devices that have detected the network signal.
[0276] The specific implementation of S35-S44 can be found in Figure 4 The relevant descriptions of S15-S17 in are not repeated here.
[0277] S44 can be regarded as that the access point device 2 is still the access point device with the highest network quality among the access point devices whose network signals are detected again by the station device.
[0278] S45 . The station device successfully establishes a connection with the access point device 2 , and forms a data channel with the access point device 2 .
[0279] For example, when i is 5 and duration 1 is 10 minutes, S11-S21 has been executed 3 times, and in the 3 times, the association disconnection tag in S18 is 1, and the site device detects that among the access point devices of the network signal, the access point device with the highest network quality is access point device 2, and the connection between the site device and access point device 2 fails, in the fourth time, when executing from S31 to S34, among the access point devices of the network signal detected by the site device, the access point device with the highest network quality is still access point device 2, the site device connects to access point device 2, and fails to establish a connection again.
[0280] Correspondingly, in the roaming processing flow, the site device can determine that the association is about to be disconnected label is 1, and the site device determines that the number of connection failures with the access point device identified as access point device 2 in the basic service set is 4 times, and thus, re-association is initiated again, so that the site device is connected to access point device 1, and the connection is successful.
[0281] Next, during the process of connecting the site device to access point device 1, the access point device again detects that the network signal strength of the site device is less than threshold 1. If in this wireless roaming, among the access point devices whose network signals the site device detects, the access point device with the highest network quality is access point device 2, the site device connects to access point device 2, and the connection is successful, forming a data channel between the site device and access point device 2. In this way, the site device has failed to establish a connection with access point device 2 4 times and succeeded 1 time.
[0282] 2.3 Second failure stage
[0283] The second failure stage can be understood as a stage in which the STA successfully roams to AP1 when it receives a roaming request during the connection between the STA and AP2, and fails to roam to AP2 again when it receives a roaming request during the connection between the STA and AP1; for example, Figure 6 S46-S54 shown.
[0284] S46 , the access point device 2 detects that the network signal strength of the site device is less than the threshold 1 .
[0285] S47: Access point device 2 sends a roaming request to the site device.
[0286] S48: The site device sends a roaming response message to the access point device 2.
[0287] S49: The site device detects the network signal, and determines that the access point device with the highest network quality is access point device 2 from among the access point devices that have detected the network signal.
[0288] The specific implementation of S46-S49 can be found in Figure 4 The relevant descriptions of S14-S17 in will not be repeated here.
[0289] For S49 , it can be considered that among the access point devices whose network signals are detected again by the station device, the access point device 1 is the access point device with the highest network quality.
[0290] S50 : When the station device successfully establishes a connection with the access point device 1 , a data channel is formed between the station device and the access point device 1 .
[0291] The specific implementation of S50 can be found in Figure 4 The relevant description of S13 in will not be repeated here.
[0292] S51 . Access point device 1 detects that the network signal strength of a site device is less than threshold 1 .
[0293] S52: Access point device 1 sends a roaming request to the site device.
[0294] S53: The site device sends a roaming response message to the access point device 1.
[0295] S54 : The site device detects the network signal, and determines that the access point device with the highest network quality is access point device 2 from among the access point devices that have detected the network signal.
[0296] The specific implementation of S51-S54 can be found in Figure 4 The relevant descriptions of S14-S17 in will not be repeated here.
[0297] S54 can be regarded as that the station device detects the access point device of the network signal again, and the access point device 2 is still the access point device with the highest network quality.
[0298] Combined with the example in S45, during the connection between the site device and access point device 2, the access point device again detects that the network signal strength of the site device is less than threshold 1. If in this wireless roaming, the site device detects that among the access point devices with network signals, the access point device with the highest network quality is access point device 1, the site device connects to access point device 1, and the connection is successful.
[0299] Next, during the process of connecting the site device to access point device 1, the access point device again detects that the network signal strength of the site device is less than threshold 1. If in this wireless roaming, the site device detects that the access point device with the highest network quality among the access point devices of the network signal is access point device 2, the site device connects to access point device 2, and the connection fails. In this way, the site device has failed to connect to access point device 2 5 times and succeeded 1 time.
[0300] 2.4 Reassociation Phase
[0301] The reassociation phase can be understood as the phase in which the STA performs roaming processing when roaming to AP2 fails, initiates reassociation to AP1 according to the processing result, and makes AP1 no longer send BTM roaming request to the STA, so that the STA can establish a connection with AP1 again; for example, Figure 6 S55-S61 shown.
[0302] S55 . When the site device fails to establish a data channel with the access point device 2 , the site device performs roaming processing and initiates re-association according to the processing result.
[0303] The specific implementation of S55 can be found in Figure 5 The relevant descriptions of S181-S186 in will not be repeated here.
[0304] S56 : The station device sends a reassociation request to the access point device 1 .
[0305] S57: Access point device 1 sends a reassociation response message to the site device.
[0306] S58 : The station device sends an extensible authentication protocol start message to the access point device 1 .
[0307] S59: Access point device 1 sends an Extensible Authentication Protocol success message to the site device.
[0308] S60: Access point device 1 updates status information of site devices.
[0309] S61 : The station device establishes a data channel with the access point device 1 .
[0310] The specific implementation of S55-S61 can be found in Figure 4 The relevant descriptions of S18-S24 in will not be repeated here.
[0311] Combined with the example in S54, when i is 5 and duration 1 is 10 minutes, the site device fails to connect to access point device 2 5 times and succeeds 1 time within 10 minutes, then in the roaming processing flow of S181-S186, the site device determines that the association is about to be disconnected label is 1, and the site device determines that the access point device identified as access point device 2 in the basic service set has failed to connect to the site device 5 times within 10 minutes. Therefore, the site device can turn off the BTM roaming function and initiate re-association again, so that the site device is connected to access point device 1 again, and a data channel is formed between the site device and access point device 1 again.
[0312] It can be understood that if the site device turns off the BTM roaming function, the site device sends a re-association request to the access point device 1, which may carry information used to indicate that BTM roaming is not supported. Therefore, when the access point device 1 receives the re-association request, it may no longer send a BTM roaming request to the site device, and the access point device 1 also needs to update the status information of the site device indicating that the site device supports basic service set transfer management roaming to indicate that the site device does not support basic service set transfer management roaming.
[0313] In the present application, when the site device frequently receives the BTM roaming request sent by the access point device 1, and the association disconnection tag included in the roaming request is 1, after failing to connect to the access point device 2 for many times, it successfully connects to the access point device 2. During the process of connecting the site device to the access point device 2, it receives the BTM roaming request sent by the access point device 2 and successfully connects to the access point device 1. During the process of connecting the site device to the access point device 1, it receives the BTM roaming request sent by the access point device 1 and fails to connect to the access point device 2 again, so that the site device determines according to the recorded basic service set identifier, time information and number of times that even if other access point devices are successfully connected in the middle, When the number of connection failures with access point device 2 is greater than or equal to i times, the BTM roaming function can be turned off, and re-association can be initiated again, so that the site device is connected to access point device 1 again. Based on this, access point device 1 can also update the status information of the site device to not support basic service set transfer management roaming, which is equivalent to the site device re-establishing a connection with access point device 1. In this way, access point device 1 can no longer actively disassociate with the site device, that is, it will not be disconnected from the site device. The site device can further shield the impact caused by the frequent initiation of BTM roaming by the same access point device, reduce the frequent disconnection of the wireless network Wi-Fi of the site device in a weak network scenario, and improve the user's network usage experience.
[0314] Based on some of the aforementioned embodiments, the wireless roaming method provided by the present application is introduced below.
[0315] Exemplarily, the present application provides a wireless roaming method.
[0316] For the convenience of explanation, the wireless roaming method of the present application can be Figure 2 to be executed by the site equipment in the.
[0317] The site device may access the wireless local area network through the first access point device or the second access point device.
[0318] See also Figure 7 , Figure 7 A flow chart of a wireless roaming method provided in an embodiment of the present application is shown.
[0319] like Figure 7 As shown, the wireless roaming method provided by the present application may include:
[0320] S301. During a connection process with a first access point device, upon receiving a first message sent by the first access point device, determining a second access point device, wherein the first message is used to instruct a site device to perform wireless roaming, and the second access point device is an access point device whose network signal strength detected by the site device is greater than a first threshold and has the highest network signal strength.
[0321] The first threshold is preset, for example, the first threshold is 0.
[0322] When the first access point device detects that the network signal strength of the site device is less than a preset threshold, the first access point device may send a first message to the site device.
[0323] The first access point device can be Figure 4-Figure 6 The access point device 1 in the example, the second access point device may be Figure 4-Figure 6 Access point device 2 in.
[0324] For the specific implementation of the first message, please refer to Figure 4 Roaming requests in Figure 6 The description of roaming request in is not repeated here.
[0325] In addition, the site device may detect that the network signal is greater than the first threshold value, which may be multiple access point devices, and the second access point device is an access point device with the highest network quality among the multiple access point devices in descending order of network quality.
[0326] For the specific implementation of S301, please refer to Figure 4 S14-S17 in, and Figure 5 The description of S31-S34 in the description will not be repeated here.
[0327] S302: Send a second message to the second access point device, where the second message is used to request to establish a connection with the second access point device.
[0328] S303: upon receiving a first response message returned by the second access point device based on the second message, determining whether the first message includes first information, the first information being used to indicate that the site device disconnects from the first access point device before the first moment, and the first response message indicating that the second access point device cannot establish a connection with the site device.
[0329] When receiving the first response message returned by the second access point device based on the second message, the site device may determine that establishing a connection with the second access point device fails.
[0330] In addition, when receiving the third response message returned by the second access point device based on the second message, the site device may determine that the connection with the second access point device is successfully established, and the third response message indicates that the second access point device can establish a connection with the site device.
[0331] In addition, when the connection with the second access point device is successfully established, the site device may not perform any operation until a wireless roaming request sent by the second access point device is received.
[0332] The first information may carry duration information, and the duration corresponding to the duration information is preset, for example, 1 minute.
[0333] The first moment is the end moment of the duration corresponding to the duration information carried in the first information.
[0334] For example, the site device receives the first message at 12:12, and the duration information carried in the first message corresponds to a duration of 1 minute, so the first time is 12:13.
[0335] For the specific implementation of the first information, please refer to Figure 4 , Figure 5 ,as well as Figure 6 The description of the tag that is about to be disconnected is not repeated here.
[0336] For the specific implementation of S303, please refer to Figure 5 The relevant descriptions of S181-S182 are not repeated here.
[0337] S304: When the first information is included in the first message, re-establish a connection with the first access point device before a second time, where the second time is earlier than or equal to the first time.
[0338] For example, the time when the site device receives the first message is 12:12, and the duration information carried in the first message corresponds to 1 minute, then the first moment is 12:13. If the second moment is equal to the first moment, the second moment is also 12:13; if the second moment is earlier than the first moment, the second moment can be 12:12:30.
[0339] For the specific implementation of S304, please refer to Figure 4 S18-S24, Figure 5 S181-S186 in, and Figure 6 The descriptions of S35-S41 and S55-S61 are not repeated here.
[0340] The wireless roaming method of the present application, when receiving a first message for instructing a site device to perform wireless roaming, the site device can determine that the access point device with the highest network signal strength is the second access point device from the access point devices that detect that the network signal is greater than the first threshold, and make a second attempt to connect with the access point device. When the site device fails to establish a connection with the second access point device and the first message includes first information for instructing the site device to disconnect from the first access point device before the first moment, the site device can re-establish a connection with the first access point device before the second moment, that is, before the first access point device actively disconnects from the site device, causing the site device to be disconnected from the network, the site device re-forms a data channel with the first access point device to update the connection status with the first access point device. In this way, the site device can re-associate with the first access point device by means of re-association self-healing, thereby avoiding the situation where the site device is disconnected from the wireless network.
[0341] In some embodiments, the wireless roaming method of the present application may include:
[0342] When the first information is included in the first message, a first function is disabled, where the first function is a basic service set transfer management roaming function;
[0343] A connection is established again with the first access point device before the second time.
[0344] The specific implementation of the above steps can be found in Figure 5 S184-S186 in Figure 4 S19-S24 in, and Figure 6 The relevant descriptions of S56-S61 are not repeated here.
[0345] In some embodiments, the wireless roaming method of the present application may include:
[0346] When the first information is included in the first message, determining whether the number of failures within the first time period is greater than or equal to a preset number of times, the number of failures being the number of times the station device fails to establish a connection with the second access point device;
[0347] If the number of failures is greater than or equal to the preset number, the first function is turned off.
[0348] The first duration is pre-set, for example, the first duration is 10 minutes.
[0349] Furthermore, the preset number of times is also pre-set, for example, the preset number of times is 5 times.
[0350] For example, when the first duration is 10 minutes and the preset number of times is 5, then when the connection fails 5 times within 10 minutes, the site device may first disable the first function and then establish a connection with the first access point device again.
[0351] The specific implementation of the first function can be found in Figure 5 The description of the BTM roaming function is not repeated here.
[0352] The specific implementation of the above steps can be found in Figure 5 S184-S186 in Figure 4 S19-S24 in, and Figure 6 The relevant descriptions of S56-S61 are not repeated here.
[0353] In the present application, when the site device fails to establish a connection with the second access point device, the number of failures is greater than or equal to the preset number of times, and the first message includes first information for instructing the site device to disconnect from the first access point device before the first moment, the first function can be turned off first, and then the connection with the first access point device can be re-established before the second moment, that is, before the first access point device actively disconnects from the site device, causing the site device to be disconnected from the network, the site device and the first access point device re-form a data channel to update the connection status with the first access point device. In this way, the site device can associate with the access point device again through re-association self-healing, thereby avoiding the situation where the site device is disconnected from the wireless network.
[0354] In addition, the site device turns off the first function, and the first access point device no longer sends the first message to the site device, thereby reducing the frequent disconnection of the wireless network of the site device in a weak network scenario, suppressing the impact of the access point device initiating BTM roaming requests multiple times on the site device, and improving the user's network experience.
[0355] In some embodiments, the wireless roaming method of the present application may include:
[0356] Sending a third message to the first access point device, where the third message is used to request to establish a connection with the first access point device again;
[0357] When receiving the fourth message returned by the first access point device based on the third message, a connection is established with the first access point device, and the fourth message is used to indicate that the first access point device accepts to establish a connection with the first access point device again.
[0358] The specific implementation of the third message can be found in Figure 4 The reassociation request in Figure 6 The description of the reassociation request in is not repeated here.
[0359] The specific implementation of the fourth message can be found in Figure 4 The reassociation response message in Figure 6 The description of the reassociation response message in is not repeated here.
[0360] The specific implementation of the above steps can be found in Figure 4 S19-S24 in, and Figure 6 The descriptions of S36-S41 and S56-S61 in the description are not repeated here.
[0361] In the present application, the station device may establish a connection with the first access point device based on a third message for requesting to re-establish a connection with the first access point device.
[0362] In some embodiments, when the site device turns off the first function, the third message includes second information, where the second information is used to indicate that the site device does not support the first function.
[0363] The specific implementation method of the second information can be found in Figure 4 Description of the information about not supported basic service set transfer management (BSS transition management, BTM) roaming in the Figure 6 The relevant description of the information on not supporting basic service set transfer management roaming is not repeated here.
[0364] The specific implementation of the above steps can be found in Figure 4 S19 in, and Figure 6 The relevant description of S56 in the specification will not be repeated here.
[0365] In the present application, if the site device turns off the first function, it can carry the second information when sending the third message, and notify the first access point device through the second information that the site device does not support the first function. Therefore, when the access point device receives the third message, it may no longer send the first message to the site device.
[0366] In some embodiments, the wireless roaming method of the present application may include:
[0367] When the first information is included in the first message, a basic service set identifier and first time information are recorded, where the basic service set identifier is used to indicate the second access point device, and the first time information is the time when a connection with the second access point device fails;
[0368] It is determined, according to the basic service set identifier and the first time information, whether the number of failures within the first time period is greater than or equal to a preset number.
[0369] The specific implementation of the above steps can be found in Figure 5 The relevant descriptions of S183-S184 in are not repeated here.
[0370] In the present application, the site device may record the basic service set identifier corresponding to the second access point device and the time information of the failure each time a connection with the second access point device fails, so as to determine the number of failures according to the basic service set identifier and the time information.
[0371] In some embodiments, the wireless roaming method of the present application may include:
[0372] Determine a second duration according to the time indicated by the first time information and the current time;
[0373] When the second duration is greater than or equal to the preset duration threshold, the first time information and the basic service set identifier corresponding to the first time information are deleted.
[0374] The preset time threshold is predetermined, for example, the preset time threshold is 24 hours.
[0375] In the present application, when the site device determines, based on the moment indicated by the first time information and the current moment, that a basic service set identifier and the corresponding first time information have been stored for a time period greater than or equal to a preset time period threshold, the basic service set identifier and the corresponding first time information can be deleted, so that the memory of the site device is partially released.
[0376] For example, when the preset duration threshold is 24 hours, the site device records a basic service set identifier and the first time information of that time at 11:34 on June 6, 2023. The second time between 11:34 on June 6, 2023 and the current time 11:34 on June 7, 2023 is 24 hours, which is equal to the preset duration threshold of 24 hours. Then, the site device can delete the basic service set identifier and the first time information of that time.
[0377] In some embodiments, the wireless roaming method of the present application may include:
[0378] When the first information is included in the first message, determining whether the number of failures within the first time period is greater than or equal to a preset number;
[0379] When the number of failures is less than the preset number, a connection is established with the first access point device again before the second moment.
[0380] The specific implementation of the above steps can be found in Figure 5 S184 and S186 in Figure 4 S19-S24 in, and Figure 6 The relevant descriptions of S56-S61 are not repeated here.
[0381] For example, when the first duration is 10 minutes and the preset number of times is 5, then when failure occurs 1 to 4 times within 10 minutes, the site device can directly establish a connection with the first access point device again.
[0382] In some embodiments, the wireless roaming method of the present application may include:
[0383] After successfully establishing a connection with the second access point device, disconnecting the connection with the first access point device;
[0384] When a fifth message sent by the second access point device is received and it is determined that the first access point device is the access point device whose network signal strength detected by the site device is greater than the first threshold and has the highest network signal strength, a connection is established with the first access point device.
[0385] The specific implementation of the fifth message can be found in Figure 5 The relevant description of the roaming request in S47 is not repeated here.
[0386] For details on how to establish a connection with the first access point device, see Figure 6 The relevant description of S45 is not repeated here.
[0387] The specific implementation of the above steps can be found in Figure 6 The description of S46-S50 in is not repeated here.
[0388] When the first access point device instructs the site device to perform wireless roaming, the site device may successfully connect to the access point device with the highest detected network quality, or may fail to connect. In the case of failure, reassociation with the first access point device may be performed for the first time; after reassociation, when the first access point device instructs the site device to perform wireless roaming again, the site device may successfully connect to the access point device with the highest detected network quality, or may fail to connect. In the case of success, the site device roams to the access point device; during the process of the site device being connected to the access point device, when the access point device instructs the site device to perform wireless roaming, the site device may roam to the original first access point device again. Based on this, the first access point device may instruct the site device to perform wireless roaming again. In the case of failure, reassociation with the first access point device may be performed for the second time.
[0389] It can be seen that the site device may fail to roam or succeed. Within the first time period, when the site device fails to roam on the same access point device for a preset number of times, the first function may be disabled and reassociation may be initiated.
[0390] It is understandable that each time the site device performs wireless roaming, the access point device with the highest detected network quality may be a different access point device; for example, in the first wireless roaming, the access point device with the highest detected network quality is AP2, and in the second wireless roaming, it is AP0.
[0391] For example, when the first time length is 10 minutes and the preset number of times is 5 times, then after 3 failures within 10 minutes, there is 1 success and then another failure, so that when there are 5 failures within 10 minutes, the site device can directly establish a connection with the first access point device again.
[0392] Based on some of the aforementioned embodiments, the wireless roaming method provided by the present application is introduced below.
[0393] Exemplarily, the present application provides a wireless roaming method.
[0394] For the sake of convenience, the wireless roaming method of the present application may be executed by a first access point device.
[0395] The first access point device is applied to a wireless roaming system, which includes a site device, a first access point device and a second access point device. The site device accesses the wireless local area network through the first access point device or the second access point device.
[0396] See also Figure 8 , Figure 8 A flow chart of a wireless roaming method provided in an embodiment of the present application is shown.
[0397] like Figure 8 As shown, the wireless roaming method provided by the present application may include:
[0398] S401. When it is detected that the network signal strength of a site device is less than a second threshold, send a first message to the site device, where the first message is used to instruct the site device to perform wireless roaming.
[0399] S402: Receive a third message sent by the station device to the first access point device when determining that the connection with the second access point device fails, where the third message is used to request to re-establish a connection with the first access point device.
[0400] S403: Send a second response message to the site device, where the second response message is used to indicate that the first access point device accepts to establish a connection with the site device again.
[0401] The first access point device may be Figure 4-Figure 6 Access point device 1 in.
[0402] For the specific implementation of the first message, please refer to Figure 4 Roaming requests in Figure 6The description of roaming request in is not repeated here.
[0403] For the specific implementation of the third message, please refer to Figure 4 The reassociation request in Figure 6 The description of the reassociation request in is not repeated here.
[0404] The specific implementation method of the second information can be found in Figure 4 Description of the information about not supported basic service set transfer management (BSS transition management, BTM) roaming in the Figure 6 The relevant description of the information on not supporting basic service set transfer management roaming is not repeated here.
[0405] For the specific implementation of the second response message, please refer to Figure 4 The reassociation response message in Figure 6 The description of the reassociation response message in is not repeated here.
[0406] The specific implementation of the above steps can be found in Figure 4 The relevant descriptions of S14-S15 and S20 in Figure 6 The relevant descriptions of S31-S32, S41-S42 and S51-S52 are not repeated here.
[0407] In the wireless roaming method of the present application, the first access point device accepts to re-establish a connection with the site device, that is, before the first access point device actively disconnects from the site device and causes the site device to be disconnected from the network, the site device reconnects with the first access point device to update the connection status with the first access point device. In this way, the site device can re-associate with the access point device by means of re-association self-healing, thereby avoiding the site device from being disconnected from the network.
[0408] In some embodiments, the wireless roaming method of the present application may include:
[0409] When the site device turns off the first function, the third message includes second information, where the second information is used to indicate that the site device does not support the first function, and the first function is a basic service set transfer management roaming function.
[0410] The specific implementation method of the second information can be found in Figure 4 The description of the information about not supporting basic service set transfer management roaming in Figure 6 The relevant description of the information on not supporting basic service set transfer management roaming is not repeated here.
[0411] The specific implementation of the above steps can be found in Figure 4The relevant description of S19 in Figure 6 The description of S56 in is not repeated here.
[0412] In the present application, the first access point device may determine that the site device does not support the first function through the second information carried in the received third message, so that the first access point device may no longer send the first message to the site device when receiving the third message.
[0413] In some embodiments, the wireless roaming method of the present application may include:
[0414] The second information is stored.
[0415] The specific implementation of the above steps can be found in Figure 4 The relevant description of S23 in Figure 6 The relevant description of S60 in is not repeated here.
[0416] In the above steps, when the third message includes the second information, the second information may be stored, and the first access point device may stop sending the first message to the site device according to the second information.
[0417] In some embodiments, the wireless roaming method of the present application may include:
[0418] Stop sending a first message to the site device, where the first message is used to instruct the site device to perform wireless roaming.
[0419] In the above steps, when the second information is included in the third message, the first access point device can stop sending the first message to the site device to avoid the first access point device instructing the site device to perform wireless roaming. This reduces the frequent disconnection of the wireless network of the site device in weak network scenarios, suppresses the impact of the access point device initiating BTM roaming requests multiple times on the site device, and improves the user's network usage experience.
[0420] Exemplarily, the present application provides a device, which may include one or more modules for executing the wireless roaming method in the foregoing embodiments.
[0421] Exemplarily, the present application provides an electronic device, including a processor; when the processor executes computer code or instructions in the memory, the electronic device executes the wireless roaming method in the foregoing embodiment.
[0422] Exemplarily, the present application provides an electronic device, comprising: a memory and a processor; the memory is coupled to the processor, and the memory is used to store program codes or instructions; the processor is used to call the program codes or instructions in the memory so that the electronic device executes the wireless roaming method in the foregoing embodiment.
[0423] Exemplarily, the present application provides a chip system, which is applied to an electronic device including a memory, a display screen and a sensor; the chip system includes: one or more interface circuits and one or more processors; the interface circuit and the processor are interconnected through lines; the interface circuit is used to receive signals from the memory and send signals to the processor, and the signals include computer codes or instructions stored in the memory; when the processor executes the computer code or instructions, the electronic device executes the wireless roaming method in the previous embodiment.
[0424] Exemplarily, the present application provides a computer-readable storage medium, in which codes or instructions are stored. When the codes or instructions are executed on an electronic device, the electronic device implements the wireless roaming method in the foregoing embodiment.
[0425] Exemplarily, the present application provides a computer program product, which enables an electronic device to implement the wireless roaming method in the foregoing embodiment when the computer program product is executed on a computer.
[0426] In the above embodiments, all or part of the functions can be implemented by software, hardware, or a combination of software and hardware. When implemented using software, it can be implemented in whole or in part in the form of a computer program product. The computer program product includes one or more computer codes or instructions. When the computer program code or instructions are loaded and executed on a computer, the process or function according to the present application is generated in whole or in part. The computer can be a general-purpose computer, a special-purpose computer, a computer network, or other programmable devices. The computer code or instructions can be stored in a computer-readable storage medium. The computer-readable storage medium can be any available medium that a computer can access or a data storage device such as a server or a data center that includes one or more available media integration. Available media can be magnetic media, (e.g., floppy disk, hard disk, tape), optical media (e.g., DVD), or semiconductor media (e.g., solid state disk (SSD)), etc.
[0427] A person skilled in the art can understand that to implement all or part of the processes in the above-mentioned embodiments, the processes can be completed by a computer program to instruct the relevant hardware, and the program can be stored in a computer-readable storage medium. When the program is executed, it can include the processes of the above-mentioned method embodiments. The aforementioned storage medium includes: a read-only memory (ROM) or a random access memory (RAM), a magnetic disk or an optical disk, and other media that can store program codes.
Claims
1. A wireless roaming method, characterized in that: Applied to a site device, the site device accesses a wireless local area network through a first access point device or a second access point device, the method comprising: In the process of connecting with the first access point device, upon receiving a first message sent by the first access point device, determining the second access point device, wherein the first message is used to instruct the site device to perform wireless roaming, and the second access point device is an access point device for which the site device detects that the network signal strength is greater than a first threshold and the network signal strength is the highest; Sending a second message to the second access point device, where the second message is used to request to establish a connection with the second access point device; Upon receiving a first response message returned by the second access point device based on the second message, determining whether the first message includes first information, the first information being used to indicate that the site device disconnects from the first access point device before a first moment, and the first response message indicating that the second access point device cannot establish a connection with the site device; When the first information is included in the first message, a connection is established again with the first access point device before a second time, and the second time is earlier than or equal to the first time.
2. The method according to claim 1, characterized in that When the first information is included in the first message, establishing a connection with the first access point device again before the second time includes: When the first information is included in the first message, disabling a first function, where the first function is a basic service set transfer management roaming function; A connection is established again with the first access point device before the second time.
3. The method according to claim 2, characterized in that When the first message includes the first information, disabling the first function includes: When the first information is included in the first message, determining whether the number of failures within the first time period is greater than or equal to a preset number, the number of failures being the number of times the site device fails to establish a connection with the second access point device; When the number of failures is greater than or equal to the preset number of times, the first function is disabled.
4. The method according to claim 2 or 3, characterized in that: The re-establishing a connection with the first access point device before the second moment includes: Sending a third message to the first access point device, where the third message is used to request to establish a connection with the first access point device again; When receiving a fourth message returned by the first access point device based on the third message, a connection is established with the first access point device before the second time, and the fourth message is used to indicate that the first access point device accepts to establish a connection with the first access point device again.
5. The method according to claim 4, characterized in that The third message includes second information, where the second information is used to indicate that the site device does not support the first function.
6. The method according to any one of claims 3 to 5, characterized in that: When the first information is included in the first message, determining whether the number of failures within the first time period is greater than or equal to a preset number includes: When the first information is included in the first message, a basic service set identifier and first time information are recorded, where the basic service set identifier is used to indicate the second access point device, and the first time information is the time when a connection with the second access point device fails; According to the basic service set identifier and the first time information, determine whether the number of failures within the first duration is greater than or equal to a preset number.
7. The method according to claim 6, characterized in that The method further comprises: Determine a second duration according to the time indicated by the first time information and the current time; When the second duration is greater than or equal to a preset duration threshold, the first time information and the basic service set identifier corresponding to the first time information are deleted.
8. The method according to any one of claims 3 to 7, characterized in that When the first information is included in the first message, establishing a connection with the first access point device again before the second time includes: When the first information is included in the first message, determining whether the number of failures within a first time period is greater than or equal to a preset number; When the number of failures is less than the preset number of times, a connection is established with the first access point device again before the second moment.
9. The method according to any one of claims 1 to 8, characterized in that The method further comprises: After successfully establishing a connection with the second access point device, disconnecting the connection with the first access point device; When a fifth message sent by the second access point device is received and it is determined that the first access point device is the access point device whose network signal strength detected by the site device is greater than the first threshold and has the highest network signal strength, a connection is established with the first access point device.
10. A wireless roaming method, characterized in that: Applied to a first access point device, the first access point device is applied to a wireless roaming system, the wireless roaming system includes a site device, the first access point device and a second access point device, the site device accesses a wireless local area network through the first access point device or the second access point device, the method includes: When it is detected that the network signal strength of the site device is less than a second threshold, sending a first message to the site device, where the first message is used to instruct the site device to perform wireless roaming; receiving a third message sent by the site device to the first access point device when determining that the connection with the second access point device fails, wherein the third message is used to request to establish a connection with the first access point device again; A second response message is sent to the site device, where the second response message is used to indicate that the first access point device accepts to establish a connection with the site device again.
11. The method according to claim 10, characterized in that When the site device turns off the first function, the third message includes second information, where the second information is used to indicate that the site device does not support the first function, and the first function is a basic service set transfer management roaming function.
12. The method according to claim 11, characterized in that The method further comprises: The second information is stored.
13. The method according to claim 11 or 12, characterized in that: After sending the second response message to the site device, the method further includes: Stop sending the first message to the site device, where the first message is used to instruct the site device to perform wireless roaming.
14. An electronic device, characterized in that: include: One or more processors, a memory, and one or more computer programs; wherein the one or more computer programs are stored in the memory, and when the computer programs are executed by the one or more processors, the electronic device performs the wireless roaming method according to any one of claims 1 to 9, and / or the wireless roaming method according to any one of claims 10 to 13.
15. A chip system, characterized in that: The chip system includes a processor for calling and running a computer program from a memory, so that an electronic device equipped with the chip system performs the wireless roaming method as described in any one of claims 1 to 9, and / or the wireless roaming method as described in any one of claims 10 to 13.
16. A computer-readable storage medium comprising a computer program, characterized in that: When the computer program is executed on an electronic device, the electronic device is enabled to perform the wireless roaming method according to any one of claims 1 to 9 and / or the wireless roaming method according to any one of claims 10 to 13.
Citation Information
Cited By
Wireless access point device, wireless communication method, and wireless communication chip
WO2026157108A1
Seamless roaming method, apparatus and device
WO2026175226A1