A method and system for interconnection and intercommunication between a terminal device and a browser

By establishing a point-to-point connection with terminal devices through the SIP protocol and utilizing the RTC module to process streaming media, the issues of interoperability, real-time performance, and security in the interconnection between terminal devices and browsers are resolved, achieving efficient interconnection.

CN119094505BActive Publication Date: 2025-12-19GUANGZHOU BAOLUN ELECTRONICS CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202411051689.0
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2024-08-01
Publication Date
2025-12-19
Estimated Expiration
2044-08-01

AI Technical Summary

Technical Problem

Existing methods for interconnecting terminal devices and browsers cannot simultaneously meet the requirements of interoperability, real-time performance, and security.

Method used

It uses the SIP protocol to establish a point-to-point connection with the terminal device, processes streaming media through the RTC module, and performs policy bridging inside the server to achieve interconnection between the terminal device and the browser.

Benefits of technology

It improves real-time performance and security, reduces server load and CPU resource consumption, and enables efficient interconnection between terminal devices and browsers.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119094505B_ABST
    Figure CN119094505B_ABST
Patent Text Reader

Abstract

The application discloses a kind of terminal equipment and the method, system of interconnection and intercommunication of browser, the method includes: client sends signaling request to server, the client is browser or terminal equipment;Signaling module is handled as instruction of uniform format to the signaling request, and the instruction is sent to instruction processing submodule;Instruction processing submodule sends the instruction to rtc submodule and processes, rtc submodule creates offer sdp and sets the answer of opposite end, according to the offer sdp and the answer of opposite end, rtc submodule is connected with terminal equipment or browser by sdp data Point-to-point connection;Server generates abstract proxy entity object and sets to bridge strategy submodule, bridge strategy submodule establishes mapping relationship between the same stream_name stream name entity, and carries out data forwarding.The application can simultaneously meet intercommunication, real-time, security, realize terminal equipment and the two-way real-time audio and video communication of browser.
Need to check novelty before this filing date? Find Prior Art

Description

TECHNICAL FIELD

[0001] The present application relates to the technical field of data transmission, and particularly relates to a method and system for interconnection and intercommunication between a terminal device and a browser. BACKGROUND

[0002] Web browsers have become the mainstream product used by users, so terminal devices with intercom functions can also realize two-way intercom functions with browsers to achieve interconnection and intercommunication. In this scenario, the intercommunication, real-time performance, security and other issues need to be considered comprehensively. Although the existing technologies such as using rtsp and rtmp to realize stream pushing and pulling can meet the interconnection and intercommunication functions, they cannot meet the above requirements of real-time performance or security at the same time.

[0003] In summary, there is an urgent need in the industry to develop an interconnection and intercommunication method or system that can meet the intercommunication, real-time performance and security at the same time. SUMMARY

[0004] The present application aims to overcome the deficiencies of the prior art and provides a method and system for interconnection and intercommunication between a terminal device and a browser that can meet the intercommunication, real-time performance and security at the same time.

[0005] The purpose of the present application is achieved by the following technical solutions:

[0006] The present application provides a method for interconnection and intercommunication between a terminal device and a browser, which comprises the following steps:

[0007] S1, a client sends a signaling request to a server, the client being a browser or a terminal device;

[0008] S2, a signaling module of the server processes the signaling request into an instruction in a unified format and sends the instruction to an instruction processing submodule; the instruction contains a stream_name flow name, a uid instruction code, a cmd instruction code and data carried by the cmd_data instruction code;

[0009] S3, the instruction processing submodule sends the instruction to an rtc submodule for processing, the rtc submodule creates an offer sdp and sets an answer of the opposite end, the opposite end being a browser or a terminal device;

[0010] S4, according to the offer sdp and the answer of the opposite end, the rtc submodule performs point-to-point connection with the terminal device or the browser through the data in the sdp;

[0011] S5, the server sets the generated abstract proxy entity object into a bridge strategy submodule, the bridge strategy submodule establishes a mapping relationship between entities with the same stream_name flow name and performs data forwarding, thereby realizing interconnection and intercommunication between the terminal device and the browser.

