CN111278011A - Network distribution method of intelligent loudspeaker box and intelligent loudspeaker box - Google Patents
Network distribution method of intelligent loudspeaker box and intelligent loudspeaker box Download PDFInfo
- Publication number
- CN111278011A CN111278011A CN202010091309.1A CN202010091309A CN111278011A CN 111278011 A CN111278011 A CN 111278011A CN 202010091309 A CN202010091309 A CN 202010091309A CN 111278011 A CN111278011 A CN 111278011A
- Authority
- CN
- China
- Prior art keywords
- terminal
- wifi list
- data
- wifi
- size
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Granted
Links
Images
Classifications
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04W—WIRELESS COMMUNICATION NETWORKS
- H04W12/00—Security arrangements; Authentication; Protecting privacy or anonymity
- H04W12/06—Authentication
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04W—WIRELESS COMMUNICATION NETWORKS
- H04W12/00—Security arrangements; Authentication; Protecting privacy or anonymity
- H04W12/06—Authentication
- H04W12/068—Authentication using credential vaults, e.g. password manager applications or one time password [OTP] applications
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04W—WIRELESS COMMUNICATION NETWORKS
- H04W48/00—Access restriction; Network selection; Access point selection
- H04W48/16—Discovering, processing access restriction or access information
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04W—WIRELESS COMMUNICATION NETWORKS
- H04W48/00—Access restriction; Network selection; Access point selection
- H04W48/18—Selecting a network or a communication service
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04W—WIRELESS COMMUNICATION NETWORKS
- H04W76/00—Connection management
- H04W76/10—Connection setup
-
- Y—GENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
- Y02—TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
- Y02D—CLIMATE CHANGE MITIGATION TECHNOLOGIES IN INFORMATION AND COMMUNICATION TECHNOLOGIES [ICT], I.E. INFORMATION AND COMMUNICATION TECHNOLOGIES AIMING AT THE REDUCTION OF THEIR OWN ENERGY USE
- Y02D30/00—Reducing energy consumption in communication networks
- Y02D30/70—Reducing energy consumption in communication networks in wireless communication networks
Landscapes
- Engineering & Computer Science (AREA)
- Computer Networks & Wireless Communication (AREA)
- Signal Processing (AREA)
- Computer Security & Cryptography (AREA)
- Mobile Radio Communication Systems (AREA)
- Telephone Function (AREA)
Abstract
The application discloses a network distribution method of an intelligent sound box and the intelligent sound box, wherein after the intelligent sound box is successfully connected with a terminal, a request for acquiring a maximum transmission unit is sent to the terminal; if the maximum transmission unit replied by the terminal is not received, a wifi list is established; and transmitting the data of the wifi list to the terminal according to the data size in the wifi list transmission data queue in sequence until receiving the message which is not lost and is sent by the terminal. The intelligent sound box receives a service set identifier and a password of wifi selected by a user; and connecting the wireless network according to the service set identifier and the password. According to the method and the device, in the process of a distribution network, when the maximum transmission unit condition of the terminal is not acquired, the use of the default maximum transmission unit of ble for data transmission can be avoided, the device compatible with different systems can realize the function of acquiring a wifi list, the free configuration of a user can be realized, the terminal is not required to be connected with wifi in advance or the wifi connected with an intelligent connection terminal is not required, and the user experience is enhanced.
Description
Technical Field
The application relates to the technical field of sound box distribution networks, in particular to a network distribution method of an intelligent sound box and the intelligent sound box.
Background
At present, more and more intelligent sound boxes are available in the market, and the user group is also larger and larger. The most important dependence of the intelligent loudspeaker box is the network, and the intelligent loudspeaker box is necessarily a wireless network. Therefore, configuring a network for the smart speaker becomes the most important function of the smart speaker.
The smart sound box configures the network, needs to use mobile phone app, establishes connection with the sound box through the ble mode of bluetooth, and the information transfer that will connect wifi transmits for the sound box, and the sound box uses wifi information connection network. There are three user scenarios when configuring a network: 1. when the current mobile phone is connected with wifi, the distribution network app automatically fills the wifi name of the mobile phone connection, the user inputs the wifi password, and the mobile phone transmits wifi information to the sound box; 2. the current cell-phone has connected wifi, but the user does not need this wifi of audio amplifier connection, and the user need select other wifi, gives audio amplifier 3 with the information transfer of wifi of selecting at last.
In the former two cases, before the network distribution function is started, the mobile phone must be connected with a wifi, and only the wifi can be configured for the sound box. And under the third condition, although the loudspeaker box supports that the user can select wifi, the loudspeaker box needs to transmit a wifi list which can be connected with the loudspeaker box to the mobile phone. However, due to the fact that the amount of data of the wifi list is large, the size of the default transmission data of ble communication is limited by the current intelligent sound box distribution network scheme, and therefore the wifi list cannot be obtained. The wifi that can only give the audio amplifier configuration current connection leads to intelligent audio amplifier can't be realizing the wifi that the user freely selected the audio amplifier to connect, and user experience is very poor.
Disclosure of Invention
The application aims to provide a network distribution method of an intelligent sound box and the intelligent sound box, and the problem that the user experience is very poor due to the fact that the intelligent sound box cannot freely select wifi connected with the sound box by a user is solved.
In a first aspect, an embodiment of the present application provides an intelligent speaker, including:
the voice output module is used for outputting a voice signal acquired from the terminal;
a communicator for establishing a connection state with the terminal;
a controller coupled to the voice input module and the communicator, for performing:
sending a request for acquiring a maximum transmission unit to a terminal;
receiving a request for acquiring a wifi list sent by the terminal;
if the maximum transmission unit replied by the terminal is not received, obtaining wifi information available in a preset range, and establishing a wifi list according to the wifi information;
transmitting the data of the wifi list to the terminal according to the size of the first data in the wifi list transmission data queue;
if a packet loss message sent by the terminal is received, transmitting data of a wifi list to the terminal according to the size of the next data in a wifi list transmission data queue until a packet loss-free message sent by the terminal is received or a packet loss-free message sent by the terminal is not received after the wifi list transmission data queue is traversed;
if a message which is not lost and is sent by the terminal is received, receiving a service set identifier and a password of wifi selected by a user;
and connecting the wireless network according to the service set identifier and the password.
In a second aspect, an embodiment of the present application provides a network distribution method for a smart speaker, which is applied to the smart speaker and includes:
sending a request for acquiring a maximum transmission unit to a terminal;
receiving a request for acquiring a wifi list sent by the terminal;
if the maximum transmission unit replied by the terminal is not received, obtaining wifi information available in a preset range, and establishing a wifi list according to the wifi information;
transmitting the data of the wifi list to the terminal according to the size of the first data in the wifi list transmission data queue;
if a packet loss message sent by the terminal is received, transmitting data of a wifi list to the terminal according to the size of the next data in a wifi list transmission data queue until a packet loss-free message sent by the terminal is received or the wifi list transmission data queue is traversed and a packet loss-free message sent by the terminal is still not received;
if a message which is not lost and is sent by the terminal is received, receiving a service set identifier and a password of wifi selected by a user;
and connecting the wireless network according to the service set identifier and the password.
According to the technical scheme, after the intelligent sound box is successfully connected with the terminal, a request for acquiring the maximum transmission unit is sent to the terminal; if the maximum transmission unit replied by the terminal is not received, a wifi list is established; and transmitting the data of the wifi list to the terminal according to the data size in the wifi list transmission data queue in sequence until the packet loss free message is sent by the terminal. The intelligent sound box receives a service set identifier and a password of wifi selected by a user; and connecting the wireless network according to the service set identifier and the password. According to the method and the device, in the process of a distribution network, when the MTU condition of the terminal is not acquired, the acquiescent maximum transmission unit can be avoided from being used for transmitting data, the device compatible with different systems can acquire a wifi list, the user can freely configure the network, the terminal is not required to be connected with wifi in advance or the wifi connected with an intelligent connection terminal is not required, and the user experience is enhanced.
Drawings
In order to more clearly illustrate the embodiments of the present application or the technical solutions in the prior art, the drawings needed to be used in the embodiments will be briefly described below, and it is obvious that the drawings in the following description are only some embodiments of the present application, and it is obvious for those skilled in the art to obtain other drawings without creative efforts.
Fig. 1A is a schematic diagram illustrating an operation scenario between a smart sound box and a terminal;
FIG. 1B is a block diagram illustrating the configuration of smart sound box 200 of FIG. 1A;
fig. 2A is a flowchart illustrating a network distribution method for a smart speaker according to an embodiment of the present application;
fig. 2B is a flowchart illustrating a BLE _ WIFI adaptive transmission algorithm according to an embodiment of the present application.
Detailed Description
In order to make the objects, technical solutions and advantages of the present application more apparent, the technical solutions of the present application will be described in detail and completely with reference to the following specific embodiments of the present application and the accompanying drawings. It should be apparent that the described embodiments are only some of the embodiments of the present application, and not all of the embodiments. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present application. The technical solutions provided by the embodiments of the present application are described in detail below with reference to the accompanying drawings.
Fig. 1A is a schematic diagram illustrating an operation scenario between a smart speaker and a terminal. As shown in fig. 1A, the terminal 100 and the smart sound box 200 may communicate with each other in a wireless manner.
Wherein, terminal 100 is configured to control smart sound box 200, which may receive an operation instruction input by a user, and convert the operation instruction into an instruction recognizable and responsive by smart sound box 200, and play an intermediary role in interaction between the user and smart sound box 200. Such as: the user responds to the operation of voice addition and subtraction by operating the voice addition and subtraction keys on the terminal 100.
The terminal 100 may also be a smart device, such as a mobile terminal, a tablet computer, a notebook computer, etc. For example, smart sound box 200 is controlled using an application running on the smart device. The application program may provide various controls to a user through an intuitive User Interface (UI) on a screen associated with the smart device through configuration.
A block diagram of the configuration of smart sound box 200 is illustrated in fig. 1B. As shown in fig. 1B, the smart sound box 200 includes a controller 210, a communicator 220, a sound output module 230, and a power supply 240.
The controller 210 includes a Random Access Memory (RAM)211, a Read Only Memory (ROM)212, a processor 213, a communication interface, and a communication bus. Controller 210 is used to control the operation of smart sound box 200, as well as the communication cooperation between the internal components, external and internal data processing functions.
The communicator 220 enables communication of data signals with the terminal 100 under the control of the controller 210. Such as: the smart sound box 200 transmits the data signal to the terminal 100 via the communicator 220, and the smart sound box 200 may receive the data signal and the control signal transmitted by the terminal 100 via the communicator 220. The communicator 220 may include a network communication protocol module or a near field communication protocol module, such as a WIFI module 221, a bluetooth communication protocol module 222, and a wired ethernet communication protocol module 223, so that the communicator 220 may receive a control signal of the terminal 100 according to the control of the controller 210, and implement the control signal as a WIFI signal, a bluetooth signal, a radio frequency signal, and the like.
The sound output module 230 is configured to output a sound signal, specifically, play a sound designated by the user under the control of the controller 210.
Optionally, smart sound box 200 further includes a power supply 240 for providing operational power support to the various components of smart sound box 200 under the control of controller 210. In the form of a battery and associated control circuitry.
Referring to fig. 2A, an embodiment of the present application provides a network distribution method for an intelligent sound box, including:
the intelligent sound box starts a distribution network;
the terminal starts a distribution network interface, searches the Bluetooth of the intelligent sound box and initiates connection with the intelligent sound box;
the terminal can be a mobile phone, a computer and an ipad.
After the intelligent sound box is successfully connected with the terminal, other terminals cannot be connected with the intelligent sound box;
the intelligent sound box sends a request for acquiring the maximum transmission unit to the terminal;
and after receiving the request sent by the intelligent sound box, the terminal responds to the request for obtaining the maximum transmission unit.
The terminal may or may not reply to the limit size of the maximum transmission unit of the smart speaker.
For example, in the andorid system, before using bluetooth (ble) to transmit data, the limit of MAXIMUM TRANSMISSION UNIT (MTU) of the andorid device can be obtained, which is generally 512 bytes. And the limited size of the maximum transmission unit of the intelligent sound box can not be replied to part of the terminals and the system.
A user clicks a button for acquiring a wifi list on a terminal, and the terminal sends a request for acquiring the wifi list;
the intelligent sound box receives a wifi list acquisition request sent by the terminal, and determines a transmission mode according to whether the terminal replies to the maximum transmission unit.
If the smart sound box does not receive the limitation of the maximum transmission unit replied by the terminal, the existing mode usually adopts the default transmission size transmission of ble transmission, and the default transmission size of ble transmission is 23 bytes. When the default MTU is used for transmitting data, it takes a long time to acquire the wifi list, so that it is impossible to acquire the wifi list by using the default MTU, and a user cannot select wifi. Aiming at the condition that the terminal does not reply the maximum transmission unit, the method and the device use a BLE _ WIFI self-adaptive transmission algorithm to transmit WIFI list data, and can meet the acquisition speed of a WIFI list. The specific method comprises the following steps:
referring to fig. 2B, fig. 2B is a flowchart of the BLE _ WIFI adaptive transmission algorithm.
When the intelligent sound box does not receive the limitation of the maximum transmission unit replied by the terminal, obtaining available wifi information within a preset range;
establishing a wifi list according to wifi information;
and calculating the data size of the wifi list, and transmitting the data size of the wifi list to the terminal according to the default transmission size of ble.
And the terminal receives and records the data size of the wifi list transmitted in the ble default transmission size.
For example: the data size of the wifi list is obtained through calculation of the intelligent sound box, namely the data size of the wifi list before being transmitted to the terminal is 1000 bytes, and the data of 1000 bytes is transmitted to the terminal in 23 byte transmission size.
If the data size of the wifi list is smaller than the preset byte, the preset byte can be 512 bytes, the data of the wifi list is transmitted to the terminal according to the first forward data size in the wifi list transmission data queue, and the wifi list transmission data queue comprises the data sizes which are arranged from small to large.
The wifi list transmission data queue may be {70,134,262,518}, and the unit is byte. The value of the wifi list transmission data queue represents the size of a data packet transmitted at one time. According to the structure of ble transport packets, each transport packet is composed of a header (2 bytes), a payload, and a trailer (4 bytes), so the queue data is composed of: the first 2 bytes are packet headers, the effective data loads are respectively 64, 128, 256 and 512 bytes, and the last 4 bytes are packet tails, so that a wifi list transmission data queue is formed and is {70,134,262,518 }.
The terminal continuously receives data of the wifi list sent by the intelligent sound box until an end mark is received; calculating the data size of the received wifi list; if the data size of the wifi list transmitted by the intelligent sound box is not consistent with the data size of the wifi list calculated by the terminal, sending a packet loss message to the intelligent sound box; and if the data size of the wifi list transmitted by the intelligent sound box is consistent with the data size of the wifi list calculated by the terminal, displaying the wifi name in the wifi list and sending a message which does not lose the packet to the intelligent sound box. After the user checks the available wifi in the wifi list, any wifi in the list is selected, the password corresponding to the wifi is input, and the terminal sends the service set identification and the password of the wifi selected by the user to the intelligent sound box.
If the intelligent sound box receives a packet loss message sent by the terminal, judging whether the size of the transmission data is the last value of a wifi list transmission data queue;
and judging the last value of the wifi list transmission data queue according to the direction of the wifi list transmission data queue. The wifi list transmit data queue is specifically 70,134,262,518 because the start is transmitted 70 bytes in forward first data size, then the last value is 518 bytes in forward last value.
And if the transmission data size is not the last value of the wifi list transmission data queue, retransmitting the data of the wifi list to the terminal by using the next forward data size in the wifi list transmission data queue.
And if the size of the transmission data is the last value of the transmission data queue of the wifi list, sending a message that the acquisition of the wifi list fails to be obtained to the terminal.
And if the intelligent sound box receives the message which is not lost and sent by the terminal, receiving the service set identification and the password of the wifi selected by the user. Connecting a wireless network using the received service set identifier and password; and after the connection is successful, reporting the networking successful state to the terminal.
The terminal enters a home page to display media resources and the like.
For example: the wifi list transmission data queue is specifically {70,134,262,518}, the size of data transmitted to the terminal wifi list by the intelligent sound box is 500 bytes, and the intelligent terminal transmits the data of the wifi list to the terminal in 70 bytes. If the terminal receives all transmitted data and calculates that the size of the received data is 500 bytes, the data size transmitted to the wifi list of the terminal by the intelligent sound box is consistent with the size of the data calculated by the terminal, the terminal sends a packet loss-free message to the intelligent sound box, and the intelligent sound box receives a service set identifier and a password of wifi selected by a user. Connecting a wireless network using the received service set identifier and password; and after the connection is successful, reporting the networking successful state to the terminal. The terminal enters the home page to display the media resources. If the terminal receives all transmitted data and calculates that the size of the received data is 490 bytes, the data size transmitted by the intelligent sound box to the terminal wifi list is inconsistent with the data size calculated by the terminal, and the terminal sends a packet loss message to the intelligent sound box. Because 70 is not the last data size of the wifi list transmission data queue, the smart sound box retransmits the data of the wifi list to the terminal with a 134-byte transmission size until receiving the message that the packet is not lost sent by the terminal, or retransmits the data of the data list to the terminal with a 518-byte transmission size of the last data size of the wifi list transmission data queue, the message that the packet is not lost sent by the terminal is still not received, the smart terminal sends the message that the wifi list acquisition fails to the terminal, the terminal displays the message that the distribution network fails, and the user can try to distribute the network again.
If the data size of the wifi list is not smaller than the preset byte, the preset byte can be 512 bytes, and the data of the wifi list is transmitted to the terminal by the first reverse data size in the wifi list transmission data queue.
The wifi list transmission data queue may be {70,134,262,518}, and the unit is byte. The value of the wifi list transmission data queue represents the size of a data packet transmitted at one time. According to the structure of ble transport packets, each transport packet is composed of a header (2 bytes), a payload, and a trailer (4 bytes), so the queue data is composed of: the first 2 bytes are packet headers, the effective data loads are respectively 64, 128, 256 and 512 bytes, and the last 4 bytes are packet tails, so that a wifi list transmission data queue is formed and is {70,134,262,518 }.
The terminal continuously receives data of the wifi list sent by the intelligent sound box until an end mark is received; calculating the data size of the received wifi list; if the data size of the wifi list transmitted by the intelligent sound box is not consistent with the data size of the wifi list calculated by the terminal, sending a packet loss message to the intelligent sound box; and if the data size of the wifi list transmitted by the intelligent sound box is consistent with the data size of the wifi list calculated by the terminal, displaying the wifi name in the wifi list and sending a message which does not lose the packet to the intelligent sound box. After the user checks the available wifi in the wifi list, any wifi in the list is selected, the password corresponding to the wifi is input, and the terminal sends the service set identification and the password of the wifi selected by the user to the intelligent sound box.
If the intelligent sound box receives a packet loss message sent by the terminal, judging whether the size of the transmission data is the last value of a wifi list transmission data queue;
and judging the last value of the wifi list transmission data queue according to the direction of the wifi list transmission data queue. The wifi list transmit data queue may be 70,134,262,518 since transmission begins with the reverse first data size of 518 bytes, then the last value is the reverse last value of 70 bytes.
And if the size of the transmission data is not the last value of the wifi list transmission data queue, retransmitting the data of the wifi list to the terminal by using the next reverse data size in the wifi list transmission data queue.
And if the size of the transmission data is the last value of the transmission data queue of the wifi list, sending a message that the acquisition of the wifi list fails to be obtained to the terminal.
And if the intelligent sound box receives the message which is not lost and sent by the terminal, receiving the service set identification and the password of the wifi selected by the user. Connecting a wireless network using the received service set identifier and password; and after the connection is successful, reporting the networking successful state to the terminal.
The terminal enters a home page to display media resources and the like.
For example: the wifi list transmission data queue can be {70,134,262,518}, the size of data transmitted to the terminal wifi list by the intelligent sound box is 3000 bytes, and the intelligent terminal transmits data of the wifi list to the terminal in size of 518 bytes. If the terminal receives all transmitted data and the size of the calculated data is 3000 bytes, the size of the data transmitted to the wifi list of the terminal by the intelligent sound box is consistent with the size of the data calculated by the terminal, the terminal sends a packet loss-free message to the intelligent sound box, and the intelligent sound box receives a service set identifier and a password of wifi selected by a user. Connecting a wireless network using the received service set identifier and password; and after the connection is successful, reporting the networking successful state to the terminal. The terminal enters the home page to display the media resources. If the terminal receives all transmitted data and calculates the data size to be 2800 bytes, the data size transmitted to the terminal wifi list by the intelligent sound box is inconsistent with the data size calculated by the terminal, and the terminal sends a packet loss message to the intelligent sound box. Because 518 is not the last value of the wifi list transmission data queue, the smart sound box retransmits the data of the wifi list to the terminal in 262 bytes transmission size until a non-packet-lost message sent by the terminal is received, or after the data of the wifi list transmission data queue is retransmitted in 70 bytes transmission size to the terminal, the non-packet-lost message sent by the terminal is still not received, the smart terminal sends a message that the wifi list acquisition fails to the terminal, the terminal displays a message that the distribution network fails, and the user can try to distribute the network again.
If the intelligent sound box receives the limitation of the maximum transmission unit replied by the terminal, acquiring available wifi information within a preset range; establishing a wifi list according to wifi information; and transmitting the data of the wifi list according to the transmission size of the maximum transmission unit.
For example, if the maximum transmission unit of the reply of the terminal is limited to 512 bytes, the wifi list data is transmitted in 512 byte transmission size.
The terminal receives an available wifi list sent by the intelligent sound box, and wifi names in the wifi list are displayed.
And the user selects any wifi in the list after checking the available wifi, and inputs the password corresponding to the wifi.
And the terminal sends the service set identification and the password of the wifi selected by the user to the intelligent sound box.
The intelligent sound box is connected with a wireless network by using the received service set identification and the password; and after the connection is successful, reporting the networking successful state to the terminal.
The terminal enters the home page to display the media resources.
The intelligent sound box is mainly dependent on the network, when the intelligent sound box is used for the first time, the network needs to be configured for the intelligent sound box through the terminal app, and in order to optimize user experience, no matter whether the app on the Android or IOS mobile phone operating system is operated, a user can freely select the network to configure the network of the sound box.
According to the technical scheme, after the intelligent sound box is successfully connected with the terminal, a request for acquiring the maximum transmission unit is sent to the terminal; if the maximum transmission unit replied by the terminal is not received, a wifi list is established; and sequentially and independently transmitting the data of the wifi list to the terminal by using the size of the data in the wifi list transmission data queue until the packet loss-free message is sent by the terminal. The intelligent sound box receives a service set identifier and a password of wifi selected by a user; and connecting the wireless network according to the service set identifier and the password. According to the method and the device, in the process of a distribution network, when the MTU condition of the terminal is not acquired, the data transmission of the default maximum transmission unit of the ble can be avoided, the device compatible with different systems can realize the free network configuration of a user by realizing the function of acquiring a wifi list, the terminal is not required to be connected with wifi in advance or the wifi connected with an intelligent connection terminal is not required, and the user experience is enhanced.
The embodiment of the application provides an intelligent sound box, include:
the voice output module is used for outputting a voice signal acquired from the terminal;
a communicator for establishing a connection state with the terminal;
a controller coupled to the voice input module and the communicator, for performing:
sending a request for acquiring a maximum transmission unit to a terminal;
receiving a request for acquiring a wifi list sent by the terminal;
if the maximum transmission unit replied by the terminal is not received, obtaining wifi information available in a preset range, and establishing a wifi list according to the wifi information;
transmitting the data of the wifi list to the terminal according to the size of the first data in the wifi list transmission data queue;
if a packet loss message sent by the terminal is received, transmitting data of a wifi list to the terminal according to the size of the next data in a wifi list transmission data queue until a packet loss-free message sent by the terminal is received or a packet loss-free message sent by the terminal is not received after the wifi list transmission data queue is traversed;
if a message which is not lost and is sent by the terminal is received, receiving a service set identifier and a password of wifi selected by a user;
and connecting the wireless network according to the service set identifier and the password.
In some embodiments, the controller performs the transmitting the data of the wifi list to the terminal with the first data size in the wifi list transmission data queue by:
calculating the data size of the wifi list;
if the data size of the wifi list is smaller than a preset byte, transmitting the data of the wifi list to the terminal by using the first positive data size in a wifi list transmission data queue, wherein the wifi list transmission data queue comprises data sizes which are arranged from small to large;
in some embodiments, the controller is further configured to transmit the data of the wifi list to the terminal with a first data size in a wifi list transmission data queue by:
and if the data size of the wifi list is not smaller than the preset byte, transmitting the data of the wifi list to the terminal by the first reverse data size in the wifi list transmission data queue.
In some embodiments, the controller is further configured to perform:
and if the information which does not lose the packet and is sent by the terminal is not received after the wifi list transmission data queue is traversed, sending the information which fails in obtaining the wifi list to the terminal.
In some embodiments, the controller is further configured to perform:
transmitting the data size of the wifi list to the terminal according to the default transmission size of ble, so that the terminal continuously receives the data of the wifi list until an end mark is received, and calculating the data size of the received wifi list; if the data size of the transmitted wifi list is inconsistent with the data size of the calculated wifi list, sending a packet loss message; and if the data size of the transmitted wifi list is consistent with the data size of the calculated wifi list, displaying the wifi name in the wifi list and sending a message without packet loss.
According to the technical scheme, after the intelligent sound box is successfully connected with the terminal, a request for acquiring the maximum transmission unit is sent to the terminal; if the maximum transmission unit replied by the terminal is not received, a wifi list is established; and sequentially and independently transmitting the data of the wifi list to the terminal by using the size of the data in the wifi list transmission data queue until the packet loss-free message is sent by the terminal. The intelligent sound box receives a service set identifier and a password of wifi selected by a user; and connecting the wireless network according to the service set identifier and the password. According to the method and the device, in the process of a distribution network, when the MTU condition of the terminal is not acquired, the data transmission of the default maximum transmission unit of the ble can be avoided, the device compatible with different systems can realize the free network configuration of a user by realizing the function of acquiring a wifi list, the terminal is not required to be connected with wifi in advance or the wifi connected with an intelligent connection terminal is not required, and the user experience is enhanced.
In specific implementation, the present application further provides a computer storage medium, where the computer storage medium may store a program, and the program may include some or all of the steps in the embodiments of the method for improving asset security provided by the present invention when executed. The storage medium may be a magnetic disk, an optical disk, a Read-Only Memory (ROM) or a Random Access Memory (RAM).
Those skilled in the art will readily appreciate that the techniques of the embodiments of the present invention may be implemented as software plus a required general purpose hardware platform. Based on such understanding, the technical solutions in the embodiments of the present invention may be essentially or partially implemented in the form of a software product, which may be stored in a storage medium, such as ROM/RAM, magnetic disk, optical disk, etc., and includes several instructions for enabling a computer device (which may be a personal computer, a server, or a network device, etc.) to execute the method according to the embodiments or some parts of the embodiments.
The same and similar parts in the various embodiments in this specification may be referred to each other. Particularly, for the intelligent sound box network distribution method and the intelligent sound box embodiment, since the method is basically similar to the method embodiment, the description is simple, and the relevant points can be referred to the description in the method embodiment.
The above-described embodiments of the present application do not limit the scope of the present application.
Claims (10)
1. An intelligent sound box, comprising:
the voice output module is used for outputting a voice signal acquired from the terminal;
a communicator for establishing a connection state with the terminal;
a controller coupled to the voice input module and the communicator, for performing:
sending a request for acquiring a maximum transmission unit to a terminal;
receiving a request for acquiring a wifi list sent by the terminal;
if the maximum transmission unit replied by the terminal is not received, obtaining wifi information available in a preset range, and establishing a wifi list according to the wifi information;
transmitting the data of the wifi list to the terminal according to the size of the first data in the wifi list transmission data queue;
if a packet loss message sent by the terminal is received, transmitting data of a wifi list to the terminal according to the size of the next data in a wifi list transmission data queue until a packet loss-free message sent by the terminal is received or a packet loss-free message sent by the terminal is not received after the wifi list transmission data queue is traversed;
if a message which is not lost and is sent by the terminal is received, receiving a service set identifier and a password of wifi selected by a user;
and connecting the wireless network according to the service set identifier and the password.
2. The smart sound box of claim 1, wherein the controller performs the transmitting the wifi list data to the terminal with a first data size in a wifi list transmit data queue by:
calculating the data size of the wifi list;
and if the data size of the wifi list is smaller than the preset bytes, transmitting the data of the wifi list to the terminal by using the first forward data size in the wifi list transmission data queue, wherein the wifi list transmission data queue comprises the data sizes which are arranged from small to large.
3. The smart sound box of claim 2, wherein the controller is further configured to perform the following steps of transmitting data of the wifi list to the terminal with a first data size in a wifi list transmission data queue:
and if the data size of the wifi list is not smaller than the preset byte, transmitting the data of the wifi list to the terminal by the first reverse data size in the wifi list transmission data queue.
4. The smart sound box of claim 1, wherein the controller is further configured to perform:
and if the information which does not lose the packet and is sent by the terminal is not received after the wifi list transmission data queue is traversed, sending the information which fails in obtaining the wifi list to the terminal.
5. The smart sound box of claim 1, wherein the controller is further configured to perform:
transmitting the data size of the wifi list to the terminal according to the default transmission size of ble, so that the terminal continuously receives the data of the wifi list until an end mark is received, and calculating the data size of the received wifi list; if the data size of the transmitted wifi list is inconsistent with the data size of the calculated wifi list, sending a packet loss message; and if the data size of the transmitted wifi list is consistent with the data size of the calculated wifi list, displaying the wifi name in the wifi list and sending a message without packet loss.
6. A network distribution method of a smart sound box is applied to the smart sound box, and is characterized by comprising the following steps:
sending a request for acquiring a maximum transmission unit to a terminal;
receiving a request for acquiring a wifi list sent by the terminal;
if the maximum transmission unit replied by the terminal is not received, obtaining wifi information available in a preset range, and establishing a wifi list according to the wifi information;
transmitting the data of the wifi list to the terminal according to the size of the first data in the wifi list transmission data queue;
if a packet loss message sent by the terminal is received, transmitting data of a wifi list to the terminal according to the size of the next data in a wifi list transmission data queue until a packet loss-free message sent by the terminal is received or the wifi list transmission data queue is traversed and a packet loss-free message sent by the terminal is still not received;
if a message which is not lost and is sent by the terminal is received, receiving a service set identifier and a password of wifi selected by a user;
and connecting the wireless network according to the service set identifier and the password.
7. The method according to claim 6, wherein the transmitting the data of the wifi list to the terminal with the first data size in the wifi list transmission data queue specifically includes:
calculating the data size of the wifi list;
and if the data size of the wifi list is smaller than the preset bytes, transmitting the data of the wifi list to the terminal by using the first forward data size in the wifi list transmission data queue, wherein the wifi list transmission data queue comprises the data sizes which are arranged from small to large.
8. The method according to claim 6, wherein the transmitting the data of the wifi list to the terminal with the size of the first data in the wifi list transmission data queue further comprises:
and if the data size of the wifi list is not smaller than the preset byte, transmitting the data of the wifi list to the terminal by the first reverse data size in the wifi list transmission data queue.
9. The method of claim 6, further comprising:
and if the information which does not lose the packet and is sent by the terminal is not received after the wifi list transmission data queue is traversed, sending the information which fails in obtaining the wifi list to the terminal.
10. The method of claim 6, further comprising:
transmitting the data size of the wifi list to the terminal according to the default transmission size of ble, so that the terminal continuously receives the data of the wifi list until an end mark is received, and calculating the data size of the received wifi list; if the data size of the transmitted wifi list is inconsistent with the data size of the calculated wifi list, sending a packet loss message; and if the data size of the transmitted wifi list is consistent with the data size of the calculated wifi list, displaying the wifi name in the wifi list and sending a message without packet loss.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202010091309.1A CN111278011B (en) | 2020-02-13 | 2020-02-13 | Network distribution method of intelligent sound box and intelligent sound box |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202010091309.1A CN111278011B (en) | 2020-02-13 | 2020-02-13 | Network distribution method of intelligent sound box and intelligent sound box |
Publications (2)
Publication Number | Publication Date |
---|---|
CN111278011A true CN111278011A (en) | 2020-06-12 |
CN111278011B CN111278011B (en) | 2023-07-21 |
Family
ID=71002555
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN202010091309.1A Active CN111278011B (en) | 2020-02-13 | 2020-02-13 | Network distribution method of intelligent sound box and intelligent sound box |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN111278011B (en) |
Citations (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN104144034A (en) * | 2013-12-04 | 2014-11-12 | 腾讯科技(深圳)有限公司 | Password sharing and obtaining methods and devices |
US20150006760A1 (en) * | 2008-06-02 | 2015-01-01 | Wilfried Steiner | Method for Synchronizing Local Clocks in a Distributed Computer System |
CN107342885A (en) * | 2016-05-03 | 2017-11-10 | 中兴通讯股份有限公司 | Method of adjustment, device and the terminal device of terminal MTU |
CN110072267A (en) * | 2018-01-22 | 2019-07-30 | 阿拉的(深圳)人工智能有限公司 | Method, apparatus, storage medium and the intelligent sound box of intelligent sound box networking |
CN110167193A (en) * | 2019-04-17 | 2019-08-23 | 苏宁智能终端有限公司 | WiFi matches network method and WiFi equipment automatically |
-
2020
- 2020-02-13 CN CN202010091309.1A patent/CN111278011B/en active Active
Patent Citations (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US20150006760A1 (en) * | 2008-06-02 | 2015-01-01 | Wilfried Steiner | Method for Synchronizing Local Clocks in a Distributed Computer System |
CN104144034A (en) * | 2013-12-04 | 2014-11-12 | 腾讯科技(深圳)有限公司 | Password sharing and obtaining methods and devices |
CN107342885A (en) * | 2016-05-03 | 2017-11-10 | 中兴通讯股份有限公司 | Method of adjustment, device and the terminal device of terminal MTU |
CN110072267A (en) * | 2018-01-22 | 2019-07-30 | 阿拉的(深圳)人工智能有限公司 | Method, apparatus, storage medium and the intelligent sound box of intelligent sound box networking |
CN110167193A (en) * | 2019-04-17 | 2019-08-23 | 苏宁智能终端有限公司 | WiFi matches network method and WiFi equipment automatically |
Also Published As
Publication number | Publication date |
---|---|
CN111278011B (en) | 2023-07-21 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
US11395213B2 (en) | Systems and methods for implementing multiple band service discovery | |
CN107231606B (en) | WiFi network access method, intelligent hardware equipment and electronic terminal | |
EP3185640A1 (en) | Communication method, communication system and relevant device of wearable device | |
US11172530B2 (en) | Communication establishment method and terminal | |
CN108200170A (en) | Message treatment method, device and readable storage medium storing program for executing | |
CN105898893B (en) | Full-duplex communication method for mobile terminal and Internet of things equipment | |
CN110636483A (en) | Network distribution method and system | |
EP2573970B1 (en) | Near field communication reader device, near field communication tag device, near field communication system and near field communication method | |
CN111464419B (en) | Data transmission control method based on bus network communication | |
CN110808948B (en) | Remote procedure calling method, device and system | |
US11889255B2 (en) | Communication method between earphones and charging box, charging box, earphones and readable storage medium | |
CN112689316B (en) | Binding method and device of intelligent equipment, storage medium and electronic device | |
CN111585801A (en) | ZigBee device upgrading method and related device | |
CN113141671A (en) | Communication method and device of wifi device and computer readable storage medium | |
CN114143659A (en) | Earphone data sending method, terminal equipment, master earphone, slave earphone and system | |
US20170127472A1 (en) | Method and wireless device for controlling disconnection of a wireless device in a wi-fi direct group of a wireless network | |
CN112422485B (en) | Communication method and device of transmission control protocol | |
CN111278011B (en) | Network distribution method of intelligent sound box and intelligent sound box | |
CN112333849A (en) | Equipment connection disconnection processing method and device, mobile terminal and storage medium | |
CN115883572A (en) | Peripheral sharing method and device | |
CN115967927A (en) | Bluetooth connection method and device, earphone and storage medium | |
CN108712373B (en) | Unidirectional communication method, device, user terminal and computer readable storage medium | |
CN107249194A (en) | Manage method, device and the equipment of wireless network connection | |
CN103546513B (en) | The method and device of communication between a kind of customer terminal webpage | |
CN112422254A (en) | Communication method, system, apparatus, computer device and storage medium |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
PB01 | Publication | ||
PB01 | Publication | ||
SE01 | Entry into force of request for substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
GR01 | Patent grant | ||
GR01 | Patent grant |