CN110070654B - Electronic lock unlocking method, system, terminal, electronic lock and computer storage medium - Google Patents

Electronic lock unlocking method, system, terminal, electronic lock and computer storage medium Download PDF

Info

Publication number
CN110070654B
CN110070654B CN201910353734.0A CN201910353734A CN110070654B CN 110070654 B CN110070654 B CN 110070654B CN 201910353734 A CN201910353734 A CN 201910353734A CN 110070654 B CN110070654 B CN 110070654B
Authority
CN
China
Prior art keywords
unlocking
electronic lock
bluetooth
terminal
unlocking instruction
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
CN201910353734.0A
Other languages
Chinese (zh)
Other versions
CN110070654A (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.)
WeBank Co Ltd
Original Assignee
WeBank 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 WeBank Co Ltd filed Critical WeBank Co Ltd
Priority to CN201910353734.0A priority Critical patent/CN110070654B/en
Publication of CN110070654A publication Critical patent/CN110070654A/en
Application granted granted Critical
Publication of CN110070654B publication Critical patent/CN110070654B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • GPHYSICS
    • G07CHECKING-DEVICES
    • G07CTIME OR ATTENDANCE REGISTERS; REGISTERING OR INDICATING THE WORKING OF MACHINES; GENERATING RANDOM NUMBERS; VOTING OR LOTTERY APPARATUS; ARRANGEMENTS, SYSTEMS OR APPARATUS FOR CHECKING NOT PROVIDED FOR ELSEWHERE
    • G07C9/00Individual registration on entry or exit
    • G07C9/00174Electronically operated locks; Circuits therefor; Nonmechanical keys therefor, e.g. passive or active electrical keys or other data carriers without mechanical keys
    • G07C9/00309Electronically operated locks; Circuits therefor; Nonmechanical keys therefor, e.g. passive or active electrical keys or other data carriers without mechanical keys operated with bidirectional data transmission between data carrier and locks

Abstract

The invention relates to the field of electronic locks, and discloses an unlocking method of an electronic lock, which comprises the following steps: when a terminal receives an unlocking instruction, acquiring an electronic lock identifier corresponding to the unlocking instruction; and when the Bluetooth is in an open state, the unlocking instruction is sent to the electronic lock corresponding to the electronic lock identification in parallel through a Bluetooth channel and a network channel, so that the electronic lock executes unlocking operation according to the unlocking instruction received firstly. The invention also discloses an electronic lock, a terminal, an electronic lock unlocking system and a computer storage medium. According to the invention, the unlocking instruction is sent in parallel through two channels, so that the problem of electronic lock unlocking failure caused by network signal difference or Bluetooth connection failure is avoided, and the success rate of electronic lock unlocking is improved.

Description