[0012] Preferably, between step S3 and step S4, there is further included: judging the client type by a data module according to a uid field in the instruction, if it is a browser, then an rtc submodule performs point-to-point connection with a terminal device or a browser through data in sdp, including:

[0013] S401, sending the processing result of the rtc submodule to a signaling module, and the signaling module constructing response data of a signaling request according to the processing result;

[0014] S402, the signaling module returning the constructed data to obtain offer data created by the server;

[0015] S403, repeating steps S1-S3, S401-S402 twice to realize sdp exchange of offer / answer, and the rtc submodule establishing point-to-point connection with the browser.

[0016] Preferably, if it is a terminal device, then the rtc submodule performs point-to-point connection with a terminal device or a browser through data in sdp, including:

[0017] S411, the sip submodule receiving an offer sdp;

[0018] S412, querying corresponding terminal information through a uid instruction code, filling the offer sdp into a sip invate according to the terminal information, and sending to a peer terminal;

[0019] S413, the peer terminal receiving the invate request and carrying an answer sdp of a terminal device response this time in a sip ack protocol packet;

[0020] S414, setting the terminal device to extract the answer sdp to an rtc module, and the rtc submodule establishing point-to-point connection with the terminal device.

[0021] Preferably, the sdp exchange of the offer / answer in step S403 includes: offer sdp creation and answer sdp setting; the offer sdp creation includes: the browser sends an http request to the server, the server first processes and analyzes the http request through the signaling module, the server obtains the instruction code by analyzing the signaling module, judges that the offer sdp needs to be created, creates the offer sdp through the rtc module, and returns the offer sdp to the signaling module; the signaling module returns the offer sdp through the http protocol; the answer sdp setting includes: after the browser receives the offer sdp, the answer sdp is created, an http request is sent to the server, and the answer sdp is carried; the server is analyzed through the signaling module; the server obtains the instruction code by analyzing the signaling module; according to the instruction code, it is judged that it is the instruction of setting the answer, the answer sdp information is extracted and set to the rtc module, the rtc module sets the answer sdp, the offer / answer sdp exchange is realized, and the point-to-point connection with the browser is started.

[0022] The second aspect of the application provides a system for interconnection and intercommunication between a terminal device and a browser, comprising a data module, a signaling module and a flow management module; wherein the flow management module comprises an instruction processing submodule, an rtc submodule, an sip submodule and a bridging strategy submodule; the data module is configured to acquire static data and dynamic data, wherein the static data is acquired by querying a connection database, and the dynamic data is dynamic push data of the terminal device; the signaling module is configured to process a udp request protocol and an http request protocol sent by the terminal device to obtain instructions in a unified format, wherein the instructions comprise a stream name stream_name, a user identifier uid and an instruction code cmd; the instruction processing submodule is configured to extract the user identifier uid and determine whether the user type is a browser or a terminal device according to the user identifier uid; the rtc submodule is configured to create an offer sdp and set an answer sdp of a peer, wherein a virtual entity connected to the peer is abstracted in the system during the creation of the offer sdp, and the peer is connected in a point-to-point manner by analyzing the answer sdp when the answer sdp of the peer is received; the sip submodule is configured to receive the offer sdp and the instructions, obtain address information of the terminal device corresponding to the user identifier uid according to the user identifier uid in the instructions, fill the offer sdp into a sipinvate protocol sent to the corresponding terminal device, and return the answer sdp by the terminal device, at this time, the corresponding answer sdp is set to the rtc submodule; and the bridging strategy submodule is configured to establish a forwarding relationship between proxy entities, and adapt and convert protocols of the browser and the terminal device.

[0023] Preferably, the instruction processing submodule comprises an sdp creation unit and a user type judgment unit; the sdp creation unit is configured to transmit the user identifier uid to the rtc submodule, and the rtc submodule creates an offer sdp, wherein the offer sdp comprises transmission information parameters of both ends, used encoder parameters and a security policy; and the user type judgment unit is configured to determine the user type according to the offer sdp, and if it is determined that the user type is a browser, return to the signaling module for an http response; if it is determined that the user type is a terminal device, input the instructions and the offer sdp to the sip submodule.

