CN109274445B - Electronic equipment pairing method and device, electronic equipment and storage medium - Google Patents

Electronic equipment pairing method and device, electronic equipment and storage medium Download PDF

Info

Publication number
CN109274445B
CN109274445B CN201811175874.5A CN201811175874A CN109274445B CN 109274445 B CN109274445 B CN 109274445B CN 201811175874 A CN201811175874 A CN 201811175874A CN 109274445 B CN109274445 B CN 109274445B
Authority
CN
China
Prior art keywords
pairing
frequency
gateway
communication channel
paired
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN201811175874.5A
Other languages
Chinese (zh)
Other versions
CN109274445A (en
Inventor
裴润源
胡政
陈波
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Changsha Sunsky Electronic Design Development Co ltd
Original Assignee
Changsha Sunsky Electronic Design Development Co ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Changsha Sunsky Electronic Design Development Co ltd filed Critical Changsha Sunsky Electronic Design Development Co ltd
Priority to CN201811175874.5A priority Critical patent/CN109274445B/en
Publication of CN109274445A publication Critical patent/CN109274445A/en
Application granted granted Critical
Publication of CN109274445B publication Critical patent/CN109274445B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04BTRANSMISSION
    • H04B17/00Monitoring; Testing
    • H04B17/30Monitoring; Testing of propagation channels
    • H04B17/382Monitoring; Testing of propagation channels for resource allocation, admission control or handover
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04WWIRELESS COMMUNICATION NETWORKS
    • H04W72/00Local resource management
    • H04W72/04Wireless resource allocation
    • H04W72/044Wireless resource allocation based on the type of the allocated resource
    • H04W72/0453Resources in frequency domain, e.g. a carrier in FDMA

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Physics & Mathematics (AREA)
  • Electromagnetism (AREA)
  • Mobile Radio Communication Systems (AREA)

Abstract

The application relates to an electronic equipment pairing method and device, electronic equipment and a storage medium. The method comprises the following steps: when a pairing trigger signal is detected, switching the frequency of a communication channel to a pairing frequency, wherein the pairing trigger signal is an electromagnetic induction signal; acquiring the working frequency of the paired equipment through a communication channel; switching a frequency of the communication channel to an operating frequency to communicate with the paired device based on the operating frequency. By adopting the method, the pairing processing between the electronic equipment and the pairing gateway can be quickly completed without additionally adding a pairing communication device, so that the cost of the electronic equipment is reduced.

Description

Electronic equipment pairing method and device, electronic equipment and storage medium
Technical Field
The present application relates to the field of electronic communication technologies, and in particular, to an electronic device pairing method and apparatus, an electronic device, and a storage medium.
Background
With the development of wireless communication technology, the wireless communication technology is widely applied to our lives to realize short-distance directional communication. In order to implement short-distance directional communication, the electronic devices involved in short-distance directional communication are usually paired, a binding relationship between the electronic devices is established, and the function of directional communication is implemented through the binding relationship. For example, in a voting system, a voter needs to be paired with a master control end, so that the voter only performs data interaction with the paired master control end.
However, in the current pairing method for electronic devices, when inductive pairing is adopted, a pairing Communication device needs to be additionally added for pairing processing, for example, an NFC (Near Field Communication) read-write chip is provided in the electronic device, and the electronic device and the base station are paired by using an NFC technology. This additional pairing of the paired communication devices increases the cost of the electronic device to some extent.
Disclosure of Invention
In view of the above, it is necessary to provide an electronic device pairing method, apparatus, electronic device and storage medium capable of reducing the cost of the electronic device.
An electronic device pairing method, the method comprising:
when a pairing trigger signal is detected, switching the frequency of a communication channel to a pairing frequency, wherein the pairing trigger signal is an electromagnetic induction signal;
acquiring the working frequency of the paired gateway through the communication channel;
switching a frequency of the communication channel to the operating frequency to communicate with the counterpart gateway based on the operating frequency.
An electronic device pairing apparatus, the apparatus comprising:
the pairing triggering module is used for switching the frequency of a communication channel to pairing frequency when a pairing triggering signal is detected, wherein the pairing triggering signal is an electromagnetic induction signal;
the working frequency acquisition module is used for acquiring the working frequency of the paired gateway through the communication channel;
a frequency switching module, configured to switch a frequency of the communication channel to the working frequency, so as to communicate with the pairing gateway based on the working frequency.
An electronic device comprising a memory and a processor, the memory storing a computer program, the processor implementing the following steps when executing the computer program:
when a pairing trigger signal is detected, switching the frequency of a communication channel to a pairing frequency, wherein the pairing trigger signal is an electromagnetic induction signal;
acquiring the working frequency of the paired gateway through the communication channel;
switching a frequency of the communication channel to the operating frequency to communicate with the counterpart gateway based on the operating frequency.
A computer-readable storage medium, on which a computer program is stored which, when executed by a processor, carries out the steps of:
when a pairing trigger signal is detected, switching the frequency of a communication channel to a pairing frequency, wherein the pairing trigger signal is an electromagnetic induction signal;
acquiring the working frequency of the paired gateway through the communication channel;
switching a frequency of the communication channel to the operating frequency to communicate with the counterpart gateway based on the operating frequency.
According to the electronic equipment pairing method, the electronic equipment pairing device, the electronic equipment and the storage medium, when the pairing trigger signal is detected, the frequency of the communication channel is switched to the pairing frequency, wherein the pairing trigger signal is an electromagnetic induction signal. When the pairing is triggered, the frequency of the communication channel is firstly switched to the general pairing frequency to receive the working frequency of the paired gateway, and the frequency of the communication channel is switched to the corresponding working frequency after the pairing signal is received, so that the current equipment and the paired gateway communicate with each other according to the specific working frequency, and the pairing between the current equipment and the paired gateway is realized. Namely, the pairing processing between the electronic devices can be quickly completed through the frequency switching of the communication channels, and a pairing communication device does not need to be additionally arranged, so that the cost of the electronic devices is reduced.
Drawings
FIG. 1 is a diagram of an application environment for a method for pairing electronic devices in one embodiment;
FIG. 2 is a flow diagram that illustrates a method for pairing electronic devices, according to one embodiment;
FIG. 3 is a flow diagram that illustrates a method for pairing electronic devices, according to one embodiment;
FIG. 4 is a timing diagram of a pairing method for electronic devices in one embodiment;
FIG. 5 is a block diagram of an apparatus for pairing electronic devices in one embodiment;
FIG. 6 is a diagram illustrating an internal structure of an electronic device in one embodiment.
Detailed Description
In order to make the objects, technical solutions and advantages of the present application more apparent, the present application is described in further detail below with reference to the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are merely illustrative of the present application and are not intended to limit the present application.
The electronic device pairing method provided by the application can be applied to the application environment shown in fig. 1. Referring to fig. 1, the electronic device pairing method is applied to an electronic device pairing system. The electronic device pairing system includes an electronic device 102 and a pairing gateway 104. Wherein application electronic device 102 communicates with pairing gateway 104 over a wireless network. The electronic device 102 refers to an electronic terminal, which may be, but is not limited to, various personal computers, notebook computers, smart phones, tablet computers, and portable wearable devices. More specifically, taking the electronic device pairing system as an answering system or a voting system as an example, the electronic device 102 may be an answerer, a voter, or the like in the answering system or the voting system. Pairing gateway 104 refers to a gateway device that is paired with electronic device 102. More specifically, it may be a base station in an answering system or a voting system, etc.
The electronic device 102 includes a memory, a processor, and a magnetic sensor coupled to the processor. The magnetic sensing element is used for generating a pairing trigger signal when approaching a magnetic object, and the pairing trigger signal is an electromagnetic induction signal; the memory stores a computer program that when executed by the processor implements the steps of the electronic device pairing method described below. Here, the steps of the electronic device pairing method may be steps in the electronic device pairing methods of the following embodiments.
Specifically, when the electronic device 102 is close to a magnetic object, or a magnetic sensor of the electronic device 102 is close to the magnetic object, the magnetic sensor generates an electromagnetic induction signal, which is used as a pairing trigger signal and transmitted to the processor, and the processor starts a pairing process when detecting the electromagnetic induction signal output by the magnetic sensor. The electromagnetic induction signal is an electric signal generated by the magnetic sensor element according to the magnetic signal. By using the magnetic sensing element to trigger pairing, batch electronic equipment can be rapidly triggered to be paired, and the complexity that each piece of electronic equipment needs to be subjected to key operation one by one to trigger pairing is avoided.
In one embodiment, as shown in fig. 2, an electronic device pairing method is provided, which is described by taking the method as an example applied to the electronic device in fig. 1, and includes the following steps:
s202, when the pairing trigger signal is detected, the frequency of the communication channel is switched to the pairing frequency, and the pairing trigger signal is an electromagnetic induction signal.
When the processor detects the electromagnetic induction signal output by the magnetic sensing element, the processor enters a pairing mode, and the frequency of the communication channel of the electronic equipment is switched to a pairing frequency, so that the communication channel between the electronic equipment and the pairing gateway based on the pairing frequency is established.
The pairing frequency refers to a frequency point of a communication channel between the electronic device and the pairing gateway when pairing is performed. The pairing frequency is a pre-configured universal fixed frequency point, and belongs to a fixed frequency band of a communication channel of the electronic equipment. Taking an answering system or a voting system as an example, a communication channel of the system usually adopts a wireless channel with a 2.4GHz frequency band, and then the pairing frequency can be configured to be a fixed frequency point in the 2.4GHz frequency band.
And S204, acquiring the working frequency of the paired gateway through a communication channel.
After the pairing mode is triggered to enter, the electronic device monitors a wireless instruction sent by the pairing gateway based on the pairing frequency of the communication channel, and obtains the working frequency of the pairing gateway according to the received wireless instruction.
The working frequency refers to a communication channel frequency point adopted when the electronic equipment communicates with the pairing gateway after the pairing is completed, and the working frequency also belongs to a fixed frequency band of the communication channel of the electronic equipment. Each pairing gateway has unique working frequency which is different from the pairing frequency, and different working frequencies are set for different pairing gateways, so that the electronic equipment can communicate with different pairing gateways based on different working frequencies, and the interference among signals is avoided. Taking the answering system or the voting system as an example, different base stations have different working frequencies, and the electronic device can communicate with the base station corresponding to the working frequency based on the different working frequencies, so that communication signals of the different base stations are not interfered with each other. In the system, the working frequency of the base station can be configured to be a fixed frequency point in the 2.4GHz frequency band, and the fixed frequency point is different from the pairing frequency.
In the present application, in the same electronic device pairing system, the pairing frequency and the operating frequency belong to the same frequency band. That is to say, in the same electronic device pairing system, both the electronic device and the pairing gateway adopt the communication channel of the same frequency band for communication when pairing or after the pairing is completed.
And S206, switching the frequency of the communication channel to the working frequency so as to communicate with the pairing gateway based on the working frequency.
Specifically, when the processor of the electronic device obtains an operating frequency of a paired gateway, the processor controls to switch the frequency of the communication channel to the operating frequency so as to establish the communication channel between the electronic device and the paired gateway corresponding to the operating frequency, and to communicate with the corresponding paired gateway based on the operating frequency. For example, the frequency of the communication channel is switched to the operating frequency of the base station, and the answering data or voting data is transmitted to the base station.
According to the electronic equipment pairing method, when the pairing trigger signal is detected, the frequency of the communication channel is switched to the pairing frequency, wherein the pairing trigger signal is an electromagnetic induction signal. When the pairing is triggered, the frequency of the communication channel is firstly switched to the general pairing frequency to receive the working frequency of the paired gateway, and the frequency of the communication channel is switched to the corresponding working frequency after the pairing signal is received, so that the current equipment and the paired gateway communicate with each other according to the specific working frequency, and the pairing between the current equipment and the paired gateway is realized. Namely, the pairing processing between the electronic devices can be quickly completed through the frequency switching of the communication channels, and a pairing communication device does not need to be additionally arranged, so that the cost of the electronic devices is reduced.
In one embodiment, the step of obtaining the operating frequency of the paired gateway through the communication channel includes: when a pairing signal carrying the working frequency is received through a communication channel, the pairing signal is analyzed to obtain the working frequency of the pairing gateway.
The pairing signal refers to configuration information issued by the pairing gateway. The configuration information includes, but is not limited to, an operating frequency of the paired gateway, and may further include, for example, a channel unique code, a pairing code, and the like. The pairing code is a verification code in communication data, and each pairing gateway has a unique pairing code corresponding to the pairing gateway and is used for judging the validity of the received data.
In this embodiment, it is determined whether data received through the communication channel is a pairing signal, and when the received data is the pairing signal, the pairing signal is analyzed, and the operating frequency of the pairing gateway is identified and obtained from the analyzed data. So as to perform frequency switching of the communication channel based on the obtained operating frequency.
In an embodiment, the data sent by the electronic device and the pairing gateway both include a pairing code, so as to verify the validity of the data. If the pairing code carried in the data is consistent with the pairing code of the electronic equipment, the data is legal, namely the data is sent to the pairing gateway, and then the data is further processed; if not, the received data is discarded. Similarly, the pairing gateway also carries a pairing code in the sent data, when the electronic equipment receives the data, whether the data is a pairing signal is judged, and if yes, processing related to the pairing signal is executed; if not, continuing to judge whether the pairing code carried in the data is consistent with the stored pairing code, if so, indicating that the data is legal, and further processing the data; if not, the received data is discarded.
In an embodiment, when the pairing trigger signal is detected, after the step of switching the frequency of the communication channel to the pairing frequency, the method further includes: acquiring the monitoring time consumption of monitoring the pairing signal; and when the monitoring time consumption reaches the preset monitoring time length, switching the frequency of the communication channel to the historical working frequency.
The monitoring time is the total time from the moment when the frequency of the communication channel is switched to the pairing frequency to the current moment when the pairing signal is not received. And the electronic equipment is always in a state of monitoring the pairing signal before the monitoring time reaches the preset time or the pairing signal is received.
Specifically, when the frequency of the communication channel is switched to the pairing frequency, the timing of the monitoring time is started, the monitoring time is obtained, whether the monitoring time reaches the preset monitoring duration is judged, and when the judgment result is yes, the frequency of the communication channel is switched to the historical working frequency. Wherein, the historical operating frequency refers to the operating frequency before switching to the pairing frequency. In addition, if the pairing signal is received, the time consumed for monitoring is terminated.
That is, after the pairing mode is triggered to enter, when the pairing signal is not received within the preset monitoring duration, the frequency of the communication channel is switched to the historical operating frequency, so that the electronic device continues to communicate with the pairing gateway corresponding to the historical operating frequency based on the historical operating frequency, and communication interruption with the historical pairing gateway due to false triggering pairing is avoided.
In an embodiment, after the step of acquiring the operating frequency of the paired gateway through the communication channel, the method further includes: generating pairing application information carrying equipment information; and sending the pairing application information to the pairing gateway, so that the pairing gateway acquires the equipment information according to the pairing application information.
The device information refers to information related to the electronic device itself. The device information includes, but is not limited to, a device identification, a user identification, and the like. The device identification may specifically be a device ID. The pairing application information is used for sending the equipment information to the pairing gateway record and/or verification so as to carry out pairing confirmation.
Specifically, the device information is acquired, the pairing application information is generated according to the device information, and the pairing application information is sent to the pairing gateway, so that the pairing gateway acquires the device information according to the pairing application information, and the pairing gateway records and counts the device information of the electronic device paired with the pairing gateway. Taking the voting system as an example, the voter sends its voter ID to the base station, and the base station records the voter ID after receiving the voter ID, for example, records the voter ID in a white list, so as to facilitate statistics and analysis of the voting result. Further, the base station can also send the device information to a main control end of the voting system, and the main control end records and counts.
The step of transmitting the pairing-application information may be performed before the step of switching the frequency of the communication channel to the operating frequency, or may be performed after the step of switching the frequency of the communication channel to the operating frequency. That is, the pairing application information may be transmitted based on the pairing frequency, or may be transmitted based on the operating frequency.
In one embodiment, the electronic device pairing method further includes: and receiving confirmation information fed back by the pairing gateway according to the pairing application information, wherein the confirmation information is used for confirming that the pairing is successful.
When the pairing gateway receives pairing application information sent by the electronic equipment, if equipment information recording and/or verification of the electronic equipment is completed, confirmation information is generated and sent to the electronic equipment through a communication channel established between the pairing gateway and the electronic equipment, and when the electronic equipment receives the confirmation information, the pairing is confirmed to be successful, and the pairing mode exits.
The step of receiving the confirmation information fed back by the pairing gateway according to the pairing application information, where the confirmation information is used to confirm that the pairing is successful, may be executed before the step of switching the frequency of the communication channel to the operating frequency, or may be executed after the step of switching the frequency of the communication channel to the operating frequency.
In an embodiment, after the step of sending the pairing application information to the pairing gateway, the method further includes: acquiring the time consumed by the pairing application; and when the time consumed by the pairing application reaches the preset application time length, switching the frequency of the communication channel to the historical working frequency.
The time consumed by the pairing application refers to the total time from the moment when the pairing application information is sent to the pairing gateway to the current moment when the confirmation information is not received.
Specifically, when the pairing application information is sent to the pairing gateway, timing of pairing application time consumption is started, the pairing application time consumption is obtained, whether the pairing application time consumption reaches a preset application time length or not is judged, and when the judgment result is yes, the frequency of the communication channel is switched to the historical working frequency. In addition, if the confirmation information is received, the time consumed for the pairing application is terminated.
That is, after the pairing application information is sent, when the corresponding confirmation information is not received within the preset application duration, it indicates that the pairing gateway does not perform pairing confirmation, and at this time, the frequency of the communication channel is switched to the historical operating frequency, so that the electronic device continues to communicate with the pairing gateway corresponding to the historical operating frequency based on the historical operating frequency, and communication interruption with the historical pairing gateway due to pairing errors is avoided.
In one embodiment, as shown in fig. 3, the electronic device pairing method includes the following steps:
s301, when a pairing trigger signal is detected, switching the frequency of the communication channel to a pairing frequency, wherein the pairing trigger signal is an electromagnetic induction signal.
S302, monitoring a pairing signal.
S303, judging whether a pairing signal carrying the working frequency is received. If yes, go to step S307; otherwise, step S304 is performed.
S304, acquiring the monitoring time consumption of the monitoring pairing signal.
S305, judging that the monitoring time reaches the preset monitoring time. If yes, go to step S306; otherwise, return to step S302.
S306, switching the frequency of the communication channel to the historical working frequency. And ends the pairing.
And S307, analyzing the pairing signal to obtain the working frequency of the pairing gateway.
And S308, switching the frequency of the communication channel to the working frequency so as to communicate with the pairing gateway based on the working frequency.
S309, generating pairing application information carrying the equipment information.
And S310, sending the pairing application information to the pairing gateway, so that the pairing gateway acquires the equipment information according to the pairing application information.
And S311, judging whether confirmation information fed back by the pairing gateway according to the pairing application information is received. If yes, finishing pairing; otherwise, step S312 is executed.
And S312, acquiring the pairing application time.
And S313, judging whether the pairing application time consumption reaches a preset application time length. If yes, go to step S306; otherwise, step S311 is performed.
According to the electronic equipment pairing method, the magnetic sensing elements are used for triggering pairing, batch electronic equipment can be rapidly triggered to be paired, and the complexity that each piece of electronic equipment needs to be subjected to key operation one by one to trigger pairing is avoided. And the communication channels of the same frequency band are adopted in pairing and subsequent data transmission, and only the frequency switching of the communication channels is needed to distinguish the data transmission during and after pairing, so that the pairing processing between the electronic equipment and the pairing gateway is quickly completed, and no additional pairing communication device is needed, thereby reducing the cost of the electronic equipment.
The following further describes the pairing method of the electronic devices by taking the voting system as an example. The voting system comprises a main control end, a base station and a plurality of voters which need to be paired with the base station and comprise magnetic sensing elements. As shown in fig. 4, in the voting system, the following steps of the electronic device pairing method are specifically executed:
the main control end sends a pairing instruction to the base station, the base station enters a pairing mode after receiving the pairing instruction, and a pairing signal is sent at regular time based on the pairing frequency. In this embodiment, the pairing signal at least includes an operating frequency and a pairing code. The timing interval may be set as required, for example, the timing interval may be set to 200ms, and the base station transmits the pairing signal once every 200 ms.
When the voter is close to a magnetic substance, a magnetic sensing element in the voter generates an electromagnetic induction signal and outputs the electromagnetic induction signal to a processor in the voter, when the processor detects the electromagnetic induction signal, the frequency of a communication channel of the voter is switched to a pairing frequency, when the pairing signal carrying the working frequency is received through the communication channel, the pairing signal is analyzed to obtain the working frequency and a pairing code of a base station, the frequency of the communication channel is switched to the working frequency, the pairing code is stored at the same time, then pairing application information carrying the voter ID and the pairing code is generated, and the pairing application information is sent to the base station.
And the base station receives the pairing application information, judges whether the pairing code in the pairing application information is consistent with the pairing code of the base station, acquires the voter ID in the pairing application information if the pairing code in the pairing application information is consistent with the pairing code of the base station, adds the voter ID into a white list, and sends the voter ID to the main control end for recording. Meanwhile, the base station generates confirmation information and sends the confirmation information to the voter corresponding to the pairing application information. When the voter receives the confirmation information transmitted by the base station, the pairing is finished (the pairing mode is exited).
According to the electronic equipment pairing method, the magnetic sensitive elements in the voters trigger pairing, the batched voters can be rapidly triggered to be paired, and the complexity that key operation needs to be performed on each voter one by one to trigger pairing is avoided. And the communication channels of the same frequency band are adopted in pairing and subsequent voting data transmission, and the data transmission during pairing and after pairing is distinguished only by switching the frequency of the communication channels, so that the pairing processing between the voter and the base station is quickly completed, a pairing communication device does not need to be additionally added in the voter, and the cost of the electronic equipment is further reduced.
It should be understood that although the various steps in the flow charts of fig. 2-4 are shown in order as indicated by the arrows, the steps are not necessarily performed in order as indicated by the arrows. The steps are not performed in the exact order shown and described, and may be performed in other orders, unless explicitly stated otherwise. Moreover, at least some of the steps in fig. 2-4 may include multiple sub-steps or multiple stages that are not necessarily performed at the same time, but may be performed at different times, and the order of performance of the sub-steps or stages is not necessarily sequential, but may be performed in turn or alternating with other steps or at least some of the sub-steps or stages of other steps.
In one embodiment, as shown in fig. 5, there is provided an electronic device pairing apparatus including: a pairing triggering module 502, an operating frequency acquisition module 504, and a frequency switching module 506, wherein:
the pairing triggering module 502 is configured to switch a frequency of the communication channel to a pairing frequency when a pairing triggering signal is detected, where the pairing triggering signal is an electromagnetic induction signal.
Specifically, when the pairing triggering module 502 detects an electromagnetic induction signal output by the magnetic sensing element, the pairing mode is entered, and the frequency of the communication channel of the electronic device is switched to the pairing frequency, so as to establish the communication channel between the electronic device and the pairing gateway based on the pairing frequency.
An operating frequency obtaining module 504, configured to obtain an operating frequency of the paired gateway through a communication channel. After the pairing mode is triggered, the working frequency obtaining module 504 monitors a wireless instruction sent by the paired gateway based on the pairing frequency of the communication channel, and obtains the working frequency of the paired gateway according to the received wireless instruction.
A frequency switching module 506, configured to switch a frequency of the communication channel to an operating frequency for communicating with the partner gateway based on the operating frequency.
Specifically, when the operating frequency obtaining module 504 obtains the operating frequency of the paired gateway, the frequency switching module 506 controls to switch the frequency of the communication channel to the operating frequency, so as to establish the communication channel between the electronic device and the paired gateway corresponding to the operating frequency, and communicate with the corresponding paired gateway based on the operating frequency. For example, the frequency of the communication channel is switched to the operating frequency of the base station, and the answering data or voting data is transmitted to the base station.
When the electronic equipment pairing device is triggered to pair through the electromagnetic induction signal, the frequency of the communication channel is firstly switched to the general pairing frequency to receive the working frequency of the pairing gateway, and the frequency of the communication channel is switched to the corresponding working frequency after the pairing signal is received, so that the current equipment and the pairing gateway communicate with each other according to the specific working frequency, and the pairing between the current equipment and the pairing gateway is realized. Namely, the pairing processing between the electronic equipment and the pairing gateway can be quickly completed through the frequency switching of the communication channel, and a pairing communication device does not need to be additionally arranged, so that the cost of the electronic equipment is reduced.
In an embodiment, the electronic device pairing apparatus further includes a signal determining module, configured to determine whether data received through the communication channel is a pairing signal. Further, the working frequency obtaining module 504 is configured to, when a pairing signal carrying the working frequency is received through a communication channel, analyze the pairing signal to obtain the working frequency of the pairing gateway.
The pairing signal refers to configuration information issued by the pairing gateway. The configuration information includes, but is not limited to, an operating frequency of the paired gateway, and may further include, for example, a channel unique code, a pairing code, and the like. The pairing code is a verification code in communication data, and each pairing gateway has a unique pairing code corresponding to the pairing gateway and is used for judging the validity of the received data.
In this embodiment, the signal determining module determines whether the received data is a pairing signal, and when the received data is the pairing signal, the operating frequency obtaining module 504 analyzes the pairing signal, and identifies the operating frequency of the pairing gateway from the analyzed data. So as to perform frequency switching of the communication channel based on the obtained operating frequency.
In an embodiment, the electronic device pairing apparatus further includes a listening time-consuming processing module. And the monitoring time consumption processing module is used for acquiring the monitoring time consumption of the monitoring pairing signal. Specifically, when the frequency of the communication channel is switched to the pairing frequency, the monitoring time consumption processing module starts timing of the monitoring time consumption to obtain the monitoring time consumption.
In addition, the monitoring time-consuming processing module is further configured to determine whether the monitoring time-consuming reaches a preset monitoring duration, and terminate timing of the monitoring time-consuming when the pairing signal is received.
In this embodiment, the frequency switching module 506 is further configured to switch the frequency of the communication channel to the historical operating frequency when the determination result of the monitoring time-consuming processing module is yes. Wherein, the historical operating frequency refers to the operating frequency before switching to the pairing frequency.
That is, after the pairing mode is triggered to enter, when the pairing signal is not received within the preset monitoring duration, the frequency of the communication channel is switched to the historical operating frequency, so that the electronic device continues to communicate with the pairing gateway corresponding to the historical operating frequency based on the historical operating frequency, and communication interruption with the historical pairing gateway due to false triggering pairing is avoided.
In an embodiment, the electronic device pairing apparatus further includes a pairing application generating module and a pairing application sending module. The device comprises a pairing application generation module, a pairing application generation module and a matching application information generation module, wherein the pairing application generation module is used for generating pairing application information carrying equipment information; and the pairing application sending module is used for sending the pairing application information to the pairing gateway so that the pairing gateway can acquire the equipment information according to the pairing application information.
Specifically, the pairing application generating module acquires the device information, generates the pairing application information according to the device information, and sends the pairing application information to the pairing gateway through the pairing application sending module, so that the pairing gateway acquires the device information according to the pairing application information, and the pairing gateway records and counts the device information of the electronic device paired with the pairing gateway.
In an embodiment, the electronic device pairing apparatus further includes a confirmation information processing module, configured to receive confirmation information fed back by the pairing gateway according to the pairing application information, where the confirmation information is used to confirm that pairing is successful.
In an embodiment, the confirmation information processing module is further configured to, when receiving the confirmation information, confirm that the pairing is successful, and exit the pairing mode.
Further, the electronic device pairing apparatus further includes a pairing application time-consuming processing module. And the pairing application time-consuming processing module is used for acquiring pairing application time. Specifically, when the pairing application information is sent to the pairing gateway, the pairing application time-consuming processing module starts timing of pairing application time-consuming, and acquires the pairing application time-consuming.
In addition, the pairing application time-consuming processing module is further used for judging whether the pairing application time-consuming reaches a preset application time length or not, and terminating the timing of the pairing application time-consuming when receiving the received confirmation information.
In this embodiment, the frequency switching module 506 is further configured to switch the frequency of the communication channel to the historical operating frequency when the determination result of the pairing application time-consuming processing module is yes.
That is, after the pairing application information is sent, when the corresponding confirmation information is not received within the preset application duration, it indicates that the pairing gateway does not perform pairing confirmation, and at this time, the frequency of the communication channel is switched to the historical operating frequency, so that the electronic device continues to communicate with the pairing gateway corresponding to the historical operating frequency based on the historical operating frequency, and communication interruption with the historical pairing gateway due to pairing errors is avoided.
According to the electronic equipment pairing device, the magnetic sensing elements are used for triggering pairing, batch electronic equipment can be rapidly triggered to be paired, and the trouble that each piece of electronic equipment needs to be subjected to key operation one by one to trigger pairing is avoided. And the communication channels of the same frequency band are adopted in pairing and subsequent data transmission, and only the frequency switching of the communication channels is needed to distinguish the data transmission during and after pairing, so that the pairing processing between the electronic equipment and the pairing gateway is quickly completed, and no additional pairing communication device is needed, thereby reducing the cost of the electronic equipment.
For specific definition of the electronic device pairing apparatus, the above definition of the electronic device pairing method may be referred to, and details are not repeated here. The respective modules in the electronic device pairing apparatus may be wholly or partially implemented by software, hardware, and a combination thereof. The modules can be embedded in a hardware form or independent of a processor in the electronic device, or can be stored in a memory in the electronic device in a software form, so that the processor can call and execute operations corresponding to the modules.
In one embodiment, an electronic device is provided, which may be an electronic terminal, and its internal structure diagram may be as shown in fig. 6. The electronic device comprises a processor, a memory, a network interface, a display screen and an input device which are connected through a system bus. Wherein the processor of the electronic device is configured to provide computing and control capabilities. The memory of the electronic equipment comprises a nonvolatile storage medium and an internal memory. The non-volatile storage medium stores an operating system and a computer program. The internal memory provides an environment for the operation of an operating system and computer programs in the non-volatile storage medium. The network interface of the electronic device is used for connecting and communicating with an external terminal through a network. The computer program is executed by a processor to implement an electronic device pairing method. The display screen of the electronic equipment can be a liquid crystal display screen or an electronic ink display screen, and the input device of the electronic equipment can be a touch layer covered on the display screen, a key, a track ball or a touch pad arranged on the shell of the electronic equipment, an external keyboard, a touch pad or a mouse and the like.
Those skilled in the art will appreciate that the configuration shown in fig. 6 is a block diagram of only a portion of the configuration associated with the present application, and does not constitute a limitation on the electronic device to which the present application is applied, and a particular electronic device may include more or less components than those shown in the drawings, or may combine certain components, or have a different arrangement of components.
In one embodiment, a computer-readable storage medium is provided, on which a computer program is stored, which, when being executed by a processor, carries out the steps of the above-mentioned electronic device pairing method. Here, the steps of the electronic device pairing method may be steps in the electronic device pairing methods of the above embodiments.
It will be understood by those skilled in the art that all or part of the processes of the methods of the embodiments described above can be implemented by hardware related to instructions of a computer program, which can be stored in a non-volatile computer-readable storage medium, and when executed, can include the processes of the embodiments of the methods described above. Any reference to memory, storage, database, or other medium used in the embodiments provided herein may include non-volatile and/or volatile memory, among others. Non-volatile memory can include read-only memory (ROM), Programmable ROM (PROM), Electrically Programmable ROM (EPROM), Electrically Erasable Programmable ROM (EEPROM), or flash memory. Volatile memory can include Random Access Memory (RAM) or external cache memory. By way of illustration and not limitation, RAM is available in a variety of forms such as Static RAM (SRAM), Dynamic RAM (DRAM), Synchronous DRAM (SDRAM), Double Data Rate SDRAM (DDRSDRAM), Enhanced SDRAM (ESDRAM), Synchronous Link DRAM (SLDRAM), Rambus Direct RAM (RDRAM), direct bus dynamic RAM (DRDRAM), and memory bus dynamic RAM (RDRAM).
The technical features of the above embodiments can be arbitrarily combined, and for the sake of brevity, all possible combinations of the technical features in the above embodiments are not described, but should be considered as the scope of the present specification as long as there is no contradiction between the combinations of the technical features.
The above examples only express several embodiments of the present application, and the description thereof is more specific and detailed, but not construed as limiting the scope of the invention. It should be noted that, for a person skilled in the art, several variations and modifications can be made without departing from the concept of the present application, which falls within the scope of protection of the present application. Therefore, the protection scope of the present patent shall be subject to the appended claims.

Claims (10)

1. An electronic device pairing method is applied to an electronic device, and is characterized by comprising the following steps:
when a pairing trigger signal is detected, switching the frequency of a communication channel to a pairing frequency, wherein the pairing trigger signal is an electromagnetic induction signal;
acquiring a working frequency of a paired gateway through the communication channel, wherein the paired gateway has the only corresponding working frequency, the working frequency is different from the paired frequency, the paired frequency and the working frequency belong to the same frequency band, and the communication channel adopts the same frequency band for communication;
switching a frequency of the communication channel to the operating frequency to communicate with the companion gateway based on the operating frequency;
the electronic equipment is an answering machine or a voting machine, and the pairing gateway is a base station.
2. The method of claim 1, wherein obtaining the operating frequency of the paired gateway through the communication channel comprises:
and when receiving a pairing signal carrying the working frequency through the communication channel, analyzing the pairing signal to obtain the working frequency of the pairing gateway.
3. The method of claim 2, wherein after switching the frequency of the communication channel to the pairing frequency when the pairing trigger signal is detected, further comprising:
acquiring the monitoring time consumption of monitoring the pairing signal;
and when the monitoring time consumption reaches a preset monitoring time length, switching the frequency of the communication channel to a historical working frequency.
4. The method of claim 1, wherein after obtaining the operating frequency of the paired gateway through the communication channel, the method further comprises:
generating pairing application information carrying equipment information;
and sending the pairing application information to the pairing gateway, so that the pairing gateway acquires the equipment information according to the pairing application information.
5. The method of claim 4, further comprising:
and receiving confirmation information fed back by the pairing gateway according to the pairing application information, wherein the confirmation information is used for confirming that pairing is successful.
6. The method of claim 4, wherein after sending the pairing request message to the pairing gateway, further comprising:
acquiring the time consumed by the pairing application;
and when the pairing application time consumption reaches a preset application time length, switching the frequency of the communication channel to a historical working frequency.
7. An electronic device pairing apparatus applied to an electronic device, the apparatus comprising:
the pairing triggering module is used for switching the frequency of a communication channel to pairing frequency when a pairing triggering signal is detected, wherein the pairing triggering signal is an electromagnetic induction signal;
a working frequency obtaining module, configured to obtain a working frequency of a paired gateway through the communication channel, where the paired gateway has the only corresponding working frequency, the working frequency is different from the paired frequency, the paired frequency and the working frequency belong to the same frequency band, and the communication channel communicates using the same frequency band;
a frequency switching module, configured to switch a frequency of the communication channel to the operating frequency, so as to communicate with the pairing gateway based on the operating frequency;
the electronic equipment is an answering machine or a voting machine, and the pairing gateway is a base station.
8. The apparatus of claim 7, further comprising:
the pairing application generating module is used for generating pairing application information carrying equipment information;
and the pairing application sending module is used for sending the pairing application information to the pairing gateway so that the pairing gateway obtains the equipment information according to the pairing application information.
9. An electronic device, characterized in that the electronic device comprises: the magnetic sensor comprises a memory, a processor and a magnetic sensing element connected with the processor;
the magnetic sensing element is used for generating a pairing trigger signal when approaching a magnetic object, and the pairing trigger signal is an electromagnetic induction signal;
the memory stores a computer program which, when executed by the processor, implements the steps of the method of any one of claims 1 to 6.
10. A readable storage medium, on which a computer program is stored, which, when being executed by a processor, carries out the steps of the method of any one of claims 1 to 6.
CN201811175874.5A 2018-10-10 2018-10-10 Electronic equipment pairing method and device, electronic equipment and storage medium Active CN109274445B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201811175874.5A CN109274445B (en) 2018-10-10 2018-10-10 Electronic equipment pairing method and device, electronic equipment and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201811175874.5A CN109274445B (en) 2018-10-10 2018-10-10 Electronic equipment pairing method and device, electronic equipment and storage medium

Publications (2)

Publication Number Publication Date
CN109274445A CN109274445A (en) 2019-01-25
CN109274445B true CN109274445B (en) 2021-09-24

Family

ID=65195417

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201811175874.5A Active CN109274445B (en) 2018-10-10 2018-10-10 Electronic equipment pairing method and device, electronic equipment and storage medium

Country Status (1)

Country Link
CN (1) CN109274445B (en)

Families Citing this family (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111897394B (en) * 2020-06-28 2022-08-05 北京凌宇智控科技有限公司 Equipment pairing method, equipment pairing device and equipment pairing system
CN113596805A (en) * 2021-06-11 2021-11-02 珠海派诺科技股份有限公司 Wireless communication pairing method, device and medium
CN113423084B (en) * 2021-06-22 2022-02-22 欧梯恩智能科技(苏州)有限公司 LoRa gateway and equipment pairing arrangement method and application in bridge pier impact detection
CN114185313A (en) * 2021-11-12 2022-03-15 北京天玛智控科技股份有限公司 Sensor data acquisition method and device suitable for underground

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1362795A (en) * 2000-12-27 2002-08-07 株式会社东芝 Method and apparatus for executing radio communication using spread spectrum-frequency hopping
CN104410435A (en) * 2014-05-07 2015-03-11 丰唐物联技术(深圳)有限公司 Method for triggering networking, node and gateway
CN104506333A (en) * 2014-12-31 2015-04-08 深圳市明微电子股份有限公司 Control method based on radio frequency communication
CN104885404A (en) * 2012-11-12 2015-09-02 奥林奇公司 Method of mutual authentication between a radio tag and a reader

Family Cites Families (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US9674744B2 (en) * 2015-09-17 2017-06-06 Qualcomm Incorporated Techniques for wireless communication channel management in shared frequency bands

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1362795A (en) * 2000-12-27 2002-08-07 株式会社东芝 Method and apparatus for executing radio communication using spread spectrum-frequency hopping
CN104885404A (en) * 2012-11-12 2015-09-02 奥林奇公司 Method of mutual authentication between a radio tag and a reader
CN104410435A (en) * 2014-05-07 2015-03-11 丰唐物联技术(深圳)有限公司 Method for triggering networking, node and gateway
CN104506333A (en) * 2014-12-31 2015-04-08 深圳市明微电子股份有限公司 Control method based on radio frequency communication

Also Published As

Publication number Publication date
CN109274445A (en) 2019-01-25

Similar Documents

Publication Publication Date Title
CN109274445B (en) Electronic equipment pairing method and device, electronic equipment and storage medium
CN108024011B (en) Method for establishing wireless connection by vibration, electronic device, and recording medium
US9794253B2 (en) Device security utilizing continually changing QR codes
US9155026B2 (en) Systems for facilitating wireless communication and related methods
CN110677533B (en) Mobile terminal control method and device, mobile terminal and storage medium
CN104636924B (en) Secure payment method, server and system
US9800714B2 (en) Control method, information processing device, and storage medium
CA3053278A1 (en) Control system and method
CN114039734B (en) Device resetting method and device
CN109872143B (en) Payment information binding method, device, mobile terminal and system
CN104704447A (en) Using Bluetooth low energy
WO2021077828A1 (en) Near field communication authentication initiating method and related apparatus
CN110636590B (en) Hotspot list generation method and device, computer equipment and storage medium
CN110495195B (en) Random access method, device and storage medium
CN112911560A (en) Electronic business card transmission method and device
CN104485982A (en) Intelligent accessory-based NFC (near field communication) method and system
JP5195496B2 (en) Authentication target device and key, and wireless authentication system
CN112954660A (en) Bluetooth matching method and device, mobile terminal, Bluetooth equipment and communication system
EP3062475B1 (en) Communication device, communication method, and communication system
CN111586074A (en) Communication method, server, Internet of things system and readable storage medium
CN112583920A (en) Pushing method, pushing device, electronic equipment and storage medium
CN111194070B (en) Wireless network processing and access method, device, system, storage medium and equipment
EP2202675A1 (en) Reader/writer and authentication system using the reader/writer
JP6701314B2 (en) Portable device, control method thereof, and program
CN112423405B (en) Communication method and device, electronic equipment and computer readable storage medium

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant