CN112383903B - Bluetooth code matching control method and device and computer storage medium - Google Patents

Bluetooth code matching control method and device and computer storage medium Download PDF

Info

Publication number
CN112383903B
CN112383903B CN202011028949.4A CN202011028949A CN112383903B CN 112383903 B CN112383903 B CN 112383903B CN 202011028949 A CN202011028949 A CN 202011028949A CN 112383903 B CN112383903 B CN 112383903B
Authority
CN
China
Prior art keywords
bluetooth
code
slave control
intelligent master
equipment
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
CN202011028949.4A
Other languages
Chinese (zh)
Other versions
CN112383903A (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.)
Shenzhen TCL New Technology Co Ltd
Original Assignee
Shenzhen TCL New Technology 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 Shenzhen TCL New Technology Co Ltd filed Critical Shenzhen TCL New Technology Co Ltd
Priority to CN202011028949.4A priority Critical patent/CN112383903B/en
Publication of CN112383903A publication Critical patent/CN112383903A/en
Application granted granted Critical
Publication of CN112383903B publication Critical patent/CN112383903B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04WWIRELESS COMMUNICATION NETWORKS
    • H04W4/00Services specially adapted for wireless communication networks; Facilities therefor
    • H04W4/80Services using short range communication, e.g. near-field communication [NFC], radio-frequency identification [RFID] or low energy communication
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04WWIRELESS COMMUNICATION NETWORKS
    • H04W76/00Connection management
    • H04W76/10Connection setup
    • H04W76/14Direct-mode setup
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04WWIRELESS COMMUNICATION NETWORKS
    • H04W8/00Network data management
    • H04W8/005Discovery of network devices, e.g. terminals
    • YGENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
    • Y02TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
    • Y02DCLIMATE CHANGE MITIGATION TECHNOLOGIES IN INFORMATION AND COMMUNICATION TECHNOLOGIES [ICT], I.E. INFORMATION AND COMMUNICATION TECHNOLOGIES AIMING AT THE REDUCTION OF THEIR OWN ENERGY USE
    • Y02D30/00Reducing energy consumption in communication networks
    • Y02D30/70Reducing energy consumption in communication networks in wireless communication networks

Abstract

The invention discloses a Bluetooth code matching control method, a device and a computer storage medium, wherein the method comprises the following steps: when the Hall switch is detected to be in a closed state, the slave control equipment is controlled to enter a Bluetooth code matching mode; and if the Bluetooth communication code transmitted by the intelligent master device is captured, controlling the slave control device to establish connection with the intelligent master device. Therefore, intelligent one-to-one Bluetooth code matching is realized through the Hall switch of the slave control equipment, and the Bluetooth code matching accuracy of the slave control equipment is improved.

Description