[0024] Preferably, the bridging strategy submodule is further configured to internally bridge both sides with the same stream_name extracted from the instructions, and adapt an rtp packet received at one end into an rtp packet format negotiated at the other end.

[0025] Compared with the prior art, the application has the following advantages:

[0026] The server of the application uses sip protocol to negotiate point-to-point connection with terminal device, the terminal device needs to support sip protocol, and only uses sip protocol to exchange sdp, the processing of stream media is processed by rtc module, in addition, since the data packet is directly forwarded, encoding and decoding are not needed, the CPU resource consumption is very small. And the direct forwarding greatly reduces the delay, so the real-time of the device link is guaranteed by the server.

[0027] The other end server establishes point-to-point connection with the browser by exchanging sdp twice through http, the webrtc protocol guarantees good real-time and security, the internal strategy bridge of the server is carried out, the whole realizes the interconnection and intercommunication of the terminal device and the browser, and also guarantees the real-time and security.

[0028] Meanwhile, the underlying stream media analysis of sip protocol and webrtc protocol is based on rtp / rtcp, the work on protocol conversion between the two is less, and through the server generating offer sdp mode, the server as the active party can unify the media format used by both ends from the source, the encoder used, so that the server can avoid the adaptation work of both ends, the server can realize conversion with small amount of calculation, which can reduce the load of the server and guarantee the real-time. BRIEF DESCRIPTION OF DRAWINGS

[0029] The drawings constituting a part of the specification of the application are used to provide further understanding of the application, the illustrative embodiments of the application and the description thereof are used to explain the application, and do not constitute improper limitation on the application. In the drawings:

[0030] Figure 1 It is a flow chart of the method for interconnecting and intercommunicating the terminal device and the browser of the application.

[0031] Figure 2 It is a block diagram of the system for interconnecting and intercommunicating the terminal device and the browser of the application.

[0032] Figure 3 It is a flow chart of the stream management module of the application. DETAILED DESCRIPTION

[0033] The application will be further described below in combination with the drawings and embodiments.

[0034] Reference Figures 2-3The system for interconnection and intercommunication between a terminal device and a browser comprises a data module, a signaling module and a stream management module; the stream management module comprises an instruction processing submodule, an RTC submodule, an SIP submodule and a bridging strategy submodule; the data module is configured to acquire static data and dynamic data, wherein the static data is acquired by querying a database, and the dynamic data is dynamic push data of the terminal device; the signaling module is configured to process a UDP request protocol and an HTTP request protocol sent by the terminal device to obtain instructions in a unified format, wherein the instructions comprise a stream name stream_name, a user identifier uid and an instruction code cmd; the instruction processing submodule is configured to extract the user identifier uid and determine whether the user type is a browser or a terminal device according to the user identifier uid; the RTC submodule is configured to create an offer sdp and set an answer sdp of a peer, abstract a virtual entity connected with the peer in a system during the creation of the offer sdp, and perform point-to-point connection with the peer by analyzing the answer sdp when the answer sdp of the peer is received; the SIP submodule is configured to receive the offer sdp and the instructions, obtain address information of the terminal device corresponding to the user identifier uid according to the user identifier uid in the instructions, fill the offer sdp into a SIP invite protocol sent to the corresponding terminal device, return an answer sdp by the terminal device, and set the corresponding answer sdp to the RTC submodule at the same time; and the bridging strategy submodule is configured to establish a forwarding relationship between proxy entities and adaptively convert protocols of the browser and the terminal device.

[0035] In the embodiment, the data module mainly acquires data from other services in the system, and is divided into static data and dynamic data. The static data is acquired by querying a database, and the dynamic data is acquired by connecting a relay server for managing terminal devices to acquire online states of the terminal devices, dynamic push data such as task execution of the terminal devices, and the like. The function of the module is provided to other modules for querying data for common use. The other services in the system can be a data service, a service program of which accesses a database to provide a database access interface for other programs, and mainly provides basic information of the terminal devices, such as a model, an IP address and the like. The other services in the system can also be a relay service, a service program of which is connected with the terminal devices to acquire online information and state information of the terminal devices. The other services in the system can also be other services, which are not limited here.

