Disclosure of Invention
The invention mainly aims to provide a cloud talkback control method, a server and a talkback terminal, and aims to solve the technical problem of talkback limitation caused by distance limitation between interphones in the prior art.
In order to achieve the above object, the present invention provides a cloud intercom control method, including:
the method comprises the steps that when a server receives a call request sent by a first intercom terminal through a wide area network, first terminal information in the call request is obtained;
acquiring second terminal information according to the first terminal information, and establishing a conversation room;
sending a ringing instruction to a second talkback terminal corresponding to the second terminal information, wherein the second terminal outputs ringing information when receiving the ringing instruction, and sends answering notification information to the server when detecting an answering instruction;
and when receiving answering notification information sent by the second talkback terminal, adding the second talkback terminal and the first talkback terminal which are successfully answered into the conversation room for conversation.
Optionally, when the server receives a call request sent by a first intercom terminal through a wide area network, before the step of obtaining first terminal information in the call request, the cloud intercom control method further includes:
when a login request sent by a first talkback terminal is received, the first talkback terminal is verified;
and when the verification is successful, establishing communication between the server and the first talkback terminal, and updating the state of the first talkback terminal to be a login state.
Optionally, after the step of sending the ringing instruction to the second intercom terminal corresponding to the second terminal information, the method further includes:
changing the state of the second talkback terminal from an idle state to a busy state;
the step of sending the ringing instruction to the second intercom terminal corresponding to the second terminal information includes:
acquiring the state of each second talkback terminal corresponding to the second terminal information;
and sending the ringing instruction to the second talkback terminal in the idle state.
Optionally, the step of adding the second intercom terminal and the first intercom terminal that are answered successfully into the conversation room for conversation when receiving the answer notification information sent by the second intercom terminal includes:
when receiving answering notification information sent by the second talkback terminal, adding the second talkback terminal which successfully answers into the conversation room;
sending the answering notification information to the first intercom terminal;
and when receiving a session request for joining the session room sent by the first talkback terminal, joining the second talkback terminal into the session room for session.
Optionally, after the step of adding the second intercom terminal and the first intercom terminal that are successfully answered to the conversation room for conversation after receiving the answer notification information sent by the second intercom terminal, the cloud intercom control method further includes:
sending first terminal information of the first talkback terminal for the second talkback terminal to the second talkback terminal so that the second talkback terminal can update an address list according to the first terminal information;
when a call request sent by the second talkback terminal through the address list is received, a first talkback terminal corresponding to the pass request is obtained;
establishing a conversation room, and sending a ringing instruction to the first talkback terminal, wherein the first talkback terminal outputs ringing information when receiving the ringing instruction, and sends answering notification information to the server after a preset time length;
and when receiving answering notification information sent by the first talkback terminal, adding the first talkback terminal and the second talkback terminal which are successfully answered into the conversation room for conversation.
Optionally, the step of obtaining the second terminal information according to the first terminal information includes:
and acquiring the second terminal information according to the first terminal information and a preset configuration rule.
In addition, in order to achieve the above object, the present invention further provides a cloud intercom control method, including:
when receiving an intercom instruction, a first intercom terminal sends an intercom request comprising first terminal information to the server, so that the server sends a ringing instruction to a second terminal according to the intercom request;
and when receiving answering notification information sent by a server, sending a session request for joining a session room to the server, so that the server joins the first intercom terminal to the session room for session after receiving the session request.
Optionally, the step of sending an intercom request including the first terminal information to the server includes:
and after scanning information is obtained by scanning the two-dimensional code, sending the talkback request to the server according to first terminal information in the scanning information, wherein when the scanning information is detected, the talkback instruction is judged to be received.
In addition, in order to achieve the above object, the present invention further provides a server, where the server includes a first memory, a first processor, and a cloud intercom control program stored in the first memory and operable on the first processor, and the cloud intercom control program is executed by the first processor to perform the cloud intercom control method as described above.
In addition, in order to achieve the above object, the present invention further provides an intercom terminal, including a second memory, a second processor, and a cloud intercom control program stored in the second memory and operable on the second processor, wherein the cloud intercom control program is executed by the second processor to perform the cloud intercom control method.
According to the cloud talkback control method, the server and the talkback terminal, the first talkback terminal can initiate the call request through the wide area network, the server can call the corresponding second talkback terminal according to the information of the first talkback terminal, cloud end conversation between the first talkback terminal and the second talkback terminal is achieved, the limitation of the distance between the talkback terminals is avoided, and the application universality of talkback is improved.
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.
Referring to fig. 1, fig. 1 is a schematic view of an intercom system related to the cloud intercom control method of the present invention.
The intercom system in this embodiment at least includes a first intercom terminal, a server, and a second intercom terminal, where the first intercom terminal may be a parking lot host, a merchant host, a mobile terminal of a user, such as a mobile phone, a cell gate access, and the like, and the second intercom terminal may be a cloud intercom manager terminal, an attendant terminal, a cell management terminal, and the like. The first intercom terminal may communicate with the server through the gateway.
When the first talkback terminal is a mobile terminal, the mobile terminal can send a call request to the server in a mode of scanning the two-dimensional code, the two-dimensional code can comprise terminal information of the local talkback terminal and address information of the server, and the call request can be sent to the server through the address information of the server.
Referring to fig. 2, fig. 2 is a schematic diagram of a hardware architecture of a terminal device according to the present invention.
As shown in fig. 1, the terminal device according to this embodiment is a server or an intercom terminal, the terminal device in this embodiment includes amemory 110, aprocessor 120, and acommunication module 130, and thememory 110 may store a cloud intercom control program and a control system. Thecommunication module 130 in this embodiment is used for wide area network communication.
When the terminal device in this embodiment is an intercom terminal, the terminal device may further include a microphone and a camera, so as to facilitate interaction between the intercom terminals, and the intercom terminal may include a display screen for displaying video information transmitted by another intercom terminal.
When the terminal device in this embodiment is a server, the cloud intercom control program in thememory 110 implements the following steps when executed by the processor 120:
the method comprises the steps that when a server receives a call request sent by a first intercom terminal through a wide area network, first terminal information in the call request is obtained;
establishing a conversation room according to second terminal information related to the first terminal information;
sending a ringing instruction to a second talkback terminal corresponding to the second terminal information, wherein the second terminal outputs ringing information when receiving the ringing instruction, and sends answering notification information to the server when detecting an answering instruction;
and when receiving answering notification information sent by the second talkback terminal, adding the second talkback terminal and the first talkback terminal which are successfully answered into the conversation room for conversation.
When the terminal device in this embodiment is an intercom terminal, the cloud intercom control program in thememory 110 implements the following steps when executed by the processor 120:
when receiving an intercom instruction, a first intercom terminal sends an intercom request comprising first terminal information to the server, so that the server sends a ringing instruction to a second terminal according to the intercom request;
and when receiving answering notification information sent by a server, sending a session request for joining a session room to the server, so that the server joins the first intercom terminal to the session room for session after receiving the session request.
Example one
Referring to fig. 3, fig. 3 is a schematic flowchart of a first exemplary embodiment in which the cloud intercom control method of the present invention is applied to a server, and in this embodiment, when the cloud intercom control method is applied to the server, the cloud intercom control method includes:
step S10, when a server receives a call request sent by a first intercom terminal through a wide area network, first terminal information in the call request is obtained;
in this embodiment, the first intercom terminal sends the information to communicate with the server through a TCP/IP protocol, and the first terminal information may be an identifier of the first intercom terminal, such as an equipment identifier of the first intercom terminal or an address and an equipment identifier of the first intercom terminal, for example, No. 01 intercom terminal in a parking lot of a certain building, or the address may be a physical address or an IP address of the first intercom terminal.
Step S20, acquiring second terminal information according to the first terminal information, and establishing a conversation room;
in this embodiment, the first terminal information and the second terminal information may be associated in advance, that is, the first intercom terminal and the second intercom terminal are associated, for example, the second intercom terminal corresponding to the associated second terminal information may be a merchant management terminal when the first intercom terminal is a merchant; or the type of the first intercom terminal may also be obtained according to the first terminal information, and second terminal information corresponding to the type is obtained, for example, if the first intercom terminal is an intercom terminal in a parking lot, the corresponding second intercom terminal may be a management terminal corresponding to the parking lot, or a management terminal in the whole area.
In this embodiment, after the conversation room is established, a room number of the conversation room is generated, and the first terminal information and the second terminal information are associated after the room number is established, so that the first intercom terminal and the second intercom terminal are added to the conversation room corresponding to the associated room number in the following; or only generating the room number of the conversation room, and adding the first talkback terminal and the second talkback terminal to the conversation room in the idle state when the call between the first talkback terminal and the second talkback terminal is successful, namely the second talkback terminal answers the conversation of the first talkback terminal.
Step S30, sending a ringing instruction to a second intercom terminal corresponding to the second terminal information, where the second terminal outputs ringing information when receiving the ringing instruction, and sends an answering notification information to the server when detecting an answering instruction;
step S40, when receiving the answering notification information sent by the second intercom terminal, adding the second intercom terminal and the first intercom terminal that answer successfully into the conversation room for conversation.
After the server sends a ringing instruction to the second talkback terminal, the second talkback terminal performs ringing operation, for example, a buzzer of the second talkback terminal outputs a ringing tone, when the second talkback terminal receives an answering instruction, the second talkback terminal sends answering notification information to the server, and at the moment, the server can add the second talkback terminal to a conversation room; meanwhile, the server can send the answering notification information to the first talkback terminal, at the moment, the first talkback terminal sends a request for joining the conversation room when receiving the answering success information, and the server joins the first talkback terminal in the conversation room when receiving the request for joining the conversation room. Namely, step S30 includes: when receiving answering notification information sent by the second talkback terminal, adding the second talkback terminal which successfully answers into the conversation room; sending the answering notification information to the first intercom terminal; and when receiving a session request for joining the session room sent by the first talkback terminal, joining the second talkback terminal into the session room for session.
In the technical solution disclosed in this embodiment, the second intercom terminal may also reject, that is, after the second intercom terminal outputs the ringing information, if the second intercom terminal receives a rejection ringing, the second intercom terminal sends a rejection prompting message to the server, and when the server receives the rejection prompting message, the server sends a notification message of call failure to the first intercom terminal.
When the first terminal or the second terminal hangs up, the conversation room can be closed, that is, when a hang-up request sent by the first intercom terminal or the second intercom terminal is received, the conversation room is closed. When a hang-up request sent by a first talkback terminal is received, hang-up prompt information can be sent to a second talkback terminal and a conversation room is closed, and when the second talkback terminal receives the hang-up prompt information, a corresponding hang-up prompt, such as a prompt tone or a prompt interface, is output; the same reason for hanging up the second intercom terminal is not described herein again.
In the technical solution disclosed in this embodiment, the second intercom terminal may also actively call the corresponding first intercom terminal, and the principle is similar, which is not described herein again.
Referring to fig. 4, fig. 4 is a schematic flowchart of a first exemplary embodiment in which the cloud intercom control method of the present invention is applied to a first intercom terminal, and in this embodiment, when the cloud intercom control method is applied to the first intercom terminal, the cloud intercom control method includes:
step S50, when receiving an intercom instruction, the first intercom terminal sends an intercom request including first terminal information to the server, so that the server sends a ringing instruction to the second terminal according to the intercom request;
step S60, when receiving the answer notification information sent by the server, sending a session request for joining in a session room to the server, so that the server joins the first intercom terminal in the session room for a session after receiving the session request.
After the first talkback terminal and the second talkback terminal join a conversation room, the first talkback terminal and the second talkback terminal can carry out conversation, and after receiving the audio/video data sent by the first talkback terminal, the server sends the received audio/video data to the second talkback terminal in the conversation room where the first talkback terminal is located; similarly, after receiving the audio/video data sent by the second intercom terminal, the first intercom terminal in the conversation room where the second intercom terminal is located sends the received audio/video data.
It is to be understood that the first intercom terminal may set the state to the away state, that is, send away information to the server, and the server switches the state of the first terminal to the away state when receiving the away information.
The first talkback terminal in this embodiment may be a mobile terminal such as a mobile phone, the mobile terminal may call by scanning a two-dimensional code, and after scanning information is obtained by scanning the two-dimensional code, send the talkback request to the server according to first terminal information in the scanning information, for example, the mobile terminal scans a two-dimensional code pasted on the talkback terminal, and may directly generate the talkback request by scanning the obtained two-dimensional code and send the talkback request to the server, where the two-dimensional code may include first terminal information corresponding to the talkback terminal; or the first terminal information corresponding to the plurality of first intercom terminals can be acquired through the two-dimensional code, for example, the two-dimensional code includes the first terminal information of the first intercom terminals in the whole cell or parking lot, after the scanning information is obtained through scanning the two-dimensional code, a selection interface is displayed according to the scanning information, the selection interface includes the information of each first intercom terminal, and after a selection instruction of a user is detected, a call request is generated according to the selected first terminal information of the first intercom terminal and is sent to the server.
In the technical scheme disclosed in this embodiment, the first intercom terminal can initiate a call request through the wide area network, the server can call the corresponding second intercom terminal according to the information of the first intercom terminal, and the cloud end conversation between the first intercom terminal and the second intercom terminal is realized, so that the limitation of the distance between the intercom terminals is avoided, and the application universality of the intercom is improved.
Further, referring to fig. 5, a second embodiment of the cloud intercom control method according to the present invention is proposed based on the first embodiment, in this embodiment, when the cloud intercom control method is applied to a server, before step S10, the cloud intercom control method includes:
step S70, when receiving a login request sent by a first intercom terminal, verifying the first intercom terminal;
step S80, when the authentication is successful, establishing communication between the server and the first intercom terminal, and updating the state of the first intercom terminal to the login state.
The first intercom terminal needs to log in the server and perform authentication, the authentication mode may be an account and a password of the first intercom terminal, or may be a secret key negotiated in advance between the first intercom terminal and the server, and the specific method is not limited. After the first talkback terminal is connected with the server, the first talkback terminal can regularly send a detection packet to the server to determine the network connection state between the first talkback terminal and the server and determine whether the first talkback terminal is disconnected with the server according to the network connection state, when the first talkback terminal is disconnected with the server, the first talkback terminal can try to reconnect the server, and when the reconnection with the server fails, the first talkback terminal can output prompt information of disconnection; when the server does not receive the detection data packet sent by the first talkback terminal within the preset time interval, the first talkback terminal is considered to be disconnected, at the moment, the state of the first talkback terminal can be updated to be a disconnected state, and prompt information of disconnection of the first talkback terminal can be sent to the corresponding management terminal, so that the first talkback terminal can be maintained conveniently.
It can be understood that, when receiving the answering notification information sent by the second intercom terminal, joining the second intercom terminal with successful ringing into the conversation room; sending the answering notification information to the first intercom terminal; and when receiving a session request for joining the session room sent by the first talkback terminal, joining the second talkback terminal into the session room for session.
In the technical scheme disclosed in this embodiment, the first intercom terminal may also log off, that is, the first intercom terminal sends a logout request to the service, and the server updates the state of the first intercom terminal to the non-logged-on state when receiving the logout request.
In the technical scheme disclosed by the embodiment, the first intercom terminal can log in the server in advance, and can make a call after logging in the server; the identity of the first talkback terminal is verified during login, and safety is improved.
Further, a third embodiment of the cloud intercom control method according to the present invention is proposed based on the first or second embodiment, and in this embodiment, when the cloud intercom control method is applied to a server in this embodiment, after step S30, the cloud intercom control method includes:
changing the state of the second talkback terminal from an idle state to a busy state;
step S30 includes:
acquiring the state of each second talkback terminal corresponding to the second terminal information;
and sending the ringing instruction to the second talkback terminal in the idle state.
The server receives the answering notification information sent by the second talkback terminal, and then changes the state of the second talkback terminal sending the answering notification information into a busy state; when a call request of a first talkback terminal is received, the state of a second talkback terminal corresponding to the first talkback terminal can be acquired, and when the state of the second talkback terminal is an idle state, a ringing instruction is sent to the idle second talkback terminal; when the states of all the second talkback terminals are not busy, sending waiting prompt information to the first talkback terminal, re-determining the states of all the second talkback terminals after waiting for a preset time interval, and sending prompt information of call failure to the first talkback terminal when the states of the second talkback terminals are still busy; or, when all the second talkback terminals are busy, sending prompt information of call failure to the first talkback terminal; or, when all the second talkback terminals are busy, sending the call information to the management terminal so that the management terminal and the first talkback terminal can carry out conversation.
In this embodiment, an emergency call button may be set in the first intercom terminal, the emergency call request may be sent through the emergency call button, and when the server receives the emergency call request, and if all the second intercom terminals are busy, the server may send call information to the management terminal or disconnect a call of a certain second intercom terminal in a busy state, so as to establish a call with the first intercom terminal.
In the technical scheme disclosed in this embodiment, when receiving the call request of the first intercom terminal, the server only calls the second intercom terminal in the idle state, so that the communication is more stable.
Further, a fourth embodiment of the cloud intercom control method according to the present invention is provided based on any one of the first to third embodiments, and in this embodiment, when the cloud intercom control method is applied to a server, the step S30 is followed by further including:
sending first terminal information of the first talkback terminal for the second talkback terminal to the second talkback terminal so that the second talkback terminal can update an address list according to the first terminal information;
when a call request sent by the second talkback terminal through the address list is received, a first talkback terminal corresponding to the pass request is obtained;
establishing a conversation room, and sending a ringing instruction to the first talkback terminal, wherein the first talkback terminal outputs ringing information when receiving the ringing instruction, and sends answering notification information to the server after a preset time length;
and when receiving answering notification information sent by the first talkback terminal, adding the first talkback terminal and the second talkback terminal which are successfully answered into the conversation room for conversation.
In this embodiment, the address book may be displayed at the second intercom terminal, the status of each first intercom terminal may be displayed in the address book, and when the status of the first intercom terminal is abnormal, the abnormal first intercom terminal may be called through the address book; or when the first talkback terminal needs to be called, the corresponding first talkback terminal is called. The address book of the second intercom terminal may include information of the first intercom terminal that passes through the address book, such as an identifier of the first intercom terminal, and the identifier of the first intercom terminal is stored in association with the call address of the first intercom terminal.
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 an … …" does not exclude the presence of other like elements in a process, method, article, or system that comprises the element.
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) and includes instructions for enabling a terminal device (e.g., a mobile phone, a computer, a server, a controlled terminal, or a network device) to execute the method of each embodiment 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.