Voice intercom method and device of camera, computer equipment and storage medium

By negotiating intercom mode with the camera when the camera is connected to the target platform, and sending audio data based on the matching mode, the compatibility problem of camera voice intercom functions of different manufacturers is solved, and the effect of simplifying configuration and improving compatibility is achieved.

CN119496867AActive Publication Date: 2025-02-21CHINA TELECOM CLOUD TECH CO LTD
View PDF 6 Cites 0 Cited by

Patent Information

Application Number
CN202411652197.7
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-11-19
Publication Date
2025-02-21
Estimated Expiration
2044-11-19

AI Technical Summary

Technical Problem

Cameras from different manufacturers have compatibility problems when implementing voice intercom functions, which leads to complex adaptation and configuration of video surveillance platforms when connecting to third-party cameras, which increases the complexity of the system and maintenance costs.

Method used

When the camera connects to the target platform, the server sends a data packet carrying the target identifier to the camera. If the return data packet is received, it is determined that the intercom mode is the first mode; if the return data packet is not received, the carrying target will be sent. If the return packet is received for the address information, the intercom mode is determined to be the second mode. Based on the matching intercom mode, audio data packaged by the target communication protocol is sent to the camera.

Benefits of technology

It simplifies the camera configuration process, improves the compatibility between the camera and the platform, reduces the possibility of manual intervention and configuration errors, improves the reliability and stability of the system, and reduces operation and maintenance costs.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119496867A_ABST
    Figure CN119496867A_ABST
Patent Text Reader

Abstract

The invention relates to a voice talkback method and device of a camera, computer equipment and a storage medium. The method comprises the following steps: when a camera accesses a target platform, a server corresponding to the target platform sends a first data packet carrying a target identifier to the camera; if a return data packet carrying the target identifier is received through the first port, determining a talkback mode matched with the camera as a first talkback mode; if the return data packet carrying the target identifier is not received at the first port, a second data packet carrying target address information is sent to the camera, and if the return data packet sent by the camera based on the target address information is received, the talkback mode matched with the camera is determined to be a second talkback mode; and sending the audio data packaged by the target communication protocol to the camera based on the intercom mode matched with the camera. By adopting the method, the talkback mode which can be supported by the camera can be automatically adapted, so that the configuration of the camera can be simplified.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the field of communication technology, and in particular to a method, device, computer equipment, computer-readable storage medium and computer program product for voice intercom of a camera. Background Art

[0002] With the development of Internet technology, video surveillance technology has emerged. Video surveillance technology is widely used in security, management, transportation and other fields to monitor and record on-site conditions in real time. With the development of technology, video surveillance systems not only need to provide high-quality video images, but also need to realize voice intercom functions so that real-time voice communication and command can be carried out in emergency situations.

[0003] However, different manufacturers have different implementation rules for the intercom function of cameras, resulting in compatibility issues in actual applications. As a result, the video surveillance platform needs to perform complex adaptation and configuration work when incorporating a large number of third-party surveillance cameras, which increases the complexity and maintenance costs of the system. Summary of the invention

[0004] Based on this, it is necessary to provide a camera voice intercom method, device, computer equipment, computer-readable storage medium and computer program product that can simplify the camera configuration process and thus improve the compatibility of the platform connected to the camera in order to solve the above technical problems.

[0005] In a first aspect, the present application provides a camera voice intercom method, comprising:

[0006] When the camera is connected to the target platform, the server corresponding to the target platform sends a first data packet carrying a target identifier to the camera;

[0007] If a return data packet carrying the target identifier is received through the first port, it is determined that the intercom mode matched by the camera is the first intercom mode, and the first intercom mode communicates with the camera through the first port;

[0008] If the return data packet carrying the target identifier is not received at the first port, a second data packet carrying the target address information is sent to the camera, and if a return data packet sent by the camera based on the target address information is received, it is determined that the intercom mode matched by the camera is the second intercom mode, and the second intercom mode communicates with the camera through the second port;

[0009] Based on the intercom mode matched by the camera, audio data packaged in a target communication protocol is sent to the camera, so that the camera receives the audio data and plays the voice corresponding to the audio data.

[0010] In one embodiment, when a camera is connected to a target platform, a step in which a server corresponding to the target platform sends a first data packet carrying a target identifier to the camera includes:

[0011] When the camera is connected to the target platform, the server generates the target identifier;

[0012] Creating a session establishment request data packet carrying the target identifier;

[0013] The session establishment request data packet is sent to the camera via the SIP protocol.

[0014] In one embodiment, the target identifier is a synchronization source identifier.

[0015] In one embodiment, the step of sending a second data packet carrying target address information to the camera includes:

[0016] Creating a session establishment request data packet carrying the target address information;

[0017] Sending the session establishment request data packet to the camera via the SIP protocol;

[0018] The step of receiving a return data packet sent by the camera based on the target address information comprises:

[0019] A TCP link establishment request data packet carrying the target address information is received from the camera.

[0020] In one embodiment, the steps after receiving the TCP link establishment request data packet carrying the target address information from the camera include:

[0021] Obtaining the address of the camera based on the TCP link establishment request data packet;

[0022] A separate target intercom port is allocated to the camera to send the audio data to the address of the camera through the target intercom port.

[0023] In one of the embodiments, the audio payload data corresponding to the audio data is an integer number of audio coding frames, and the audio bit stream corresponding to the audio data complies with the target coding standard.

[0024] In one embodiment, the step of sending audio data packaged in a target communication protocol to the camera so that the camera receives the audio data and plays the voice corresponding to the audio data includes:

[0025] Get the device type of the camera;

[0026] determining a data format of the audio data based on the device type;

[0027] The audio data in the data format packaged by the RTP protocol is sent to the camera, so that the camera can play the voice corresponding to the audio data when receiving the audio data in the data format.

[0028] In a second aspect, the present application also provides a camera voice intercom device, comprising:

[0029] A first determination module is used for, when the camera is connected to a target platform, the server corresponding to the target platform sends a first data packet carrying a target identifier to the camera; if a return data packet carrying the target identifier is received through the first port, then determining that the intercom mode matched by the camera is the first intercom mode, and the first intercom mode communicates with the camera through the first port;

[0030] a second determination module, configured to send a second data packet carrying target address information to the camera if the return data packet carrying the target identifier is not received at the first port, and to determine that the intercom mode matched by the camera is the second intercom mode if the return data packet sent by the camera based on the target address information is received, and the second intercom mode communicates with the camera through the second port;

[0031] The intercom module is used to send audio data packaged in a target communication protocol to the camera based on the intercom mode matched by the camera, so that the camera receives the audio data and plays the voice corresponding to the audio data.

[0032] In a third aspect, the present application further provides a computer device, including a memory and a processor, wherein the memory stores a computer program, and when the processor executes the computer program, the following steps are implemented:

[0033] When the camera is connected to the target platform, the server corresponding to the target platform sends a first data packet carrying a target identifier to the camera;

[0034] If a return data packet carrying the target identifier is received through the first port, it is determined that the intercom mode matched by the camera is the first intercom mode, and the first intercom mode communicates with the camera through the first port;

[0035] If the return data packet carrying the target identifier is not received at the first port, a second data packet carrying the target address information is sent to the camera, and if a return data packet sent by the camera based on the target address information is received, it is determined that the intercom mode matched by the camera is the second intercom mode, and the second intercom mode communicates with the camera through the second port;

[0036] Based on the intercom mode matched by the camera, audio data packaged in a target communication protocol is sent to the camera, so that the camera receives the audio data and plays the voice corresponding to the audio data.

[0037] In a fourth aspect, the present application further provides a computer-readable storage medium having a computer program stored thereon, wherein when the computer program is executed by a processor, the following steps are implemented:

[0038] When the camera is connected to the target platform, the server corresponding to the target platform sends a first data packet carrying a target identifier to the camera;

[0039] If a return data packet carrying the target identifier is received through the first port, it is determined that the intercom mode matched by the camera is the first intercom mode, and the first intercom mode communicates with the camera through the first port;

[0040] If the return data packet carrying the target identifier is not received at the first port, a second data packet carrying the target address information is sent to the camera, and if a return data packet sent by the camera based on the target address information is received, it is determined that the intercom mode matched by the camera is the second intercom mode, and the second intercom mode communicates with the camera through the second port;

[0041] Based on the intercom mode matched by the camera, audio data packaged in a target communication protocol is sent to the camera, so that the camera receives the audio data and plays the voice corresponding to the audio data.

[0042] In a fifth aspect, the present application further provides a computer program product, including a computer program, which implements the following steps when executed by a processor:

[0043] When the camera is connected to the target platform, the server corresponding to the target platform sends a first data packet carrying a target identifier to the camera;

[0044] If a return data packet carrying the target identifier is received through the first port, it is determined that the intercom mode matched by the camera is the first intercom mode, and the first intercom mode communicates with the camera through the first port;

[0045] If the return data packet carrying the target identifier is not received at the first port, a second data packet carrying the target address information is sent to the camera, and if a return data packet sent by the camera based on the target address information is received, it is determined that the intercom mode matched by the camera is the second intercom mode, and the second intercom mode communicates with the camera through the second port;

[0046] Based on the intercom mode matched by the camera, audio data packaged in a target communication protocol is sent to the camera, so that the camera receives the audio data and plays the voice corresponding to the audio data.

[0047] The above-mentioned voice intercom method, device, computer equipment, computer-readable storage medium and computer program product of the camera, when the camera is connected to the target platform, the server corresponding to the target platform sends a first data packet carrying a target identifier to the camera. If a return data packet carrying a target identifier is received through the first port, it is determined that the intercom mode matched by the camera is the first intercom mode. If the return data packet carrying the target identifier is not received at the first port, a second data packet carrying target address information is sent to the camera. If a return data packet sent by the camera based on the target address information is received, it is determined that the intercom mode matched by the camera is the second intercom mode. In this way, after the camera is connected to the target platform, it is attempted to determine which of the two intercom modes the intercom mode supported by the camera belongs to. Compared with obtaining detailed information of the camera to perform complex adaptation and configuration on each camera, it can simplify the configuration process required for the camera to access the target platform, and can adapt the intercom mode of cameras in the sound fields of different manufacturers, thereby improving the compatibility of the platform, reducing the possibility of manual intervention and configuration errors, improving the reliability and stability of the target platform, and reducing operation and maintenance costs. BRIEF DESCRIPTION OF THE DRAWINGS

[0048] In order to more clearly illustrate the technical solutions in the embodiments of the present application or related technologies, the drawings required for use in the embodiments of the present application or related technical descriptions will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present application. For ordinary technicians in this field, other related drawings can be obtained based on these drawings without paying creative work.

[0049] FIG1 is a diagram showing an application environment of a voice intercom method using a camera in one embodiment;

[0050] FIG2 is a schematic flow chart of a method for voice intercom using a camera in one embodiment;

[0051] FIG3 is a schematic flow chart of a first intercom mode matching step in one embodiment;

[0052] FIG4 is a schematic flow chart of a second intercom mode matching step in one embodiment;

[0053] FIG5 is a schematic flow chart of a voice intercom step in a first intercom mode according to an embodiment;

[0054] FIG6 is a schematic flow chart of a voice intercom step in a second intercom mode according to an embodiment;

[0055] FIG7 is a structural block diagram of a voice intercom device of a camera in one embodiment;

[0056] FIG. 8 is a diagram showing the internal structure of a computer device in one embodiment. DETAILED DESCRIPTION

[0057] In order to make the purpose, technical solution and advantages of the present application more clearly understood, the present application is further described in detail below in conjunction with the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are only used to explain the present application and are not used to limit the present application.

[0058] The voice intercom method of the camera provided in the embodiment of the present application can be applied to the application environment shown in Figure 1. Among them, the terminal 102 communicates with the server 104 through the network. The data storage system can store the data that the server 104 needs to process. The data storage system can be integrated on the server 104, or it can be placed on the cloud or other network servers. The terminal and the server constitute a target platform. The target platform can connect multiple cameras 106 to manage these cameras 106 in a unified manner. When the camera 106 is connected to the target platform, the server 104 corresponding to the target platform sends a first data packet carrying a target identifier to the camera 106. If a return data packet carrying a target identifier is received through the first port, it is determined that the intercom mode matched by the camera 106 is the first intercom mode. If a return data packet carrying a target identifier is not received at the first port, a second data packet carrying target address information is sent to the camera 106. If a return data packet sent by the camera 106 based on the target address information is received, it is determined that the intercom mode matched by the camera 106 is the second intercom mode. After determining the intercom mode corresponding to the camera 106, the server 104 can send the audio data packaged by the target communication protocol to the camera 106 based on the intercom mode matched by the camera 106, so that the camera 106 receives the audio data and plays the voice corresponding to the audio data. Among them, the terminal 102 can be, but is not limited to, various personal computers, laptops, smart phones, and tablet computers. The server 104 can be an independent physical server, a server cluster or a distributed system composed of multiple physical servers, or a cloud server that provides cloud computing services.

[0059] In an exemplary embodiment, as shown in FIG2 , a method for voice intercom of a camera is provided, and the method is applied to the server in FIG1 as an example for description, and includes the following steps 202 to 208 . Among them:

[0060] Step 202: When the camera is connected to the target platform, the server corresponding to the target platform sends a first data packet carrying a target identifier to the camera.

[0061] Among them, the target platform is used for unified management of multiple cameras. The target platform can realize functions such as live broadcast, cloud recording, and intercom of the camera. For cameras connected to the network, in order to communicate with them (such as data transmission), it is usually necessary to know the address of the camera in the network, such as the IP address and port number. Therefore, when the camera is connected to the target platform, the server corresponding to the target platform can try to send a data packet to the network. If a data packet based on the response of the camera is received, the address of the camera can be obtained by parsing the response data packet. And when a data packet based on the response of the camera is received, it means that the transmission protocol used by the server to send data to the camera is also supported by the camera. Therefore, the audio data can be sent to the address previously parsed through the transmission protocol in the future, so that the voice intercom between the target platform and the camera can be realized.

[0062] The server supports two intercom modes, a first intercom mode and a second intercom mode. The first intercom mode is an intercom mode based on a target identifier, and the second intercom mode is an intercom mode based on target address information.

[0063] For the first intercom mode, the server sends a first data packet carrying a target identifier to the camera. If the camera supports the first intercom mode, the camera will send a response data packet to the server after receiving the first data packet. The response data packet carries the target identifier and the address information of the camera. Therefore, when the server receives the response data packet, it can obtain the address information of the camera. After that, the server can communicate with the camera through the first intercom mode and the address information of the camera.

[0064] For the second intercom mode, the server sends a second data packet carrying the target address information to the camera. Since the target address information is the address information of the server, the camera can send a data packet to the server based on the target address information after receiving the target address information, thereby establishing a communication connection with the server, and then the server can communicate with the camera through the established communication connection.

[0065] Exemplarily, when the camera is connected to the target platform, the server may first try to establish a connection with the camera in the first intercom mode. Specifically, the server may send a first data packet carrying a target identifier to the camera. Optionally, the target identifier may be an SSRC (Synchronization Source Identifier). If the camera supports the first intercom mode, the communication data packet between the camera and the server will carry the SSRC. In this way, the server can determine the address information of the camera through the SSRC carried in the data packet, thereby realizing intercom with the camera.

[0066] Step 204: If a return data packet carrying a target identifier is received through the first port, it is determined that the intercom mode matched by the camera is the first intercom mode.

[0067] Among them, the first intercom mode communicates with the camera through the first port.

[0068] In some embodiments, the server may include an intercom server. When the camera accesses the target platform, the server generates an identifier and sends the target identifier to the intercom server and the camera. Optionally, the server may send an Invite request to the camera via the SIP protocol. The Invite request carries the target identifier. After the camera receives the Invite request, it sends a response data packet to the intercom server according to the given target identifier. If the intercom server receives a response data packet carrying the target identifier at the first port, and the target identifier is the identifier generated above. The intercom server can then communicate with the camera through an intercom based on the address information parsed from the response data packet.

[0069] Step 206, if no return data packet carrying the target identifier is received at the first port, a second data packet carrying the target address information is sent to the camera. If a return data packet sent by the camera based on the target address information is received, it is determined that the intercom mode matched by the camera is the second intercom mode.

[0070] The second intercom mode communicates with the camera through the second port.

[0071] Since not all cameras can support the RTP transmission protocol or the intercom mode based on the target identifier, for such cameras, you need to try the second intercom mode to communicate with them. Since the second intercom mode uses a common network transmission protocol such as TCP, cameras that cannot use the first intercom mode can usually use the second intercom mode for intercom.

[0072] In some embodiments, the server can send an Invite request to the camera through the SIP protocol to inform the camera of the address information of the intercom server (i.e., the target address information). After receiving the Invite request, the camera actively sends a TCP link establishment request to the intercom server. After receiving the TCP link establishment request from the camera, the intercom server allocates a separate intercom port to the camera. In this way, the intercom server can intercom with the camera through the allocated separate intercom port.

[0073] Step 208, based on the intercom mode matched by the camera, the audio data packaged in the target communication protocol is sent to the camera, so that the camera receives the audio data and plays the voice corresponding to the audio data.

[0074] After the above steps, the server has learned the address information of the camera and the intercom mode supported by the camera. The intercom mode supported by the camera can be stored in the server as the tag information of the camera. The server can then send the audio data packaged by the target communication protocol to the camera based on the intercom mode matched by the camera, so that the camera can receive the audio data and play the voice corresponding to the audio data.

[0075] The target communication protocol may be an RTP communication protocol. For both intercom modes, the target communication protocol is used to package the audio data. In this way, the intercom rules can be unified, so that different devices can communicate with each other in a standardized manner, thereby simplifying the compatibility issues of voice intercom.

[0076] In the above-mentioned voice intercom method for the camera, when the camera is connected to the target platform, the server corresponding to the target platform sends a first data packet carrying a target identifier to the camera. If a return data packet carrying a target identifier is received through the first port, it is determined that the intercom mode matched by the camera is the first intercom mode. If the return data packet carrying the target identifier is not received at the first port, a second data packet carrying the target address information is sent to the camera. If a return data packet sent by the camera based on the target address information is received, it is determined that the intercom mode matched by the camera is the second intercom mode. In this way, after the camera is connected to the target platform, an attempt is made to determine which of the two intercom modes the intercom mode supported by the camera belongs to. Compared with obtaining detailed information of the camera to perform complex adaptation and configuration on each camera, it can simplify the configuration process required for the camera to access the target platform, and can adapt the intercom mode of cameras in the sound fields of different manufacturers, thereby improving the compatibility of the platform, reducing the possibility of manual intervention and configuration errors, improving the reliability and stability of the target platform, and reducing operation and maintenance costs.

[0077] In an exemplary embodiment, as shown in FIG3 , when the camera is connected to the target platform, the step of the server corresponding to the target platform sending the first data carrying the target identifier to the camera includes steps 302 to 306. Among them:

[0078] Step 302: When the camera is connected to the target platform, the server generates a target identifier.

[0079] Step 304: Create a session establishment request data packet carrying a target identifier.

[0080] Step 306: Send a session establishment request data packet to the camera via the SIP protocol.

[0081] The target identifier may be a synchronization source identifier. In this way, the server can identify whether the corresponding target identifier exists in the received data packet. If so, it can be determined that the camera supports the first intercom mode and the address information of the camera can be obtained by parsing the received data packet.

[0082] The SIP protocol (Session initialization Protocol) is a network communication protocol and is the basis of modern interactive communication on the Internet. The session establishment request data packet may be, for example, the Invite request data packet mentioned above.

[0083] Exemplarily, when the camera is connected to the target platform, the server generates a target identifier, sends the target identifier to the camera through a session establishment request data packet, and sends the target identifier to the intercom server. Afterwards, the intercom server analyzes the identifier carried in the received data packet at the first port to determine whether it is the target identifier.

[0084] In this embodiment, by generating a target identifier and creating a session establishment request data packet carrying the target identifier, and then sending the session establishment request data packet to the camera through the SIP protocol, the intercom service in the server can determine the address information and supported intercom modes of the camera based on the target identifier, thereby determining the voice intercom mode supported by the camera through matching, thereby simplifying the problem of configuring the device.

[0085] In some embodiments, as shown in FIG. 4 , the step of sending a second data packet carrying target address information to the camera includes:

[0086] Step S402: Create a session establishment request data packet carrying target address information.

[0087] Step S404: Send a session establishment request data packet to the camera via the SIP protocol.

[0088] Step S406: receiving a TCP link establishment request data packet carrying target address information from the camera.

[0089] Among them, the target address information may be the address information of the server. Optionally, the target address information may be the address information of the intercom server. The second data packet is sent based on the TCP protocol. The second intercom mode may be an intercom mode based on TCP link establishment. In order to establish intercom communication between the camera and the server, the server may establish a session request data packet to the camera through the SIP protocol, wherein the session establishment request data packet carries the target address information. In this way, after receiving the session establishment request data packet, the camera may send a TCP link establishment request to the intercom server. After receiving the TCP link establishment request, the intercom server allocates a separate intercom port for intercom communication with the camera.

[0090] In this embodiment, a session establishment request data packet carrying the target address information is created, and a session establishment request data packet is sent to the camera through the SIP protocol. After the camera receives the session establishment request data packet, the server will receive the TCP link establishment request sent by the camera. In this way, the intercom server can obtain the address information of the camera and the information that the camera supports the second intercom mode, which facilitates the subsequent intercom server to communicate with the camera directly based on the address information of the camera and the intercom rules corresponding to the second intercom mode. In this way, the complex configuration process of the camera can be simplified, and the configuration of the camera can be completed by selecting the intercom mode that matches the camera from the two intercom modes.

[0091] In some embodiments, after the server obtains the address of the camera based on the TCP link establishment request data packet, it allocates a separate target intercom port to the camera to send audio data to the address of the camera through the target intercom port. Through the above steps, the server can perform reliable intercom communication with the camera, and communicate with the camera through a separate target intercom port, which can also improve the communication efficiency and communication quality of the camera intercom.

[0092] As mentioned above, the server uses the target communication protocol to package the audio data sent to the camera. The target communication protocol may be, for example, the RTP communication protocol. The packaging rule may be that the audio payload data corresponding to the audio data is an integer number of audio coding frames, and the audio bit stream corresponding to the audio data complies with the target coding standard. For example, the time length of the audio payload data is between 20 milliseconds and 180 milliseconds. For example, the time length of the audio payload data is 100 milliseconds or 80 milliseconds. By unifying the format of sending audio data, the communication between the camera and the server can meet the standard, thereby improving the reliability of the server in voice intercom.

[0093] In some embodiments, since the rules for parsing audio data by cameras configured by various manufacturers are different, some format processing of the audio data is required. When matching the intercom mode of the camera, the server can also learn the manufacturer to which the camera belongs or the device type of the camera. For some device types, the corresponding data packet that can be parsed may be in the first format. For other device types, the corresponding data packet that can be parsed may be in the second format. Since the target communication protocol is the RTP protocol, the first format may be to add the RTP data header. The second format may be without the RTP data header. Optionally, the first format also needs to add two bytes of RTP packet length, and the second format does not need to add two bytes of RTP packet length. Exemplarily, before sending audio data to the camera, the server first obtains the device type of the camera; determines the data format of the audio data based on the device type; and sends audio data in a data format packaged by the RTP protocol to the camera, so that the camera can play the voice corresponding to the audio data when receiving the audio data in the data format.

[0094] The data format is selected from the first format or the second format, so that the audio data can adapt to the camera's data parsing rules, so that the camera can parse the audio data sent by the server to play the corresponding voice normally.

[0095] In an exemplary embodiment, the target platform corresponding to the voice intercom method of the camera is composed of the following parts.

[0096] (1) Video surveillance terminal: responsible for collecting audio data from the client and encrypting it before sending it to the voice intercom gateway.

[0097] (2) Voice intercom gateway: Receives and decrypts audio data, and sends the decrypted audio data to the intercom service.

[0098] (3) Intercom service: responsible for processing and distributing audio data. Receive the RTP packet from the camera and parse the SSRC to find the corresponding intercom device or receive the TCP link. Find the corresponding matching camera through the fixed port and parse the IP and port information of the camera. Send audio data to the camera based on the parsed IP and port information of the camera.

[0099] (4) Camera: A camera provided by a third-party manufacturer that supports different intercom functions and is responsible for receiving and playing audio data.

[0100] In order to be able to conduct voice intercom with the camera, as shown in Figure 5, when the camera is connected to the target platform, the server generates a target identifier; creates a session establishment request packet carrying the target identifier; and sends a session establishment request packet to the camera through the SIP protocol. If a return packet carrying the target identifier is received through the first port, it is determined that the intercom mode matched by the camera is the first intercom mode, and the first intercom mode communicates with the camera through the first port. For example, the video surveillance platform initiates an Invite request to the camera through the SIP protocol, carrying a predetermined SSRC. After receiving the Invite request, the camera sends an RTP packet to the intercom service according to the given SSRC. After receiving the RTP packet at its fixed intercom port, the intercom service parses the SSRC in the RTP header. If the parsed SSRC matches the device that has started the intercom, it is determined that the camera matches the first intercom mode.

[0101] If the return data packet carrying the target identifier is not received on the first port, a session establishment request data packet carrying the target address information is created (see Figure 6). A session establishment request data packet is sent to the camera via the SIP protocol; if a TCP link establishment request data packet carrying the target address information is received from the camera, the intercom mode matched by the camera is determined to be the second intercom mode, and the second intercom mode communicates with the camera via the second port. For example, the video surveillance platform initiates an Invite request to the camera via the SIP protocol, informing the camera of the receiving IP and port of the intercom service (for example, 192.168.1.100:5000). After receiving the Invite request, the camera actively sends a TCP link establishment request to the intercom service. After receiving the TCP link establishment request from the camera, the intercom service allocates a separate intercom port (for example, 6000) to the camera. After receiving the TCP link establishment request at a specific port, the intercom service parses the exit IP and port of the camera. In this way, it can be determined that the intercom mode matched by the camera is the second intercom mode.

[0102] After knowing the intercom mode matched by the camera, the server, that is, the intercom service, sends the audio data packaged by the target communication protocol to the camera based on the intercom mode matched by the camera, so that the camera receives the audio data and plays the voice corresponding to the audio data. Regardless of which intercom mode is used, the intercom service packages the audio data into RTP packets and sends them to the camera. The specific processing process is as follows: The audio data collected by the front-end device (the sound receiving device connected to the video surveillance platform) is transmitted to the video surveillance platform. The video surveillance platform encrypts the collected audio data and sends it to the voice intercom gateway. After receiving the encrypted audio data, the voice intercom gateway decrypts it and sends the decrypted data to the intercom service. The intercom service packages the audio data according to the RTP protocol according to the pre-configured RTP packaging rules. The audio payload data should be an integer number of audio coding frames, and the time length should be between 20ms and 180ms. The packaged RTP packet is transmitted to the target camera through the network.

[0103] In addition, different types of cameras have different ways of processing audio data. For the first type of camera, an RTP header and a 2-byte RTP packet length are required. For the second type of camera, the RTP header and the 2-byte length are not required to make normal sounds. When sending audio data, the intercom service in the server dynamically adjusts the data format according to the type of camera to ensure that the audio data can be correctly received and played by the camera.

[0104] Through the above steps, it is possible to support dynamic expansion of intercom functions according to device types. For different types of cameras, the processing logic of the intercom service can be dynamically adjusted according to the intercom functions and audio data receiving and processing methods they support, ensuring that the system can adapt to camera devices from more manufacturers. This solves the compatibility issues existing in the existing system, simplifies the system adaptation and configuration process, improves the system stability and user experience, and provides an efficient and reliable intelligent voice intercom solution for video surveillance systems.

[0105] It should be understood that, although the steps in the flowcharts involved in the above embodiments are displayed in sequence according to the indication of the arrows, these steps are not necessarily executed in sequence according to the order indicated by the arrows. Unless there is a clear explanation in this article, the execution of these steps is not strictly limited in order, and these steps can be executed in other orders. Moreover, at least a part of the steps in the flowcharts involved in the above embodiments may include multiple steps or multiple stages, and these steps or stages are not necessarily executed at the same time, but can be executed at different times, and the execution order of these steps or stages is not necessarily carried out in sequence, but can be executed in turn or alternately with other steps or at least a part of the steps or stages in other steps.

[0106] Based on the same inventive concept, the embodiment of the present application also provides a camera voice intercom device 700 for implementing the above-mentioned camera voice intercom method. The implementation scheme for solving the problem provided by the device is similar to the implementation scheme recorded in the above-mentioned method, so the specific limitations in the embodiments of the one or more camera voice intercom device provided below can refer to the limitations of the camera voice intercom method above, and will not be repeated here.

[0107] In an exemplary embodiment, as shown in FIG. 7 , a voice intercom device for a camera is provided, comprising: a first determination module 701, a second determination module 702 and an intercom module 703, wherein:

[0108] The first determination module 701 is used for, when the camera is connected to the target platform, the server corresponding to the target platform sends a first data packet carrying a target identifier to the camera; if a return data packet carrying the target identifier is received through the first port, it is determined that the intercom mode matched by the camera is the first intercom mode, and the first intercom mode communicates with the camera through the first port;

[0109] The second determination module 702 is used for sending a second data packet carrying target address information to the camera if no return data packet carrying the target identifier is received at the first port, and determining that the intercom mode matched by the camera is the second intercom mode if a return data packet sent by the camera based on the target address information is received, and the second intercom mode communicates with the camera through the second port;

[0110] The intercom module 703 is used to send audio data packaged in a target communication protocol to the camera based on the intercom mode matched by the camera, so that the camera receives the audio data and plays the voice corresponding to the audio data.

[0111] In some embodiments, the first determination module is further used for: when the camera is connected to the target platform, the server generates a target identifier; creates a session establishment request data packet carrying the target identifier; and sends the session establishment request data packet to the camera via the SIP protocol.

[0112] In some embodiments, the second determination module 702 is further used to create a session establishment request packet carrying target address information; send a session establishment request packet to the camera via the SIP protocol; and receive a TCP link establishment request packet carrying target address information from the camera.

[0113] In some embodiments, the second determination module 702 is further used to obtain the address of the camera based on the TCP link establishment request data packet; allocate a separate target intercom port to the camera to send audio data to the address of the camera through the target intercom port.