[0036] In the embodiment, the signaling module is an entrance of the entire server, and supports a UDP request protocol and an HTTP request protocol sent by the terminal device. The signaling module transmits instructions in a unified format obtained by the signaling module to the stream management module.

[0037] In the embodiment, the instruction processing submodule includes an sdp creation unit and a user type judgment unit; the sdp creation unit is configured to transmit a user identifier uid to an rtc submodule, and the rtc submodule creates an offer sdp, which includes transmission information parameters of two ends, used encoder parameters and security policies; the user type judgment unit is configured to judge the user type according to the offer sdp, and if it is judged that the user type is a browser, the instruction processing submodule returns to a signaling module for http response; if it is judged that the user type is a terminal device, the instruction and the offer sdp are input to a sip submodule; the instruction processing submodule mainly extracts the user identifier uid, and judges the user type to be a browser or a terminal device through a data module. Regardless of the type, the first stage is to transmit the user identifier uid to the rtc submodule to create an offer type sdp (offer sdp), and the sdp represents a session description protocol. The text describes transmission information parameters of two ends, used encoder parameters, security policies and the like, which are created by the server. After the sdp is created, the second stage is performed; the second stage judges the user type, returns to the signaling module for http response for the browser type, and inputs the instruction and the created offer sdp to the sip submodule for the terminal type. The sip submodule performs an invate interaction with the corresponding terminal device, sets an answer sdp in the invate process to the rtc submodule, and finally returns the result of the whole process to the signaling module for return. The offer sdp information is returned and carried in the http response.

[0038] In the embodiment, the sip submodule receives the offer sdp and instruction data of the instruction processing submodule, extracts a user identifier uid field, and obtains address information of the terminal through a data module. The offer sdp is used to fill the sip invate protocol to the corresponding terminal, the terminal returns an answer sdp under normal circumstances, and the corresponding answer sdp is set to the rtc submodule. The user identifier uid is parsed by the signaling module, because the data sent by the terminal is generally based on udp, and the request sent by the browser is generally based on http / https. The signaling module processes different formats of external request types into internal definition structure data.

[0039] In the embodiment, the rtc submodule provides two functions of creating an offer sdp and setting an answer sdp of a peer. In the stage of creating the offer sdp, a virtual entity connected with the peer is abstracted internally. When the answer sdp of the peer is received, the peer is connected through the analysis of the answer sdp. The virtual entity abstracted internally by the rtc submodule can be considered as a proxy of the peer in the server. The entity is internally composed of two sub-objects, which are a push stream end of an uplink of the server as a receiver and the peer as a sender, and a pull stream end of a downlink of the server as a sender and the peer as a receiver. The server implements synchronization, jitter optimization, jitterbuf, and various standard protocol rtcp packets including nack, pli, xr, rr, and the like on the side. The other sub-object is the pull stream end of the downlink of the server as the sender and the peer as the receiver. The internal implementation includes smooth sending, nack packet loss retransmission, and gcc Google congestion control algorithm.

[0040] In the embodiment, the bridging strategy submodule is also used to internally bridge two sides with the same stream_name extracted from the instructions to each other, and adapt the rtp packet received by one end into the rtp packet format negotiated by the other end. The main function of the bridging strategy submodule is to establish a forwarding relationship among the proxy entities generated by the multiple rtc submodules, and to adapt and convert the protocols of the two ends. Specifically, the two sides with the same stream_name extracted from the instructions are internally bridged to each other, and the rtp packet received by one end is adapted into the rtp packet format negotiated by the other end.

[0041] Referring to Figures 1-3 , a terminal device and browser interconnection and intercommunication method suitable for the terminal device and browser interconnection and intercommunication system described above includes the following steps.

[0042] S1, a client sends a signaling request to a server, the client is a browser or a terminal device; the signaling request can be in http format or udp format.