Electronic lock unlocking method, system, terminal, electronic lock and computer storage medium
Technical Field
The invention relates to the technical field of electronic locks, in particular to an electronic lock unlocking method, an electronic lock unlocking system, a terminal, an electronic lock and a computer storage medium.
Background
In recent years, the application of intelligent electronic locks to shared devices is becoming more and more widespread. The method for unlocking the shared device by the user mainly comprises the following steps: the method comprises the steps that a user uses a mobile phone to scan a two-dimensional code on the sharing device to obtain a device identifier of the sharing device, a request is sent to a server through the mobile phone, the request carries the device identifier of the sharing device and relevant information of the user, the server verifies the received request, an unlocking instruction is sent to the sharing device when the verification is passed, the sharing device is unlocked, and the user can use the sharing device.
In the current mode of unlocking equipment, if a mobile phone of a user cannot communicate with a server, unlocking operation cannot be finished.
Disclosure of Invention
The invention mainly aims to provide an electronic lock unlocking method, an electronic lock unlocking system, a terminal electronic lock and a computer storage medium, and aims to solve the technical problem of electronic lock unlocking failure caused by failure in delivery of an unlocking instruction.
In order to achieve the above object, the present invention provides an electronic lock unlocking method;
the electronic lock unlocking method is applied to a terminal, and comprises the following steps:
when an unlocking instruction is received, acquiring an electronic lock identifier corresponding to the unlocking instruction;
and when the Bluetooth is in an open state, the unlocking instruction is sent to the electronic lock corresponding to the electronic lock identification in parallel through a Bluetooth channel and a network channel, so that the electronic lock executes unlocking operation according to the unlocking instruction received firstly.
Optionally, the step of acquiring, when an unlocking instruction is received, an electronic lock identifier corresponding to the unlocking instruction includes:
scanning the two-dimension code and loading an application program corresponding to the two-dimension code;
and when an unlocking instruction triggered based on the application program is received, acquiring identification information corresponding to the two-dimensional code, and taking the identification information as an electronic lock identification corresponding to the unlocking instruction.
Optionally, when the bluetooth is in the open state, the step of sending the unlocking instruction to the electronic lock corresponding to the electronic lock identifier in parallel through the bluetooth channel and the network channel includes:
when the Bluetooth is in an open state, sending a Bluetooth pairing request to an electronic lock corresponding to the electronic lock identification;
when a Bluetooth pairing code fed back by the electronic lock based on the Bluetooth pairing request is received, executing Bluetooth pairing operation according to the Bluetooth pairing code to establish Bluetooth connection;
and when the Bluetooth connection is detected to be successful, the unlocking instruction is sent to the electronic lock corresponding to the electronic lock identification in parallel through a Bluetooth channel and a network channel.
Optionally, when it is detected that the bluetooth connection is successful, the step of sending the unlocking instruction to the electronic lock corresponding to the electronic lock identifier in parallel through the bluetooth channel and the network channel includes:
when the Bluetooth connection is detected to be successful, judging whether a network signal exists at present;
when no network signal exists at present, the unlocking instruction is sent to the electronic lock corresponding to the electronic lock identification through a Bluetooth channel;
when a network signal exists at present, the unlocking instruction is sent to the electronic lock corresponding to the electronic lock identification through the Bluetooth channel, and the unlocking instruction is sent to the server through the network channel, so that the server broadcasts the unlocking instruction to the electronic lock corresponding to the electronic lock identification through the Internet of things.
Optionally, after the step of obtaining the electronic lock identifier corresponding to the unlocking instruction when the unlocking instruction is received, the method includes:
when the Bluetooth is in a closed state, judging whether a network signal exists at present;
when a network signal exists currently, the unlocking instruction is sent to a server through a network channel, so that the server broadcasts the unlocking instruction to the electronic lock corresponding to the electronic lock identifier through the Internet of things;
and when the Bluetooth connection is successful, the unlocking instruction is sent to the electronic lock corresponding to the electronic lock identification through the Bluetooth channel.
Optionally, after the step of sending the unlocking instruction to the electronic lock corresponding to the electronic lock identifier in parallel through the bluetooth channel and the network channel when the bluetooth is in the open state, the method includes:
receiving an unlocking result sent by the electronic lock, and judging whether the unlocking result is from the Bluetooth channel;
and when the unlocking result is from the Bluetooth channel, feeding the unlocking result back to a server so that the server marks the use state of the electronic lock according to the unlocking result.
In addition, in order to achieve the purpose, the invention also provides an electronic lock unlocking method;
the electronic lock unlocking method is applied to an electronic lock, and comprises the following steps:
when a Bluetooth pairing request is received, acquiring a terminal identifier in the Bluetooth pairing request, and establishing Bluetooth connection with a terminal corresponding to the terminal identifier;
when an unlocking instruction is received, executing unlocking operation and judging whether a network signal exists at present;
when a network signal exists currently, an unlocking result of the unlocking operation is fed back to a server through the Internet of things, so that the server marks the use state of the electronic lock according to the unlocking result;
and when no network signal exists at present, sending the unlocking result of the unlocking operation to the terminal through a Bluetooth channel so that the terminal sends the unlocking result to a server.
In addition, in order to achieve the purpose, the invention also provides an electronic lock unlocking system;
the electronic lock unlocking system includes: communication connection's terminal, electronic lock and server, electronic lock unblock system includes:
when a terminal receives an unlocking instruction, acquiring an electronic lock identifier corresponding to the unlocking instruction;
when the terminal determines that the Bluetooth is in an open state, the terminal concurrently issues an unlocking instruction to the electronic lock corresponding to the electronic lock identification through a Bluetooth channel and a network channel;
when the electronic lock receives an unlocking instruction, executing unlocking operation, and feeding back an unlocking result of the unlocking operation to a server;
and the server receives the unlocking result, and marks the use state of the electronic lock according to the unlocking result.
In addition, in order to achieve the above object, the present invention also provides a terminal;
the terminal includes: a bluetooth module, a network communication module, a first memory, a first processor, and a computer program stored on the first memory and executable on the first processor, wherein:
the computer program when executed by the first processor implementing the steps of:
when the first processor receives an unlocking instruction, the first processor acquires an electronic lock identifier corresponding to the unlocking instruction;
when the Bluetooth is in an open state, the first processor sends the unlocking instruction to the electronic lock corresponding to the electronic lock identification in parallel through the Bluetooth module and the network communication module, so that the electronic lock executes unlocking operation according to the unlocking instruction received firstly.
In addition, in order to achieve the purpose, the invention also provides an electronic lock;
the electronic lock includes: a second memory, a second processor, and a computer program stored on the second memory and executable on the second processor, wherein:
the computer program when executed by the second processor implementing the steps of:
when the second processor receives a Bluetooth pairing request, the second processor acquires a terminal identifier in the Bluetooth pairing request and establishes Bluetooth connection with a terminal corresponding to the terminal identifier;
when the second processor receives an unlocking instruction, the second processor executes unlocking operation and judges whether a network signal exists at present;
when a network signal exists currently, an unlocking result of the unlocking operation is fed back to a server through the Internet of things, so that the server marks the use state of the electronic lock according to the unlocking result;
and when no network signal exists at present, sending the unlocking result of the unlocking operation to the terminal through a Bluetooth channel so that the terminal sends the unlocking result to a server.
In addition, to achieve the above object, the present invention also provides a computer storage medium;
the computer storage medium has stored thereon a computer program which, when executed by a processor, implements the steps of the electronic lock unlocking method as described above.
According to the electronic lock unlocking method, the electronic lock unlocking system, the terminal, the electronic lock and the computer storage medium, when the terminal receives an unlocking instruction, an electronic lock identifier corresponding to the unlocking instruction is obtained; when the Bluetooth of the terminal is in an open state, the unlocking instruction is sent to the electronic lock corresponding to the electronic lock identification in parallel through a Bluetooth channel and a network channel, so that the electronic lock executes unlocking operation according to the unlocking instruction received firstly; in the embodiment, the terminal sends the unlocking instruction to the electronic lock in parallel through the network and the Bluetooth dual channel, so that the problem that the unlocking instruction fails to be sent due to poor network signals or failure in Bluetooth connection is avoided, the unlocking instruction is guaranteed to successfully reach the electronic lock, and the unlocking success rate of the electronic lock is improved.
Drawings
FIG. 1 is a schematic diagram of an apparatus in a hardware operating environment according to an embodiment of the present invention;
FIG. 2 is a flowchart illustrating a first embodiment of an unlocking method of an electronic lock according to the present invention;
FIG. 3 is a flowchart illustrating a method for unlocking an electronic lock according to a third embodiment of the present invention;
FIG. 4 is a flowchart illustrating a fourth exemplary embodiment of an unlocking method of an electronic lock according to the present invention;
FIG. 5 is a detailed diagram of an electronic lock according to a fourth embodiment of the unlocking method of the electronic lock of the present invention;
fig. 6 is a schematic view illustrating an implementation of a specific scenario of an electronic lock unlocking system according to an embodiment of the present invention.
The implementation, functional features and advantages of the objects of the present invention will be further explained with reference to the accompanying drawings.
Detailed Description
It should be understood that the specific embodiments described herein are merely illustrative of the invention and are not intended to limit the invention.
As shown in fig. 1, fig. 1 is a schematic terminal structure diagram of a hardware operating environment according to an embodiment of the present invention.
The terminal of the embodiment of the invention can be a fixed terminal or a mobile terminal, such as an intelligent air conditioner with a networking function, an intelligent electric lamp, an intelligent power supply, an intelligent sound box, an automatic driving automobile, a Personal Computer (PC), a smart phone, a tablet computer, an electronic book reader, a portable computer and the like.
As shown in fig. 1, the terminal may include: a processor 1001, such as a Central Processing Unit (CPU), a network interface 1004, a user interface 1003, a memory 1005, and a communication bus 1002. Wherein a communication bus 1002 is used to enable connective communication between these components. The user interface 1003 may include a Display screen (Display), an input unit such as a Keyboard (Keyboard), and the optional user interface 1003 may also include a standard wired interface, a wireless interface. The network interface 1004 may optionally include a standard wired interface, a WIreless interface (e.g., WIFI interface, WIreless FIdelity, WIFI interface). The memory 1005 may be a high-speed RAM memory or a non-volatile memory (e.g., a magnetic disk memory). The memory 1005 may alternatively be a storage device separate from the processor 1001.
Optionally, the terminal may further include a camera, a Radio Frequency (RF) circuit, a sensor, an audio circuit, and a WiFi module; the input unit is compared with a display screen and a touch screen; the network interface may optionally be other than WiFi, bluetooth, probe, etc. in the wireless interface. Such as light sensors, motion sensors, and other sensors. In particular, the light sensor may include an ambient light sensor and a proximity sensor; of course, the mobile terminal may also be configured with other sensors such as a gyroscope, a barometer, a hygrometer, a thermometer, and an infrared sensor, which are not described herein again.
Those skilled in the art will appreciate that the terminal structure shown in fig. 1 is not intended to be limiting and may include more or fewer components than those shown, or some components may be combined, or a different arrangement of components.
As shown in fig. 1, the computer software product is stored in a storage medium (storage medium: also called computer storage medium, computer medium, readable storage medium, computer readable storage medium, or direct storage medium, etc., and the storage medium may be a non-volatile readable storage medium, such as RAM, magnetic disk, optical disk), and includes several instructions for enabling a terminal device (which may be a mobile phone, a computer, a server, an air conditioner, or a network device, etc.) to execute the method according to the embodiments of the present invention, and a memory 1005 as a computer storage medium may include an operating system, a network communication module, a user interface module, and a computer program.
In the terminal shown in fig. 1, the network interface 1004 is mainly used for connecting to a backend server and performing data communication with the backend server; the user interface 1003 is mainly used for connecting a client (user side) and performing data communication with the client; and the processor 1001 may be configured to call up a computer program stored in the memory 1005 and perform the steps of the electronic lock unlocking method provided by the following embodiments of the present invention.
Referring to fig. 2, in a first embodiment of the electronic lock unlocking method of the present invention, the electronic lock unlocking method includes:
step S10, when an unlocking instruction is received, the electronic lock identification corresponding to the unlocking instruction is obtained.
The electronic lock unlocking method in this embodiment is applied to a terminal shown in fig. 1, in which a bluetooth module and a network communication module are installed, the bluetooth module is a PCBA (Printed Circuit Board Assembly) Board integrating a bluetooth function, the bluetooth module is used for short-distance wireless communication, and the bluetooth module is divided into a bluetooth data module and a bluetooth voice module according to functions; the network communication module is a chip integrating wireless network communication functions, and can interact with the server and the electronic lock.
In this embodiment, the terminal receives the unlocking instruction, and the triggering mode of the unlocking instruction is not specifically limited, that is, the unlocking instruction may be actively triggered by a user, for example, the user outputs a xxx-numbered electronic lock triggering unlocking instruction in a display interface of the terminal; the unlocking instruction can also be automatically triggered by the terminal, for example, the terminal presets the unlocking instruction triggering conditions as follows: the distance between the terminal and the electronic lock is smaller than a preset distance (the preset distance is a preset distance critical value, for example, the preset distance is 1 meter), and when the terminal detects that the distance between the terminal and the electronic lock is smaller than the preset distance, the terminal automatically triggers an unlocking instruction.
After the terminal receives the unlocking instruction, the terminal acquires an electronic lock identifier corresponding to the unlocking instruction, then the terminal judges whether the Bluetooth of the terminal is in an open state or not so as to determine a sending path of the unlocking instruction according to the state of the Bluetooth of the terminal, specifically:
and step S20, when the Bluetooth is in the open state, the unlocking instruction is sent to the electronic lock corresponding to the electronic lock identification in parallel through the Bluetooth channel and the network channel, so that the electronic lock executes the unlocking operation according to the unlocking instruction received firstly.
When the terminal determines that the bluetooth of the terminal is in the unlocking state, the terminal concurrently issues an unlocking instruction to the electronic lock corresponding to the electronic lock identifier through the bluetooth module and the network communication module, so that the electronic lock executes the unlocking operation according to the first received unlocking instruction. Specifically, the method comprises the following steps:
and step S21, when the Bluetooth is in the open state, sending a Bluetooth pairing request to the electronic lock corresponding to the electronic lock identifier.
When the bluetooth of the terminal is in an open state, the terminal sends a bluetooth pairing request to the electronic lock corresponding to the electronic lock identifier, that is, the terminal loads own device information (the device information includes the terminal identifier and the bluetooth pairing code) into the bluetooth pairing request, and the terminal sends the bluetooth pairing request to the electronic lock according to a bluetooth transmission protocol, so that the electronic lock feeds back the bluetooth pairing code according to the received bluetooth pairing request.
And step S22, when receiving the Bluetooth pairing code fed back by the electronic lock based on the Bluetooth pairing request, executing Bluetooth pairing operation according to the Bluetooth pairing code to establish Bluetooth connection.
The terminal receives the Bluetooth pairing code fed back by the electronic lock based on the Bluetooth pairing request, the terminal performs Bluetooth pairing with the electronic lock corresponding to the electronic lock identification according to the Bluetooth pairing code, in the embodiment, the user does not need to manually perform Bluetooth pairing operation, the terminal can automatically perform Bluetooth pairing, and user operation is reduced.
And step S23, when detecting that the Bluetooth connection is successful, sending the unlocking instruction to the electronic lock corresponding to the electronic lock identification in parallel through the Bluetooth channel and the network channel.
Specifically, step S23 includes:
step b1, when detecting that the Bluetooth connection is successful, judging whether a network signal exists currently;
b2, when no network signal exists at present, the unlocking instruction is sent to the electronic lock corresponding to the electronic lock identification through a Bluetooth channel;
and b3, when a network signal exists currently, sending the unlocking instruction to the electronic lock corresponding to the electronic lock identification through a Bluetooth channel, and sending the unlocking instruction to a server through a network channel, so that the server broadcasts the unlocking instruction to the electronic lock corresponding to the electronic lock identification through the Internet of things.
In the embodiment, when the bluetooth connection is successful, the terminal judges whether a network signal exists at present, so as to determine a transmission path of an unlocking instruction according to whether the network signal exists at present; specifically, when no network signal exists currently, the terminal sends an unlocking instruction to the electronic lock corresponding to the electronic lock identifier through the Bluetooth module; when a network signal exists currently, the terminal sends an unlocking instruction through the Bluetooth channel and the network channel, namely, the terminal sends the unlocking instruction to the electronic lock corresponding to the electronic lock identifier through the Bluetooth module, and meanwhile, the terminal sends the unlocking instruction to the server through the network communication module, so that the server broadcasts the unlocking instruction to the electronic lock corresponding to the electronic lock identifier through the Internet of things.
In the embodiment, the terminal sends the unlocking instruction to the electronic lock in parallel through the network and the Bluetooth double channels, so that the problem that the unlocking instruction fails to be sent due to poor network signals or failure in Bluetooth connection is avoided, the unlocking instruction is guaranteed to successfully reach the electronic lock, and the unlocking success rate of the electronic lock is improved.
Further, a second embodiment of the electronic unlocking method of the present invention is proposed on the basis of the first embodiment.
The present embodiment is a refinement of step S10 in the first embodiment, and the specific implementation manner that the terminal obtains the electronic lock identifier in the form of scanning the two-dimensional code is provided in the present embodiment, and includes:
and step S11, scanning the two-dimensional code and loading an application program corresponding to the two-dimensional code.
The user uses the terminal to scan the two-dimensional code, and the terminal loads the application program corresponding to the two-dimensional code, that is, the electronic lock unlocking control method is set to be a small program in the embodiment, so that the occupation of the storage space of the terminal is reduced, and the operation of the user is facilitated.
Step S12, when an unlocking instruction triggered based on the application program is received, acquiring identification information corresponding to the two-dimensional code, and taking the identification information as an electronic lock identification corresponding to the unlocking instruction.
In this embodiment, when the terminal finishes loading the application program, the user may trigger an unlocking instruction based on the application program, that is, the user opens the application program, then clicks the unlocking button to trigger the unlocking instruction, when the terminal receives the unlocking instruction triggered based on the application program, the terminal acquires the identification information corresponding to the two-dimensional code, and the terminal uses the identification information as the electronic lock identification corresponding to the unlocking instruction. In the embodiment, the user does not need to manually input the electronic lock identifier, so that the user can operate the electronic lock more conveniently in the unlocking process.
Further, referring to fig. 3, a third embodiment of the electronic lock unlocking method of the present invention is provided on the basis of the first embodiment of the present invention.
This embodiment is a step after step S10 in the first embodiment, and specifically describes that when the bluetooth of the terminal is in the off state, the electronic lock unlocking method includes:
step S30, when the bluetooth of the terminal is in the off state, the terminal determines whether there is a network signal currently.
In this embodiment, after the terminal receives the unlocking instruction, when the terminal determines that the bluetooth is in the off state, the terminal determines whether a network signal exists currently to determine whether the bluetooth needs to be turned on, specifically:
and step S40, when a network signal exists currently, the unlocking instruction is sent to a server through a network channel, so that the server broadcasts the unlocking instruction to the electronic lock corresponding to the electronic lock identification through the Internet of things.
When a network signal exists currently, the terminal sends an unlocking instruction to the server through the network communication module, so that the server broadcasts the unlocking instruction to the electronic lock corresponding to the electronic lock identifier through the Internet of things; it can be understood that, when there is the network signal at present, use the network channel to carry out the transmission of unblock instruction in this embodiment, reduced the power consumption of opening the bluetooth, when having avoided unable bluetooth connection to establish, lead to the unblock instruction can't give down the condition to the electronic lock.
And step S50, when no network signal exists at present, starting the Bluetooth and executing Bluetooth pairing operation, and when the Bluetooth connection is successful, sending an unlocking instruction to the electronic lock corresponding to the electronic lock identification through the Bluetooth channel.
When no network signal exists currently, the terminal starts the bluetooth and executes the bluetooth pairing operation, wherein the specific implementation step of executing the bluetooth pairing operation may refer to the first embodiment of the present invention, which is not described in detail in this embodiment, and when the bluetooth connection is successful, the terminal sends the unlocking instruction to the electronic lock corresponding to the electronic lock identifier through the bluetooth channel.
In this embodiment, when the bluetooth of the terminal is in an off state, the terminal selects a suitable unlocking instruction sending path according to the current network signal information, so as to reduce user operations and ensure the unlocking success rate of the electronic lock.
Further, a fourth embodiment of the electronic lock unlocking method according to the present invention is provided on the basis of the above embodiments, and the steps of the present embodiment after the electronic lock is unlocked include:
step S60, receiving an unlocking result sent by the electronic lock, and judging whether the unlocking result is from the Bluetooth channel; and when the unlocking result is from the Bluetooth channel, feeding the unlocking result back to a server so that the server marks the use state of the electronic lock according to the unlocking result.
In the embodiment, after the terminal completes sending the unlocking instruction, the terminal receives the unlocking result fed back by the electronic lock in real time; when the unlocking result is from a network channel, the terminal outputs the unlocking result for the user to check, and when the unlocking result is from a Bluetooth channel, the terminal feeds the unlocking result back to the server, so that the server marks the use state of the electronic lock according to the unlocking result, namely, when the unlocking result is successful, the terminal sends information of successful unlocking to the server, and the server marks the electronic lock corresponding to the electronic lock identifier as the use state; and when the unlocking result is unlocking failure, the terminal sends information of the unlocking failure to the server, and the server counts the unlocking times of the electronic lock mark corresponding to the electronic lock mark, so that the electronic lock is prevented from being in failure.
Further, referring to fig. 4, in a fourth embodiment of the electronic lock unlocking method of the present invention, the electronic lock unlocking method includes:
step S70, when receiving the Bluetooth pairing request, acquiring the terminal identification in the Bluetooth pairing request, and establishing the Bluetooth connection with the terminal corresponding to the terminal identification.
The electronic lock unlocking method in the embodiment is applied to an electronic lock, wherein a Bluetooth module and a network communication module are installed in the electronic lock, the Bluetooth module is a PCBA (Printed Circuit Board Assembly) Board integrating a Bluetooth function, the Bluetooth module is used for short-distance wireless communication, and the Bluetooth module is divided into a Bluetooth data module and a Bluetooth voice module according to functions; the network communication module is a chip integrating wireless network communication functions, can be communicated with a terminal, and can also interact with a server through the Internet of things.
When the electronic lock receives the Bluetooth pairing request, the electronic lock acquires the terminal identification in the Bluetooth pairing request, and the electronic lock establishes Bluetooth connection with the terminal corresponding to the terminal identification. It is understood that the type of the electronic lock in the present embodiment is not particularly limited, and refer to the shopping cart electronic lock shown in fig. 5.
Step S80, when receiving the unlocking instruction, executing the unlocking operation and judging whether the network signal exists currently;
when the electronic lock receives the unlocking instruction, the electronic lock executes the unlocking operation, the unlocking instruction in the embodiment is received by the Bluetooth module, the unlocking instruction can also be received by the network communication module, the electronic lock executes the unlocking operation according to the unlocking instruction received firstly,
in addition, when the execution of the unlocking instruction is completed, the terminal feeds back the unlocking result of the unlocking instruction according to the source of the unlocking result. Specifically, when the electronic lock is unlocked, the electronic lock judges whether a network signal exists at present to determine an unlocking result feedback path obtained by the unlocking operation, specifically:
and step S90, when a network signal exists currently, the unlocking result of the unlocking operation is fed back to the server through the Internet of things.
When a network signal exists currently, the electronic lock feeds back an unlocking result of the unlocking operation to the server through the Internet of things, so that the server marks the use state of the electronic lock according to the unlocking result; the electronic lock sends an unlocking result of the unlocking operation to the gateway, the gateway sends the unlocking result to the corresponding Internet of things, and the Internet of things feeds the unlocking result back to the server, so that the server marks the use state of the electronic lock according to the received unlocking result.
And S100, when no network signal exists currently, sending the unlocking result of the unlocking operation to the terminal through a Bluetooth channel so that the terminal sends the unlocking result to a server.
When no network signal exists at present, the electronic lock sends an unlocking result of the unlocking operation to the terminal through the Bluetooth channel, so that the terminal sends the unlocking result to the server, and the server marks the use state of the electronic lock according to the received unlocking result.
The electronic lock is provided with the Bluetooth module and the network communication module, the Bluetooth of the electronic lock is in an open state, the electronic lock can receive an unlocking instruction sent by the Bluetooth module and/or the network communication module and execute unlocking operation, the unlocking success rate of the electronic lock is effectively guaranteed, and meanwhile, the electronic lock feeds back an unlocking result to enable a user to know the use state of the electronic lock.
In addition, referring to fig. 6, an embodiment of the present invention further provides an electronic lock unlocking system, where the electronic lock unlocking device includes:
when a terminal receives an unlocking instruction, acquiring an electronic lock identifier corresponding to the unlocking instruction;
when the terminal determines that the Bluetooth is in an open state, the terminal concurrently issues an unlocking instruction to the electronic lock corresponding to the electronic lock identification through a Bluetooth channel and a network channel;
when the electronic lock receives an unlocking instruction, executing unlocking operation, and feeding back an unlocking result of the unlocking operation to a server;
and the server receives the unlocking result, and marks the use state of the electronic lock according to the unlocking result.
The steps implemented by each functional module of the electronic lock unlocking device may refer to each embodiment of the electronic lock unlocking method of the present invention, and are not described herein again.
In addition, the embodiment of the invention also provides a computer storage medium.
The computer storage medium stores thereon a computer program, and the computer program, when executed by a processor, implements the operations in the electronic lock unlocking method provided by the above embodiments.
It is noted that, herein, relational terms such as first and second, and the like may be used solely to distinguish one entity/action/object from another entity/action/object without necessarily requiring or implying any actual such relationship or order between such entities/actions/objects; 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 an … …" does not exclude the presence of other like elements in a process, method, article, or system that comprises the element.
For the apparatus embodiment, since it is substantially similar to the method embodiment, it is described relatively simply, and reference may be made to some descriptions of the method embodiment for relevant points. The above-described apparatus embodiments are merely illustrative, in that elements described as separate components may or may not be physically separate. Some or all of the modules can be selected according to actual needs to achieve the purpose of the scheme of the invention. One of ordinary skill in the art can understand and implement it without inventive effort.
The above-mentioned serial numbers of the embodiments of the present invention are merely for description and do not represent the merits of the embodiments.
Through the above description of the embodiments, those skilled in the art will clearly understand that the method of the above embodiments can be implemented by software plus a necessary general hardware platform, and certainly can also be implemented by hardware, but in many cases, the former is a better implementation manner. Based on such understanding, the technical solution of the present invention may be embodied in the form of a software product, which is stored in a storage medium (e.g., ROM/RAM, magnetic disk, optical disk) as described above and includes instructions for enabling a terminal device (e.g., a mobile phone, a computer, a server, an air conditioner, or a network device) to execute the method according to the embodiments of the present invention.
The above description is only a preferred embodiment of the present invention, and not intended to limit the scope of the present invention, and all modifications of equivalent structures and equivalent processes, which are made by using the contents of the present specification and the accompanying drawings, or directly or indirectly applied to other related technical fields, are included in the scope of the present invention.