[0114] In some embodiments, the voice intercom device of the camera also includes a format configuration module, which is used to obtain the device type of the camera; determine the data format of the audio data based on the device type; and send audio data in a data format packaged by the RTP protocol to the camera, so that the camera can play the voice corresponding to the audio data when receiving the audio data in the data format.

[0115] Each module in the above-mentioned voice intercom device of the camera can be implemented in whole or in part by software, hardware and their combination. Each of the above-mentioned modules can be embedded in or independent of the processor in the computer device in the form of hardware, or can be stored in the memory of the computer device in the form of software, so that the processor can call and execute the corresponding operations of each of the above modules.

[0116] In an exemplary embodiment, a computer device is provided, which may be a server, and its internal structure diagram may be shown in FIG7. The computer device includes a processor, a memory, an input / output interface (Input / Output, referred to as I / O) and a communication interface. The processor, the memory and the input / output interface are connected via a system bus, and the communication interface is connected to the system bus via the input / output interface. The processor of the computer device is used to provide computing and control capabilities. The memory of the computer device includes a non-volatile storage medium and an internal memory. The non-volatile storage medium stores an operating system, a computer program and a database. The internal memory provides an environment for the operation of the operating system and the computer program in the non-volatile storage medium. The input / output interface of the computer device is used to exchange information between the processor and an external device. The communication interface of the computer device is used to communicate with an external terminal through a network connection. When the computer program is executed by the processor, a voice intercom method of a camera is implemented.

[0117] Those skilled in the art will understand that the structure shown in FIG. 7 is merely a block diagram of a partial structure related to the solution of the present application, and does not constitute a limitation on the computer device to which the solution of the present application is applied. The specific computer device may include more or fewer components than shown in the figure, or combine certain components, or have a different arrangement of components.

[0118] In an exemplary embodiment, a computer device is provided, including a memory and a processor, wherein a computer program is stored in the memory, and when the processor executes the computer program, the following steps are implemented:

[0119] When the camera is connected to the target platform, the server corresponding to the target platform sends a first data packet carrying a target identifier to the camera;

[0120] If a return data packet carrying a target identifier is received through the first port, it is determined that the intercom mode matched by the camera is the first intercom mode, and the first intercom mode communicates with the camera through the first port;

[0121] If no return data packet carrying the target identifier is received at the first port, a second data packet carrying the target address information is sent to the camera. If a return data packet sent by the camera based on the target address information is received, it is determined that the intercom mode matched by the camera is the second intercom mode, and the second intercom mode communicates with the camera through the second port;

[0122] Based on the intercom mode matched by the camera, the audio data packaged by the target communication protocol is sent to the camera, so that the camera receives the audio data and plays the voice corresponding to the audio data.

[0123] In one embodiment, a computer readable storage medium is provided, on which a computer program is stored, and when the computer program is executed by a processor, the following steps are implemented:

[0124] When the camera is connected to the target platform, the server corresponding to the target platform sends a first data packet carrying a target identifier to the camera;

[0125] If a return data packet carrying a target identifier is received through the first port, it is determined that the intercom mode matched by the camera is the first intercom mode, and the first intercom mode communicates with the camera through the first port;

[0126] If no return data packet carrying the target identifier is received at the first port, a second data packet carrying the target address information is sent to the camera. If a return data packet sent by the camera based on the target address information is received, it is determined that the intercom mode matched by the camera is the second intercom mode, and the second intercom mode communicates with the camera through the second port;

[0127] Based on the intercom mode matched by the camera, the audio data packaged by the target communication protocol is sent to the camera, so that the camera receives the audio data and plays the voice corresponding to the audio data.

[0128] In one embodiment, a computer program product is provided, comprising a computer program, which, when executed by a processor, implements the following steps:

[0129] When the camera is connected to the target platform, the server corresponding to the target platform sends a first data packet carrying a target identifier to the camera;

[0130] If a return data packet carrying a target identifier is received through the first port, it is determined that the intercom mode matched by the camera is the first intercom mode, and the first intercom mode communicates with the camera through the first port;

[0131] If no return data packet carrying the target identifier is received at the first port, a second data packet carrying the target address information is sent to the camera. If a return data packet sent by the camera based on the target address information is received, it is determined that the intercom mode matched by the camera is the second intercom mode, and the second intercom mode communicates with the camera through the second port;

[0132] Based on the intercom mode matched by the camera, the audio data packaged by the target communication protocol is sent to the camera, so that the camera receives the audio data and plays the voice corresponding to the audio data.

[0133] It should be noted that the user information (including but not limited to user device information, user personal information, etc.) and data (including but not limited to data used for analysis, stored data, displayed data, etc.) involved in this application are all information and data authorized by the user or fully authorized by all parties, and the collection, use and processing of relevant data must comply with relevant regulations.