[0043] S2, the signaling module of the server processes the signaling request into an instruction in a unified format, and sends the instruction to an instruction processing submodule; the instruction contains a stream_name flow name, a uid instruction code, a cmd instruction code, and data carried by a cmd_data instruction code; the signaling module is one of the modules inside the server, the server simultaneously listens to a udp port and an http port, the signaling request of the terminal device is data coming from the udp port, the signaling request of the browser is data coming from the http port, because the data packet encapsulation formats of different ports are different, all the signaling requests of different sources received are processed by the signaling module into an instruction in a unified internal format data; the instruction contains a stream_name flow name, a uid instruction code, a cmd instruction code, and data carried by a cmd_data instruction code; the uid instruction code is a user id, the type of the user can be obtained through the data module through the field, and through the type, it can be known which terminal device is communicated or which browser user is communicated.

[0044] S3, the instruction processing submodule sends the instruction to an rtc submodule for processing, the rtc submodule creates an offer sdp and sets an answer of the opposite end; if an offer is created, the user type is judged through the data module according to the uid field in the unified instruction, if it is a browser, steps S401-S403 are executed, and then step S5 is executed, if it is a terminal device, steps S411-S414 are executed, and then step S5 is executed.

[0045] In the embodiment, the opposite end is a browser or a terminal device, if the sdp is exchanged in the form of http, the browser is communicated, if the sdp is exchanged in the form of a sip protocol, the terminal device is communicated.

[0046] S401, according to the processing result of the rtc submodule, the signaling module sends a response data of the signaling request to the signaling module; the core field of the response data includes:

[0047] {

[0048] Errno: error code

[0049] Offer: sdp text string

[0050] }

[0051] S402, the signaling module returns the constructed data, obtains the offer data created by the server; returns according to the corresponding link of the source type of the request, if the protocol of the request is the http protocol, returns through the http protocol, if the protocol of the request is the udp protocol, returns through the udp protocol. That is, the http protocol is used for communication with the browser, and the udp protocol is used for communication with the device terminal.

[0052] S403, steps S1-S3, S401-S402 are repeatedly executed twice, sdp exchange of offer / answer is realized, and the rtc submodule establishes a point-to-point connection with the browser. Because one offer and answer interaction can only establish one point-to-point connection, two offer and answer interactions establish point-to-point connections with the opposite end in turn. Among them, the sdp exchange of offer / answer here is the process of establishing a point-to-point connection between the browser type and the server, and the complete flow includes:

[0053] Offer stage:

[0054] 1. The browser sends an http request to the server;

[0055] 2. The server is first processed and parsed by the signaling module;

[0056] 3. The server parses the instruction code obtained through the signaling module, judges that an offer sdp needs to be created, then creates the offer sdp through the rtc module, and returns it to the signaling module;

[0057] 4. The signaling module receives the offer sdp created by the rtc module, and returns it through the http protocol.

[0058] Answer stage:

[0059] 1. After the browser receives the offer sdp, it creates an answer sdp, sends an http request and carries the answer sdp to the server;

[0060] 2. The server is parsed by the signaling module;

[0061] 3. The server parses the instruction code through the signaling, judges that it is an instruction for setting the answer, and then extracts the answer sdp information in it and sets it to the rtc module

[0062] 4. The rtc module sets the answer sdp, realizes the sdp exchange of offer / answer, and starts the point-to-point connection with the browser.

[0063] In the embodiment, the rtc submodule establishes a p2p point-to-point connection with the browser, and the process of establishing the connection needs to go through the following three steps:

[0064] 1. An ice interactive process is performed to establish an ice connection.

[0065] 2. The transmission channel is encrypted, and a dtls protocol handshake is performed.

[0066] 3. The streaming media channel is successfully established, and the two parties perform bidirectional audio and video data communication transmission.

[0067] It should be noted that the point-to-point connection with the browser uses the Webrtc protocol, and the Webrtc protocol is a collection of a series of protocols. The steps of establishing a webrtc connection include:

[0068] 1. Two http requests are used to exchange sdp session description protocols of both ends.

[0069] 2. According to the information in the sdp, an ice connection and a dtls interactive process are established for data communication.

[0070] 3. The rtp / rtcp audio and video data packets are transmitted based on the established communication link.

[0071] The above process indicates the sdp exchange method, the subsequent ice and dtls process, and finally the transmission of the rtp / rtcp load audio and video data packets, so the webrtc protocol has been implemented.