Bluetooth code matching control method and device and computer storage medium
Technical Field
The present invention relates to the field of bluetooth pairing technologies, and in particular, to a bluetooth pairing code control method, device and computer storage medium.
Background
When the slave control device is in Bluetooth remote control, when the slave control device is used for controlling the intelligent master device (such as a television and the like), the slave control device firstly needs to be in Bluetooth pairing with the intelligent master device to control the intelligent master device, and the process of pairing the slave control device and the intelligent master device is called as 'slave control device code matching', when the slave control device code matching is carried out, the infrared code matching request and the infrared code matching information are transmitted through infrared, but the infrared remote control is characterized in that one slave control device can simultaneously remotely control a plurality of intelligent master devices, and the plurality of intelligent master devices can respond to the infrared code matching request after simultaneously receiving the infrared code matching request, so that the task currently executed by the intelligent master device is interrupted, namely the response is considered as misoperation of the slave control device.
Disclosure of Invention
The invention provides a Bluetooth code matching control method, a Bluetooth code matching control device and a computer storage medium, which aim to realize intelligent one-to-one Bluetooth code matching and improve the Bluetooth code matching precision of slave control equipment.
To achieve the above object, the present invention provides a bluetooth pairing code control method applied to a slave control apparatus configured with a pair of code devices, wherein the code devices include hall switches, the method comprising:
when the Hall switch is detected to be in a closed state, the slave control equipment is controlled to enter a Bluetooth code matching mode;
and if the Bluetooth communication code transmitted by the intelligent master device is captured, controlling the slave control device to establish connection with the intelligent master device.
Preferably, the step of establishing connection with the intelligent master device if the bluetooth communication code transmitted by the intelligent master device is captured includes:
if the Bluetooth communication code transmitted by the intelligent main equipment is captured, generating first response confirmation information corresponding to the Bluetooth communication code;
and controlling the slave control equipment to establish connection with the intelligent master equipment according to the Bluetooth communication code and the first response confirmation information.
Preferably, the step of controlling the slave control device to establish connection with the intelligent master device according to the bluetooth communication code and the first response confirmation information includes:
transmitting the Bluetooth communication code and the first response confirmation information, and judging whether second response confirmation information transmitted by the intelligent master equipment is captured or not;
and if the second response confirmation information transmitted by the intelligent master equipment is captured, judging that the Bluetooth code matching between the slave control equipment and the intelligent master equipment is successful, and controlling the slave control equipment to establish connection with the intelligent master equipment.
Preferably, before the step of establishing connection with the intelligent master device if the bluetooth communication code transmitted by the intelligent master device is captured, the method further includes:
and transmitting an infrared communication code to enable the intelligent master device to transmit a Bluetooth communication code according to the infrared communication code.
In addition, to achieve the above object, the present invention further provides a bluetooth pairing control method, where the bluetooth pairing control method is applied to an intelligent master device, and the intelligent master device is configured with a pair of coders, where the pair of coders includes:
when the Hall switch is detected to be in a closed state, controlling the intelligent main equipment to enter a Bluetooth code matching mode;
transmitting a Bluetooth communication code to establish connection with the slave control device according to the Bluetooth communication code.
Preferably, the step of transmitting a bluetooth communication code to establish a connection with the slave control device according to the bluetooth communication code:
transmitting a Bluetooth communication code, and judging whether the third response confirmation information transmitted from the control equipment is captured or not;
and if the third response confirmation information transmitted by the slave control equipment is captured, controlling the slave control equipment to establish connection with the intelligent master equipment according to the third response confirmation information.
Preferably, the step of controlling the slave control device to establish a connection with the intelligent master device according to the third acknowledgement information includes:
generating fourth response confirmation information corresponding to the third response confirmation information;
and transmitting the fourth response confirmation information to enable the slave control equipment to establish connection with the intelligent master equipment according to the fourth response confirmation information.
Preferably, after the step of transmitting the bluetooth communication code to establish a connection with the slave control device according to the bluetooth communication code, the method further includes:
if the Bluetooth signal transmitted from the control device is captured, converting the Bluetooth signal into an electrical signal;
and decoding the electric signal to obtain a control instruction corresponding to the electric signal, and responding to the control instruction.
In addition, in order to achieve the above object, the present invention also provides a bluetooth pairing code control device, which is characterized in that the bluetooth pairing code control device includes:
the control module is used for controlling the intelligent main equipment to enter a Bluetooth code matching mode when the Hall switch is detected to be in a closed state;
and the connection module is used for controlling the slave control equipment to establish connection with the intelligent master equipment if the Bluetooth communication code transmitted by the intelligent master equipment is captured.
In addition, in order to achieve the above object, the present invention also provides a computer storage medium having stored thereon a bluetooth pairing control program which, when executed by a processor, implements the steps of the bluetooth pairing control method as described above.
Compared with the prior art, the invention discloses a Bluetooth code matching control method, a Bluetooth code matching control device and a computer storage medium, wherein when the Hall switch is detected to be in a closed state, the slave control equipment is controlled to enter a Bluetooth code matching mode; if the Bluetooth communication code transmitted by the intelligent master equipment is captured, the slave control equipment is controlled to establish connection with the intelligent master equipment, so that intelligent one-to-one Bluetooth code matching is realized through a Hall switch of the slave control equipment, and the Bluetooth code matching accuracy of the slave control equipment is improved.
Drawings
Fig. 1 is a schematic hardware structure of a bluetooth pairing code control device according to various embodiments of the present invention;
fig. 2 is a flowchart of a first embodiment of the bluetooth pair code control method according to the present invention;
fig. 3 is a flowchart of a second embodiment of the bluetooth pair code control method according to the present invention;
fig. 4 is a schematic functional block diagram of a first embodiment of the bluetooth pairing control device according to the invention.
The achievement of the objects, functional features and advantages of the present invention will be further described with reference to the accompanying drawings, in conjunction with the embodiments.
Detailed Description
It should be understood that the specific embodiments described herein are for purposes of illustration only and are not intended to limit the scope of the invention.
The Bluetooth code matching control device mainly related to the embodiment of the invention refers to network connection equipment capable of realizing network connection, and the Bluetooth code matching control device can be a server, a cloud platform and the like.
Referring to fig. 1, fig. 1 is a schematic hardware configuration of a bluetooth pairing code control device according to various embodiments of the invention. In an embodiment of the present invention, the bluetooth pairing control device may include a processor 1001 (e.g. a central processing unit Central Processing Unit, a CPU), a communication bus 1002, an input port 1003, an output port 1004, and a memory 1005. Wherein the communication bus 1002 is used to enable connected communications between these components; the input port 1003 is used for data input; the output port 1004 is used for data output, and the memory 1005 may be a high-speed RAM memory or a stable memory (non-volatile memory), such as a disk memory, and the memory 1005 may be an optional storage device independent of the processor 1001. Those skilled in the art will appreciate that the hardware configuration shown in fig. 1 is not limiting of the invention and may include more or fewer components than shown, or may combine certain components, or a different arrangement of components.
With continued reference to fig. 1, the memory 1005 of fig. 1, which is a readable storage medium, may include an operating system, a network communication module, an application module, and a bluetooth pairing control program. In fig. 1, the network communication module is mainly used for connecting with a server and performing data communication with the server; and the processor 1001 may call the bluetooth pairing control program stored in the memory 1005 and perform the following operations:
when the Hall switch is detected to be in a closed state, the slave control equipment is controlled to enter a Bluetooth code matching mode;
and if the Bluetooth communication code transmitted by the intelligent master device is captured, controlling the slave control device to establish connection with the intelligent master device.
Further, the processor 1001 may be further configured to invoke the bluetooth pairing control program stored in the memory 1005, and perform the following steps:
if the Bluetooth communication code transmitted by the intelligent main equipment is captured, generating first response confirmation information corresponding to the Bluetooth communication code;
and controlling the slave control equipment to establish connection with the intelligent master equipment according to the Bluetooth communication code and the first response confirmation information.
Further, the processor 1001 may be further configured to invoke the bluetooth pairing control program stored in the memory 1005, and perform the following steps:
transmitting the Bluetooth communication code and the first response confirmation information, and judging whether second response confirmation information transmitted by the intelligent master equipment is captured or not;
and if the second response confirmation information transmitted by the intelligent master equipment is captured, judging that the Bluetooth code matching between the slave control equipment and the intelligent master equipment is successful, and controlling the slave control equipment to establish connection with the intelligent master equipment.
Further, the processor 1001 may be further configured to invoke the bluetooth pairing control program stored in the memory 1005, and perform the following steps:
and transmitting an infrared communication code to enable the intelligent master device to transmit a Bluetooth communication code according to the infrared communication code.
Further, the processor 1001 may be further configured to invoke the bluetooth pairing control program stored in the memory 1005, and perform the following steps:
when the Hall switch is detected to be in a closed state, controlling the intelligent main equipment to enter a Bluetooth code matching mode;
transmitting a Bluetooth communication code to establish connection with the slave control device according to the Bluetooth communication code.
Further, the processor 1001 may be further configured to invoke the bluetooth pairing control program stored in the memory 1005, and perform the following steps:
transmitting a Bluetooth communication code, and judging whether the third response confirmation information transmitted from the control equipment is captured or not;
and if the third response confirmation information transmitted by the slave control equipment is captured, controlling the slave control equipment to establish connection with the intelligent master equipment according to the third response confirmation information.
Further, the processor 1001 may be further configured to invoke the bluetooth pairing control program stored in the memory 1005, and perform the following steps:
generating fourth response confirmation information corresponding to the third response confirmation information;
and transmitting the fourth response confirmation information to enable the slave control equipment to establish connection with the intelligent master equipment according to the fourth response confirmation information.
Further, the processor 1001 may be further configured to invoke the bluetooth pairing control program stored in the memory 1005, and perform the following steps:
if the Bluetooth signal transmitted from the control device is captured, converting the Bluetooth signal into an electrical signal;
and decoding the electric signal to obtain a control instruction corresponding to the electric signal, and responding to the control instruction.
Based on the above structure, a first embodiment of the bluetooth pair code control method of the present invention is presented.
Referring to fig. 2, fig. 2 is a flowchart of a first embodiment of the bluetooth pair code control method according to the present invention.
In this embodiment, the bluetooth code matching control method is applied to an intelligent device for sending an action instruction, including an intelligent bluetooth remote controller and an intelligent infrared remote controller, where the intelligent device is optionally provided with a pair of coders, where the coders include a hall switch and a magnet separated from the hall switch by a separation wall, where it is required to specify that the separation wall is a material capable of implementing magnetostatic shielding, such as a copper plate, an aluminum plate, a superconducting material, a ferromagnetic material with high permeability, and the like, and the specific material type is not limited, and optionally, in this embodiment, the hall switch in the slave control device is separated from the magnet in the slave control device as far as possible, and a block of magnetostatic shielding material is placed between the magnet and the hall switch to implement magnetostatic shielding between the magnet and the hall switch, or a block of magnetostatic shielding material with the same size as the magnet is placed in a direction of a vertical back of the magnet, where it is required to specify that in this embodiment, the separation wall is a material capable of implementing magnetostatic shielding between the magnet and the hall switch, and the hall switch is separated from the magnet by the separation wall, in order to avoid the fact that the bluetooth switch in the slave control device is inside the slave control device due to the fact that the control device has a function on the magnetostatic shielding code matching:
step S10: when the Hall switch is detected to be in a closed state, the slave control equipment is controlled to enter a Bluetooth code matching mode;
in this step, specifically, in this embodiment, the output end of the hall switch of the slave control device is connected to the control interface GPIO of the slave control device, where it is required to specify that when the magnetic object moves closer to the hall switch, the hall element on the hall switch changes the internal circuit state of the hall switch due to the generation of the hall effect, so that the hall switch recognizes that the magnetic object exists nearby.
Further, it should be noted that, in order to facilitate the user's manipulation, in this embodiment, a pair of code area identifiers are provided at the position where the slave control device configures the code matching device to indicate the position of the hall switch of the slave control device, for example, a pair of code labels are attached to the external position corresponding to the hall switch on the slave control device.
Based on the above-mentioned slave control device structure, each step in this embodiment is explained, specifically, when the user holds the slave control device to send an instruction to the intelligent master device, the slave control device needs to pair with the intelligent master device first, specifically, when the user holds the slave control device and approaches the external code alignment tag of the slave control device to the external code alignment tag of the intelligent master device, when detecting that the hall element on the hall switch of the slave control device generates the hall effect due to the magnet of the intelligent master device, the state of the internal circuit of the hall switch of the slave control device changes, that is, when detecting that the magnet of the intelligent master device approaches by the hall switch of the slave control device, the magnetic field strength generated by the magnet of the intelligent master device is detected by the hall switch of the slave control device in real time, and when detecting that the magnetic field strength generated by the magnet of the intelligent master device exceeds the preset strength, the hall switch of the slave control device is closed, the hall switch sends a corresponding closing state signal to the control interface GPIO of the slave control device, after the control interface o of the slave control device acquires the hall switch to generate the hall effect, the control interface o of the slave control device is in the closing state signal, the bluetooth control device enters the bluetooth control mode, and optionally the slave control device is instructed to enter the bluetooth code to the slave control device, and the slave control device is instructed to enter the bluetooth mode.
Step S20: and if the Bluetooth communication code transmitted by the intelligent master device is captured, controlling the slave control device to establish connection with the intelligent master device.
When the slave control equipment enters a Bluetooth code matching mode, namely the slave control equipment starts a Bluetooth scanning mode, and if the Bluetooth communication code transmitted by the intelligent master equipment is captured, the slave control equipment is controlled to establish connection with the intelligent master equipment.
Further, step S20 further includes:
step S201: if the Bluetooth communication code transmitted by the intelligent main equipment is captured, generating first response confirmation information corresponding to the Bluetooth communication code;
step S202: and controlling the slave control equipment to establish connection with the intelligent master equipment according to the Bluetooth communication code and the first response confirmation information.
In this step, in order to improve the accuracy of bluetooth pairing, in this embodiment, a three-step reply rule is adopted to perform bluetooth pairing, specifically, if a bluetooth communication code transmitted by an intelligent master device is captured by a slave control device, the slave control device decodes the bluetooth communication code to obtain a combinational logic code of the intelligent master device, then verifies the combinational logic code of the intelligent master device, and when the verification is passed, determines that the first bluetooth pairing between the slave control device and the intelligent master device is successful, and generates corresponding first reply confirmation information, so as to control the slave control device to establish connection with the intelligent master device according to the bluetooth communication code and the first reply confirmation information.
For example, if the slave control device does not have the infrared emission function, it is determined whether the bluetooth communication code emitted by the intelligent master device is captured, where the bluetooth communication code is a bluetooth communication code capable of representing the identity of the intelligent master device, if the bluetooth communication code emitted by the intelligent master device is captured, the slave control device parses the second bluetooth communication code to verify the identity of the intelligent master device, after the verification is passed, generates first response confirmation information corresponding to the bluetooth communication code, packages the bluetooth communication code and the first response confirmation information, and places the first response confirmation information in a first response confirmation file package, so as to control the slave control device to establish connection with the intelligent master device according to the first response confirmation file package, and specifically, step S202 further includes:
step S2021: transmitting the Bluetooth communication code and the first response confirmation information, and judging whether second response confirmation information transmitted by the intelligent master equipment is captured or not;
step S2022: and if the second response confirmation information transmitted by the intelligent master equipment is captured, judging that the Bluetooth code matching between the slave control equipment and the intelligent master equipment is successful, and controlling the slave control equipment to establish connection with the intelligent master equipment.
In the step, after first response confirmation information is generated, a Bluetooth communication code and first response confirmation information are transmitted, whether second response confirmation information transmitted by the intelligent master device is captured is judged, and it is required to be noted that after the Bluetooth communication code and the first response confirmation information transmitted by the slave control device are captured, the intelligent master device generates the second response confirmation information corresponding to the Bluetooth communication code and the first response confirmation information, returns the Bluetooth communication code, the first response confirmation information and the second response confirmation information to the slave control device, and if the second response confirmation information transmitted by the intelligent master device is captured by the slave control device, the slave control device judges that the Bluetooth communication with the intelligent master device is successful, and controls the slave control device to establish connection with the intelligent master device.
Further, step S20: if the Bluetooth communication code transmitted by the intelligent master device is captured, before the step of establishing connection with the intelligent master device, the method further comprises the following steps:
step S30: and transmitting an infrared communication code to enable the intelligent master device to transmit a Bluetooth communication code according to the infrared communication code.
In this step, it can be understood that if the slave control device has an infrared emission function, the slave control device obtains a matched combinational logic code, where it is required to be explained that the slave control device matches the combinational logic code that can represent the combinational logic code corresponding to the identity of the slave control device, after the slave control device obtains the combinational logic code that matches the slave control device, the slave control device encoder encodes the combinational logic code (i.e. an infrared communication code) and emits the encoded combinational logic code through an infrared emission tube, then the infrared capturing tube of the intelligent master device captures the infrared communication code emitted by the slave control device, the intelligent master device decodes the infrared communication code to obtain the combinational logic code of the slave control device, and then verifies the combinational logic code of the slave control device, and after verification is passed, the intelligent master device obtains the combinational logic code that can represent the combinational logic code corresponding to the identity of the intelligent master device, and after the intelligent master device obtains the combinational logic code that matches the intelligent master device encodes the combinational logic code and emits the bluetooth communication code (i.e. the bluetooth communication code).
Further, in this embodiment, after step S20, the method further includes:
if the key operation corresponding to the slave control equipment is monitored, acquiring an electric signal corresponding to the key operation;
encoding the electric signal to obtain a key instruction signal corresponding to the electric signal;
and converting the key instruction signal into a Bluetooth signal and transmitting the Bluetooth signal to the intelligent master device so that the intelligent master device can respond to the key operation.
In the step, the slave control equipment monitors whether key operation is captured in real time, if key operation is captured, the key operation is converted into corresponding electric signals, the electric signals are encoded to be converted into key instruction signals corresponding to the key operation, then Bluetooth signals are converted into Bluetooth signals, the Bluetooth signals are transmitted to the intelligent master equipment, and further control instructions corresponding to the key operation are transmitted to the intelligent master equipment through the Bluetooth signals.
Based on the scheme, when the Hall switch is detected to be in the off state, the slave control equipment is controlled to enter a Bluetooth code matching mode; if the Bluetooth communication code transmitted by the intelligent master equipment is captured, the slave control equipment is controlled to establish connection with the intelligent master equipment, so that intelligent one-to-one Bluetooth code matching is realized through a Hall switch of the slave control equipment, and the Bluetooth code matching accuracy of the slave control equipment is improved.
Furthermore, based on the above-described structure, a second embodiment of the bluetooth pairing code control method of the invention is proposed.
Referring to fig. 3, fig. 3 is a flowchart of a second embodiment of the bluetooth pair code control method according to the present invention.
In this embodiment, the bluetooth code matching control method is applied to an intelligent device for responding to an action instruction, such as an intelligent television, where the intelligent device is configured with a pair of coders, where the coders include a hall switch and a magnet separated from the hall switch by a partition wall, where the partition wall is a material capable of implementing magnetostatic shielding, such as a copper plate, an aluminum plate, a superconducting material, a ferromagnetic material with high magnetic permeability, and the specific material type is not limited, and optionally, in this embodiment, the hall switch in the intelligent device is far away from the magnet in the intelligent device as far as possible, and a magnetostatic shielding material is placed between the magnet and the hall switch to implement magnetostatic shielding between the magnet and the hall switch, or a magnetostatic shielding material with the same size as that of the magnet is placed in a direction perpendicular to the back of the magnet to implement magnetostatic shielding between the magnet and the hall switch, where in this embodiment, the partition wall and the hall switch in the intelligent device are separated by the partition wall, because the magnet in the intelligent device is used to avoid that the magnetostatic shielding of the hall switch in the intelligent device is applied to the intelligent device, the bluetooth code matching control method includes:
step S40: when the Hall switch is detected to be in a closed state, controlling the intelligent main equipment to enter a Bluetooth code matching mode;
in this step, specifically, in this embodiment, the output end of the hall switch of the intelligent master device is connected to the control interface GPIO of the intelligent master device, where it is required to describe that when the magnetic object moves close to the hall switch, the hall element on the hall switch changes the internal circuit state of the hall switch due to the generation of the hall effect, and thus the hall switch recognizes that the magnetic object exists nearby.
Further, it should be noted that, in order to facilitate the user's operation, in this embodiment, a pair of code area identifiers are provided at the position where the smart master device configures the code matching device to indicate the hall switch position of the smart master device, for example, a pair of code labels are attached to the external position corresponding to the hall switch on the smart master device.
Based on the above-mentioned slave control device structure, each step in this embodiment is explained, specifically, when the user holds the slave control device and sends an instruction to the intelligent master device, the slave control device needs to pair with the intelligent master device first, specifically, when the user holds the slave control device and approaches the external code alignment tag of the slave control device to the external code alignment tag of the intelligent master device, when detecting that the hall element on the hall switch of the intelligent master device generates the hall effect due to the magnet of the slave control device, the internal circuit state of the hall switch of the intelligent master device changes, that is, when detecting that the magnet of the slave control device approaches through the hall switch of the intelligent master device, the magnetic field intensity generated by the magnet of the slave control device is detected through the hall switch of the intelligent master device, and when detecting that the magnetic field intensity generated by the magnet of the slave control device exceeds the preset intensity, the hall switch of the slave control device is closed, the hall switch sends a corresponding closing state signal to the control interface GPIO of the intelligent master device, when the control interface of the intelligent master device acquires the hall switch to generate the hall effect, that the bluetooth control interface of the intelligent master device is in the closing state, the bluetooth control device enters the bluetooth control mode, and the bluetooth code is indicated to the intelligent master device, and the bluetooth control device can enter the intelligent master device in a bluetooth mode.
Step S50: transmitting a Bluetooth communication code to establish connection with the slave control device according to the Bluetooth communication code.
When the intelligent master device enters a Bluetooth opposite code mode, namely the intelligent master device starts a Bluetooth scanning mode, bluetooth communication codes are continuously transmitted to the periphery, and connection is established with the slave control device according to the Bluetooth communication codes.
Further, step S50 further includes:
step S501: transmitting a Bluetooth communication code, and judging whether the third response confirmation information transmitted from the control equipment is captured or not;
step S502: and if the third response confirmation information transmitted by the slave control equipment is captured, controlling the slave control equipment to establish connection with the intelligent master equipment according to the third response confirmation information.
In this step, in order to improve the accuracy of bluetooth pairing code, in this embodiment, a three-step reply rule is adopted to perform bluetooth pairing code, specifically, obtain a combination logic code matched with an intelligent master device, where it needs to be described that, after the combination logic code matched with the intelligent master device is obtained, an encoder of the intelligent master device encodes the combination logic code and transmits the encoded combination logic code (i.e. a bluetooth communication code) through bluetooth transmission, and determines whether third response confirmation information transmitted from a control device is captured, and it needs to be described that, after the bluetooth communication code transmitted from the intelligent master device is captured by the control device, third response confirmation information corresponding to the bluetooth communication code is generated, and the bluetooth communication code and the third response confirmation information are transmitted to the intelligent master device in a bluetooth transmission mode, if the third response confirmation information transmitted from the control device is captured by the intelligent master device, the slave control device is controlled to establish connection with the intelligent master device according to the third response confirmation information
Further, it can be understood that the slave control device includes a slave control device having an infrared emission function and a slave control device having only a bluetooth emission function, when the slave control device is the slave control device having the infrared emission function, the slave control device will send a corresponding infrared communication code in advance, where it needs to be described that the infrared communication code of the slave control device is a combination logic code corresponding to the identity of the slave control device, so after the intelligent master device enters a bluetooth opposite code mode, it is firstly determined whether the infrared communication code emitted by the slave control device is captured, if the infrared communication code emitted by the slave control device is captured by the intelligent master device, the intelligent master device decodes the infrared communication code to perform identity verification on the slave control device, after the identity verification is passed, a combination logic code matched by the intelligent master device is obtained, after the combination logic code matched by the intelligent master device is obtained, the combination logic code matched by the intelligent master device is encoded by an encoder of the intelligent master device, and after the bluetooth opposite code is obtained by the intelligent master device, the bluetooth communication code is successfully decoded by the slave control device, and when the bluetooth communication code is successfully obtained by the slave control device, the intelligent master device, and the slave control device is successfully decoded.
Specifically, step S502 further includes:
step S5021: generating fourth response confirmation information corresponding to the third response confirmation information;
step S5022: and transmitting the fourth response confirmation information to enable the slave control equipment to establish connection with the intelligent master equipment according to the fourth response confirmation information.
In the step, after the intelligent master device captures the third response confirmation information transmitted by the slave control device, the intelligent master device generates fourth response confirmation information corresponding to the third response confirmation information, and sends the fourth response confirmation information to the slave control device in a Bluetooth transmission mode, and if the slave control device captures the fourth response confirmation information transmitted by the intelligent master device, the slave control device judges that the Bluetooth code matching with the intelligent master device is successful and controls the slave control device to establish connection with the intelligent master device.
Further, in this embodiment, after step 50, the method further includes:
if the Bluetooth signal transmitted from the control device is captured, converting the Bluetooth signal into an electrical signal;
and decoding the electric signal to obtain a control instruction corresponding to the electric signal, and responding to the control instruction.
In this step, it should be noted that, after the slave control device is connected with the bluetooth of the intelligent master device, the slave control device may send a corresponding control instruction to the intelligent master device through bluetooth, so that the intelligent master device monitors in real time whether the bluetooth signal emitted from the slave control device is captured, if the bluetooth signal emitted from the slave control device is captured by the intelligent master device, the bluetooth signal is converted into an electrical signal, and decodes the electrical signal to obtain the control instruction corresponding to the electrical signal, and then responds to the control instruction.
Based on the scheme, when the Hall switch is detected to be in the off state, the intelligent main equipment is controlled to enter a Bluetooth code matching mode; and transmitting a Bluetooth communication code to establish connection with the slave control equipment according to the Bluetooth communication code, thereby realizing intelligent one-to-one Bluetooth code matching through a Hall switch of the slave control equipment and further improving the Bluetooth code matching accuracy of the slave control equipment.
In addition, the embodiment also provides a Bluetooth code matching control device. Referring to fig. 4, fig. 4 is a schematic diagram of a functional module of a bluetooth pairing control device according to a first embodiment of the invention.
In this embodiment, the bluetooth code matching control device is a virtual device, and is stored in the memory 1005 of the bluetooth code matching control device shown in fig. 1, so as to implement all functions of the bluetooth code matching control program: the slave control equipment is used for controlling the slave control equipment to enter a Bluetooth code matching mode when the Hall switch is detected to be in a closed state; and the control device is used for controlling the slave control device to establish connection with the intelligent master device if the Bluetooth communication code transmitted by the intelligent master device is captured.
Specifically, the bluetooth code matching control device comprises:
the control module 10 is used for controlling the intelligent master device to enter a Bluetooth code matching mode when the Hall switch is detected to be in a closed state;
and the connection module 20 is used for controlling the slave control device to establish connection with the intelligent master device if the Bluetooth communication code transmitted by the intelligent master device is captured.
Further, the control module is further configured to:
if the Bluetooth communication code transmitted by the intelligent main equipment is captured, generating first response confirmation information corresponding to the Bluetooth communication code;
and controlling the slave control equipment to establish connection with the intelligent master equipment according to the Bluetooth communication code and the first response confirmation information.
Further, the control module is further configured to:
transmitting the Bluetooth communication code and the first response confirmation information, and judging whether second response confirmation information transmitted by the intelligent master equipment is captured or not;
and if the second response confirmation information transmitted by the intelligent master equipment is captured, judging that the Bluetooth code matching between the slave control equipment and the intelligent master equipment is successful, and controlling the slave control equipment to establish connection with the intelligent master equipment.
Further, the control module is further configured to:
and transmitting an infrared communication code to enable the intelligent master device to transmit a Bluetooth communication code according to the infrared communication code.
In addition, the embodiment of the invention further provides a computer storage medium, on which a bluetooth code matching control program is stored, and when the bluetooth code matching control program is run by a processor, the steps of the bluetooth code matching control method described above are implemented, which is not described herein again.
Compared with the prior art, the invention provides a Bluetooth code matching control method, a Bluetooth code matching control device and a computer storage medium, wherein the method comprises the following steps: when the Hall switch is detected to be in a closed state, the slave control equipment is controlled to enter a Bluetooth code matching mode; if the Bluetooth communication code transmitted by the intelligent master equipment is captured, the slave control equipment is controlled to establish connection with the intelligent master equipment, so that intelligent one-to-one Bluetooth code matching is realized through a Hall switch of the slave control equipment, and the Bluetooth code matching accuracy of the slave control equipment is improved.
It should be noted that, in this document, the terms "comprises," "comprising," or any other variation thereof, are intended to cover a non-exclusive inclusion, such that a process, method, article, or system that comprises a list of elements does not include only those elements but may include other elements not expressly listed or inherent to such process, method, article, or system. Without further limitation, an element defined by the phrase "comprising one … …" does not exclude the presence of other like elements in a process, method, article, or system that comprises the element.
The foregoing embodiment numbers of the present invention are merely for the purpose of description, and do not represent the advantages or disadvantages of the embodiments.
From the above description of the embodiments, it will be clear to those skilled in the art that the above-described embodiment method may be implemented by means of software plus a necessary general hardware platform, but of course may also be implemented by means of hardware, but in many cases the former is a preferred embodiment. Based on such understanding, the technical solution of the present invention may be embodied essentially or in a part contributing to the prior art in the form of a software product stored in a storage medium (e.g. ROM/RAM, magnetic disk, optical disk) as described above, comprising several instructions for causing a terminal device to perform the method according to the embodiments of the present invention.
The foregoing description is only of the preferred embodiments of the present invention and is not intended to limit the scope of the invention, and all equivalent structures or modifications in the structures or processes described in the specification and drawings, or the direct or indirect application of the present invention to other related technical fields, are included in the scope of the present invention.

