The disclosed implementations relate generally to data communication technology, and in particular, to communicating specific data (such as identification numbers, passwords and instructions) to a receiver device over a wireless network and thereby controlling the receiver device remotely.
As network technology develops, a large number of electronic devices (such as computers, mobile phones and small appliances) are communicatively coupled on a wireless network. Sometimes, a peripheral communication component may be further integrated in an electronic device to allow it to communicate with other electronic devices and receive useful data. For example, an electronic device may also include a Bluetooth module, a near field communication module or the like. However, usage of such a peripheral communication component increases the cost of the electronic device, while communication based on the component are not necessarily made more convenient. Therefore, there is a need to take advantage of existing wireless networks to deliver useful data to electronic devices efficiently without resorting to any peripheral communication component.
The above deficiencies and other problems associated with the conventional approaches of network communication are reduced or eliminated by the application disclosed below. In some embodiments, the application is implemented in an electronic device that has one or more processors, memory and one or more modules, programs or sets of instructions stored in the memory for performing multiple functions. Instructions for performing these functions may be included in a computer program product configured for execution by one or more processors.
One aspect of the application is a data communication method implemented at an electronic device. The method includes obtaining a sequence of data packets, wherein each data packet complies with a first data format corresponding to a network access protocol and includes a respective header that further includes a data length field for specifying a length of the respective data packet. The method further includes assigning data to the data length fields of the sequence of data packets according to a second data format and encrypting the sequence of data packets that include the assigned data. The method further includes sending the sequence of encrypted data packets to a receiver device that is communicatively coupled to the electronic device via a wireless network, wherein the receiver device is configured to retrieve the assigned data from the data length fields of the sequence of data packets according to the first and second data formats and perform operations in accordance with the retrieved data.
Another aspect of the application is a data processing method implemented at an electronic device. The method includes obtaining a sequence of data packets from a receiver device that is communicatively coupled to the receiver device via a wireless network and decrypting the sequence of data packets. Each decrypted data packet complies with a first data format corresponding to a network access protocol and includes a respective header that further includes a data length field for specifying a length of the respective decrypted data packet. The method includes retrieving data from the data length fields of the sequence of decrypted data packets according to a second data format distinct from the first data format, and performing operations in accordance with the retrieved data.
Another aspect of the application is an electronic device that includes one or more processors and memory having at least one program (including instructions) stored thereon, which when executed by the one or more processors cause the processors to perform operations to obtain a sequence of data packets. Each data packet complies with a first data format corresponding to a network access protocol and includes a respective header that further includes a data length field for specifying a length of the respective data packet. The at least one program further includes instructions to assign data to the data length fields of the sequence of data packets according to a second data format and encrypt the sequence of data packets that include the assigned data. The at least one program further includes instructions to send the sequence of encrypted data packets to a receiver device that is communicatively coupled to the electronic device via a wireless network, wherein the receiver device is configured to retrieve the assigned data from the data length fields of the sequence of data packets according to the first and second data formats and perform operations in accordance with the retrieved data.
Other embodiments and advantages may be apparent to those skilled in the art in light of the descriptions and drawings in this specification.
The aforementioned implementation of the present disclosure as well as additional implementations will be more clearly understood as a result of the following detailed description of the various aspects of the present disclosure when taken in conjunction with the drawings.
Like reference numerals refer to corresponding parts throughout the drawings.
Reference will now be made in detail to embodiments, examples of which are illustrated in the accompanying drawings. In the following detailed description, numerous specific details are set forth in order to provide a thorough understanding of the subject matter presented herein. But it will be apparent to one skilled in the art that the subject matter may be practiced without these specific details. The appended drawings, however, merely illustrate the more pertinent features of the present disclosure and are therefore not to be considered limiting, for the description may admit to other effective features. In other instances, well-known methods, procedures, components, and circuits have not been described in detail so as not to unnecessarily obscure aspects of the embodiments.
The technical scheme of the embodiment of the application will now be described in connection with the accompanying drawings in some embodiments of the application. Obviously, some but not all embodiments of the application are described. Based on the embodiments of the application, other embodiments obtained by people having ordinary skill in the art are also included in the protective scope of the application.
Unless there is special definition, all the present application technique and science terms used herein have the same meanings as those understood by the skilled of the technique field of the present application. The terms used herein for the description of password sharing and acquiring methods and systems are merely for describing particular embodiments, but not intended to limit the application. The term “and/or” used herein means any combination of one or more listed items.
Service set 100 is associated with a service set identifier (SSID) that differentiates communication network 30 from any other communication network. Access point 300 and electronic devices 100, 200 and 400 must use the same SSID to access the same communication network (e.g., network 30). In one specific example, a SSID is a unique identifier that includes 32 case sensitive alphanumeric characters, and acts as a password when a mobile device (e.g., device 100B) tries to connect to service set 10 associated with communication network 30. Under some circumstances, the SSID is attached to a header of every data packet sent over communication network 30.
In some implementations, the SSID of service set 100 is further associated with a SSID password. An electronic device has to provide both the SSID and the SSID password to connect to service set 10 associated with communication network 30. An electronic device not only has to encode a data packet according to the SSID and the SSID password before it distributes the data packet on communication network 30, but also has to decode a data packet when it receives the data packet via communication network 30 according to the SSID and the SSID password.
In many embodiments, the SSID and the SSID password are defined for an electronic device included in service set 10 based on a user's input, selection or confirmation. However, as discussed in the background of the application, some electronic devices (e.g., device 200) do not include a keyboard or a touch display that allows a user to manually input the SSID and/or the SSID password. In accordance with some embodiments of this application, such electronic devices receive the SSID and the SSID password from another electronic device that is included in the same service set 10 associated with communication network 30. The receiver devices thereby recover the SSID and the SSID password from one or more data packets transferred from the other electronic device. The recovered SSID information is then used to decode data packets received at the receiver devices via communication network 30 and encode data packets that are broadcasted by the receiver devices.
In one specific example, a receiver device is a smart sensor device that is controlled by another master computer for wireless energy management. The smart sensor device is plugged onto a wall power outlet. Due to its small form factor and low cost requirements, the smart sensor device may include a limited number of control switches or buttons, but does not include any display or keyboard. This smart sensor device has to rely on a communication network to receive instructions from the master computer and return sensing data back to the master computers for further analysis. Therefore, the smart sensor device has to receive the SSID information to access the communication network for the purposes of receiving the instructions and returning the sensing data.
Despite this specific example, one of those skilled in the art may see that, in some embodiments, a receiver device may include an input/output interface for receiving the input of the SSID or the SSID password, but chooses to receive the SSID or the SSID password from another electronic device of service set 10.
In accordance with some embodiments of this application, a SSID data set (including the SSID and the SSID password) is coded in a specific header field of a data packet. When the specific header field of one data packet is not sufficient to include all information of the SSID data set, a sequence of data packets are involved, and the SSID data set is coded in the specific header fields of multiple data packets based on a specific link layer data structure. The specific header fields includes either plain texts that are not encrypted or encrypted data that are encrypted with an encryption method that is known to a receiver device. As such, when it is first coupled to communication network 30, the receiver device may conveniently receive the SSID data set from another master device, recovers the SSID and the SSID password, and obtain an authorized access to communication network 30.
Further, in some embodiments, regardless of how the SSID or the SSID password associated with a service set 10 are obtained by a receiver device, the receiver device receives instructions via network 30 from another electronic device that also belongs to the same service set, and performs operations according to the received instructions. In accordance with some embodiments of this application, data associated with an instruction are coded in a specific header field of a data packet. When the specific header field of one data packet is not sufficient to include all information associated with the instruction, a sequence of data packets are involved, and the data associated with the instruction are coded in the specific header fields of multiple data packets based on a data format (i.e., a specific link layer data structure) that is distinct from a data format of the data packet. The specific header fields include either plain data that are not encrypted or encrypted data that are encrypted with an encryption method known to the receiver device.
In one specific example, each specific header field includes a data length field that specifies a length of a respective data packet, and data that are communicated to a receiver device are assigned to data length fields in headers of a sequence of data packets.
In some embodiments, the receiver device that is designated to receive the SSID data set is uniquely associated with a receiver device identifier. The receiver device identifier is often assigned by the manufacturer of the receiver device and provided upon the sale of the receiver device. The user of the master device optionally inputs the receiver device identifier, or selects a receiver device identifier from a list of receiver device identifiers.
Then, the user issues a SSID share request by clicking on a button 24. Upon receiving the SSID share request, the master device includes the SSID and the SSID password in a specific data field of one or more data packets based on a link layer data structure. The one or more data packets including the SSID data set is then communicated to the receiver device.
Assume the receiver device obtains the SSID data set requested based on user interface 20 and gains authorized access to communication network 30.
The user interface 26 is displayed on a master electronic device. In this example, the receiver device returns temperature data to the master electronic device via communication network 30, and such temperature data are displayed on user interface 26. In some embodiments, a user of the master device sets forth a target temperature by dragging a tick 28 on user interface 26, and click button “Done and Exit” to issue a temperature control command to the receiver device via communication network 30. Then, when the receiver device receives one or more data packets via communication network 30, it retrieves the temperature control command from header fields of the data packets by decoding the data packets according to predetermined data formats of the data packets.
In some implementations, user interfaces 20 and 26 are included in a social network platform, such as WeChat, WhatsApp, Link and Facebook. A user may directly access and control an electronic device via such user interfaces of this social network platform.
In some implementations, the data of the data field are encrypted, and however, a receiver device cannot decrypt the data of the data field without the SSID or the SSID password associated with communication network 30. However, the packet header is either unencrypted or encrypted with a known encryption method, such that the receiver device may easily extract information contained in the packet header without using the SSID data set.
In accordance with some embodiments of the application, a data field (e.g., a data length field) in the packet header is used to communicate interested data, such as the SSID, the SSID password, or instruction data, to a receiver device. The receiver device receives and decodes data packets over communication network 30, and retrieves the interested data from the designated data fields in the packet headers of the data packets. In one example, the data length fields of the packet headers are used to communicate the SSID data set (including the SSID or the SSID password), and the data fields (DATA) of the subsequent data packets are used to transfer commands (e.g., the temperature control command in
In some implementations, the interested data (e.g., the SSID data set or the instruction data) are coded in a respective header field (e.g., a data length field) of each packet of the data packet sequence 34 based on a link layer data structure.
In accordance with second data format 40, assigned data include a data control header 402, a prefix code field 404, and a number of data sequences 406, and each data sequence further includes a sequence header 406A and a data field 406B. Optionally, data control header 402 defines one or more of a data length, a data integrity word and an identifier of a receiver device. Specifically, as shown in
In some embodiments, the data length included in data control header 402 is the total length of assigned data 42 or the length of data control header 402. In this application, data control header 402 is also called as a magic code field.
Prefix code field 404 is followed by a number of data sequences, and therefore, it is used to indicate a start of such data sequences. In a specific example, a byte including eight bits of “1” is used to fill prefix code field 404.
In the specific example as shown in
In some implementations, data field 406B includes at least a part of the SSID data set (including the SSID and the SSID password). When the SSID data set is relatively long and cannot be delivered within six bytes (i.e., more than one data sequence), the SSID data set are included in two or more data sequences in data set 40 with each data sequence identified with a sequence header field 406A. In some embodiments, the SSID data set is so long that it cannot be delivered within all the data sequences of 406 of one data set 40, and two or more data sets 40 having their respective data control headers and prefix code fields are used to transmit the SSID data set. As such, two or more data packets 34 are involved to include the long SSID data set and deliver it to the receiver device.
In some embodiments, the SSID data set includes a SSID of a service set associated with a communication network, a corresponding SSID password, and a random number. When a receiver device receives the random number, it broadcasts the random number back to a master device that sends the SSID data set to the receiver device and confirms to the master device that it has received the SSID data set.
In the example shown in
Further, as shown in
In some embodiments, the six bytes of data field 408B identifies an instruction that the receiver device may receive and operate thereupon. In one example, the instruction is defined according to an instruction identification number, and when the receiver device receives the instruction identification number, it identifies the corresponding instruction based on a predetermined instruction lookup table. In addition to the instruction identification number, data field 408B optionally includes instruction information that provides parameters for performing operations according to the corresponding instruction. For instance, as shown in
In some embodiments, the interested data assigned to a data sequence field have a length is less that the length as defined in data control header 402. The extra bytes of the data sequence field are filled with zero.
More details on second data format 40 and corresponding assigned data 42 are explained below with reference to
Method 50 is performed by an electronic device that obtains (502) that obtains a sequence of data packets. Each data packet complies with a first data format corresponding to a network access protocol and includes a respective header that further includes a data length field for specifying a length of the respective data packet. Data are assigned (504) to the data length fields of the sequence of data packets according to a second data format. The sequence of data packets that include the assigned data are then encrypted (506). Further, the sequence of encrypted data packets are sent (508) to a receiver device that is communicatively coupled to the electronic device via a wireless network. The receiver device is configured to retrieve the assigned data from the data length fields of the sequence of data packets according to the first and second data formats and perform operations in accordance with the retrieved data.
In some embodiments, the assigned data includes a SSID and a SSID password, and the SSID identifies the wireless network that transmits the sequence of data packets and is accessible when the SSID password is verified. In some embodiments, the assigned data further includes a random number that is provided by the electronic device to the receiver device with the SSID and the SSID password, such that after receiving the SSID and the SSID password, the receiver device returns the random number to the electronic device to verify that it has received the SSID and the SSID password.
In some embodiments, the network access protocol associated with the sequence of data packets is selected from an IEEE protocol group consisting of Ethernet 802.2 SNAP, Ethernet 802.2, Ethernet 802.3 SNAP, and Ethernet 802.3.
In some embodiments, each data length field includes eight bits of data.
In some embodiments, the sequence of encrypted data packets are sent to the receiver device via a wireless access point that is also communicatively coupled on the identified wireless network.
In some embodiments, as shown in
In some embodiments, in accordance with the second data format, the assigned data includes a data control header that precedes a data field (e.g., data sequence fields 406 and 408) for specifying a plurality of characteristics associated with the assigned data, the data control header and the data field being assigned to the data length fields of a respective subset of data packets. In some situations, in accordance with the second data format, the assigned data include a plurality of bytes, and each byte further includes one or more control bits that identify whether the respective byte is associated with the data control header or the data field of the assigned data. In some situations, in accordance with the second data format, the plurality of characteristics that are associated with the assigned data include validity of the assigned data, and one or more bytes of the data control header are associated with integrity data for the assigned data. In some situations, in accordance with the second data format, the plurality of characteristics that are associated with the assigned data include a data length of the assigned data, and one or more bytes of the data control header are used to define the data length of the assigned data. In some situations, in accordance with the second data format, the data control header further includes one or more bytes that identify a start of the assigned data.
Method 60 is performed by an electronic device that obtains (602) sequence of data packets from a receiver device that is communicatively coupled to another electronic device via a wireless network. Each decrypted data packet complies with a first data format corresponding to a network access protocol and includes a respective header that further includes a data length field for specifying a length of the respective decrypted data packet. The sequence of data packets are decrypted (604) at the receiver device. Data are then retrieved (606) from the data length fields of the sequence of decrypted data packets according to a second data format distinct from the first data format. The receiver device performs (608) operations in accordance with the retrieved data.
In some embodiments, the retrieved data includes a SSID and a SSID password, and the SSID identifies the wireless network that transmits the sequence of data packets and is accessible when the SSID password is verified.
In some embodiments, the retrieved data further includes a random number that is provided by the electronic device to the receiver device with the SSID and the SSID password, such that after receiving the SSID and the SSID password, the receiver device returns the random number to the electronic device to verify that it has received the SSID and the SSID password.
In some embodiments, the network access protocol associated with the sequence of data packets is selected from an IEEE protocol group consisting of Ethernet 802.2 SNAP, Ethernet 802.2, Ethernet 802.3 SNAP, and Ethernet 802.3.
In some embodiments, each data length field includes eight bits of data.
In some embodiments, in accordance with the second data format, the retrieved data includes a data control header that precedes a data field for specifying a plurality of characteristics associated with the retrieved data, the data control header and the data field being assigned to the data length fields of a respective subset of data packets. Further, in some embodiments, in accordance with the second data format, the retrieved data include a plurality of bytes, and each byte further includes one or more control bits that identify whether the respective byte is associated with the data control header or the data field of the assigned data.
It should be understood that the particular order in which the operations in
In some embodiments, input/output interface 16 includes a display and input devices such as a keyboard, a mouse or a track-pad. In some embodiments, communication buses 80 include circuitry (sometimes called a chipset) that interconnects and controls communications between system components. In some embodiments, memory 14 includes high-speed random access memory, such as DRAM, SRAM, DDR RAM or other random access solid state memory devices; and optionally includes non-volatile memory, such as one or more magnetic disk storage devices, optical disk storage devices, flash memory devices, or other non-volatile solid state storage devices. In some embodiments, memory 14 includes one or more storage devices remotely located from the one or more processors 12. In some embodiments, memory 14, or alternatively the non-volatile memory device(s) within memory 14, includes a non-transitory computer readable storage medium.
In some embodiments, memory 14 or alternatively the non-transitory computer readable storage medium of memory 14 stores the following programs, modules and data structures, instructions, or a subset thereof:
In some embodiments, electronic device 70 is associated with a master electronic device that provides the SSID data set to a receiver device, and its memory 14 further includes:
In some embodiments, electronic device 70 is associated with a receiver device, and its memory 14 further includes:
In some embodiments, the sequence of data packets communicated from the master device to the receiver device are encrypted. The receiver device decrypts the encrypted data packets before it extracts the interested data from the header fields of the data packets.
In order to understand the present application clearly, detailed description of the communication method, communication system and information sending/receiving apparatus will be made with reference to the related drawings. The drawings show the preferred embodiments of the communication method, communication system and information sending/receiving apparatus. However, the communication method, communication system and information sending/receiving apparatus may be implemented in many different forms, and not limited to the described embodiments herein. The object of these embodiments is for full and deep disclosure of the communication method, communication system and information sending/receiving apparatus.
Unless there is special definition, all the present application technique and science terms used herein have the same meanings as those understood by the skilled of the technique field of the present application. The terms used herein for the description of the communication method, communication system and information sending/receiving apparatus are merely for describing particular embodiments, which are not intended to limit the present application. The term “and/or” used herein means any combination of one or more listed items.
At step S120, the master device acquires interested data that need to be sent to the receiver device. The interested data include the user data that need to be sent to the receiver device via a wireless communication network (e.g., network 30), and does not include control data generated by the system for the corresponding transmission process. The interested data, for example, may include a service set identifier (SSID) and a SSID password required for a wireless access, and instructions for controlling an intelligent air-conditioner. The interested data are optionally acquired by receiving user input on the master device. The interested data are optionally provided by another source via a network, or retrieved from a local memory of the master device.
At step S140, the interested data are encoded and assigned in the header field of a data packet. The header field is a plain data field in the data packet. The plain data field is able to be directly monitored, and thus, data of the header field are exposed during a wireless transmission process. When a receiver device is located within a coverage range of a corresponding wireless network, the receiver device can obtain the specific concrete content of the header field, even though the receiver device does not have the SSID and the SSID password associated with the wireless network. In many wireless communication modes, some information in a data packet is not secure, and can be used to as the header field at step S140. For example, at least a data length field in a header of a data packet that adopts an IEEE 802.2 SNAP format is such an header field that allows an easy access to the content stored therein.
The interested data may be transmitted in plaintext or transmitted with additional encryption, wherein the password for the encryption channel is different to the password for encrypting the interested data. If the interested data is encrypted, the receiver device may perform corresponding decryption, wherein the content of the interested data may be directly obtained without influence from the encryption channel.
At step S160, the data packet is sent by the master device to the receiver device. In some embodiments, after it is generated, the data packet is sent using a specific frequency band and a specific power level as specified by a communication protocol. In some embodiments, the data packet is encrypted using a data encryption method, when it is transferred via the corresponding communication channel according to the communication protocol.
In foregoing communication method, by using the header field in a data packet in which the content can be directly monitored, the interested data is encoded and sent out, and is received by the receiver device. With foregoing method, since the content of the header field encoded with the interested data may be directly monitored, the interested data may be obtained even though the contents of other fields in the data packet are encrypted and thus cannot be known, thereby realizing object to send information to a receiver device and receive and obtain the information by the receiver device. The receiver device may receive the interested data, without need of arrangement in advance to establish a connection with environment.
In some embodiments, a Wi-Fi wireless signal may be used a signal carrier to transfer data between the master and receiver devices. In one example, Wi-Fi channels 1 to 14 are used to transfer the data. By using the header field in a data packet in which the content can be directly monitored, the interested data is encoded to the header field, e.g., a data length field of a data packet header. The receiver device may be in hybrid mode to monitor the wireless signal in the space, thereby enabling monitoring the header field in which the content can be directly monitored, and obtaining the interested data by decoding the header field. The method of the embodiment is preferably suitable for transmission of minor data, which may applied in wireless terminals such as mobile phones and tablet computers having capability of wireless sending to send service set identifiers and passwords to intelligent control chips of Internet of Things on intelligent devices. At step S160, the data packet may be a broadcast packet, which is forwarded to receiver devices through a wireless access point. The wireless access point has a large communication power, such that the coverage area of the wireless signal that carries the data packet may be expanded after the wireless signal is forwarded by the wireless access point.
In some embodiments, the header field is a field which is controlled by a regular software application. Conventional operating systems (e.g., iOS or Android) of a mobile terminal has a limited level of control on a data packet, and specifically, may only be able to control all fields in a header of a data packet. In some situations, specific fields (e.g., DA and SA) in a data packet header involves a high level of control, and when such a header field is configured for use as the header field, this high level of control is required. However, many regular software applications operated on the conventional operating systems are not granted with such a high level of control. Therefore, in some implementations, the header field is preferably selected from a specific header field that does not require a high level of control and is controllable by a regular software application. As such, it is convenient to implement and use data communication method 80, and a high level of security is maintained for the corresponding electronic devices.
The header field “Length” in
Therefore, by using the header field “Length” in which the content can be directly monitored and controlled by many software applications, an application for coding in the master device gains convenient control to send data in the header field “Length” of the data packet as needed.
In some embodiments, the data packet is based on a user datagram protocol (UDP). The master devices uses the UDP broadcast packet to carry interested data and specifically, sends a series of UDP broadcast packets in which the respective header field “length” of each packet is encoded with the interested data. The receiver device monitors the wireless signal in space in a hybrid mode, intercepts the data packets that are configured in a 802.2 SNAP format, obtains data in the encoded header fields “Length” of the intercepted data packets, and retrieves the interested data (i.e., the interested data) by decoding the obtained data in the encoded header fields. In some embodiments, the data packet has a data format that complies with a transmission control protocol (TCP).
In some embodiments, due to a limitation for maximum transmission units (MTU), the maximum number of bits that can be used to carry the interested data in the header field “Length” is 10. However, the packet loss rate is normally proportional to the length of the UDP packet. When the header field “Length” provides more than 9 bits for carrying the interested data or the corresponding UDP packet has more than 256 bits, the packet loss rate of the UDP broadcast packet substantially increases, and a loss of order among different packets often occurs. Therefore, in some preferred embodiments, the number of bits is limited to 8 for some header fields that are used for carrying interested data, and the UDP broadcast packet is controlled to have a length of no more than 256 bits. In these circumstances, each UDP data packet includes one byte of interested data that is conveniently readable by the receiver device. Given such limited data amount in each data packet, the interested data may need multiple UDP data packets to be completely transferred from the master device to the receiver device.
The data field 1400 includes the sequence header field which is used for loading a check code of the check data. The data field 1400 further includes the sequence field used for loading the interested data. When each header field of a data packet used for carrying the interested data includes a byte (or 8 bits), the control field and the data field are distinguished by the 7th bit of a byte (sometimes called a control bit). Specifically, in one example, the 7th bit of “1” represents data field, and “0” represents control field. In other embodiments, any other bit may be used for the control bit for identifying the control field and the data field, wherein the codes of the control bit in the byte of the control field and the data field are distinct. The bit may be any one of 0th bit to 7th bit. In some embodiments, 0 may represents the data fields, and 1 represents the control fields. The magic code field and sequence header field are distinguished by the 6th bit, and 1 represents the sequence header field while 0 represents the identification field. In other embodiments, other bit(s) may also be used for identifying the magic code field. In some embodiments, 0 may represents the sequence header field, and 1 represents the identification field.
In some embodiments, a predetermined number of bytes (e.g., 20) are sent for identification fields 1200. The wireless network environment in which the receiver device locates may be complicated. Specifically, there would be multiple APs in the same space, and these APs may be distributed on same or different channels. Therefore, initially, the receiver device does not recognize which channel of 1 to 14 is used by the master device to send information and which of numerous devices on a specific channel is associated with the master device. In this situation, the receiver device could receive huge amount of data provided by different devices from different channels.
In order to find out the channel used by the master device and the physical address (i.e., MAC address) of the master device from the huge amount of data, the master device may send a predetermined number of bytes as identification fields 1200 before sending other information. Each of these identification fields 1200 includes 4 bytes, and is used to identify the master device. Therefore, the receiver device can know and focus on the MAC address and the channel of the master device, and use them in subsequent information monitoring procedure to effectively filter the huge amount of data.
Referring to
Referring to
As shown in
S220, receiving data packets generated by encoding the interested data in the header field. The header field is a field in the data packet which may directly monitored. Step S220 is associated with step S160. For the data packet transmitted on the encryption channel, the data packet is acquired on the encryption channel.
S240, decoding the header field to obtain the interested data. The interested data may be obtained through decoding according to the format corresponding to the encoding. For the data packet transmitted through an encryption channel, although the data field of the data packet is encrypted and thus the specific content contained in the data field cannot be recognized, the header field that carries the interested data can be directly monitored without knowing the corresponding encryption method that encrypts the data field of the data packet. The interested data are retrieved from the open header field.
Data communication method 1600 may involve a Wi-Fi network based on a Wi-Fi wireless communication protocol, and is suitable for communicating small amount of data. In some embodiments, data communication method 1600 is applied to control an intelligent control chip of Internet of Things to receive a SSID and a corresponding SSID password. For example, in a receiving mode, an intelligent switch does not have a key or touch screen to receive inputs of a SSID, and thereby, obtains the SSID and the password conveniently and quickly using data communication method 1600. Above-mentioned data packet may be a broadcast packet, and may be received through forwarding by a wireless access point. The wireless access point has large power, so that the coverage area of signal physical space of wireless communication may be increased when it forwards the corresponding wireless signals. The receiver device carries out step S220, by monitoring the wireless signals in space in a hybrid mode. At step S220, the receiver device retrieves data from a data packet in a data link layer.
As for the data packet and the header field, please referring to the embodiments shown in
In some embodiments, one reception of interested data is completed through receiving a data packet set composed by a plurality of data packets, the step S240 include: decoding the plurality of data packets, to sequentially obtain the control field used for being identified and the data field used for loading interested data, which are encoded in the header fields of the plurality of data packets. The control fields include identification field and sequence header field, wherein the identification field is used for identification, and the sequence header field is used for decoding the obtained check code of the check data. The data fields include sequence field, and the sequence field is used for loading the interested data.
The sequence header field includes sequence circular redundancy check code, and sequence index. The sequence field includes sequence byte, and the sequence field is used for obtaining the interested data. After receiving a data packet set, check is performed through sequence circular redundancy check code. If the check fails, the sequence of data is proved to be received with errors, which should be discarded.
In some embodiments, a sequence header field and a sequence field consist a sequence, and the interested data may be transmitted by a plurality of sequences. The sequence header field includes two bytes, wherein the lower six bits of the first byte carry the CRC8 of all sent data from the start of the sequence index to the end of the sequence. After receiving a sequence of data, check for the CRC8 value is performed. If not same, the sequence of data is proved to be received with errors, which should be discarded.
Before receiving N sequences carrying the interested data at each time, the prefix field will be received, the SSID CRC8 of the SSID used for decoding may be obtained. The communication method of the embodiment also includes scanning the APs in the environment to obtain an environment service set identifier. The environment service set identifier is checked with the SSID CRC8, if success, giving up receiving the SSID. Before the receiver device receives data, the wireless access points (APs) is scanned, wherein the SSID, RSSI (received signal strength indicator) and channels of all non-hide APs in the wireless environment may be obtained through acquired beacon During transmission procedure, the receiver device first acquires the CRC8 value of the SSID of a target AP, then compares it with the CRC8 value of the SSID obtained by scanning previously. If same value is found, the receiver device will not need to receive the SSID information again in the following procedure of reception, thereby significantly shortening the transmission time.
The communication model in the foregoing embodiment may be abstracted as a unidirectional channel with its error rate of 0-5%, wherein the maximum length of information to be transferred is 68 bytes. In such a case, if not using error correction algorithm, it is hard to assurance the completion of sending information in limited times. In some embodiments, the accumulation error correction algorithm is used to assurance the completion of transmission in limited times. Theoretical base of the accumulation error correction algorithm is that in multiple processes of sending data the error probability of data on the same bit is very low. Therefore multiple results of transferring data may be accumulated and analyzed. For a bit with large probability of error data in one process, its corresponding correct value may be found in other processes, thereby assuring the completion of sending information in limited times.
The transmission rate of the embodiment depends on the sending rate of the UDP broadcast packet in master device. Currently, the frequency of sending broadcast packets is ⅕ ms, so that the transmission rate is 200 bytes/s. In the case that the identification field will not be calculated, the efficiency of load is 66.7%. If the length of information sent is 68 bytes which is the longest, in the worst case, the information sending may be completed in 5 times at most, and the transmission time at most is 68/66.7*5/200=2.549s.
In another embodiment, the data packet also may be in Ethernet 802.2 format.
The data packet also may is in Ethernet 802.3 format.
The data packet also may is in Ethernet 802.3 SNAP format. Referring to
As shown in
S320, acquiring interested data to be sent. The interested data is the user data which needed to be send to receiver devices for wireless communication, but not the transmission control data automatically generated by the system for transmission process. The interested data, for example, may be a service set identifier (SSID) and a password required at wireless access, and adjustment parameter of an intelligent air-conditioner. The interested data may be acquired by receiving user input, may be acquired through network, or may be acquired from a local memory of the master device.
S340, encoding the interested data in the header field to generate a data packet, wherein, the header field is a field in the data packet which may directly monitored. The header field in which the content can be directly monitored refers to a field for exposing specific content in a wireless transmission procedure. As long as within the coverage of signal, any receiver device having wireless transmission function can obtain the specific concrete content of the header field, even though without the password of the wireless communication. In many wireless communication modes, some information in a data packet are not necessary to be secreted, for example the length field and the like in data packet of 802.2 SNAP format, which are exposed directly.
S360, sending the data packet. Particularly, the data packet is sent, for example, by using given frequency, power and the like according to the requirement of wireless communication after the data packet is generated. If the channel for sending data packet is encrypted, the data packet is sent through the encryption channel.
S380, receiving data packets. This step corresponds with S360. For the data packet transmitted on the encryption channel, the data packet is acquired on the encryption channel.
S390, decoding the header field to obtain the interested data. The interested data may be obtained through decoding according to the format corresponding to the encoding. For the data packet transmitted through a encryption channel, in which although the data area of the data packet is encrypted and thus the specific content cannot be known, the header field is a field of the data packet in which the content can be directly monitored without influence of the encryption channel, so that the content in the header field can be obtained for decoding.
In foregoing communication method, by using the header field in a data packet in which the content can be directly monitored, the interested data is encoded and sent out, and is received by the receiver device. With foregoing method, since the content of the header field encoded with the interested data may be directly monitored, the interested data may be obtained even though the contents of other fields in the data packet are encrypted and thus cannot be known, thereby realizing object to send information to a receiver device and receive and obtain the information by the receiver device. The receiver device may receive the interested data, without need of arrangement in advance to establish a connection with environment.
For the signal carrier, Wi-Fi wireless signal may be adopted for information transfer. Preferred, all channels of 1 to 14 may be used for support. By using the header field in a data packet in which the content can be directly monitored, the interested data is encoded. The receiver device may be in hybrid mode to monitor the wireless signal in the space, thereby enabling monitoring the header field in which the content can be directly monitored, and obtaining the interested data by decoding the header field. The method of the embodiment is preferably suitable for transmission of minor data, which may applied in wireless terminals such as mobile phones and tablet computers having capability of wireless sending to send service set identifiers and passwords to intelligent control chips of Internet of Things on intelligent devices. In step S360, the data packet may be a broadcast packet, which is forwarded to receiver devices through wireless access point. The wireless access point has large power, so that the coverage area of signal physical space of wireless communication may be increased by its forwarding.
In some embodiments, the header field is a field which may directly controlled by normal application. Because of the limitation of operating system (e.g., iOS or Android) of a mobile terminal, a control authority of very high level is needed for the control for a field in which the content can be directly monitored, thus those applications for coding is hard to get those control. If a field that can be directly controlled by normal applications is selected as the header field, a control authority of very high level is not needed to carry out the application of the embodiment, which is not only convenient for use but also keep the security of the system. In some embodiments, the data packet may be in the format of 802.2 SNAP, the header field is the length field in the data packet in the format of 802.2 SNAP. 802.11 is a wireless LAN protocol set by IEEE, with which the IP packet is carried by the logic link control packaging of 802.2, therefore the wireless network data may be received with 802.2 SNAP format. If the hybrid mode of Wi-Fi chip is enabled, the data packet as shown in
The header field “Length” in
Therefore, by using the header field “Length” in which the content can be directly monitored and controlled by many software applications, an application for coding in the master device gains convenient control to send data in the header field “Length” of the data packet as needed.
In some embodiments, the data packet is based on a user datagram protocol (UDP). The master devices uses the UDP broadcast packet to carry interested data and specifically, sends a series of UDP broadcast packets in which the respective header field “length” of each packet is encoded with the interested data. The receiver device monitors the wireless signal in space in a hybrid mode, intercepts the data packets that are configured in a 802.2 SNAP format, obtains data in the encoded header fields “Length” of the intercepted data packets, and retrieves the interested data (i.e., the interested data) by decoding the obtained data in the encoded header fields. In some embodiments, the data packet has a data format that complies with a transmission control protocol (TCP).
In some embodiments, due to a limitation for maximum transmission units (MTU), the maximum number of bits that can be used to carry the interested data in the header field “Length” is 10. However, the packet loss rate is normally proportional to the length of the UDP packet. When the header field “Length” provides more than 9 bits for carrying the interested data or the corresponding UDP packet has more than 256 bits, the packet loss rate of the UDP broadcast packet substantially increases, and a loss of order among different packets often occurs. Therefore, in some preferred embodiments, the number of bits is limited to 8 for some header fields that are used for carrying interested data, and the UDP broadcast packet is controlled to have a length of no more than 256 bits. In these circumstances, each UDP data packet includes one byte of interested data that is conveniently readable by the receiver device. Given such limited data amount in each data packet, the interested data may need multiple UDP data packets to be completely transferred from the master device to the receiver device.
Since each data packet can carry fewer data, in some embodiments, one whole interested data is sent through a data packet set consisting of a plurality of data packets, thus the step S340 include:
By using the control field and data field, in the case that a single data packet has limited interested data amount, a data transmission with its data amount larger than that of a single data packet may be realized by means of a data packet set.
The data field 1400 includes the sequence header field which is used for loading a check code of the check data. The data field 1400 further includes the sequence field used for loading the interested data. When each header field of a data packet used for carrying the interested data includes a byte (or 8 bits), the control field and the data field are distinguished by the 7th bit of a byte (sometimes called a control bit). Specifically, in one example, the 7th bit of “1” represents data field, and “0” represents control field. In other embodiments, any other bit may be used for the control bit for identifying the control field and the data field, wherein the codes of the control bit in the byte of the control field and the data field are distinct. The bit may be any one of 0th bit to 7th bit. In some embodiments, 0 may represents the data fields, and 1 represents the control fields. The magic code field and sequence header field are distinguished by the 6th bit, and 1 represents the sequence header field while 0 represents the identification field. In other embodiments, other bit(s) may also be used for identifying the magic code field. In some embodiments, 0 may represents the sequence header field, and 1 represents the identification field.
Referring to
In some embodiments, a predetermined number of bytes (e.g., 20) are sent for identification fields 1200. The wireless network environment in which the receiver device locates may be complicated. Specifically, there would be multiple APs in the same space, and these APs may be distributed on same or different channels. Therefore, initially, the receiver device does not recognize which channel of 1 to 14 is used by the master device to send information and which of numerous devices on a specific channel is associated with the master device. In this situation, the receiver device could receive huge amount of data provided by different devices from different channels.
In order to find out the channel used by the master device and the physical address (i.e., MAC address) of the master device from the huge amount of data, the master device may send a predetermined number of bytes as identification fields 1200 before sending other information. Each of these identification fields 1200 includes 4 bytes, and is used to identify the master device. Therefore, the receiver device can know and focus on the MAC address and the channel of the master device, and use them in subsequent information monitoring procedure to effectively filter the huge amount of data.
Referring to
Referring to
Further as shown in
The receiver device of the embodiment may be based on Wi-Fi wireless communication protocol, is suitable for receiving minor data, and may be applied in the intelligent control chip of Internet of Things to receive SSID and password. For example, through this receiving mode, an intelligent switch without a key or touch screen for inputting a SSID may obtain the SSID and password conveniently and quickly. Above-mentioned data packet may be a broadcast packet, and may be received through forwarding by a wireless access point. The wireless access point has large power, so that the coverage area of signal physical space of wireless communication may be increased by its forwarding. The receiver device carries out step S380, by monitoring the wireless signal in space with a hybrid mode. Step S380 is intercepting data in data link layer and obtaining data packet.
Before sending, the data packet is packaged and encrypted in IP layer and data link layer. Therefore, the step S390 includes a step for modifying the length field. In some embodiments, the data packet is sent as UDP broadcast packet. A data packet of UDP layer is first packaged in IP layer and data link layer, encrypted (in manners of WPA2. WPA or WEP) and then is sent out. In this way, the length of UDP broadcast packet sent by the master device will be different with the value of the header field “Length” monitored finally by the receiver device, therefore modification is needed. It is found that: as long as the length of the UDP broadcast packet is within the limitation range of the MTU (i.e., the UDP packet will not be intersected), the difference between the length of the UDP broadcast packet sent by the master device and the value of field Length monitored finally by the receiver device is a constant value. And the constant value will not change along with the length change of the UDP broadcast packet, and is only associated with the Wi-Fi encryption manner for the channel. Therefore, as long as the value of the difference under different encryption manner is found out, the receiver device can modify the header field “Length”.
Through a series of experiments, a modification table is obtained as shown in
In some embodiments, one reception of interested data is completed through receiving a data packet set composed by a plurality of data packets, the step S390 include: decoding the plurality of data packets, to sequentially obtain the control field used for being identified and the data field used for loading interested data, which are encoded in the header fields of the plurality of data packets. The control fields include identification field and sequence header field, wherein the identification field is used for identification, and the sequence header field is used for decoding the obtained check code of the check data. The data fields include sequence field, and the sequence field is used for loading the interested data.
The sequence header field includes sequence circular redundancy check code, and sequence index. The sequence field includes sequence byte, and the sequence field is used for obtaining the interested data. After receiving a data packet set, check is performed through sequence circular redundancy check code. If the check fails, the sequence of data is proved to be received with errors, which should be discarded.
In some embodiments, a sequence header field and a sequence field consist a sequence, and the interested data may be transmitted by a plurality of sequences. The sequence header field includes two bytes, wherein the lower six bits of the first byte carry the CRC8 of all sent data from the start of the sequence index to the end of the sequence. After receiving a sequence of data, check for the CRC8 value is performed. If not same, the sequence of data is proved to be received with errors, which should be discarded.
Before receiving N sequences carrying the interested data at each time, the prefix field will be received, the SSID CRC8 of the SSID used for decoding may be obtained. The communication method of the embodiment also includes scanning the APs in the environment to obtain an environment service set identifier. The environment service set identifier is checked with the SSID CRC8, if success, giving up receiving the SSID. Before the receiver device receives data, the wireless access points (APs) is scanned, wherein the SSID, RSSI (received signal strength indicator) and channels of all non-hide APs in the wireless environment may be obtained through acquired beacon. During transmission procedure, the receiver device first acquires the CRC8 value of the SSID of a target AP, then compares it with the CRC8 value of the SSID obtained by scanning previously. If same value is found, the receiver device will not need to receive the SSID information again in the following procedure of reception, thereby significantly shortening the transmission time.
The communication model in the foregoing embodiment may be abstracted as a unidirectional channel with its error rate of 0-5%, wherein the maximum length of information to be transferred is 68 bytes. In such a case, if not using error correction algorithm, it is hard to assurance the completion of sending information in limited times. In some embodiments, the accumulation error correction algorithm is used to assurance the completion of transmission in limited times. Theoretical base of the accumulation error correction algorithm is that in multiple processes of sending data the error probability of data on the same bit is very low. Therefore multiple results of transferring data may be accumulated and analyzed. For a bit with large probability of error data in one process, its corresponding correct value may be found in other processes, thereby assuring the completion of sending information in limited times.
Assuming the length of information to be transferred is 68 bytes, in worst case, the probability of successful information sending is calculated with the accumulation error correction algorithm and without accumulation error correction algorithm, and the relationship between the results and times of sending is shown in
The transmission rate of the embodiment depends on the sending rate of the UDP broadcast packet in master device. Currently, the frequency of sending broadcast packets is ⅕ ms, so that the transmission rate is 200 bytes/s. In the case that the identification field will not be calculated, the efficiency of loading is 66.7%. If the length of information sent is 68 bytes which is the longest, in the worst case, the information sending may be completed in 5 times at most, and the transmission time at most is 68/66.7*5/200=2.549s.
In other embodiments, the data packet also may is in Ethernet 802.2 format.
The data packet also may is in Ethernet 802.3 format.
The data packet also may be in Ethernet 802.3 SNAP format. Referring to
Acquiring module 120, used for acquiring interested data to be sent. The interested data is the user data which needed to be send to receiver devices for wireless communication, but not the transmission control data automatically generated by the system for transmission process.
The interested data, for example, may be a service set identifier (SSID) and a password required at wireless access, and adjustment parameter of an intelligent air-conditioner. The interested data may be acquired by receiving user input, may be acquired through network, or may be acquired from a local memory of the information sending apparatus 100.
Encoding module 140, used for encoding the interested data in the header field to generate a data packet, wherein, the header field is a field in the data packet which may directly monitored. The header field in which the content can be directly monitored refers to a field for exposing specific content in a wireless transmission procedure. As long as within the coverage of signal, any receiver device having wireless transmission function can obtain the specific concrete content of the header field, even though without the password of the wireless communication.
In many wireless communication modes, some information in a data packet are not necessary to be secreted, for example the length field and the like in data packet of 802.2 SNAP format, which are exposed directly. The interested data may be transmitted in plaintext or transmitted with additional encryption, wherein the password for the encryption channel is different to the password for encrypting the interested data. If the interested data is encrypted, the receiver device may perform corresponding decryption, wherein the content of the interested data may be directly obtained without influence from the encryption channel.
Sending module 160, used for sending the data packet. Particularly, the data packet is sent, for example, by using given frequency, power and the like according to the requirement of wireless communication after the data packet is generated. If the channel for sending data packet is encrypted, the data packet is sent through the encryption channel.
In foregoing information sending apparatus 100, by using the header field in a data packet in which the content can be directly monitored, the interested data is encoded and sent out, and is received by the receiver device. With information sending apparatus 100, since the content of the header field encoded with the interested data may be directly monitored, the interested data may be obtained even though the contents of other fields in the data packet are encrypted and thus cannot be known, thereby realizing object to send information to a receiver device and receive and obtain the information by the receiver device. The receiver device may receive the interested data, without need of arrangement in advance to establish a connection with environment.
For the signal carrier, Wi-Fi wireless signal may be adopted for information transfer. Preferred, all channels of 1 to 14 may be used for support. By using the header field in a data packet in which the content can be directly monitored, the interested data is encoded. The receiver device may be in hybrid mode to monitor the wireless signal in the space, thereby enabling monitoring the header field in which the content can be directly monitored, and obtaining the interested data by decoding the header field. The information sending apparatus 100 is preferably suitable for transmission of minor data, which may applied in wireless terminals such as mobile phones and tablet computers having capability of wireless sending to send service set identifiers and passwords to intelligent control chips of Internet of Things on intelligent devices. In sending module 160, the data packet may be a broadcast packet, which is forwarded to receiver devices through wireless access point. The wireless access point has large power, so that the coverage area of signal physical space of wireless communication may be increased by its forwarding.
In some embodiments, the header field is a field which may directly controlled by normal application. Because of the limitation of operating system (e.g., iOS or Android) of a mobile terminal, a control authority of very high level is needed for the control for a field in which the content can be directly monitored, thus those applications for coding is hard to get those control. If a field that can be directly controlled by normal applications is selected as the header field, a control authority of very high level is not needed to carry out the application of the embodiment, which is not only convenient for use but also keep the security of the system. In some embodiments, the data packet may be in the format of 802.2 SNAP, the header field is the length field in the data packet in the format of 802.2 SNAP. 802.11 is a wireless LAN protocol set by IEEE, with which the IP packet is carried by the logic link control packaging of 802.2, therefore the wireless network data may be received with 802.2 SNAP format. If the hybrid mode of Wi-Fi chip is enabled, the data packet as shown in
The header field “Length” in
Therefore, by using the header field “Length” in which the content can be directly monitored and controlled by many software applications, an application for coding in the master device gains convenient control to send data in the header field “Length” of the data packet as needed.
In some embodiments, the data packet is based on a user datagram protocol (UDP). The master devices uses the UDP broadcast packet to carry interested data and specifically, sends a series of UDP broadcast packets in which the respective header field “length” of each packet is encoded with the interested data. The receiver device monitors the wireless signal in space in a hybrid mode, intercepts the data packets that are configured in a 802.2 SNAP format, obtains data in the encoded header fields “Length” of the intercepted data packets, and retrieves the interested data (i.e., the interested data) by decoding the obtained data in the encoded header fields. In some embodiments, the data packet has a data format that complies with a transmission control protocol (TCP).
In some embodiments, due to a limitation for maximum transmission units (MTU), the maximum number of bits that can be used to carry the interested data in the header field “Length” is 10. However, the packet loss rate is normally proportional to the length of the UDP packet. When the header field “Length” provides more than 9 bits for carrying the interested data or the corresponding UDP packet has more than 256 bits, the packet loss rate of the UDP broadcast packet substantially increases, and a loss of order among different packets often occurs. Therefore, in some preferred embodiments, the number of bits is limited to 8 for some header fields that are used for carrying interested data, and the UDP broadcast packet is controlled to have a length of no more than 256 bits. In these circumstances, each UDP data packet includes one byte of interested data that is conveniently readable by the receiver device. Given such limited data amount in each data packet, the interested data may need multiple UDP data packets to be completely transferred from the master device to the receiver device.
Since each data packet can carry fewer data, in some embodiments, one whole interested data is sent through a data packet set consisting of a plurality of data packets. Particularly, the step of encoding the interested data in the header field to generate a data packet (wherein the header field is a field in the data packet in which the content can be directly monitored) comprises:
Referring to
The data field 1400 includes the sequence header field which is used for loading a check code of the check data. The data field 1400 further includes the sequence field used for loading the interested data. When each header field of a data packet used for carrying the interested data includes a byte (or 8 bits), the control field and the data field are distinguished by the 7th bit of a byte (sometimes called a control bit). Specifically, in one example, the 7th bit of “1” represents data field, and “0” represents control field. In other embodiments, any other bit may be used for the control bit for identifying the control field and the data field, wherein the codes of the control bit in the byte of the control field and the data field are distinct. The bit may be any one of 0th bit to 7th bit. In some embodiments, 0 may represents the data fields, and 1 represents the control fields. The magic code field and sequence header field are distinguished by the 6th bit, and 1 represents the sequence header field while 0 represents the identification field. In other embodiments, other bit(s) may also be used for identifying the magic code field. In some embodiments, 0 may represents the sequence header field, and 1 represents the identification field.
Referring to
In some embodiments, a predetermined number of bytes (e.g., 20) are sent for identification fields 1200. The wireless network environment in which the receiver device locates may be complicated. Specifically, there would be multiple APs in the same space, and these APs may be distributed on same or different channels. Therefore, initially, the receiver device does not recognize which channel of 1 to 14 is used by the master device to send information and which of numerous devices on a specific channel is associated with the master device. In this situation, the receiver device could receive huge amount of data provided by different devices from different channels.
In order to find out the channel used by the master device and the physical address (i.e., MAC address) of the master device from the huge amount of data, the master device may send a predetermined number of bytes as identification fields 1200 before sending other information. Each of these identification fields 1200 includes 4 bytes, and is used to identify the master device. Therefore, the receiver device can know and focus on the MAC address and the channel of the master device, and use them in subsequent information monitoring procedure to effectively filter the huge amount of data.
Referring to
Referring to
Further as shown in
Receiving module 220, used for receiving data packets generated by encoding the interested data in the header field, wherein, the header field is a field in the data packet which may directly monitored. The step corresponds to sending module 160, and will not be described repeatedly. For the data packet transmitted on the encryption channel, the data packet is acquired on the encryption channel.
Decoding module 240, used for decoding the header field to obtain the interested data. The interested data may be obtained through decoding according to the format corresponding to the encoding. For the data packet transmitted through a encryption channel, in which although the data area of the data packet is encrypted and thus the specific content cannot be known, the header field is a field of the data packet in which the content can be directly monitored without influence of the encryption channel, so that the content in the header field can be obtained for decoding.
The information receiving apparatus 200 may be based on Wi-Fi wireless communication protocol, is suitable for receiving minor data, and may be applied in the intelligent control chip of Internet of Things to receive SSID and password. For example, through this receiving mode, an intelligent switch without a key or touch screen for inputting a SSID may obtain the SSID and password conveniently and quickly. Above-mentioned data packet may be a broadcast packet, and may be received through forwarding by a wireless access point. The wireless access point has large power, so that the coverage area of signal physical space of wireless communication may be increased by its forwarding. The receiving module 220 monitors the wireless signal in space with a hybrid mode, intercepts data in data link layer, and obtains the data packet.
As for the data packet and the header field, please referring to the embodiments shown in
Through a series of experiments, a modification table is obtained as shown in
In some embodiments, one reception of interested data is completed through receiving a data packet set composed by a plurality of data packets. Decoding module 240 decodes the plurality of data packets, to obtain the control field used for being identified and the data field used for loading interested data, which are sequentially encoded in the header fields of the plurality of data packets. The control fields include identification field and sequence header field, wherein the identification field is used for identification, and the sequence header field is used for decoding the obtained check code of the check data. The data fields include sequence field, and the sequence field is used for loading the interested data.
The sequence header field includes sequence circular redundancy check code, and sequence index. The sequence field includes sequence byte, and the sequence field is used for obtaining the interested data. After receiving a data packet set, check is performed through sequence circular redundancy check code. If the check fails, the sequence of data is proved to be received with errors, which should be discarded.
In some embodiments, a sequence header field and a sequence field consist a sequence, and the interested data may be transmitted by a plurality of sequences. The sequence header field includes two bytes, wherein the lower six bits of the first byte carry the CRC8 of all sent data from the start of the sequence index to the end of the sequence. After receiving a sequence of data, check for the CRC8 value is performed. If not same, the sequence of data is proved to be received with errors, which should be discarded.
Before receiving N sequences carrying the interested data at each time, the prefix field will be received, the SSID CRC8 of the SSID used for decoding may be obtained. Receiving module 220 is also used for scanning the APs in the environment, to obtain the environment service set identifier The environment service set identifier is checked with the SSID CRC8, if success, giving up receiving the SSID. Before the information receiving apparatus 200 receives data, the APs are scanned, wherein the SSID, RSSI (received signal strength indicator) and channels of all non-hide APs in the wireless environment may be obtained through acquired beacon. During transmission procedure, the information receiving apparatus 200 first acquires the CRC8 value of the SSID of a target AP, and then compares it with the CRC8 value of the SSID obtained by scanning previously. If same value is found, the information receiving apparatus 200 will not need to receive the SSID information again in the following procedure of reception, thereby significantly shortening the transmission time.
The communication model in the foregoing embodiment may be abstracted as a unidirectional channel with its error rate of 0-5%, wherein the maximum length of information to be transferred is 68 bytes. In such a case, if not using error correction algorithm, it is hard to assurance the completion of sending information in limited times. In some embodiments, the accumulation error correction algorithm is used to assurance the completion of transmission in limited times. Theoretical base of the accumulation error correction algorithm is that in multiple processes of sending data the error probability of data on the same bit is very low. Therefore multiple results of transferring data may be accumulated and analyzed. For a bit with large probability of error data in one process, its corresponding correct value may be found in other processes, thereby assuring the completion of sending information in limited times.
Assuming the length of information to be transferred is 68 bytes, in worst case, the probability of successful information sending is calculated with the accumulation error correction algorithm and without accumulation error correction algorithm, and the relationship between the results and times of sending is shown in
The transmission rate of the embodiment depends on the sending rate of the UDP broadcast packet in master device. Currently, the frequency of sending broadcast packets is ⅕ ms, so that the transmission rate is 200 bytes/s. In the case that the identification field will not be calculated, the efficiency of loading is 66.7%. If the length of information sent is 68 bytes which is the longest, in the worst case, the information sending may be completed in 5 times at most, and the transmission time at most is 68/66.7*5/200=2.549s.
In another embodiment, the data packet also may be in Ethernet 802.2 format.
The data packet also may is in Ethernet 802.3 format.
The data packet also may be in Ethernet 802.3 SNAP format. Referring to
As shown in
Acquiring module 120, used for acquiring interested data to be sent. The interested data is the user data which needed to be send to receiver devices for wireless communication, but not the transmission control data automatically generated by the system for transmission process.
The interested data, for example, may be a service set identifier (SSID) and a password required at wireless access, and adjustment parameter of an intelligent air-conditioner. The interested data may be acquired by receiving user input, may be acquired through network, or may be acquired from a local memory of the master device.
Encoding module 140, used for encoding the interested data in the header field to generate a data packet, wherein, the header field is a field in the data packet which may directly monitored. The header field in which the content can be directly monitored refers to a field for exposing specific content in a wireless transmission procedure. As long as within the coverage of signal, any receiver device having wireless transmission function can obtain the specific concrete content of the header field, even though without the password of the wireless communication.
In many wireless communication modes, some information in a data packet are not necessary to be secreted, for example the length field and the like in data packet of 802.2 SNAP format, which are exposed directly.
Sending module 160, used for sending the data packet. Particularly, the data packet is sent, for example, by using given frequency, power and the like according to the requirement of wireless communication after the data packet is generated. If the channel for sending data packet is encrypted, the data packet is sent through the encryption channel.
Receiving module 220, used for receiving data packet. Corresponding to the sending module 160, receiving the data packet sent by the sending module 160. For the data packet transmitted on the encryption channel, the data packet is acquired on the encryption channel.
Decoding module 240, used for decoding the header field to obtain the interested data. The interested data may be obtained through decoding according to the format corresponding to the encoding. For the data packet transmitted through a encryption channel, in which although the data area of the data packet is encrypted and thus the specific content cannot be known, the header field is a field of the data packet in which the content can be directly monitored without influence of the encryption channel, so that the content in the header field can be obtained for decoding.
In foregoing communication system, by using the header field in a data packet in which the content can be directly monitored, the interested data is encoded and sent out, and is received by the receiver device. With foregoing communication system, since the content of the header field encoded with the interested data may be directly monitored, the interested data may be obtained even though the contents of other fields in the data packet are encrypted and thus cannot be known, thereby realizing object to send information to a receiver device and receive and obtain the information by the receiver device. The receiver device may receive the interested data, without need of arrangement in advance to establish a connection with environment.
For the signal carrier, Wi-Fi wireless signal may be adopted for information transfer. Preferred, all channels of 1 to 14 may be used for support. By using the header field in a data packet in which the content can be directly monitored, the interested data is encoded. The receiver device may be in hybrid mode to monitor the wireless signal in the space, thereby enabling monitoring the header field in which the content can be directly monitored, and obtaining the interested data by decoding the header field. The communication system of the embodiment is preferably suitable for transmission of minor data, which may applied in wireless terminals such as mobile phones and tablet computers having capability of wireless sending to send service set identifiers and passwords to intelligent control chips of Internet of Things in intelligent devices. The data packet sent by the sending module 160 may be a broadcast packet, which is forwarded to receiver devices through wireless access point. The wireless access point has large power, so that the coverage area of signal physical space of wireless communication may be increased by its forwarding.
In some embodiments, the header field is a field which may directly controlled by normal application. Because of the limitation of operating system (e.g., iOS or Android) of a mobile terminal, a control authority of very high level is needed for the control for a field in which the content can be directly monitored, thus those applications for coding is hard to get those control. If a field that can be directly controlled by normal applications is selected as the header field, a control authority of very high level is not needed to carry out the application of the embodiment, which is not only convenient for use but also keep the security of the system. In some embodiments, the data packet may be in the format of 802.2 SNAP, the header field is the length field in the data packet in the format of 802.2 SNAP. 802.11 is a wireless LAN protocol set by IEEE, with which the IP packet is carried by the logic link control packaging of 802.2, therefore the wireless network data may be received with 802.2 SNAP format. If the hybrid mode of Wi-Fi chip is enabled, the data packet as shown in
The header field “Length” in
Therefore, by using the header field “Length” in which the content can be directly monitored and controlled by many software applications, an application for coding in the master device gains convenient control to send data in the header field “Length” of the data packet as needed.
In some embodiments, the data packet is based on a user datagram protocol (UDP). The master devices uses the UDP broadcast packet to carry interested data and specifically, sends a series of UDP broadcast packets in which the respective header field “length” of each packet is encoded with the interested data. The receiver device monitors the wireless signal in space in a hybrid mode, intercepts the data packets that are configured in a 802.2 SNAP format, obtains data in the encoded header fields “Length” of the intercepted data packets, and retrieves the interested data (i.e., the interested data) by decoding the obtained data in the encoded header fields. In some embodiments, the data packet has a data format that complies with a transmission control protocol (TCP).
In some embodiments, due to a limitation for maximum transmission units (MTU), the maximum number of bits that can be used to carry the interested data in the header field “Length” is 10. However, the packet loss rate is normally proportional to the length of the UDP packet. When the header field “Length” provides more than 9 bits for carrying the interested data or the corresponding UDP packet has more than 256 bits, the packet loss rate of the UDP broadcast packet substantially increases, and a loss of order among different packets often occurs. Therefore, in some preferred embodiments, the number of bits is limited to 8 for some header fields that are used for carrying interested data, and the UDP broadcast packet is controlled to have a length of no more than 256 bits. In these circumstances, each UDP data packet includes one byte of interested data that is conveniently readable by the receiver device. Given such limited data amount in each data packet, the interested data may need multiple UDP data packets to be completely transferred from the master device to the receiver device.
Since each data packet can carry fewer data, in some embodiments, one whole interested data is sent through a data packet set consisting of a plurality of data packets. Particularly, the step of encoding the interested data in the header field to generate a data packet (wherein the header field is a field in the data packet in which the content can be directly monitored) includes:
The data field 1400 includes the sequence header field which is used for loading a check code of the check data. The data field 1400 further includes the sequence field used for loading the interested data. When each header field of a data packet used for carrying the interested data includes a byte (or 8 bits), the control field and the data field are distinguished by the 7th bit of a byte (sometimes called a control bit). Specifically, in one example, the 7th bit of “1” represents data field, and “0” represents control field. In other embodiments, any other bit may be used for the control bit for identifying the control field and the data field, wherein the codes of the control bit in the byte of the control field and the data field are distinct. The bit may be any one of 0th bit to 7th bit. In some embodiments, 0 may represents the data fields, and 1 represents the control fields. The magic code field and sequence header field are distinguished by the 6th bit, and 1 represents the sequence header field while 0 represents the identification field. In other embodiments, other bit(s) may also be used for identifying the magic code field. In some embodiments, 0 may represents the sequence header field, and 1 represents the identification field.
Referring to
In some embodiments, a predetermined number of bytes (e.g., 20) are sent for identification fields 1200. The wireless network environment in which the receiver device locates may be complicated. Specifically, there would be multiple APs in the same space, and these APs may be distributed on same or different channels. Therefore, initially, the receiver device does not recognize which channel of 1 to 14 is used by the master device to send information and which of numerous devices on a specific channel is associated with the master device. In this situation, the receiver device could receive huge amount of data provided by different devices from different channels.
In order to find out the channel used by the master device and the physical address (i.e., MAC address) of the master device from the huge amount of data, the master device may send a predetermined number of bytes as identification fields 1200 before sending other information. Each of these identification fields 1200 includes 4 bytes, and is used to identify the master device. Therefore, the receiver device can know and focus on the MAC address and the channel of the master device, and use them in subsequent information monitoring procedure to effectively filter the huge amount of data.
Referring to
Referring to
Further as shown in
The receiver device of the embodiment may be based on Wi-Fi wireless communication protocol, is suitable for receiving minor data, and may be applied in the intelligent control chip of Internet of Things to receive SSID and password. For example, through this receiving mode, an intelligent switch without a key or touch screen for inputting a SSID may obtain the SSID and password conveniently and quickly. Above-mentioned data packet may be a broadcast packet, and may be received through forwarding by a wireless access point. The wireless access point has large power, so that the coverage area of signal physical space of wireless communication may be increased by its forwarding. The receiving module 220 monitors the wireless signal in space with a hybrid mode, carries out the step of receiving data packet. Receiving module 220 intercepts the data in data link layer and obtains data packet.
Before sending, the data packet is packaged and encrypted in IP layer and data link layer. The decoding module 240 is also used for modifying the length field. In some embodiments, the data packet is sent as UDP broadcast packet. A data packet of UDP layer is first packaged in IP layer and data link layer, encrypted (in manners of WPA2, WPA or WEP) and then is sent out. In this way, the length of UDP broadcast packet sent by the master device will be different with the value of the header field “Length” monitored finally by the receiver device, therefore modification is needed. It is found that: as long as the length of the UDP broadcast packet is within the limitation range of the MTU (i.e., the UDP packet will not be intersected), the difference between the length of the UDP broadcast packet sent by the master device and the value of field Length monitored finally by the receiver device is a constant value. And the constant value will not change along with the length change of the UDP broadcast packet, and is only associated with the Wi-Fi encryption manner for the channel. Therefore, as long as the value of the difference under different encryption manner is found out, the receiver device can modify the header field “Length”.
Through a series of experiments, a modification table is obtained as shown in
In some embodiments, one reception of interested data is completed through receiving a data packet set composed by a plurality of data packets. Decoding module 240 decodes the plurality of data packets, to obtain the control field used for being identified and the data field used for loading interested data, which are sequentially encoded in the header fields of the plurality of data packets. The control fields include identification field and sequence header field, wherein the identification field is used for identification, and the sequence header field is used for decoding the obtained check code of the check data. The data fields include sequence field, and the sequence field is used for loading the interested data.
The sequence header field includes sequence circular redundancy check code, and sequence index. The sequence field includes sequence byte, and the sequence field is used for obtaining the interested data. After receiving a data packet set, check is performed through sequence circular redundancy check code. If the check fails, the sequence of data is proved to be received with errors, which should be discarded.
In some embodiments, a sequence header field and a sequence field consist a sequence, and the interested data may be transmitted by a plurality of sequences. The sequence header field includes two bytes, wherein the lower six bits of the first byte carry the CRC8 of all sent data from the start of the sequence index to the end of the sequence. After receiving a sequence of data, check for the CRC8 value is performed. If not same, the sequence of data is proved to be received with errors, which should be discarded.
Before receiving N sequences carrying the interested data at each time, the prefix field will be received, the SSID CRC8 of the SSID used for decoding may be obtained. The communication system of the embodiment also includes scanning the APs in the environment to obtain an environment service set identifier. The environment service set identifier is checked with the SSID CRC8, if success, giving up receiving the SSID. Before the receiver device receives data, the wireless access points (APs) is scanned, wherein the SSID, RSSI (received signal strength indicator) and channels of all non-hide APs in the wireless environment may be obtained through acquired beacon. During transmission procedure, the receiver device first acquires the CRC8 value of the SSID of a target AP, and then compares it with the CRC8 value of the SSID obtained by scanning previously. If same value is found, the receiver device will not need to receive the SSID information again in the following procedure of reception, thereby significantly shortening the transmission time.
The communication model in the foregoing embodiment may be abstracted as a unidirectional channel with its error rate of 0-5%, wherein the maximum length of information to be transferred is 68 bytes. In such a case, if not using error correction algorithm, it is hard to assurance the completion of sending information in limited times. In some embodiments, the accumulation error correction algorithm is used to assurance the completion of transmission in limited times. Theoretical base of the accumulation error correction algorithm is that in multiple processes of sending data the error probability of data on the same bit is very low. Therefore multiple results of transferring data may be accumulated and analyzed. For a bit with large probability of error data in one process, its corresponding correct value may be found in other processes, thereby assuring the completion of sending information in limited times.
Assuming the length of information to be transferred is 68 bytes, in worst case, the probability of successful information sending is calculated with the accumulation error correction algorithm and without accumulation error correction algorithm, and the relationship between the results and times of sending is shown in
The transmission rate of the embodiment depends on the sending rate of the UDP broadcast packet in master device. Currently, the frequency of sending broadcast packets is ⅕ ms, so that the transmission rate is 200 bytes/s. In the case that the identification field will not be calculated, the efficiency of loading is 66.7%. If the length of information sent is 68 bytes which is the longest, in the worst case, the information sending may be completed in 5 times at most, and the transmission time at most is 68/66.7*5/200=2.549s.
In another embodiment, the data packet also may be in Ethernet 802.2 format.
The data packet also may is in Ethernet 802.3 format.
The data packet also may be in Ethernet 802.3 SNAP format. Referring to
The skilled in the art may understand that the whole or part flow of the methods in foregoing embodiments may performed by relevant hardware through the instruction of computer program. The program may be stored in computer readable storage medium, and may implement methods of foregoing embodiments when being carrying out. Wherein, the storage medium may be magnetic disc, optical disc, Read-Only Memory (ROM) or Random Access Memory (RAM) and the like.
Foregoing embodiments only express several implementation modes of the present application, which are specific and detailed, but is not intended to limit the protection range of the present application. For the skilled in the art, some modification and improvement may be made without departing from sprit of the present application, which will fall in the protection scope of the present application. Therefore, the protection scope of the present application should be determined by the claims.
While particular embodiments are described above, it will be understood it is not intended to limit the invention to these particular embodiments. On the contrary, the invention includes alternatives, modifications and equivalents that are within the spirit and scope of the appended claims. Numerous specific details are set forth in order to provide a thorough understanding of the subject matter presented herein. But it will be apparent to one of ordinary skill in the art that the subject matter may be practiced without these specific details. In other instances, well-known methods, procedures, components, and circuits have not been described in detail so as not to unnecessarily obscure aspects of the embodiments.
Although the terms first, second, etc. may be used herein to describe various elements, these elements should not be limited by these terms. These terms are only used to distinguish one element from another. For example, first ranking criteria could be termed second ranking criteria, and, similarly, second ranking criteria could be termed first ranking criteria, without departing from the scope of the present application. First ranking criteria and second ranking criteria are both ranking criteria, but they are not the same ranking criteria.
The terminology used in the description of the invention herein is for the purpose of describing particular embodiments only and is not intended to be limiting of the invention. As used in the description of the invention and the appended claims, the singular forms “a,” “an,” and “the” are intended to include the plural forms as well, unless the context clearly indicates otherwise. It will also be understood that the term “and/or” as used herein refers to and encompasses any and all possible combinations of one or more of the associated listed items. It will be further understood that the terms “includes,” “including,” “comprises,” and/or “comprising,” when used in this specification, specify the presence of stated features, operations, elements, and/or components, but do not preclude the presence or addition of one or more other features, operations, elements, components, and/or groups thereof.
As used herein, the term “if” may be construed to mean “when” or “upon” or “in response to determining” or “in accordance with a determination” or “in response to detecting,” that a stated condition precedent is true, depending on the context. Similarly, the phrase “if it is determined [that a stated condition precedent is true]” or “if [a stated condition precedent is true]” or “when [a stated condition precedent is true]” may be construed to mean “upon determining” or “in response to determining” or “in accordance with a determination” or “upon detecting” or “in response to detecting” that the stated condition precedent is true, depending on the context.
Although some of the various drawings illustrate a number of logical stages in a particular order, stages that are not order dependent may be reordered and other stages may be combined or broken out. While some reordering or other groupings are specifically mentioned, others will be obvious to those of ordinary skill in the art and so do not present an exhaustive list of alternatives. Moreover, it should be recognized that the stages could be implemented in hardware, firmware, software or any combination thereof.
The foregoing description, for purpose of explanation, has been described with reference to specific implementations. However, the illustrative discussions above are not intended to be exhaustive or to limit the invention to the precise forms disclosed. Many modifications and variations are possible in view of the above teachings. The implementations were chosen and described in order to best explain principles of the invention and its practical applications, to thereby enable others skilled in the art to best utilize the invention and various implementations with various modifications as are suited to the particular use contemplated. Implementations include alternatives, modifications and equivalents that are within the spirit and scope of the appended claims. Numerous specific details are set forth in order to provide a thorough understanding of the subject matter presented herein. But it will be apparent to one of ordinary skill in the art that the subject matter may be practiced without these specific details. In other instances, well-known methods, procedures, components, and circuits have not been described in detail so as not to unnecessarily obscure aspects of the implementations.
Number | Date | Country | Kind |
---|---|---|---|
2013 1 0649198 | Dec 2013 | CN | national |
This application is a continuation application of PCT Patent Application No. PCT/CN2014/092652, entitled “DATA COMMUNICATION VIA DATA PACKET HEADERS” filed on Dec. 1, 2014, which claims priority to Chinese Patent Application No. 201310649198.1, entitled “Communication method, communication system and information sending/receiving apparatus” filed on Dec. 4, 2014, both of which are incorporated by reference in their entirety.
Number | Name | Date | Kind |
---|---|---|---|
20060039341 | Ptasinski | Feb 2006 | A1 |
20080046545 | Koren | Feb 2008 | A1 |
20080056216 | Zimmerman | Mar 2008 | A1 |
20140196142 | Louboutin | Jul 2014 | A1 |
Number | Date | Country |
---|---|---|
1531260 | Sep 2004 | CN |
101471937 | Jul 2009 | CN |
101488954 | Jul 2009 | CN |
103237313 | Aug 2013 | CN |
103327030 | Sep 2013 | CN |
104144034 | Nov 2014 | CN |
104144086 | Nov 2014 | CN |
WO 2008030877 | Mar 2008 | WO |
Entry |
---|
Tencent Technology, ISRWO, PCT/CN2014/092652, Mar. 2, 2015, 8 pgs. |
Tencent Technology, IPRP, PCT/CN2014/092652, Jun. 7, 2016, 6 pgs. |
Number | Date | Country | |
---|---|---|---|
20160112901 A1 | Apr 2016 | US |
Number | Date | Country | |
---|---|---|---|
Parent | PCT/CN2014/092652 | Dec 2014 | US |
Child | 14973474 | US |