[0072] S411, the sip submodule receives an offer sdp;

[0073] S412, the terminal information corresponding to the offer sdp is queried through the uid instruction code, the offer sdp is filled into the sip invate according to the terminal information, and the sip invate is sent to the opposite end;

[0074] S413, the opposite end receives the invate request and carries the answer sdp of the terminal device response this time in the sip ack protocol package. The server internally listens to the 5060 port, which is used for sip protocol communication with the device terminal. After the server receives the signaling request, the unified data is obtained by parsing in the signaling module. The terminal device information to be communicated can be obtained in the data module through the information in the data. The important data includes the address for communication with the terminal device. The server constructs the offer and sends the sip invate request to the address. The corresponding terminal device returns the answer information according to the sip protocol and carries it in the sip ack protocol package.

[0075] S414, the terminal device is extracted to the answer sdp setting to the rtc module, and the rtc submodule establishes a point-to-point connection with the terminal device.

[0076] The rtc module has obtained the sdp data of both ends through the above steps, and performs point-to-point connection with the terminal device or the browser through the data in the sdp.

[0077] S5, the server sets the generated abstract proxy entity object to the bridge strategy submodule, the bridge strategy submodule establishes a mapping relationship between entities with the same stream_name flow name, and performs data forwarding, thereby realizing interconnection and intercommunication between the terminal device and the browser.

[0078] In summary, the application provides a method compatible with sip and webrtc protocols and realizing interconnection and intercommunication between the two protocols, which is cross-protocol conversion and takes into account real-time performance. Specifically, the server uses the sip protocol to negotiate point-to-point connection with the terminal device, the terminal device needs to support the sip protocol, and only the sip protocol is used to exchange sdp functions, and the stream media is processed by the rtc module, so that the server guarantees the real-time performance of the device link. Because the server adopts the architecture design of sfu, the most core feature of the SFU server is to "disguise" itself as a sip protocol or webrtc Peer client, and other clients actually do not know whether they are connected to a real client or a server through point-to-point connection. The server internally performs bridge forwarding of data, so that it can better adapt to different network conditions and terminal types (browser or terminal). Thus, since the data packets are directly forwarded, there is no need for encoding and decoding, and the CPU resource consumption is very small. And direct forwarding also greatly reduces the delay and improves the real-time performance. The other end establishes a point-to-point connection with the browser through twice http exchange of sdp, and the webrtc protocol guarantees good real-time performance and security. The server internally performs strategy bridging, thereby realizing interconnection and intercommunication between the terminal device and the browser, and guaranteeing real-time performance and security. At the same time, the sip protocol and the webrtc protocol are based on rtp / rtcp for stream media analysis, and the work of protocol conversion is less. Through the server generation of offer sdp, the server as the active party can unify the media formats and encoders used by both ends from the source, so that the server can avoid the adaptation work of both ends, and the server can realize conversion with less computing amount, which can reduce the load of the server and guarantee the real-time performance.

[0079] The above specific embodiments are the preferred embodiments of the present application, and cannot limit the present application, any changes or other equivalent replacement manners made without departing from the technical solutions of the present application are included in the protection scope of the present application.

Claims