Claims (7)

1. A bluetooth pairing code control method, wherein the bluetooth pairing code control method is applied to a slave control device, the slave control device being configured with a pair of coders, wherein the coders include hall switches, the method comprising:
when the Hall switch is detected to be in a closed state, the slave control equipment is controlled to enter a Bluetooth opposite code mode and transmit an infrared communication code, so that the intelligent master equipment transmits the Bluetooth communication code according to the infrared communication code;
if the Bluetooth communication code transmitted by the intelligent master device is captured, the slave control device is controlled to carry out Bluetooth communication by adopting a three-step response method, connection is established with the intelligent master device, the Bluetooth communication code is decoded by the three-step response method for the slave control device, so that the combination logic code of the intelligent master device is obtained, the combination logic code is verified, after verification is passed, the first Bluetooth communication between the slave control device and the intelligent master device is judged to be successful, and first response confirmation information is generated according to a judgment result, so that the slave control device is controlled to establish connection with the intelligent master device according to the Bluetooth communication code and the first response confirmation information.
2. The method of claim 1, wherein the step of controlling the slave control device to establish a connection with the intelligent master device according to the bluetooth communication code and the first response confirmation information comprises:
transmitting the Bluetooth communication code and the first response confirmation information, and judging whether second response confirmation information transmitted by the intelligent master equipment is captured or not;
and if the second response confirmation information transmitted by the intelligent master equipment is captured, judging that the Bluetooth code matching between the slave control equipment and the intelligent master equipment is successful, and controlling the slave control equipment to establish connection with the intelligent master equipment.
3. A bluetooth pairing code control method, wherein the bluetooth pairing code control method is applied to an intelligent master device, the intelligent master device is configured with a pair of coders, wherein the coders comprise hall switches, and the method comprises:
when the Hall switch is detected to be in a closed state, controlling the intelligent main equipment to enter a Bluetooth code matching mode;
transmitting a Bluetooth communication code when the infrared communication code transmitted by the slave control equipment is captured, so as to establish connection with the slave control equipment by adopting a three-step response method according to the Bluetooth communication code, wherein the three-step response method is used for generating third response confirmation information corresponding to the Bluetooth communication code after the slave control equipment captures the Bluetooth communication code, transmitting the Bluetooth communication code and the third response confirmation information to the intelligent master equipment, and controlling the slave control equipment to establish connection with the intelligent master equipment according to the third response confirmation information by the intelligent master equipment.
4. A method according to claim 3, wherein the step of controlling the slave control device to establish a connection with the intelligent master device in accordance with the third acknowledgement information comprises:
generating fourth response confirmation information corresponding to the third response confirmation information;
and transmitting the fourth response confirmation information to enable the slave control equipment to establish connection with the intelligent master equipment according to the fourth response confirmation information.
5. The method according to claim 3 or 4, wherein the step of transmitting a bluetooth communication code when the infrared communication code transmitted from the control device is captured to establish a connection with the control device by a three-step response method according to the bluetooth communication code further comprises:
if the Bluetooth signal transmitted from the control device is captured, converting the Bluetooth signal into an electrical signal;
and decoding the electric signal to obtain a control instruction corresponding to the electric signal, and responding to the control instruction.
6. A bluetooth code alignment control device, characterized in that the bluetooth code alignment control device includes:
the control module is used for controlling the slave control equipment to enter a Bluetooth code matching mode and transmit an infrared communication code when the Hall switch is detected to be in a closed state, so that the intelligent master equipment transmits the Bluetooth communication code according to the infrared communication code;
the connection module is used for controlling the slave control equipment to carry out Bluetooth pairing by adopting a three-step response method after capturing the Bluetooth communication code transmitted by the intelligent master equipment, establishing connection with the intelligent master equipment, decoding the Bluetooth communication code by adopting the three-step response method for the slave control equipment so as to acquire a combined logic code of the intelligent master equipment, verifying the combined logic code, judging that the first Bluetooth pairing between the slave control equipment and the intelligent master equipment is successful after verification is passed, and generating first response confirmation information according to a judgment result so as to control the slave control equipment to establish connection with the intelligent master equipment according to the Bluetooth communication code and the first response confirmation information.
7. A computer storage medium, wherein a bluetooth pairing code control program is stored on the computer storage medium, and the bluetooth pairing code control program when executed by a processor implements the steps of the bluetooth pairing code control method according to any one of claims 1 to 5.
CN202011028949.4A 2020-09-24 2020-09-24 Bluetooth code matching control method and device and computer storage medium Active CN112383903B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202011028949.4A CN112383903B (en) 2020-09-24 2020-09-24 Bluetooth code matching control method and device and computer storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202011028949.4A CN112383903B (en) 2020-09-24 2020-09-24 Bluetooth code matching control method and device and computer storage medium