Claims (8)

1. An electronic lock unlocking method is applied to a terminal, and comprises the following steps:
when an unlocking instruction is received, acquiring an electronic lock identifier corresponding to the unlocking instruction, wherein the unlocking instruction is actively triggered and/or automatically triggered by a terminal according to a user, and the terminal automatically triggers the unlocking instruction when the terminal detects that the distance between the terminal and the electronic lock is smaller than a preset distance;
when the Bluetooth is in an open state, the unlocking instruction is sent to the electronic lock corresponding to the electronic lock identification in parallel through a Bluetooth channel and a network channel, so that the electronic lock executes unlocking operation according to the unlocking instruction received firstly;
receiving an unlocking result sent by the electronic lock, and judging whether the unlocking result is from the Bluetooth channel;
when the unlocking result is from the Bluetooth channel, the unlocking result is fed back to the server so that the server marks the use state of the electronic lock according to the unlocking result, wherein when the unlocking result is unlocking failure, information of the unlocking failure is sent to the server so that the server can count the unlocking times of the electronic lock corresponding to the electronic lock identifier, and when the unlocking result is from the network channel, the terminal outputs the unlocking result for a user to check;
when an unlocking instruction is received, after the step of obtaining the electronic lock identifier corresponding to the unlocking instruction, the method further comprises the following steps:
when the Bluetooth is in a closed state, judging whether a network signal exists at present;
when a network signal exists currently, the unlocking instruction is sent to a server through a network channel, so that the server broadcasts the unlocking instruction to the electronic lock corresponding to the electronic lock identifier through the Internet of things;
and when the Bluetooth connection is successful, the unlocking instruction is sent to the electronic lock corresponding to the electronic lock identification through the Bluetooth channel.
2. The electronic lock unlocking method according to claim 1, wherein the step of acquiring the electronic lock identifier corresponding to the unlocking instruction when the unlocking instruction is received includes:
scanning the two-dimension code and loading an application program corresponding to the two-dimension code;
and when an unlocking instruction triggered based on the application program is received, acquiring identification information corresponding to the two-dimensional code, and taking the identification information as an electronic lock identification corresponding to the unlocking instruction.
3. The electronic lock unlocking method according to claim 1, wherein the step of sending the unlocking instruction to the electronic lock corresponding to the electronic lock identifier in parallel through a bluetooth channel and a network channel when the bluetooth is in an open state includes:
when the Bluetooth is in an open state, sending a Bluetooth pairing request to an electronic lock corresponding to the electronic lock identification;
when a Bluetooth pairing code fed back by the electronic lock based on the Bluetooth pairing request is received, executing Bluetooth pairing operation according to the Bluetooth pairing code to establish Bluetooth connection;
and when the Bluetooth connection is detected to be successful, the unlocking instruction is sent to the electronic lock corresponding to the electronic lock identification in parallel through a Bluetooth channel and a network channel.
4. The electronic lock unlocking method according to claim 3, wherein the step of sending the unlocking instruction to the electronic lock corresponding to the electronic lock identifier in parallel through a bluetooth channel and a network channel when detecting that the bluetooth connection is successful includes:
when the Bluetooth connection is detected to be successful, judging whether a network signal exists at present;
when no network signal exists at present, the unlocking instruction is sent to the electronic lock corresponding to the electronic lock identification through a Bluetooth channel;
when a network signal exists at present, the unlocking instruction is sent to the electronic lock corresponding to the electronic lock identification through the Bluetooth channel, and the unlocking instruction is sent to the server through the network channel, so that the server broadcasts the unlocking instruction to the electronic lock corresponding to the electronic lock identification through the Internet of things.
5. An electronic lock unlocking method is applied to an electronic lock, and comprises the following steps:
when a Bluetooth pairing request is received, acquiring a terminal identifier in the Bluetooth pairing request, and establishing Bluetooth connection with a terminal corresponding to the terminal identifier;
when an unlocking instruction is received, executing unlocking operation according to the unlocking instruction received firstly, and judging whether a network signal exists currently, wherein when the unlocking instruction is executed, an unlocking result of the unlocking instruction is fed back according to the source of the unlocking instruction;
when a network signal exists currently, an unlocking result of the unlocking operation is fed back to a server through the Internet of things, so that the server marks the use state of the electronic lock according to the unlocking result, wherein the unlocking result of the unlocking operation is sent to a gateway, the gateway sends the unlocking result to the corresponding Internet of things, and the Internet of things feeds back the unlocking result to the server;
and when no network signal exists at present, sending the unlocking result of the unlocking operation to the terminal through a Bluetooth channel so that the terminal sends the unlocking result to a server.
6. An electronic lock unlocking system, characterized by comprising: communication connection's terminal, electronic lock and server, electronic lock unblock system includes:
the method comprises the steps that when a terminal receives an unlocking instruction, an electronic lock identifier corresponding to the unlocking instruction is obtained, wherein the unlocking instruction is actively triggered and/or automatically triggered by the terminal according to a user, and the terminal automatically triggers the unlocking instruction when the terminal detects that the distance between the terminal and an electronic lock is smaller than a preset distance;
when the terminal determines that the Bluetooth is in an open state, the terminal concurrently issues an unlocking instruction to the electronic lock corresponding to the electronic lock identification through a Bluetooth channel and a network channel;
when the electronic lock receives an unlocking instruction, executing unlocking operation, and feeding back an unlocking result of the unlocking operation to a server, wherein the terminal receives the unlocking result of the electronic lock, judges whether the unlocking result is from the Bluetooth channel, and feeds back the unlocking result to the server if the unlocking result is from the Bluetooth channel, or outputs the unlocking result for a user to check if the unlocking result is from a network channel;
the server receives the unlocking result, and marks the use state of the electronic lock according to the unlocking result, wherein when the unlocking result is unlocking failure, the server counts the unlocking times of the electronic lock corresponding to the electronic lock identification;
when the terminal receives an unlocking instruction, after the step of obtaining the electronic lock identifier corresponding to the unlocking instruction, the method further comprises the following steps:
when the Bluetooth is in a closed state, judging whether a network signal exists at present;
when a network signal exists currently, the unlocking instruction is sent to a server through a network channel, so that the server broadcasts the unlocking instruction to the electronic lock corresponding to the electronic lock identifier through the Internet of things;
and when the Bluetooth connection is successful, the unlocking instruction is sent to the electronic lock corresponding to the electronic lock identification through the Bluetooth channel.
7. A terminal, characterized in that the terminal comprises: a bluetooth module, a network communication module, a first memory, a first processor, and a computer program stored on the first memory and executable on the first processor, wherein:
the computer program when executed by the first processor implementing the steps of:
when the first processor receives an unlocking instruction, the first processor acquires an electronic lock identifier corresponding to the unlocking instruction, wherein the unlocking instruction is actively triggered and/or automatically triggered by a terminal according to a user, and the terminal automatically triggers the unlocking instruction when the terminal detects that the distance between the terminal and the electronic lock is smaller than a preset distance;
when the Bluetooth is in an open state, the first processor sends the unlocking instruction to the electronic lock corresponding to the electronic lock identifier through the Bluetooth module and the network communication module in parallel, so that the electronic lock executes unlocking operation according to the unlocking instruction received firstly; receiving an unlocking result sent by the electronic lock, and judging whether the unlocking result is from the Bluetooth channel; when the unlocking result is from the Bluetooth channel, the unlocking result is fed back to the server so that the server marks the use state of the electronic lock according to the unlocking result, wherein when the unlocking result is unlocking failure, information of the unlocking failure is sent to the server so that the server can count the unlocking times of the electronic lock corresponding to the electronic lock identifier, and when the unlocking result is from the network channel, the terminal outputs the unlocking result for a user to check;
after the step of obtaining the electronic lock identifier corresponding to the unlocking instruction, the first processor further includes:
when the Bluetooth is in a closed state, judging whether a network signal exists at present;
when a network signal exists currently, the unlocking instruction is sent to a server through a network channel, so that the server broadcasts the unlocking instruction to the electronic lock corresponding to the electronic lock identifier through the Internet of things;
and when the Bluetooth connection is successful, the unlocking instruction is sent to the electronic lock corresponding to the electronic lock identification through the Bluetooth channel.
8. A computer storage medium, characterized in that the computer storage medium has stored thereon a computer program which, when being executed by a processor, carries out the steps of the electronic lock unlocking method according to any one of claims 1 to 4 or 5.
CN201910353734.0A 2019-04-29 2019-04-29 Electronic lock unlocking method, system, terminal, electronic lock and computer storage medium Active CN110070654B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201910353734.0A CN110070654B (en) 2019-04-29 2019-04-29 Electronic lock unlocking method, system, terminal, electronic lock and computer storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201910353734.0A CN110070654B (en) 2019-04-29 2019-04-29 Electronic lock unlocking method, system, terminal, electronic lock and computer storage medium