1. A method for interconnecting a terminal device and a browser, characterized in that, include: S1, the client sends a signaling request to the server; the client is a browser or a terminal device. S2, the server's signaling module processes the signaling request into a unified format instruction and sends the instruction to the instruction processing submodule; the instruction includes the stream name (stream_name), uid instruction code, cmd instruction code, and data carried by the cmd_data instruction code. S3, the instruction processing submodule sends the instruction to the RTC submodule for processing; the RTC submodule creates an offerersdp and sets the answer for the peer (browser or terminal device). S4, based on the offerersdp and the peer's answer, the RTC submodule establishes a peer-to-peer connection with the terminal device or browser through the data in the SDP. S5, the server sets the generated abstract proxy entity object in the bridging strategy submodule; the bridging strategy submodule establishes a mapping relationship between entities with the same stream name (stream_name) and forwards data, enabling interconnection between the terminal device and the browser. Between steps S3 and S4, the process further includes: determining the client type based on the uid field in the instruction via the data module; if it is a browser, the RTC submodule establishes a peer-to-peer connection with the terminal device or browser through the SDP data; S401, sending the processing result of the RTC submodule to the signaling module, and the signaling module constructing response data for the signaling request based on the processing result; S402, the signaling module returning the constructed data to obtain the offer data created by the server; S403, repeating steps S1-S3 and S401-S402 twice to achieve SDP exchange of offer / answer, and establishing a peer-to-peer connection between the RTC submodule and the browser; If it is a device terminal, the RTC submodule establishes a peer-to-peer connection with the terminal device or browser through the data in the SDP, including: S411, the SIP submodule receives the offerersdp; S412, the corresponding terminal information is retrieved through the UID command code, the offerersdp is filled into the sipinvate according to the terminal information, and sent to the peer; S413, the peer receives the invite request and carries the answersdp of the terminal device's current response in the sipack protocol packet; S414, the answersdp extracted from the terminal device is set in the RTC module, and the RTC submodule establishes a peer-to-peer connection with the terminal device. The offer / answer SDP exchange in step S403 includes: offersdp creation and answersdp setting. Offersdp creation involves the browser sending an HTTP request to the server. The server first processes and parses the HTTP request through a signaling module. Based on the command code obtained from the signaling module, if the server determines that an offersdp needs to be created, it will create the offersdp through the RTC module and return the offersdp to the signaling module. The signaling module then carries the offersdp in the HTTP protocol and returns it. Answersdp setting involves the browser receiving the offersdp, creating the answersdp, and sending an HTTP request carrying the answersdp to the server. The server parses the request through a signaling module. Based on the command code obtained from the signaling module, the server determines that it is an instruction to set the answer. It then extracts the answersdp information and sets it to the RTC module. The RTC module sets the answersdp, realizing the offer / answersdp exchange and initiating a peer-to-peer connection with the browser.

2. A system for interconnecting terminal devices and browsers, characterized in that, include: The system comprises a data module, a signaling module, and a stream management module. The stream management module includes an instruction processing submodule, an RTC submodule, a SIP submodule, and a bridging strategy submodule. The data module acquires static and dynamic data; static data is obtained by querying a database, while dynamic data is dynamically pushed data from terminal devices. The signaling module processes UDP and HTTP request protocols sent by the terminal to obtain instructions in a unified format, including a stream name (stream_name), a user identifier (uid), and a command code (cmd). The instruction processing submodule extracts the user identifier (uid) to determine whether the user is a browser or a terminal device. The RTC submodule creates offers. The system uses a DP (Dedicated Programming) module and sets the answersDP (AnswersDP) of the peer. During the offerersDP creation phase, a virtual entity connected to the peer is abstracted internally. Upon receiving the peer's answersDP, a point-to-point connection is established by parsing the answersDP. The SIP (Simplified Protocol over Instructions) submodule receives the offersDP and instructions, obtains the address information corresponding to the terminal device based on the user identifier (uid) in the instructions, fills the SIPIVATE protocol sent to the corresponding terminal device with the offersDP, and the terminal returns the answersDP. At the same time, the corresponding answersDP is set in the RTC (Richter / Telecom) submodule. The bridging policy submodule is used to establish forwarding relationships between proxy entities and adapt and convert the protocols of the browser and the terminal device. The instruction processing submodule includes an SDP creation unit and a user type determination unit. The SDP creation unit is used to pass the user identifier (UID) to the RTC submodule, which then creates an offerersDP. The offerersDP includes transmission information parameters from both ends, encoder parameters, and security policies. The user type determination unit is used to determine the user type based on the offerersDP. If the user type is determined to be a browser, it sends the result back to the signaling module for an HTTP response. If the user type is determined to be a terminal device, the instruction and offerersDP are input to the SIP submodule. The bridging strategy submodule is also used to bridge the two sides with the same stream_name obtained from the instruction extraction together, and adapt the RTP packet received at one end to the RTP packet format negotiated by the other end.

Citation Information

Patent Citations

  • Real-time communication method, terminal equipment, real-time communication server and system

    CN103580986A

  • Data routing system and method

    CN116366738A