Publications (2)

Publication Number Publication Date
CN112383903A CN112383903A (en) 2021-02-19
CN112383903B true CN112383903B (en) 2023-07-25

Family

ID=74579859

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202011028949.4A Active CN112383903B (en) 2020-09-24 2020-09-24 Bluetooth code matching control method and device and computer storage medium

Country Status (1)

Country Link
CN (1) CN112383903B (en)

Families Citing this family (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN116761234A (en) * 2023-08-18 2023-09-15 深圳雷柏科技股份有限公司 Equipment code matching method and system
CN117112472B (en) * 2023-10-19 2024-03-15 深圳雷柏科技股份有限公司 Communication control method, device, equipment and medium for peripheral code matching and connection

Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102983892A (en) * 2012-11-19 2013-03-20 深圳市文鼎创数据科技有限公司 Method and system for bluetooth pairing
CN104602230A (en) * 2013-10-31 2015-05-06 深圳富泰宏精密工业有限公司 Bluetooth communication device and method for using same
CN106686541A (en) * 2017-03-22 2017-05-17 北京小米移动软件有限公司 Bluetooth relaying method and device
CN106712811A (en) * 2016-11-29 2017-05-24 深圳天珑无线科技有限公司 Bluetooth connection method based on Hall switch and apparatus thereof
WO2019178709A1 (en) * 2018-02-02 2019-09-26 深圳市迈斯科技有限公司 Bluetooth earphones having magnetic control tws
CN110572869A (en) * 2019-09-11 2019-12-13 武汉拓宝科技股份有限公司 equipment awakening method and device based on BLE and Hall switch

Family Cites Families (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
KR100442625B1 (en) * 2002-04-11 2004-08-02 삼성전자주식회사 Apparatus and method for controlling the malfunction of hall effect switch used for sensing open or close of the flip or polder of terminal equipment

Patent Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102983892A (en) * 2012-11-19 2013-03-20 深圳市文鼎创数据科技有限公司 Method and system for bluetooth pairing
CN104602230A (en) * 2013-10-31 2015-05-06 深圳富泰宏精密工业有限公司 Bluetooth communication device and method for using same
CN106712811A (en) * 2016-11-29 2017-05-24 深圳天珑无线科技有限公司 Bluetooth connection method based on Hall switch and apparatus thereof
CN106686541A (en) * 2017-03-22 2017-05-17 北京小米移动软件有限公司 Bluetooth relaying method and device
WO2019178709A1 (en) * 2018-02-02 2019-09-26 深圳市迈斯科技有限公司 Bluetooth earphones having magnetic control tws
CN110572869A (en) * 2019-09-11 2019-12-13 武汉拓宝科技股份有限公司 equipment awakening method and device based on BLE and Hall switch

Also Published As

Publication number Publication date
CN112383903A (en) 2021-02-19

Similar Documents

Publication Publication Date Title
CN112383903B (en) Bluetooth code matching control method and device and computer storage medium
CN107730859B (en) Wireless device pairing method, device and storage medium
EP2296390A1 (en) Matching authentication method, device and system for wireless communication
US20110285570A1 (en) Radio communication module, remote controller, and radio system
EP4064618A1 (en) Network configuration terminal, network configuration method for household appliance, and computer-readable storage medium
US20140355993A1 (en) Electronic device and storage medium with remote control function, and remote control method
JP2023524546A (en) Home appliance and its network setting method, control terminal, computer storage medium
CN108418905B (en) Method, terminal, cloud platform device and medium for safely binding devices
CN111081005B (en) Directional remote control method, device, equipment and storage medium
CN105430646A (en) ZigBee equipment networking implementation method and device, and ZigBee equipment networking system
CN111740960A (en) Communication method of Internet of things equipment, Internet of things equipment and storage medium
WO2013037175A1 (en) Remote control
CN105025548B (en) A kind of the connection control method and device of SIM card
CN107809418B (en) Autonomous binding method and system for LoRa terminal equipment
CN111385611A (en) Account login method of smart television, smart television and terminal equipment
US8669851B2 (en) Radio communication module, remote controller, and radio system
CN104050430A (en) Method and device for generating RFID chip trigger signal
US10894320B2 (en) Robot system and robot control method
CN112258815A (en) Terminal controller, terminal control method, terminal control device, readable storage medium and system
CN112422377A (en) Intelligent terminal control method and device and computer readable storage medium
KR20100026440A (en) Device for controlling the equipment by using sms and drving method thereof
CN103475650A (en) Data processing method and device based on wireless communication protocol
CN108958125A (en) Processing method, central control system and the vehicle of central control system
CN109309608A (en) A kind of smart home internet of things wide area dynamic unlocking system
CN105323262B (en) End message method for uploading and system based on transmission device

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