[0134] A person of ordinary skill in the art can understand that all or part of the processes in the above-mentioned embodiment method can be completed by instructing the relevant hardware through a computer program, and the computer program can be stored in a non-volatile computer-readable storage medium. When the computer program is executed, it can include the processes of the embodiments of the above-mentioned methods. Among them, any reference to the memory, database or other medium used in the embodiments provided in the present application can include at least one of non-volatile memory and volatile memory. Non-volatile memory can include read-only memory (ROM), magnetic tape, floppy disk, flash memory, optical memory, high-density embedded non-volatile memory, resistive random access memory (ReRAM), magnetic random access memory (MRAM), ferroelectric random access memory (FRAM), phase change memory (PCM), graphene memory, etc. Volatile memory can include random access memory (RAM) or external cache memory, etc. As an illustration and not limitation, RAM can be in various forms, such as static random access memory (SRAM) or dynamic random access memory (DRAM). The database involved in each embodiment provided in this application may include at least one of a relational database and a non-relational database. Non-relational databases may include distributed databases based on blockchains, etc., but are not limited to this. The processor involved in each embodiment provided in this application may be a general-purpose processor, a central processing unit, a graphics processor, a digital signal processor, a programmable logic device, a data processing logic device based on quantum computing, an artificial intelligence (AI) processor, etc., but are not limited to this.

[0135] The technical features of the above embodiments may be combined arbitrarily. To make the description concise, not all possible combinations of the technical features in the above embodiments are described. However, as long as there is no contradiction in the combination of these technical features, they should be considered to be within the scope of this application.

[0136] The above-described embodiments only express several implementation methods of the present application, and the descriptions thereof are relatively specific and detailed, but they cannot be understood as limiting the scope of the present application. It should be pointed out that, for a person of ordinary skill in the art, several variations and improvements can be made without departing from the concept of the present application, and these all belong to the protection scope of the present application. Therefore, the protection scope of the present application shall be subject to the attached claims.

Claims

1. A voice intercom method for a camera, characterized in that: The method comprises: When the camera is connected to the target platform, the server corresponding to the target platform sends a first data packet carrying a target identifier to the camera; If a return data packet carrying the target identifier is received through the first port, it is determined that the intercom mode matched by the camera is the first intercom mode, and the first intercom mode communicates with the camera through the first port; If the return data packet carrying the target identifier is not received at the first port, a second data packet carrying the target address information is sent to the camera, and if a return data packet sent by the camera based on the target address information is received, it is determined that the intercom mode matched by the camera is the second intercom mode, and the second intercom mode communicates with the camera through the second port; Based on the intercom mode matched by the camera, audio data packaged in a target communication protocol is sent to the camera, so that the camera receives the audio data and plays the voice corresponding to the audio data.

2. The method according to claim 1, characterized in that When the camera is connected to the target platform, the server corresponding to the target platform sends a first data packet carrying a target identifier to the camera, including: When the camera is connected to the target platform, the server generates the target identifier; Creating a session establishment request data packet carrying the target identifier; The session establishment request data packet is sent to the camera via the SIP protocol.

3. The method according to claim 2, characterized in that The target identifier is a synchronization source identifier.

4. The method according to claim 1, characterized in that The sending a second data packet carrying target address information to the camera includes: Creating a session establishment request data packet carrying the target address information; Sending the session establishment request data packet to the camera via the SIP protocol; The receiving of a return data packet sent by the camera based on the target address information includes: A TCP link establishment request data packet carrying the target address information is received from the camera.

5. The method according to claim 4, characterized in that After receiving the TCP link establishment request data packet carrying the target address information from the camera, the method further includes: Obtaining the address of the camera based on the TCP link establishment request data packet; A separate target intercom port is allocated to the camera to send the audio data to the address of the camera through the target intercom port.

6. The method according to claim 1, characterized in that The audio payload data corresponding to the audio data is an integer number of audio coding frames, and the audio bit stream corresponding to the audio data complies with a target coding standard.

7. The method according to claim 1, characterized in that The sending of the audio data packaged by the target communication protocol to the camera so that the camera receives the audio data and plays the voice corresponding to the audio data includes: Get the device type of the camera; determining a data format of the audio data based on the device type; The audio data in the data format packaged by the RTP protocol is sent to the camera, so that the camera can play the voice corresponding to the audio data when receiving the audio data in the data format.

8. A voice intercom device for a camera, characterized in that: The device comprises: A first determination module is used for, when the camera is connected to a target platform, the server corresponding to the target platform sends a first data packet carrying a target identifier to the camera; if a return data packet carrying the target identifier is received through the first port, then determining that the intercom mode matched by the camera is the first intercom mode, and the first intercom mode communicates with the camera through the first port; a second determination module, configured to send a second data packet carrying target address information to the camera if the return data packet carrying the target identifier is not received at the first port, and to determine that the intercom mode matched by the camera is a second intercom mode if a return data packet sent by the camera based on the target address information is received, and the second intercom mode communicates with the camera through the second port; The intercom module is used to send audio data packaged in a target communication protocol to the camera based on the intercom mode matched by the camera, so that the camera receives the audio data and plays the voice corresponding to the audio data.

9. A computer device comprising a memory and a processor, wherein the memory stores a computer program, wherein: When the processor executes the computer program, the steps of the method according to any one of claims 1 to 7 are implemented.

10. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by a processor, the steps of the method according to any one of claims 1 to 7 are implemented.

Citation Information

Patent Citations

  • Video transmission method and device, electronic equipment and computer readable storage medium

    CN113873342A

  • Elevator monitoring camera access call center system capable of achieving two-way conversation

    CN114584535A

  • Equipment hosting method and device, equipment and storage medium

    CN117424923A

  • Social alarm unit with speech communication

    EP1727105A2

  • Intercom system

    JP2014229915A