CN117336378A - A method, device and gateway for realizing terminal communication with different protocols - Google Patents
A method, device and gateway for realizing terminal communication with different protocols Download PDFInfo
- Publication number
- CN117336378A CN117336378A CN202311176594.7A CN202311176594A CN117336378A CN 117336378 A CN117336378 A CN 117336378A CN 202311176594 A CN202311176594 A CN 202311176594A CN 117336378 A CN117336378 A CN 117336378A
- Authority
- CN
- China
- Prior art keywords
- data stream
- terminal
- transmission data
- communication protocol
- configuration information
- 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.)
- Pending
Links
Classifications
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L69/00—Network arrangements, protocols or services independent of the application payload and not provided for in the other groups of this subclass
- H04L69/08—Protocols for interworking; Protocol conversion
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L65/00—Network arrangements, protocols or services for supporting real-time applications in data packet communication
- H04L65/10—Architectures or entities
- H04L65/102—Gateways
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L65/00—Network arrangements, protocols or services for supporting real-time applications in data packet communication
- H04L65/60—Network streaming of media packets
- H04L65/65—Network streaming protocols, e.g. real-time transport protocol [RTP] or real-time control protocol [RTCP]
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L65/00—Network arrangements, protocols or services for supporting real-time applications in data packet communication
- H04L65/60—Network streaming of media packets
- H04L65/70—Media network packetisation
Landscapes
- Engineering & Computer Science (AREA)
- Multimedia (AREA)
- Computer Networks & Wireless Communication (AREA)
- Signal Processing (AREA)
- Computer Security & Cryptography (AREA)
- Communication Control (AREA)
Abstract
Description
技术领域Technical field
本发明涉及通信技术领域,特别是涉及一种实现不同协议终端通信的方法和一种实现不同协议终端通信的装置和一种网关。The present invention relates to the field of communication technology, and in particular to a method for realizing communication between terminals of different protocols, a device for realizing communication between terminals of different protocols, and a gateway.
背景技术Background technique
随着网络技术的发展,社会的推进,在国家的大力扶持之下,诞生了很多自主研发的设备,拥有自己的独立协议。With the development of network technology and the advancement of society, with the strong support of the state, many independently developed devices have been born, with their own independent protocols.
与此同时,秉承不浪费资源、合理利用资源的原则,需要将这些非IP协议的设备与IP协议设备配合使用。At the same time, adhering to the principle of not wasting resources and utilizing resources rationally, these non-IP protocol devices need to be used in conjunction with IP protocol devices.
但目前的市场上,并不能支持非IP协议与IP协议直接进行通信,不同协议之间的产品无法配合使用,使得同类型不同协议的产品之间产生了壁垒。However, the current market does not support direct communication between non-IP protocols and IP protocols, and products with different protocols cannot be used together, creating barriers between products of the same type and different protocols.
发明内容Contents of the invention
鉴于上述问题,提出了本发明实施例以便提供一种实现不同协议终端通信的方法和一种实现不同协议终端通信的装置和一种网关。In view of the above problems, embodiments of the present invention are proposed to provide a method for realizing communication between terminals of different protocols, a device for realizing communication between terminals of different protocols, and a gateway.
为了解决上述问题,第一方面,本发明实施例公开了一种实现不同协议终端通信的方法,所述方法包括:In order to solve the above problems, in the first aspect, an embodiment of the present invention discloses a method for realizing terminal communication with different protocols. The method includes:
接收第一终端发送的第一传输数据流,所述第一传输数据流是所述第一终端发送至第二终端的,所述第一终端对应的第一通信协议与所述第二终端对应的第二通信协议不同;Receive the first transmission data stream sent by the first terminal, the first transmission data stream is sent by the first terminal to the second terminal, and the first communication protocol corresponding to the first terminal corresponds to the second terminal The second communication protocol is different;
获取所述第一终端对应的第一通信协议和第一传输数据流配置信息;Obtain the first communication protocol and first transmission data stream configuration information corresponding to the first terminal;
根据所述第一通信协议和第一传输数据流配置信息解码所述第一传输数据流,确定多媒体数据流;Decode the first transmission data stream according to the first communication protocol and the first transmission data stream configuration information to determine a multimedia data stream;
获取所述第二终端对应的第二通信协议和第二传输数据流配置信息;Obtain the second communication protocol and second transmission data flow configuration information corresponding to the second terminal;
根据所述第二传输数据流配置信息编码所述多媒体数据流,并根据所述第二通信协议将编码后的多媒体数据流转换为第二传输数据流;Encode the multimedia data stream according to the second transmission data stream configuration information, and convert the encoded multimedia data stream into a second transmission data stream according to the second communication protocol;
向所述第二终端发送所述第二传输数据流。Send the second transport data stream to the second terminal.
如上述方法,可选地,所述根据所述第一通信协议和第一传输数据流配置信息解码所述第一传输数据流,确定多媒体数据流,包括:As in the above method, optionally, decoding the first transport data stream according to the first communication protocol and the first transport data stream configuration information to determine the multimedia data stream includes:
根据所述第一通信协议解析所述第一传输数据流,确定第一编码数据流;Parse the first transmission data stream according to the first communication protocol and determine a first encoded data stream;
根据所述第一传输数据流配置信息解码所述第一编码数据流,确定所述多媒体数据流。Decode the first encoded data stream according to the first transport data stream configuration information to determine the multimedia data stream.
如上述方法,可选地,所述根据所述第二传输数据流配置信息编码所述多媒体数据流,并根据所述第二通信协议将编码后的多媒体数据流转换为第二传输数据流,包括:As in the above method, optionally, encoding the multimedia data stream according to the second transport data stream configuration information, and converting the encoded multimedia data stream into a second transport data stream according to the second communication protocol, include:
根据所述第二传输数据流配置信息编码所述多媒体数据流,确定第二编码数据流;Encode the multimedia data stream according to the second transmission data stream configuration information to determine a second encoded data stream;
根据所述第二通信协议封装所述第二编码数据流,确定第二传输数据流。The second encoded data stream is encapsulated according to the second communication protocol to determine a second transmission data stream.
为了解决上述问题,第二方面,本发明实施例公开了一种实现不同协议终端通信的装置,所述装置包括:In order to solve the above problems, in a second aspect, an embodiment of the present invention discloses a device for realizing terminal communication with different protocols. The device includes:
接收单元,用于接收第一终端发送的第一传输数据流,所述第一传输数据流是所述第一终端发送至第二终端的,所述第一终端对应的第一通信协议与所述第二终端对应的第二通信协议不同;A receiving unit configured to receive a first transmission data stream sent by the first terminal to a second terminal, and the first communication protocol corresponding to the first terminal is consistent with the first transmission data stream. The second communication protocol corresponding to the second terminal is different;
第一获取单元,用于获取所述第一终端对应的第一通信协议和第一传输数据流配置信息;A first acquisition unit configured to acquire the first communication protocol and the first transmission data stream configuration information corresponding to the first terminal;
解码单元,用于根据所述第一通信协议和第一传输数据流配置信息解码所述第一传输数据流,确定多媒体数据流;A decoding unit configured to decode the first transmission data stream according to the first communication protocol and the first transmission data stream configuration information to determine the multimedia data stream;
第二获取单元,用于获取所述第二终端对应的第二通信协议和第二传输数据流配置信息;A second acquisition unit, configured to acquire the second communication protocol and the second transmission data flow configuration information corresponding to the second terminal;
转换单元,用于根据所述第二传输数据流配置信息编码所述多媒体数据流,并根据所述第二通信协议将编码后的多媒体数据流转换为第二传输数据流;A conversion unit configured to encode the multimedia data stream according to the second transmission data stream configuration information, and convert the encoded multimedia data stream into a second transmission data stream according to the second communication protocol;
发送单元,用于向所述第二终端发送所述第二传输数据流。A sending unit, configured to send the second transmission data stream to the second terminal.
为了解决上述问题,第三方面,本发明实施例公开了一种网关,所述网关包括:In order to solve the above problems, in a third aspect, an embodiment of the present invention discloses a gateway, which includes:
识别模块、存储模块、配置模块和软编软解模块;Identification module, storage module, configuration module and soft programming module;
所述识别模块用于识别各个终端对应的通信协议和传输数据流配置信息;The identification module is used to identify the communication protocol and transmission data stream configuration information corresponding to each terminal;
所述存储模块用于存储所述各个终端对应的通信协议和传输数据流配置信息,并将存储的信息发送至配置模块;The storage module is used to store the communication protocol and transmission data flow configuration information corresponding to each terminal, and send the stored information to the configuration module;
所述配置模块用于关联各个终端、通信协议和传输数据流配置信息,生成终端配置信息,并将所述终端配置信息发送至所述软编软解模块;The configuration module is used to associate each terminal, communication protocol and transmission data flow configuration information, generate terminal configuration information, and send the terminal configuration information to the soft coding and soft decoding module;
所述软编软解模块用于执行如第一方面所述的实现不同协议终端通信的方法。The soft coding and soft decoding module is used to execute the method for implementing terminal communication with different protocols as described in the first aspect.
如上述网关,可选地,所述识别模块具体用于:Like the above gateway, optionally, the identification module is specifically used to:
获取各个终端对应的终端标识,根据所述终端标识识别所述终端对应的通信协议;Obtain the terminal identification corresponding to each terminal, and identify the communication protocol corresponding to the terminal according to the terminal identification;
根据所述通信协议,确定所述终端对应的传输数据流配置信息。According to the communication protocol, the transmission data flow configuration information corresponding to the terminal is determined.
如上述网关,可选地,所述识别模块具体用于:Like the above gateway, optionally, the identification module is specifically used to:
接收用户输入的各个终端对应的通信协议和传输数据流配置信息。Receive the communication protocol and transmission data flow configuration information corresponding to each terminal input by the user.
如上述网关,可选地,所述识别模块具体用于:Like the above gateway, optionally, the identification module is specifically used to:
向各个终端发送测试数据包;Send test data packets to each terminal;
接收所述各个终端返回的测试数据响应包,解析所述测试数据响应包,获取各个终端对应的通信协议和传输数据流配置信息。Receive the test data response packet returned by each terminal, parse the test data response packet, and obtain the communication protocol and transmission data stream configuration information corresponding to each terminal.
为了解决上述问题,第四方面,本发明实施例公开一种电子设备,包括:In order to solve the above problems, in a fourth aspect, an embodiment of the present invention discloses an electronic device, including:
一个或多个处理器;和one or more processors; and
其上存储有指令的一个或多个机器可读介质,当由所述一个或多个处理器执行时,使得所述电子设备执行如第一方面所述的实现不同协议终端通信的方法。One or more machine-readable media having instructions stored thereon, when executed by the one or more processors, cause the electronic device to perform the method for implementing different protocol terminal communication as described in the first aspect.
为了解决上述问题,第五方面,本发明实施例提供一种计算机可读存储介质,其存储的计算机程序使得处理器执行如第一方面所述的实现不同协议终端通信的方法。In order to solve the above problems, in a fifth aspect, embodiments of the present invention provide a computer-readable storage medium, which stores a computer program that causes the processor to execute the method for implementing terminal communication with different protocols as described in the first aspect.
本发明实施例包括以下优点:Embodiments of the present invention include the following advantages:
本发明实施例中,根据不同通信协议的终端之间的通信协议和传输数据流配置信息,将不同通信协议的传输数据流进行转换,转换为对端通信协议的传输数据流,通过通信协议转换和传输数据流配置信息转换,使不同通信协议的终端在不修改任何配置的情况下可以互相通信,实现了不同协议终端不同终端的互联互通。In the embodiment of the present invention, according to the communication protocol and transmission data stream configuration information between terminals of different communication protocols, the transmission data streams of different communication protocols are converted into the transmission data stream of the peer communication protocol. Through the communication protocol conversion and transmission data flow configuration information conversion, so that terminals with different communication protocols can communicate with each other without modifying any configuration, realizing the interconnection and interoperability of different terminals with different protocols.
附图说明Description of drawings
图1是本发明的一种实现不同协议终端通信的方法实施例的步骤流程图;Figure 1 is a step flow chart of an embodiment of a method for realizing terminal communication with different protocols according to the present invention;
图2是本发明的一种实现不同协议终端通信的装置实施例的结构框图;Figure 2 is a structural block diagram of an embodiment of a device for realizing terminal communication with different protocols according to the present invention;
图3是本发明的一种网关实施例的结构框图;Figure 3 is a structural block diagram of a gateway embodiment of the present invention;
图4是本发明的一种网关实施例中实现V2V终端与IP终端通信的流程示意图;Figure 4 is a schematic flow chart for realizing communication between a V2V terminal and an IP terminal in a gateway embodiment of the present invention;
图5是本发明的一种电子设备实施例的结构框图。Figure 5 is a structural block diagram of an embodiment of an electronic device of the present invention.
具体实施方式Detailed ways
为使本发明的上述目的、特征和优点能够更加明显易懂,下面结合附图和具体实施方式对本发明作进一步详细的说明。In order to make the above objects, features and advantages of the present invention more obvious and understandable, the present invention will be described in further detail below with reference to the accompanying drawings and specific embodiments.
现有技术中不同协议之间的产品无法配合使用,使得同类型不同协议的产品之间产生了壁垒,不同协议类型、不同编码格式的终端之间无法进行通信。In the existing technology, products with different protocols cannot be used together, resulting in barriers between products of the same type and different protocols, and terminals with different protocol types and different encoding formats cannot communicate.
为解决这一问题,本发明实施例中,接收第一终端发送的第一传输数据流,所述第一传输数据流是所述第一终端发送至第二终端的,所述第一终端对应的第一通信协议与所述第二终端对应的第二通信协议不同;获取所述第一终端对应的第一通信协议和第一传输数据流配置信息;根据所述第一通信协议和第一传输数据流配置信息解码所述第一传输数据流,确定多媒体数据流;获取所述第二终端对应的第二通信协议和第二传输数据流配置信息;根据所述第二传输数据流配置信息编码所述多媒体数据流,并根据所述第二通信协议将编码后的多媒体数据流转换为第二传输数据流;向所述第二终端发送所述第二传输数据流。In order to solve this problem, in the embodiment of the present invention, the first transmission data stream sent by the first terminal is received. The first transmission data stream is sent by the first terminal to the second terminal, and the first terminal corresponds to The first communication protocol is different from the second communication protocol corresponding to the second terminal; obtaining the first communication protocol and the first transmission data flow configuration information corresponding to the first terminal; according to the first communication protocol and the first Transmission data flow configuration information decodes the first transmission data stream to determine a multimedia data stream; obtains the second communication protocol and second transmission data flow configuration information corresponding to the second terminal; and according to the second transmission data flow configuration information Encoding the multimedia data stream, and converting the encoded multimedia data stream into a second transmission data stream according to the second communication protocol; sending the second transmission data stream to the second terminal.
本发明实施例根据不同通信协议的终端之间的通信协议和传输数据流配置信息,将不同通信协议的传输数据流进行转换,转换为对端通信协议的传输数据流,通过通信协议转换和传输数据流配置信息转换,使不同通信协议的终端在不修改任何配置的情况下可以互相通信,实现了不同协议终端不同终端的互联互通。Embodiments of the present invention convert the transmission data streams of different communication protocols into transmission data streams of the peer communication protocol according to the communication protocols and transmission data stream configuration information between terminals of different communication protocols, and convert and transmit them through the communication protocol Data flow configuration information conversion enables terminals with different communication protocols to communicate with each other without modifying any configuration, realizing the interconnection and interoperability of different terminals with different protocols.
参照图1,示出了本发明的一种实现不同协议终端通信的方法实施例的步骤流程图,应用于实现不同协议终端通信的装置中,具体可以包括如下步骤:Referring to Figure 1, there is shown a step flow chart of an embodiment of a method for realizing communication between terminals of different protocols according to the present invention. It is applied to a device for realizing communication between terminals of different protocols. Specifically, it may include the following steps:
步骤S110、接收第一终端发送的第一传输数据流,所述第一传输数据流是所述第一终端发送至第二终端的,所述第一终端对应的第一通信协议与所述第二终端对应的第二通信协议不同;Step S110: Receive the first transmission data stream sent by the first terminal. The first transmission data stream is sent by the first terminal to the second terminal. The first communication protocol corresponding to the first terminal is the same as the first communication protocol of the first terminal. The second communication protocols corresponding to the two terminals are different;
具体地,目前使用的较普遍的终端设备协议类型为网际互连协议(InternetProtocol,IP),也有较多的独立自主研发的终端通信协议,不同的协议类型是无法进行通信的。此外,音视频编解码有很多类型,只有相同类型的音视频编解码才能通信,显示正常的音视频画面,不同编码通信会有黑屏等各种问题。Specifically, the most commonly used terminal device protocol type currently is the Internet Protocol (IP), and there are also many independently developed terminal communication protocols. Different protocol types cannot communicate. In addition, there are many types of audio and video codecs. Only audio and video codecs of the same type can communicate and display normal audio and video pictures. Communication with different codecs will cause various problems such as black screens.
当不同协议的终端需要进行通信时,发送端(记为第一终端)向接收端(记为第二终端)发送传输数据流(记为第一传输数据流),第一传输数据流可以为音频流或视频流,该音频流或视频流是第一终端按照第一终端的通信协议类型进行封装的,直接发送至第二终端,将导致第二终端无法解析。When terminals with different protocols need to communicate, the sending end (denoted as the first terminal) sends a transmission data stream (denoted as the first transmission data stream) to the receiving end (denoted as the second terminal). The first transmission data stream can be Audio stream or video stream, which is encapsulated by the first terminal according to the communication protocol type of the first terminal and sent directly to the second terminal, will cause the second terminal to be unable to parse.
为解决这一问题,实现不同协议终端通信的装置(以下简称为实现装置)可获取第一终端发送至第二终端的第一传输数据流,对第一传输数据流进行处理之后,再发送至第二终端,以便第二终端能够解析传输数据流,实现第一终端和第二终端的通信。In order to solve this problem, a device that implements terminal communication with different protocols (hereinafter referred to as the implementation device) can obtain the first transmission data stream sent by the first terminal to the second terminal, process the first transmission data stream, and then send it to the second terminal, so that the second terminal can parse the transmission data stream and realize communication between the first terminal and the second terminal.
例如,第一终端可以为私有协议终端,第二终端可以为IP终端。For example, the first terminal may be a private protocol terminal, and the second terminal may be an IP terminal.
步骤S120、获取所述第一终端对应的第一通信协议和第一传输数据流配置信息;Step S120: Obtain the first communication protocol and first transmission data flow configuration information corresponding to the first terminal;
具体地,实现装置获取到第一终端要发送到第二终端的第一传输数据流之后,获取第一终端对应的第一通信协议,以及第一传输数据流配置信息。其中第一传输数据流配置信息可以为第一传输数据流的格式、采样率、分辨率、帧率、码率等信息。Specifically, after obtaining the first transmission data stream to be sent by the first terminal to the second terminal, the implementation device obtains the first communication protocol corresponding to the first terminal and the first transmission data stream configuration information. The first transmission data stream configuration information may be the format, sampling rate, resolution, frame rate, code rate and other information of the first transmission data stream.
实现装置可以为用户提供用于输入信息的界面,用户手动输入第一终端对应的第一通信协议和第一传输数据流配置信息,提交之后,实现装置获取到第一终端对应的第一通信协议和第一传输数据流配置信息。The implementation device can provide the user with an interface for inputting information. The user manually inputs the first communication protocol and the first transmission data stream configuration information corresponding to the first terminal. After submission, the implementation device obtains the first communication protocol corresponding to the first terminal. and first transport data stream configuration information.
实现装置还可以获取第一终端对应的标识信息,例如身份标识,通过身份标识检索已有终端身份标识与通信协议、传输数据流配置信息数据库,由第一终端对应的标识信息获取到第一终端对应的第一通信协议和第一传输数据流配置信息。The implementation device can also obtain the identification information corresponding to the first terminal, such as an identity identification, retrieve the existing terminal identity identification and communication protocol, and the transmission data stream configuration information database through the identity identification, and obtain the first terminal from the identification information corresponding to the first terminal. Corresponding first communication protocol and first transmission data flow configuration information.
实现装置还可以在接收第一终端发送的第一传输数据流之前,向第一终端发送测试数据包,并接收第一终端返回的测试数据包,解析测试数据包,从各个字段中分析,获取到第一终端对应的第一通信协议和第一传输数据流配置信息。The implementation device may also send a test data packet to the first terminal before receiving the first transmission data stream sent by the first terminal, receive the test data packet returned by the first terminal, parse the test data packet, analyze from each field, and obtain The first communication protocol and the first transmission data flow configuration information corresponding to the first terminal.
在实际应用中,实现装置还可以通过其他方式获取第一终端对应的第一通信协议和第一传输数据流配置信息,此处不再一一赘述。In actual applications, the implementation device may also obtain the first communication protocol and the first transmission data stream configuration information corresponding to the first terminal through other methods, which will not be described again here.
例如,第一终端为视联网终端,第二终端为IP终端,第一终端向第二终端发送的传输数据流为音频数据流,则实现装置可以获取到第一终端的通信协议为视联网协议,音频数据流的配置信息包括音频的编码格式,编码格式具体为Opus,Opus是一个有损声音编码的格式,由Xiph.Org基金会开发,之后由IETF(互联网工程任务组)进行标准化,目标是希望用单一格式包含声音和语音,且适用于网络上低延迟的即时声音传输。For example, if the first terminal is a video networking terminal, the second terminal is an IP terminal, and the transmission data stream sent by the first terminal to the second terminal is an audio data stream, then the implementation device can obtain that the communication protocol of the first terminal is the video networking protocol. The configuration information of the audio data stream includes the audio encoding format. The encoding format is specifically Opus. Opus is a lossy sound encoding format developed by the Xiph.Org Foundation and later standardized by the IETF (Internet Engineering Task Force). The goal It is hoped that a single format can contain sound and speech and be suitable for low-latency real-time sound transmission on the network.
仍以视联网为例,第一终端向第二终端发送的传输数据流为视频数据流,则实现装置可以获取到第一终端的通信协议为视联网协议,视频数据流的配置信息包括视频数据流的编码格式、分辨率、帧率、码率等信息,其中编码格式具体为:H265,分辨率为2K,帧率为60FPS、码率为406KBPS。Still taking video networking as an example, the transmission data stream sent by the first terminal to the second terminal is a video data stream, then the implementation device can obtain that the communication protocol of the first terminal is the video networking protocol, and the configuration information of the video data stream includes video data. The encoding format, resolution, frame rate, code rate and other information of the stream. The encoding format is specifically: H265, the resolution is 2K, the frame rate is 60FPS, and the code rate is 406KBPS.
步骤S130、根据所述第一通信协议和第一传输数据流配置信息解码所述第一传输数据流,确定多媒体数据流;Step S130: Decode the first transmission data stream according to the first communication protocol and the first transmission data stream configuration information to determine the multimedia data stream;
具体地,实现装置获取到第一终端对应的第一通信协议和第一传输数据流配置信息之后,根据第一通信协议解封装第一传输数据流,并根据第一传输数据流配置信息解析解封装后的第一传输数据流,得到多媒体数据流。Specifically, after the implementation device obtains the first communication protocol and the first transmission data flow configuration information corresponding to the first terminal, it decapsulates the first transmission data flow according to the first communication protocol, and parses the first transmission data flow according to the first transmission data flow configuration information. The encapsulated first transmission data stream is obtained as a multimedia data stream.
步骤S140、获取所述第二终端对应的第二通信协议和第二传输数据流配置信息;Step S140: Obtain the second communication protocol and second transmission data flow configuration information corresponding to the second terminal;
具体地,实现装置获取第二终端对应的第一通信协议,以及第二传输数据流配置信息。其中第二传输数据流配置信息可以为第二传输数据流的格式、采样率、分辨率、帧率、码率等信息。Specifically, the implementation device obtains the first communication protocol corresponding to the second terminal and the second transmission data flow configuration information. The second transmission data stream configuration information may be the format, sampling rate, resolution, frame rate, code rate and other information of the second transmission data stream.
实现装置可以为用户提供用于输入信息的界面,用户手动输入第二终端对应的第二通信协议和第二传输数据流配置信息,提交之后,实现装置获取到第二终端对应的第二通信协议和第二传输数据流配置信息。The implementation device can provide the user with an interface for inputting information. The user manually inputs the second communication protocol corresponding to the second terminal and the second transmission data flow configuration information. After submission, the implementation device obtains the second communication protocol corresponding to the second terminal. and second transport data stream configuration information.
实现装置还可以获取第二终端对应的标识信息,例如身份标识,通过身份标识检索已有终端身份标识与通信协议、传输数据流配置信息数据库,由第二终端对应的标识信息获取到第二终端对应的第二通信协议和第二传输数据流配置信息。The implementation device can also obtain the identification information corresponding to the second terminal, such as an identity identification, retrieve the existing terminal identity identification and communication protocol, and the transmission data flow configuration information database through the identity identification, and obtain the identification information corresponding to the second terminal to the second terminal. Corresponding second communication protocol and second transmission data stream configuration information.
实现装置还可以在接收第一终端发送的第一传输数据流之前,向第二终端发送测试数据包,并接收第二终端返回的测试数据包,解析测试数据包,从各个字段中分析,获取到第二终端对应的第二通信协议和第一传输数据流配置信息。The implementation device may also send a test data packet to the second terminal before receiving the first transmission data stream sent by the first terminal, receive the test data packet returned by the second terminal, parse the test data packet, analyze from each field, and obtain The second communication protocol and the first transmission data flow configuration information corresponding to the second terminal.
在实际应用中,实现装置还可以通过其他方式获取第二终端对应的第二通信协议和第二传输数据流配置信息,此处不再一一赘述。In actual applications, the implementation device may also obtain the second communication protocol and the second transmission data flow configuration information corresponding to the second terminal through other methods, which will not be described again here.
例如,第一终端为视联网终端,第二终端为IP终端,第一终端向第二终端发送的传输数据流为音频数据流,则实现装置可以获取到第二终端的通信协议为IP协议,音频数据流的配置信息包括音频的编码格式,编码格式具体为G711A。For example, if the first terminal is a video networking terminal, the second terminal is an IP terminal, and the transmission data stream sent by the first terminal to the second terminal is an audio data stream, then the implementation device can obtain that the communication protocol of the second terminal is the IP protocol, The configuration information of the audio data stream includes the audio encoding format, and the encoding format is specifically G711A.
仍以视联网为例,第一终端向第二终端发送的传输数据流为视频数据流,则实现装置可以获取到第二终端的通信协议为IP协议,视频数据流的配置信息包括视频数据流的编码格式、分辨率、帧率、码率等信息,其中编码格式具体为:H264,分辨率为1080P,帧率为30FPS、码率为326KBPS。Still taking video networking as an example, the transmission data stream sent by the first terminal to the second terminal is a video data stream, then the implementation device can obtain that the communication protocol of the second terminal is the IP protocol, and the configuration information of the video data stream includes the video data stream. The encoding format, resolution, frame rate, bit rate and other information. The encoding format is specifically: H264, the resolution is 1080P, the frame rate is 30FPS, and the bit rate is 326KBPS.
步骤S150、根据所述第二传输数据流配置信息编码所述多媒体数据流,并根据所述第二通信协议将编码后的多媒体数据流转换为第二传输数据流;Step S150: Encode the multimedia data stream according to the second transmission data stream configuration information, and convert the encoded multimedia data stream into a second transmission data stream according to the second communication protocol;
步骤S160、向所述第二终端发送所述第二传输数据流。Step S160: Send the second transmission data stream to the second terminal.
具体地,实现装置根据第二传输数据流配置信息编码多媒体数据流,并根据第二通信协议将编码后的多媒体数据流转换为第二传输数据流,向第二终端发送第二传输数据流。Specifically, the implementation device encodes the multimedia data stream according to the second transmission data stream configuration information, converts the encoded multimedia data stream into the second transmission data stream according to the second communication protocol, and sends the second transmission data stream to the second terminal.
第二终端接收到第二传输数据流之后,由于第二传输数据流与第二终端的通信协议和传输数据流配置信息均一致,因此,第二终端能够直接使用第二传输数据流获取到第一终端发送的信息。After the second terminal receives the second transmission data stream, since the communication protocol and transmission data stream configuration information of the second transmission data stream are consistent with that of the second terminal, the second terminal can directly use the second transmission data stream to obtain the second transmission data stream. Information sent by a terminal.
在具体实现中,第二终端接收到第二传输数据流之后,还可以继续向第一终端发送第三传输数据流,实现装置获取到第三传输数据流之后,根据第二终端的第二通信协议以及第三传输数据流配置信息确定多媒体数据流,根据第一终端的第一通信协议和第四传输数据流配置信息确定第四传输数据流,将第四传输数据流发送至第一终端,实现了不同通信协议的终端之间的通信过程。In a specific implementation, after the second terminal receives the second transmission data stream, it can continue to send the third transmission data stream to the first terminal. After the implementation device obtains the third transmission data stream, according to the second communication of the second terminal The protocol and the third transmission data stream configuration information determine the multimedia data stream, determine the fourth transmission data stream according to the first communication protocol and the fourth transmission data stream configuration information of the first terminal, and send the fourth transmission data stream to the first terminal, Realizes the communication process between terminals with different communication protocols.
本发明实施例中,根据不同通信协议的终端之间的通信协议和传输数据流配置信息,将不同通信协议的传输数据流进行转换,转换为对端通信协议的传输数据流,通过通信协议转换和传输数据流配置信息转换,使不同通信协议的终端在不修改任何配置的情况下可以互相通信,实现了不同协议终端不同终端的互联互通。In the embodiment of the present invention, according to the communication protocol and transmission data stream configuration information between terminals of different communication protocols, the transmission data streams of different communication protocols are converted into the transmission data stream of the peer communication protocol. Through the communication protocol conversion and transmission data flow configuration information conversion, so that terminals with different communication protocols can communicate with each other without modifying any configuration, realizing the interconnection and interoperability of different terminals with different protocols.
在本发明的一种优选实施例中,所述根据所述第一通信协议和第一传输数据流配置信息解码所述第一传输数据流,确定多媒体数据流,包括:In a preferred embodiment of the present invention, decoding the first transmission data stream according to the first communication protocol and the first transmission data stream configuration information to determine the multimedia data stream includes:
根据所述第一通信协议解析所述第一传输数据流,确定第一编码数据流;Parse the first transmission data stream according to the first communication protocol and determine a first encoded data stream;
根据所述第一传输数据流配置信息解码所述第一编码数据流,确定所述多媒体数据流。Decode the first encoded data stream according to the first transport data stream configuration information to determine the multimedia data stream.
具体地,实现装置获取到第一传输数据流、第一通信协议和第一传输数据流配置信息之后,根据第一通信协议解析第一传输数据流,例如,根据第一通信协议解封装第一传输数据流,得到第一编码数据流。Specifically, after obtaining the first transmission data stream, the first communication protocol and the first transmission data stream configuration information, the implementation device parses the first transmission data stream according to the first communication protocol, for example, decapsulates the first transmission data stream according to the first communication protocol. Transmit the data stream to obtain the first encoded data stream.
之后实现装置根据第一传输数据流配置信息解码所述第一编码数据流,得到多媒体数据流,即第一终端要传输的原始的数据流。The implementation device then decodes the first encoded data stream according to the first transmission data stream configuration information to obtain a multimedia data stream, that is, the original data stream to be transmitted by the first terminal.
本发明实施例中通过协议解封装、配置信息解码传输数据流,识别出多媒体数据流。进而可以依据多媒体数据流,转换为第二终端可识别的第二传输数据流,实现了不同协议终端的互联互通。In the embodiment of the present invention, the multimedia data stream is identified through protocol decapsulation and configuration information decoding to transmit the data stream. Furthermore, the multimedia data stream can be converted into a second transmission data stream that can be recognized by the second terminal, thereby realizing interconnection and interoperability of terminals with different protocols.
在本发明的一种优选实施例中,所述根据所述第二传输数据流配置信息编码所述多媒体数据流,并根据所述第二通信协议将编码后的多媒体数据流转换为第二传输数据流,包括:In a preferred embodiment of the present invention, the multimedia data stream is encoded according to the second transmission data stream configuration information, and the encoded multimedia data stream is converted into a second transmission according to the second communication protocol. Data flows, including:
根据所述第二传输数据流配置信息编码所述多媒体数据流,确定第二编码数据流;Encode the multimedia data stream according to the second transmission data stream configuration information to determine a second encoded data stream;
根据所述第二通信协议封装所述第二编码数据流,确定第二传输数据流。The second encoded data stream is encapsulated according to the second communication protocol to determine a second transmission data stream.
具体地,实现装置获取到多媒体数据流、第二通信协议和第二数据流配置信息之后,根据第二传输数据流配置信息编码多媒体数据流,得到第二表明数据流。Specifically, after obtaining the multimedia data stream, the second communication protocol and the second data stream configuration information, the implementation device encodes the multimedia data stream according to the second transmission data stream configuration information to obtain the second display data stream.
之后,实现装置根据第二通信协议封装第二编码数据流,得到第二传输数据流。Afterwards, the implementation device encapsulates the second encoded data stream according to the second communication protocol to obtain a second transmission data stream.
之后,实现装置将第二传输数据流发送至第二终端,实现第一终端与第二终端的互联互通。Afterwards, the implementation device sends the second transmission data stream to the second terminal to realize interconnection between the first terminal and the second terminal.
例如,第一终端为视联网终端,第二终端为IP终端,实现装置预先确定第一终端的通信协议为视联网V2V协议,音频数据流的配置信息为编码格式Opus,视频数据流的配置信息为:编码格式H265,分辨率为2K,帧率为60FPS、码率为406KBPS。同时,实现装置预先确定第二终端的通信协议为IP协议,音频数据流的配置信息为编码格式G711A,视频数据流的配置信息为:编码格式H264,分辨率为1080P,帧率为30FPS、码率为326KBPS。For example, the first terminal is a video network terminal and the second terminal is an IP terminal. The implementation device predetermines that the communication protocol of the first terminal is the video network V2V protocol, the configuration information of the audio data stream is the encoding format Opus, and the configuration information of the video data stream is Opus. The encoding format is H265, the resolution is 2K, the frame rate is 60FPS, and the code rate is 406KBPS. At the same time, the implementation device predetermines that the communication protocol of the second terminal is the IP protocol, the configuration information of the audio data stream is the encoding format G711A, and the configuration information of the video data stream is: the encoding format H264, the resolution is 1080P, the frame rate is 30FPS, and the code The rate is 326KBPS.
当第一终端向第二终端发送第一音视频流时,实现装置根据视联网V2V协议解析第一音视频流,将音频编码格式为Opus、视频编码格式为H265、分辨率为2k、帧率为60FPS、码率为406KBPS格式的第一音视频流转换为音频编码格式为G711A、视频编码格式H264,分辨率为1080P,帧率为30FPS、码率为326KBPS格式的符合IP协议的第二音视频流,然后将第二音视频流发送至第二终端。When the first terminal sends the first audio and video stream to the second terminal, the implementation device parses the first audio and video stream according to the V2V protocol of the Internet of Things, and sets the audio encoding format as Opus, the video encoding format as H265, the resolution as 2k, and the frame rate The first audio and video stream in the format of 60FPS, bit rate 406KBPS is converted into the second audio stream in the format of audio encoding format G711A, video encoding format H264, resolution 1080P, frame rate 30FPS, bit rate 326KBPS that complies with the IP protocol. video stream, and then sends the second audio and video stream to the second terminal.
同理,当第二终端向第一终端发送第三音视频流时,实现装置根据IP协议解析第三音视频流,将音频编码格式为G711A、视频编码格式H264,分辨率为1080P,帧率为30FPS、码率为326KBPS格式的第三音视频流转换为音频编码格式为Opus、视频编码格式为H265、分辨率为2k、帧率为60FPS、码率为406KBPS格式的符合视联网V2V协议的第四音视频流,然后将第四音视频流发送至第一终端,通过上述步骤使非IP协议终端与IP协议终端在不修改任何配置的情况下可以相互通信,实现了非IP协议的终端与IP协议终端在协议不同、编解码不一致、分辨率不统一的情况下也可以相互通信的需求。In the same way, when the second terminal sends the third audio and video stream to the first terminal, the implementation device parses the third audio and video stream according to the IP protocol, and sets the audio encoding format to G711A, the video encoding format to H264, the resolution to 1080P, and the frame rate to The third audio and video stream in the format of 30FPS, bit rate 326KBPS is converted into audio encoding format Opus, video encoding format H265, resolution 2k, frame rate 60FPS, bit rate 406KBPS format that complies with the Internet of Things V2V protocol The fourth audio and video stream is then sent to the first terminal. Through the above steps, the non-IP protocol terminal and the IP protocol terminal can communicate with each other without modifying any configuration, realizing the non-IP protocol terminal. IP protocol terminals can communicate with each other even if the protocols are different, the codecs are inconsistent, and the resolutions are inconsistent.
本发明实施例中,根据不同通信协议的终端之间的通信协议和传输数据流配置信息,将不同通信协议的传输数据流进行转换,转换为对端通信协议的传输数据流,通过通信协议转换和传输数据流配置信息转换,使不同通信协议的终端在不修改任何配置的情况下可以互相通信,实现了不同协议终端不同终端的互联互通。In the embodiment of the present invention, according to the communication protocol and transmission data stream configuration information between terminals of different communication protocols, the transmission data streams of different communication protocols are converted into the transmission data stream of the peer communication protocol. Through the communication protocol conversion and transmission data flow configuration information conversion, so that terminals with different communication protocols can communicate with each other without modifying any configuration, realizing the interconnection and interoperability of different terminals with different protocols.
需要说明的是,对于方法实施例,为了简单描述,故将其都表述为一系列的动作组合,但是本领域技术人员应该知悉,本发明实施例并不受所描述的动作顺序的限制,因为依据本发明实施例,某些步骤可以采用其他顺序或者同时进行。其次,本领域技术人员也应该知悉,说明书中所描述的实施例均属于优选实施例,所涉及的动作并不一定是本发明实施例所必须的。It should be noted that for the sake of simple description, the method embodiments are expressed as a series of action combinations. However, those skilled in the art should know that the embodiments of the present invention are not limited by the described action sequence because According to embodiments of the present invention, certain steps may be performed in other orders or simultaneously. Secondly, those skilled in the art should also know that the embodiments described in the specification are preferred embodiments, and the actions involved are not necessarily necessary for the embodiments of the present invention.
参照图2,示出了本发明的一种实现不同协议终端通信的装置实施例的结构框图,具体可以包括如下单元:Referring to Figure 2, there is shown a structural block diagram of an embodiment of a device for realizing terminal communication with different protocols of the present invention, which may specifically include the following units:
接收单元210,用于接收第一终端发送的第一传输数据流,所述第一传输数据流是所述第一终端发送至第二终端的,所述第一终端对应的第一通信协议与所述第二终端对应的第二通信协议不同;The receiving unit 210 is configured to receive the first transmission data stream sent by the first terminal. The first transmission data stream is sent by the first terminal to the second terminal. The first communication protocol corresponding to the first terminal and The second communication protocol corresponding to the second terminal is different;
第一获取单元220,用于获取所述第一终端对应的第一通信协议和第一传输数据流配置信息;The first obtaining unit 220 is used to obtain the first communication protocol and the first transmission data flow configuration information corresponding to the first terminal;
解码单元230,用于根据所述第一通信协议和第一传输数据流配置信息解码所述第一传输数据流,确定多媒体数据流;Decoding unit 230, configured to decode the first transmission data stream according to the first communication protocol and the first transmission data stream configuration information, and determine the multimedia data stream;
第二获取单元240,用于获取所述第二终端对应的第二通信协议和第二传输数据流配置信息;The second obtaining unit 240 is used to obtain the second communication protocol and the second transmission data flow configuration information corresponding to the second terminal;
转换单元250,用于根据所述第二传输数据流配置信息编码所述多媒体数据流,并根据所述第二通信协议将编码后的多媒体数据流转换为第二传输数据流;Conversion unit 250, configured to encode the multimedia data stream according to the second transmission data stream configuration information, and convert the encoded multimedia data stream into a second transmission data stream according to the second communication protocol;
发送单元260,用于向所述第二终端发送所述第二传输数据流。The sending unit 260 is configured to send the second transmission data stream to the second terminal.
在本发明的一种优选实施例中,所述解码单元230具体用于:In a preferred embodiment of the present invention, the decoding unit 230 is specifically used to:
根据所述第一通信协议解析所述第一传输数据流,确定第一编码数据流;Parse the first transmission data stream according to the first communication protocol and determine a first encoded data stream;
根据所述第一传输数据流配置信息解码所述第一编码数据流,确定所述多媒体数据流。Decode the first encoded data stream according to the first transport data stream configuration information to determine the multimedia data stream.
在本发明的一种优选实施例中,所述转换单元250具体用于:In a preferred embodiment of the present invention, the conversion unit 250 is specifically used for:
根据所述第二传输数据流配置信息编码所述多媒体数据流,确定第二编码数据流;Encode the multimedia data stream according to the second transmission data stream configuration information to determine a second encoded data stream;
根据所述第二通信协议封装所述第二编码数据流,确定第二传输数据流。The second encoded data stream is encapsulated according to the second communication protocol to determine a second transmission data stream.
对于装置实施例而言,由于其与方法实施例基本相似,所以描述的比较简单,相关之处参见方法实施例的部分说明即可。As for the device embodiment, since it is basically similar to the method embodiment, the description is relatively simple. For relevant details, please refer to the partial description of the method embodiment.
参照图3,示出了本发明的一种网关实施例的结构框图,具体可以包括如下模块:Referring to Figure 3, a structural block diagram of a gateway embodiment of the present invention is shown, which may specifically include the following modules:
识别模块310、存储模块320、配置模块330和软编软解模块340;Identification module 310, storage module 320, configuration module 330 and soft coding and soft decoding module 340;
所述识别模块310用于识别各个终端对应的通信协议和传输数据流配置信息;The identification module 310 is used to identify the communication protocol and transmission data stream configuration information corresponding to each terminal;
所述存储模块320用于存储所述各个终端对应的通信协议和传输数据流配置信息,并将存储的信息发送至配置模块330;The storage module 320 is used to store the communication protocol and transmission data flow configuration information corresponding to each terminal, and send the stored information to the configuration module 330;
所述配置模块330用于关联各个终端、通信协议和传输数据流配置信息,生成终端配置信息,并将所述终端配置信息发送至所述软编软解模块340;The configuration module 330 is used to associate each terminal, communication protocol and transmission data flow configuration information, generate terminal configuration information, and send the terminal configuration information to the soft coding and soft decoding module 340;
所述软编软解模块用于接收第一终端发送的第一传输数据流,所述第一传输数据流是所述第一终端发送至第二终端的,所述第一终端对应的第一通信协议与所述第二终端对应的第二通信协议不同;获取所述第一终端对应的第一通信协议和第一传输数据流配置信息;根据所述第一通信协议和第一传输数据流配置信息解码所述第一传输数据流,确定多媒体数据流;获取所述第二终端对应的第二通信协议和第二传输数据流配置信息;根据所述第二传输数据流配置信息编码所述多媒体数据流,并根据所述第二通信协议将编码后的多媒体数据流转换为第二传输数据流;向所述第二终端发送所述第二传输数据流。The soft coding and soft decoding module is used to receive the first transmission data stream sent by the first terminal. The first transmission data stream is sent by the first terminal to the second terminal. The first terminal corresponds to the first transmission data stream. The communication protocol is different from the second communication protocol corresponding to the second terminal; obtaining the first communication protocol and the first transmission data stream configuration information corresponding to the first terminal; according to the first communication protocol and the first transmission data stream The configuration information decodes the first transmission data stream to determine the multimedia data stream; obtains the second communication protocol and the second transmission data stream configuration information corresponding to the second terminal; and encodes the second transmission data stream according to the second transmission data stream configuration information. multimedia data stream, convert the encoded multimedia data stream into a second transmission data stream according to the second communication protocol; and send the second transmission data stream to the second terminal.
具体地,将2个终端设备通过物理网线连接到网关设备上,通过识别模块310识别出不同协议终端的设备信息,包括各个终端对应的通信协议和传输数据流配置信息。将识别的信息发送至存储模块320,存储模块320存储所有的终端信息,并将终端信息发送至配置模块330,配置模块330关联各个终端、通信协议和传输数据流配置信息,生成终端配置信息,并将终端配置信息发送至软编软解模块340。Specifically, two terminal devices are connected to the gateway device through physical network cables, and the identification module 310 identifies device information of terminals with different protocols, including communication protocols and transmission data stream configuration information corresponding to each terminal. Send the identified information to the storage module 320. The storage module 320 stores all terminal information and sends the terminal information to the configuration module 330. The configuration module 330 associates each terminal, communication protocol and transmission data flow configuration information to generate terminal configuration information, And the terminal configuration information is sent to the soft coding and soft decoding module 340.
此时可以用其中一个终端呼叫另一个终端,信令互通后终端会发送音视频流给软编软解模块340,软编软解模块340根据终端配置信息对音视频进行解码,查看接收终端的能力集,根据能力集信息进行编码,将编译后的音视频流发送给接收终端,实现不同协议下不同终端的互联互通。At this time, one of the terminals can be used to call the other terminal. After signaling intercommunication, the terminal will send the audio and video streams to the soft coding and soft decoding module 340. The soft coding and soft decoding module 340 decodes the audio and video according to the terminal configuration information, and checks the receiving terminal's Capability set, encode according to the capability set information, and send the compiled audio and video streams to the receiving terminal to realize the interconnection of different terminals under different protocols.
参照图4,示出了本发明的一种网关实施例中实现V2V终端与IP终端通信的流程示意图,在实际应用中,可将两个不同通信协议的终端通过网线与网关的两个物理网口进行连接,连接后在网关设备上点击“一键自动识别”按键启动识别模块310。Referring to Figure 4, a schematic flow chart is shown for realizing communication between a V2V terminal and an IP terminal in a gateway embodiment of the present invention. In practical applications, two terminals with different communication protocols can be connected to two physical networks of the gateway through network cables. After connecting, click the "One-click automatic identification" button on the gateway device to start the identification module 310.
识别模块310进行终端名称识别,若配置名称,则识别的结果为配置后的名称,若没有配置,则默认识别的结果为终端型号,例如识别终端为V2V终端,IP终端。The identification module 310 performs terminal name identification. If the name is configured, the identification result is the configured name. If not configured, the identification result is the terminal model by default. For example, the identified terminal is a V2V terminal or an IP terminal.
识别模块310识别协议类型,例如V2V协议,IP协议;The identification module 310 identifies the protocol type, such as V2V protocol, IP protocol;
识别模块310识别音频采样率,V2V终端的采样率为Opus;IP终端的采样率为G711A;The identification module 310 identifies the audio sampling rate, the sampling rate of the V2V terminal is Opus; the sampling rate of the IP terminal is G711A;
识别模块310识别视频配置的编码格式和分辨率,V2V终端为H265和2K;IP终端为H264和1080P;The identification module 310 identifies the encoding format and resolution of the video configuration. The V2V terminal is H265 and 2K; the IP terminal is H264 and 1080P;
识别模块310识别视频配置的帧率和码率,V2V终端为60FPS和406KBPS;IP终端为30FPS和326KBPS。The identification module 310 identifies the frame rate and code rate of the video configuration. The V2V terminal is 60FPS and 406KBPS; the IP terminal is 30FPS and 326KBPS.
之后,识别模块310将识别到的终端信息发送至存储模块320,存储模块存储所有识别到的终端信息,并发送至配置模块330。Afterwards, the recognition module 310 sends the recognized terminal information to the storage module 320 , and the storage module stores all the recognized terminal information and sends it to the configuration module 330 .
配置模块320接收到识别的所有终端信息之后,进行配置,具体地用户可以通过下拉框进行配置:After receiving all the identified terminal information, the configuration module 320 performs configuration. Specifically, the user can configure through the drop-down box:
(1)点击“名称配置项”,弹出下拉框,最新识别的终端信息会显示在第一行;(1) Click "Name Configuration Item", a drop-down box will pop up, and the latest recognized terminal information will be displayed on the first line;
(2)选中V2V终端,此时其他配置项(如通信协议、传输数据流配置信息等)会自动补全,点击保存即可。(2) Select the V2V terminal. At this time, other configuration items (such as communication protocol, transmission data flow configuration information, etc.) will be automatically completed. Click to save.
(3)再次打开下拉框,选择IP终端,此时其他配置项会自动补全,点击保存即可。(3) Open the drop-down box again and select the IP terminal. At this time, other configuration items will be automatically completed. Click to save.
若点击“名称配置项”,弹出下拉框,没有显示最新的识别信息可有2种方式解决:If you click "Name Configuration Item" and a drop-down box pops up, but the latest identification information is not displayed, there are two ways to solve the problem:
(1)再次重复识别终端信息到配置终端信息的步骤,直到配置模块330显示全部终端信息为止。(1) Repeat the steps of identifying terminal information to configuring terminal information again until the configuration module 330 displays all terminal information.
(2)直接进行手动配置,直到配置模块330显示全部终端信息为止。(2) Directly perform manual configuration until the configuration module 330 displays all terminal information.
之后,配置模块330将配置信息发送至软编软解模块340。Afterwards, the configuration module 330 sends the configuration information to the soft coding and soft decoding module 340 .
软编软解模块340对音视频流进行解码和重新编码,步骤如下:The soft encoding and soft decoding module 340 decodes and re-encodes the audio and video streams. The steps are as follows:
A1、此时用V2V终端呼叫IP终端,信令互通后终端发送音视频流给软编软解模块340;A1. At this time, the V2V terminal is used to call the IP terminal. After signaling interoperability, the terminal sends audio and video streams to the soft coding and soft decoding module 340;
A2、软编软解模块340对V2V终端发过来的视频进行解码并重新编译为G711A、H264编码格式、分辨率为1080P、帧率为30FPS、码率326KBPS的实时传输音视频流发送给IP终端;A2. The soft coding and soft decoding module 340 decodes the video sent by the V2V terminal and recompiles it into a real-time transmission audio and video stream in G711A and H264 encoding format with a resolution of 1080P, a frame rate of 30FPS, and a code rate of 326KBPS and sends it to the IP terminal. ;
A3、同样地,软编软解模块340会将IP终端发过来的印视频进行解码并重新编译的Opus、H265格式、分辨率为2k、帧率为60FPS、码率406KBPS格式的实时传输音视频流发送给V2V终端,实现可视电话通信。使用网关设备,实现不同协议终端不同编码格式下的互联互通。A3. Similarly, the soft encoding and soft decoding module 340 will decode and recompile the printed video sent from the IP terminal into real-time transmission audio and video in Opus and H265 format, with a resolution of 2k, a frame rate of 60FPS, and a code rate of 406KBPS. The stream is sent to the V2V terminal to realize video phone communication. Use gateway equipment to realize interconnection and interoperability between different protocol terminals and different encoding formats.
在本发明的一种优选实施例中,所述识别模块310具体用于:In a preferred embodiment of the present invention, the identification module 310 is specifically used to:
获取各个终端对应的终端标识,根据所述终端标识识别所述终端对应的通信协议;Obtain the terminal identification corresponding to each terminal, and identify the communication protocol corresponding to the terminal according to the terminal identification;
根据所述通信协议,确定所述终端对应的传输数据流配置信息。According to the communication protocol, the transmission data flow configuration information corresponding to the terminal is determined.
具体地,识别模块310可以获取各个终端对应的标识信息,例如身份标识,通过身份标识检索已有终端身份标识与通信协议、传输数据流配置信息数据库,由各个终端对应的标识信息获取到各个终端对应的通信协议,然后根据各个通信协议,确定终端对应的传输数据流配置信息。例如,识别模块310获取到终端为视联网V2V终端,通信协议为V2V协议,则可基于V2V协议确定终端的传输数据流配置信息为:音频数据流的配置信息为编码格式Opus,视频数据流的配置信息为:编码格式H265,分辨率为2K,帧率为60FPS、码率为406KBPS。Specifically, the identification module 310 can obtain identification information corresponding to each terminal, such as an identity identification, retrieve the existing terminal identity identification and communication protocol, and transmission data flow configuration information database through the identity identification, and obtain each terminal from the identification information corresponding to each terminal. Corresponding communication protocols, and then determine the transmission data flow configuration information corresponding to the terminal according to each communication protocol. For example, if the identification module 310 obtains that the terminal is a video network V2V terminal and the communication protocol is the V2V protocol, it can determine the transmission data stream configuration information of the terminal based on the V2V protocol: the configuration information of the audio data stream is the encoding format Opus, and the configuration information of the video data stream is Opus. The configuration information is: encoding format H265, resolution 2K, frame rate 60FPS, code rate 406KBPS.
本发明实施例中,通过终端标识获取终端通信协议,进而通过终端通信协议确定终端的传输数据流配置信息,提高了终端信息识别的正确率。In the embodiment of the present invention, the terminal communication protocol is obtained through the terminal identification, and the transmission data stream configuration information of the terminal is determined through the terminal communication protocol, thereby improving the accuracy of terminal information identification.
在本发明的一种优选实施例中,所述识别模块310具体用于:In a preferred embodiment of the present invention, the identification module 310 is specifically used to:
接收用户输入的各个终端对应的通信协议和传输数据流配置信息。Receive the communication protocol and transmission data flow configuration information corresponding to each terminal input by the user.
具体地,识别模块310提供用于输入信息的界面,用户手动输入各个终端对应的通信协议和传输数据流配置信息,提交之后,识别模块310获取到各个终端对应的通信协议和传输数据流配置信息,对于无法自动识别的终端通信协议和传输数据流配置信息,也能准确地获取到信息,扩大了终端信息识别的应用范围。Specifically, the identification module 310 provides an interface for inputting information. The user manually inputs the communication protocol and transmission data flow configuration information corresponding to each terminal. After submission, the identification module 310 obtains the communication protocol and transmission data flow configuration information corresponding to each terminal. , for terminal communication protocols and transmission data flow configuration information that cannot be automatically identified, the information can also be accurately obtained, expanding the application scope of terminal information identification.
在本发明的一种优选实施例中,所述识别模块310具体用于:In a preferred embodiment of the present invention, the identification module 310 is specifically used to:
向各个终端发送测试数据包;Send test data packets to each terminal;
接收所述各个终端返回的测试数据响应包,解析所述测试数据响应包,获取各个终端对应的通信协议和传输数据流配置信息。Receive the test data response packet returned by each terminal, parse the test data response packet, and obtain the communication protocol and transmission data stream configuration information corresponding to each terminal.
具体地,识别模块310可以向各个终端发送测试数据包,并接收终端返回的测试数据包,解析测试数据包,从各个字段中分析,获取到终端对应的通信协议和传输数据流配置信息。通过多种获取终端通信协议和传输数据流配置信息的方式,扩大了终端信息识别的应用范围,提高了终端信息识别的正确率。Specifically, the identification module 310 can send test data packets to each terminal, receive the test data packets returned by the terminals, parse the test data packets, analyze each field, and obtain the communication protocol and transmission data flow configuration information corresponding to the terminal. Through multiple ways of obtaining terminal communication protocols and transmission data flow configuration information, the application scope of terminal information identification is expanded and the accuracy of terminal information identification is improved.
对于网关实施例而言,由于其与方法实施例基本相似,所以描述的比较简单,相关之处参见方法实施例的部分说明即可。As for the gateway embodiment, since it is basically similar to the method embodiment, the description is relatively simple. For relevant details, please refer to the partial description of the method embodiment.
参照图5,示出了本发明一种电子设备实施例的结构框图,所述设备包括:处理器510、机器可读介质520和总线530;Referring to Figure 5, a structural block diagram of an embodiment of an electronic device of the present invention is shown. The device includes: a processor 510, a machine-readable medium 520 and a bus 530;
其中,处理器510和机器可读介质520通过所述总线530完成相互间的通信;Wherein, the processor 510 and the machine-readable medium 520 complete communication with each other through the bus 530;
处理器510用于调用机器可读介质520中的程序指令,以执行上述各方法实施例所提供的方法,例如包括:接收第一终端发送的第一传输数据流,所述第一传输数据流是所述第一终端发送至第二终端的,所述第一终端对应的第一通信协议与所述第二终端对应的第二通信协议不同;获取所述第一终端对应的第一通信协议和第一传输数据流配置信息;根据所述第一通信协议和第一传输数据流配置信息解码所述第一传输数据流,确定多媒体数据流;获取所述第二终端对应的第二通信协议和第二传输数据流配置信息;根据所述第二传输数据流配置信息编码所述多媒体数据流,并根据所述第二通信协议将编码后的多媒体数据流转换为第二传输数据流;向所述第二终端发送所述第二传输数据流。The processor 510 is configured to call program instructions in the machine-readable medium 520 to execute the methods provided by the above method embodiments, for example, including: receiving a first transmission data stream sent by the first terminal, the first transmission data stream is sent by the first terminal to the second terminal, and the first communication protocol corresponding to the first terminal is different from the second communication protocol corresponding to the second terminal; obtain the first communication protocol corresponding to the first terminal and the first transmission data stream configuration information; decoding the first transmission data stream according to the first communication protocol and the first transmission data stream configuration information to determine the multimedia data stream; obtaining the second communication protocol corresponding to the second terminal and second transport data stream configuration information; encoding the multimedia data stream according to the second transport data stream configuration information, and converting the encoded multimedia data stream into a second transport data stream according to the second communication protocol; to The second terminal sends the second transmission data stream.
本发明实施例公开一种计算机程序产品,所述计算机程序产品包括存储在非暂态计算机可读存储介质上的计算机程序,所述计算机程序包括程序指令,当所述程序指令被计算机执行时,计算机能够执行上述各方法实施例所提供的方法,例如包括:接收第一终端发送的第一传输数据流,所述第一传输数据流是所述第一终端发送至第二终端的,所述第一终端对应的第一通信协议与所述第二终端对应的第二通信协议不同;获取所述第一终端对应的第一通信协议和第一传输数据流配置信息;根据所述第一通信协议和第一传输数据流配置信息解码所述第一传输数据流,确定多媒体数据流;获取所述第二终端对应的第二通信协议和第二传输数据流配置信息;根据所述第二传输数据流配置信息编码所述多媒体数据流,并根据所述第二通信协议将编码后的多媒体数据流转换为第二传输数据流;向所述第二终端发送所述第二传输数据流。An embodiment of the present invention discloses a computer program product. The computer program product includes a computer program stored on a non-transitory computer-readable storage medium. The computer program includes program instructions. When the program instructions are executed by a computer, The computer can execute the methods provided by the above method embodiments, for example, including: receiving a first transmission data stream sent by the first terminal, the first transmission data stream being sent by the first terminal to the second terminal, the The first communication protocol corresponding to the first terminal is different from the second communication protocol corresponding to the second terminal; obtaining the first communication protocol and the first transmission data stream configuration information corresponding to the first terminal; according to the first communication The protocol and the first transmission data stream configuration information decode the first transmission data stream to determine the multimedia data stream; obtain the second communication protocol and the second transmission data stream configuration information corresponding to the second terminal; according to the second transmission The data stream configuration information encodes the multimedia data stream, and converts the encoded multimedia data stream into a second transmission data stream according to the second communication protocol; and sends the second transmission data stream to the second terminal.
本发明实施例提供一种非暂态计算机可读存储介质,所述非暂态计算机可读存储介质存储计算机指令,所述计算机指令使所述计算机执行上述各方法实施例所提供的方法,例如包括:接收第一终端发送的第一传输数据流,所述第一传输数据流是所述第一终端发送至第二终端的,所述第一终端对应的第一通信协议与所述第二终端对应的第二通信协议不同;获取所述第一终端对应的第一通信协议和第一传输数据流配置信息;根据所述第一通信协议和第一传输数据流配置信息解码所述第一传输数据流,确定多媒体数据流;获取所述第二终端对应的第二通信协议和第二传输数据流配置信息;根据所述第二传输数据流配置信息编码所述多媒体数据流,并根据所述第二通信协议将编码后的多媒体数据流转换为第二传输数据流;向所述第二终端发送所述第二传输数据流。Embodiments of the present invention provide a non-transitory computer-readable storage medium. The non-transitory computer-readable storage medium stores computer instructions. The computer instructions cause the computer to execute the methods provided by the above method embodiments, such as The method includes: receiving a first transmission data stream sent by the first terminal, where the first transmission data stream is sent by the first terminal to a second terminal, and the first communication protocol corresponding to the first terminal is consistent with the second transmission data stream. The second communication protocol corresponding to the terminal is different; obtain the first communication protocol and the first transmission data flow configuration information corresponding to the first terminal; and decode the first communication protocol according to the first communication protocol and the first transmission data flow configuration information. Transmit the data stream and determine the multimedia data stream; obtain the second communication protocol and the second transmission data stream configuration information corresponding to the second terminal; encode the multimedia data stream according to the second transmission data stream configuration information, and encode the multimedia data stream according to the second transmission data stream configuration information. The second communication protocol converts the encoded multimedia data stream into a second transmission data stream; and sends the second transmission data stream to the second terminal.
本说明书中的各个实施例均采用递进的方式描述,每个实施例重点说明的都是与其他实施例的不同之处,各个实施例之间相同相似的部分互相参见即可。Each embodiment in this specification is described in a progressive manner. Each embodiment focuses on its differences from other embodiments. The same and similar parts between the various embodiments can be referred to each other.
本领域内的技术人员应明白,本发明实施例的实施例可提供为方法、装置、或计算机程序产品。因此,本发明实施例可采用完全硬件实施例、完全软件实施例、或结合软件和硬件方面的实施例的形式。而且,本发明实施例可采用在一个或多个其中包含有计算机可用程序代码的计算机可用存储介质(包括但不限于磁盘存储器、CD-ROM、光学存储器等)上实施的计算机程序产品的形式。It should be understood by those skilled in the art that embodiments of the present invention may be provided as methods, devices, or computer program products. Thus, embodiments of the present invention may take the form of an entirely hardware embodiment, an entirely software embodiment, or an embodiment that combines software and hardware aspects. Furthermore, embodiments of the invention may take the form of a computer program product embodied on one or more computer-usable storage media (including, but not limited to, disk storage, CD-ROM, optical storage, etc.) having computer-usable program code embodied therein.
本发明实施例是参照根据本发明实施例的方法、终端设备(系统)、和计算机程序产品的流程图和/或方框图来描述的。应理解可由计算机程序指令实现流程图和/或方框图中的每一流程和/或方框、以及流程图和/或方框图中的流程和/或方框的结合。可提供这些计算机程序指令到通用计算机、专用计算机、嵌入式处理机或其他可编程数据处理终端设备的处理器以产生一个机器,使得通过计算机或其他可编程数据处理终端设备的处理器执行的指令产生用于实现在流程图一个流程或多个流程和/或方框图一个方框或多个方框中指定的功能的装置。Embodiments of the invention are described with reference to flowcharts and/or block diagrams of methods, terminal devices (systems), and computer program products according to embodiments of the invention. It will be understood that each process and/or block in the flowchart illustrations and/or block diagrams, and combinations of processes and/or blocks in the flowchart illustrations and/or block diagrams, can be implemented by computer program instructions. These computer program instructions may be provided to a processor of a general-purpose computer, special-purpose computer, embedded processor, or other programmable data processing terminal device to produce a machine such that the instructions are executed by the processor of the computer or other programmable data processing terminal device. Means are generated for implementing the functions specified in the process or processes of the flowchart diagrams and/or the block or blocks of the block diagrams.
这些计算机程序指令也可存储在能引导计算机或其他可编程数据处理终端设备以特定方式工作的计算机可读存储器中,使得存储在该计算机可读存储器中的指令产生包括指令装置的制造品,该指令装置实现在流程图一个流程或多个流程和/或方框图一个方框或多个方框中指定的功能。These computer program instructions may also be stored in a computer-readable memory that causes a computer or other programmable data processing terminal equipment to operate in a particular manner, such that the instructions stored in the computer-readable memory produce an article of manufacture including the instruction means, the The instruction means implements the functions specified in a process or processes of the flowchart and/or a block or blocks of the block diagram.
这些计算机程序指令也可装载到计算机或其他可编程数据处理终端设备上,使得在计算机或其他可编程终端设备上执行一系列操作步骤以产生计算机实现的处理,从而在计算机或其他可编程终端设备上执行的指令提供用于实现在流程图一个流程或多个流程和/或方框图一个方框或多个方框中指定的功能的步骤。These computer program instructions can also be loaded onto a computer or other programmable data processing terminal equipment, so that a series of operating steps are performed on the computer or other programmable terminal equipment to produce computer-implemented processing, thereby causing the computer or other programmable terminal equipment to perform a computer-implemented process. The instructions executed on provide steps for implementing the functions specified in a process or processes of the flow diagrams and/or a block or blocks of the block diagrams.
尽管已描述了本发明实施例的优选实施例,但本领域内的技术人员一旦得知了基本创造性概念,则可对这些实施例做出另外的变更和修改。所以,所附权利要求意欲解释为包括优选实施例以及落入本发明实施例范围的所有变更和修改。Although preferred embodiments of the embodiments of the present invention have been described, those skilled in the art will be able to make additional changes and modifications to these embodiments once the basic inventive concepts are apparent. Therefore, it is intended that the appended claims be construed to include the preferred embodiments and all changes and modifications that fall within the scope of embodiments of the invention.
最后,还需要说明的是,在本文中,诸如第一和第二等之类的关系术语仅仅用来将一个实体或者操作与另一个实体或操作区分开来,而不一定要求或者暗示这些实体或操作之间存在任何这种实际的关系或者顺序。而且,术语“包括”、“包含”或者其任何其他变体意在涵盖非排他性的包含,从而使得包括一系列要素的过程、方法、物品或者终端设备不仅包括那些要素,而且还包括没有明确列出的其他要素,或者是还包括为这种过程、方法、物品或者终端设备所固有的要素。在没有更多限制的情况下,由语句“包括一个……”限定的要素,并不排除在包括所述要素的过程、方法、物品或者终端设备中还存在另外的相同要素。Finally, it should be noted that in this article, relational terms such as first and second are only used to distinguish one entity or operation from another entity or operation, and do not necessarily require or imply that these entities or any such actual relationship or sequence between operations. Furthermore, the terms "comprises," "comprises," or any other variation thereof are intended to cover a non-exclusive inclusion such that a process, method, article, or end device that includes a list of elements includes not only those elements, but also elements not expressly listed or other elements inherent to such process, method, article or terminal equipment. Without further limitation, an element defined by the statement "comprises a..." does not exclude the presence of additional identical elements in a process, method, article or terminal device including the stated element.
以上对本发明所提供的一种实现不同协议终端通信的方法和一种实现不同协议终端通信的装置和一种网关,进行了详细介绍,本文中应用了具体个例对本发明的原理及实施方式进行了阐述,以上实施例的说明只是用于帮助理解本发明的方法及其核心思想;同时,对于本领域的一般技术人员,依据本发明的思想,在具体实施方式及应用范围上均会有改变之处,综上所述,本说明书内容不应理解为对本发明的限制。The above is a detailed introduction to a method for realizing terminal communication with different protocols, a device for realizing terminal communication with different protocols, and a gateway provided by the present invention. Specific examples are used in this article to illustrate the principles and implementations of the present invention. The description of the above embodiments is only used to help understand the method and its core idea of the present invention; at the same time, for those of ordinary skill in the art, there will be changes in the specific implementation and application scope according to the idea of the present invention. In summary, the contents of this description should not be construed as limitations of the present invention.
Claims (10)
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202311176594.7A CN117336378A (en) | 2023-09-12 | 2023-09-12 | A method, device and gateway for realizing terminal communication with different protocols |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202311176594.7A CN117336378A (en) | 2023-09-12 | 2023-09-12 | A method, device and gateway for realizing terminal communication with different protocols |
Publications (1)
Publication Number | Publication Date |
---|---|
CN117336378A true CN117336378A (en) | 2024-01-02 |
Family
ID=89290990
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN202311176594.7A Pending CN117336378A (en) | 2023-09-12 | 2023-09-12 | A method, device and gateway for realizing terminal communication with different protocols |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN117336378A (en) |
-
2023
- 2023-09-12 CN CN202311176594.7A patent/CN117336378A/en active Pending
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN107493484A (en) | System, method and apparatus for projection screen | |
CN111263239A (en) | Video frame packet loss processing method and related device | |
CN112019792A (en) | Conference control method, device, terminal device and storage medium | |
CN107040458B (en) | Method and system for realizing intercommunication of video conference | |
CN116935864A (en) | A semantic communication method, device and system | |
WO2021057697A1 (en) | Video encoding and decoding methods and apparatuses, storage medium, and electronic device | |
CN111818010A (en) | A data transmission method, device, electronic device and storage medium | |
CN114503569B (en) | AV1 codec for real-time video communication | |
CN114710568A (en) | Audio and video data communication method, equipment and storage medium | |
CN114125397A (en) | A kind of audio and video communication method, device and system | |
CN110798651A (en) | Video conference method, device, equipment and storage medium | |
CN119211206A (en) | Data transmission method and device based on WebRTC | |
CN117336378A (en) | A method, device and gateway for realizing terminal communication with different protocols | |
CN113065077A (en) | A horizontally scalable middle-office business processing system | |
CN106550242A (en) | The conversion method and device of IP real-time media streams | |
CN111385081B (en) | End-to-end communication method and device, electronic equipment and medium | |
CN212137851U (en) | Video output device supporting HEVC decoding | |
CN114863741A (en) | Equipment communication method and system for on-line teaching | |
CN115766695A (en) | Websocket-based remote browsing method and device for real-time image of industrial camera | |
CN115714874A (en) | Video stream screen display method, device and system, stream pulling equipment and storage medium | |
CN113596505A (en) | Method, system and device for playing audio and video resources | |
CN101166279A (en) | Content transmission method and apparatus using video call | |
CN111314659B (en) | Method, device, system, electronic equipment and medium for monitoring code stream push | |
CN103561105A (en) | Image transmitting method, sending end and receiving end | |
CN117812436A (en) | Media information negotiation method, device, equipment and storage medium |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
PB01 | Publication | ||
PB01 | Publication | ||
SE01 | Entry into force of request for substantive examination | ||
SE01 | Entry into force of request for substantive examination |