Publications (2)

Publication Number Publication Date
CN110070654A CN110070654A (en) 2019-07-30
CN110070654B true CN110070654B (en) 2022-01-11

Family

ID=67369539

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201910353734.0A Active CN110070654B (en) 2019-04-29 2019-04-29 Electronic lock unlocking method, system, terminal, electronic lock and computer storage medium

Country Status (1)

Country Link
CN (1) CN110070654B (en)

Families Citing this family (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111312206A (en) * 2019-12-23 2020-06-19 支付宝(杭州)信息技术有限公司 Information identification method and device based on voice, electronic equipment and system
CN111402460A (en) * 2020-02-27 2020-07-10 广东启正电子科技有限公司 Door lock opening method based on Internet of things
CN112124247B (en) * 2020-09-18 2022-04-22 上海钧正网络科技有限公司 Vehicle lock control method and device and computer readable storage medium
CN115131898B (en) * 2022-05-27 2024-02-02 江苏彩诚亿智能科技有限公司 Independent network information intercommunication method for electronic lock

Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN205942835U (en) * 2016-08-03 2017-02-08 赖炼坤 Wireless attendance security door lock
KR20170132061A (en) * 2016-05-23 2017-12-01 심한식 Indoor security device using the Internet of things
CN207458147U (en) * 2018-02-01 2018-06-05 哈尔滨理工大学 Multimode identification gate control system based on cloud security
CN108198285A (en) * 2017-12-21 2018-06-22 广东汇泰龙科技有限公司 One kind is based on bluetooth closely automatic safe method for unlocking and system
CN108391241A (en) * 2017-12-29 2018-08-10 上海挚想科技有限公司 control method and system
CN108447156A (en) * 2018-03-14 2018-08-24 广州科坦电子技术有限公司 A kind of hotel's smart lock
CN109493501A (en) * 2019-01-14 2019-03-19 深圳前海微众银行股份有限公司 Shopping cart electronic lock, shopping cart electronic lock management system and management method

Family Cites Families (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN108337273A (en) * 2017-01-18 2018-07-27 芜湖美的厨卫电器制造有限公司 Unlocking method, system and its equipment of leased equipment
CN109544732B (en) * 2018-10-17 2021-10-12 广州慧享佳物联科技有限公司 Electronic lock connection method and device, electronic equipment and storage medium

Patent Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
KR20170132061A (en) * 2016-05-23 2017-12-01 심한식 Indoor security device using the Internet of things
CN205942835U (en) * 2016-08-03 2017-02-08 赖炼坤 Wireless attendance security door lock
CN108198285A (en) * 2017-12-21 2018-06-22 广东汇泰龙科技有限公司 One kind is based on bluetooth closely automatic safe method for unlocking and system
CN108391241A (en) * 2017-12-29 2018-08-10 上海挚想科技有限公司 control method and system
CN207458147U (en) * 2018-02-01 2018-06-05 哈尔滨理工大学 Multimode identification gate control system based on cloud security
CN108447156A (en) * 2018-03-14 2018-08-24 广州科坦电子技术有限公司 A kind of hotel's smart lock
CN109493501A (en) * 2019-01-14 2019-03-19 深圳前海微众银行股份有限公司 Shopping cart electronic lock, shopping cart electronic lock management system and management method

Also Published As

Publication number Publication date
CN110070654A (en) 2019-07-30

Similar Documents

Publication Publication Date Title
CN110070654B (en) Electronic lock unlocking method, system, terminal, electronic lock and computer storage medium
CN111107667B (en) Bluetooth headset pairing method and device and readable storage medium
US20170019265A1 (en) Method, terminal and server for controlling smart device
US9510163B2 (en) Method and apparatus for managing a group profile in a Wi-Fi direct communication system
WO2020168569A1 (en) Intelligent device network distribution method, apparatus, electronic device and storage medium
CN110868748A (en) Intelligent equipment network access method, device, equipment, system and medium
CN104394263A (en) Accessing point list displaying method and device
CN105100190A (en) Methods, devices and system for managing control relation of account and device
CN104780155A (en) Method and device for binding equipment
KR102314690B1 (en) Device And Communication Connection Method Thereof
CN107318119B (en) Household appliance networking method, household appliance and computer readable storage medium
WO2019141130A1 (en) Payment method and terminal device
CN108733337B (en) Screen display method and device, electronic equipment and computer readable storage medium
EP3553672A1 (en) Information interaction method and device and computer readable storage medium thereof
CN111818499B (en) Quick pairing method, device, equipment and computer readable storage medium
US20150379322A1 (en) Method and apparatus for communication using fingerprint input
CN108199935B (en) Distribution network code display method, terminal, server and computer readable storage medium
CN113489630A (en) Network distribution method, device, storage medium and electronic terminal
CN110855534B (en) Method and apparatus for searching and controlling controllee in smart home system
CN113259942B (en) Connection method, connection device, electronic equipment, connection system and computer-readable storage medium
KR101921207B1 (en) Method and apparatus for performing function in mobile terminal using short range communication
JP2012039282A (en) Electronic apparatus, information display program for the same, and information display method for the same
CN110831114A (en) Connection method with wireless device, terminal and readable storage medium
CN112333054B (en) Device communication method, device and computer readable storage medium
CN105188155B (en) A kind of method and terminal of network connection

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