Data transmission method and system

By establishing multi-channel packet building chain and clock source alignment technology in the home network, the problem of out-of-synchronization of multi-channel video transmission due to insufficient wireless signal coverage is solved, and efficient multi-channel out-of-stream speed and synchronization are achieved.

CN119232995AInactive Publication Date: 2024-12-31ZHEJIANG DAHUA TECH CO LTD

Patent Information

Application Number
CN202411729511.7
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-11-28
Publication Date
2024-12-31
Estimated Expiration
Not applicable · inactive patent

AI Technical Summary

Technical Problem

The wireless signal coverage in the home network is insufficient or signal interference, resulting in the inability to guarantee the transmission quality of multi-channel video transmission, which is prone to the problem of outflow outflow. The existing technology improves the anti-network fluctuation ability by increasing cache, but cannot improve multi-channel outflow. Flow speed.

Method used

Through multi-channel packet formation, a target link is established, multiple logical channels are mapped to the target link, ensuring the synchronization of media frames of different channels during transmission, and clocking through the sending end with the time information of the data to be transmitted Source alignment ensures synchronization of transmitted picture data.

Benefits of technology

Even in the case of network fluctuations, the multi-channel outflow velocity and outflow synchronization can be ensured, and the picture outflow velocity and time synchronization can be improved.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119232995A_ABST
    Figure CN119232995A_ABST
Patent Text Reader

Abstract

The embodiment of the invention provides a data transmission method and system, and the method is applied to a transmitting end, and comprises the steps: obtaining a media frame based on to-be-transmitted data and corresponding time information, and transmitting the media frame to a corresponding logic channel; according to the sequence of the time information, media frames are selected from all the logic channels in sequence and transmitted to a target link, and the media frames are sent to a receiving end through the target link, so that after the receiving end receives the media frames, the time information of the media frames and the corresponding logic channels are obtained based on the time information of the media frames. And reconstructing a data stream corresponding to each logic channel. A plurality of logic channels are mapped by establishing a target link, the target link is transmitted and shared by multiple channels, and even if network fluctuation occurs, the outflow speed and the outflow synchronism of the multiple channels can be ensured; by adding time information and performing clock source alignment, the synchronization of transmission picture data is ensured, the picture outflow speed is increased, and the picture time synchronization is improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the field of communication technology, and in particular to a data transmission method and system. Background Art

[0002] With the development of the Internet of Things, more and more intelligent Internet of Things scenarios are being applied. Some scenarios involve multi-channel devices, such as multi-eye cameras that capture images through multiple cameras, simulate the binocular vision of the human eye, and integrate monitoring and intelligence around the three levels of perception, judgment, and action; Network Video Recorder (NVR) provides multiple network cameras. These application scenarios are inseparable from real-time audio and video, intelligent events, and streaming media transmission technology.

[0003] Home networks usually use wireless networks (Wi-Fi) or cellular transmission. The wireless signal coverage is insufficient or there is signal interference. The transmission quality of multi-channel video transmission cannot be guaranteed, and outgoing streams are prone to being out of sync.

[0004] In the related art, the ability to resist network fluctuations is improved by increasing the cache. However, increasing the cache cannot increase the multi-channel outflow speed and will lead to an increase in data. Summary of the invention

[0005] The embodiments of the present application provide a data transmission method and system for improving the outbound flow speed and outbound flow synchronization of a multi-channel real-time streaming service.

[0006] In a first aspect, an embodiment of the present application provides a first data transmission method, which is applied to a sending end, and the method includes: Obtaining a media frame based on each data to be transmitted and the corresponding time information, and transmitting the media frame to the corresponding logical channel; According to the order of the time information, media frames are selected from all logical channels in turn and transmitted to the target link, and the media frames are sent to the receiving end through the target link, so that after receiving the media frames, the receiving end can reconstruct the data streams corresponding to the logical channels based on the time information of the media frames and the corresponding logical channels.

[0007] In some optional implementation manners, before obtaining the media frame based on each data to be transmitted and the corresponding time information, the method further includes: In response to the link establishment request sent by the receiving end, establish the target link with the receiving end, and map the logical channel corresponding to the link establishment request to the target link; The link establishment request is triggered when the receiving end determines that the target link does not exist at the start of the media service.

[0008] In some optional implementation manners, before obtaining the media frame based on each data to be transmitted and the corresponding time information, the method further includes: In response to the mapping request sent by the receiving end, mapping the logical channel corresponding to the mapping request to the target link; The mapping request is triggered when the receiving end determines that the target link exists at the start of the media service.

[0009] Some optional implementations also include: In response to the channel modification request sent by the receiving end, the mapping between the logical channel and the target link is adjusted.

[0010] Some optional implementations also include: If the number of media frames in all logical channels is greater than a preset number, a target media frame is selected from the logical channels based on the time information, and the target media frame is discarded.

[0011] In a second aspect, an embodiment of the present application provides a second data transmission method, which is applied to a receiving end, and the method includes: Receive a media frame from a target link; wherein the target link maps a plurality of logical channels, and the media frame in the target link is obtained by the transmitter based on each data to be transmitted and the corresponding time information, and after the media frame is transmitted to the corresponding logical channel, the media frame is sequentially selected from all logical channels in the order of the time information and transmitted to the target link; Based on the time information of the media frame and the corresponding logical channel, the data stream corresponding to each logical channel is reconstructed.

[0012] In some optional implementation manners, before receiving the media frame from the target link, the method further includes: When the media service starts, determining whether the target link exists between the transmitting end and the transmitting end; If yes, sending a mapping request to the receiving end, so that the sending end maps the corresponding logical channel to the target link based on the mapping request; Otherwise, a link establishment request is sent to the receiving end, so that the sending end establishes the target link with the receiving end based on the link establishment request, and maps the logical channel corresponding to the link establishment request to the target link.

[0013] In some optional implementations, reconstructing a data stream corresponding to each logical channel based on the time information of the media frame and the corresponding logical channel includes: For any logical channel, all media frames corresponding to the logical channel are sorted according to the sequence of the time information to generate a data stream corresponding to the logical channel.

[0014] Some optional implementations also include: In response to the channel modification instruction, a channel modification request is sent to the receiving end, so that the sending end adjusts the mapping between the logical channel and the target link based on the channel modification request.

[0015] In some optional implementation manners, after reconstructing the data streams corresponding to each logical channel, the method further includes: For any logical channel, the media frames of the logical channel are decoded and played through the application layer.

[0016] In a third aspect, an embodiment of the present application provides a data transmission system, the data transmission system comprising a transmitting end, a target link and a receiving end; wherein: A transmitting end, configured to obtain a media frame based on each data to be transmitted and the corresponding time information, and transmit the media frame to a corresponding logical channel; The transmitting end is further used to select media frames from all logical channels in sequence according to the order of the time information and transmit them to the target link, and send the media frames to the receiving end through the target link; The receiving end is used to reconstruct the data stream corresponding to each logical channel based on the time information of the media frame and the corresponding logical channel.

[0017] In some optional implementation manners, the receiving end is further configured to: When the media service starts, determining whether the target link exists between the transmitting end and the transmitting end; If yes, a mapping request is sent to the receiving end; otherwise, a link establishment request is sent to the receiving end; The sender is also used to: In response to the link establishment request sent by the receiving end, establish the target link with the receiving end, and map the logical channel corresponding to the link establishment request to the target link; In response to the mapping request sent by the receiving end, the logical channel corresponding to the mapping request is mapped to the target link.

[0018] In some optional implementation manners, the receiving end is further configured to: In response to the channel modification instruction, sending a channel modification request to the receiving end; The sender is also used to: In response to the channel modification request sent by the receiving end, the mapping between the logical channel and the target link is adjusted.

[0019] In some optional implementation manners, the sending end is further configured to: If the number of media frames in all logical channels is greater than a preset number, a target media frame is selected from the logical channels based on the time information, and the target media frame is discarded.

[0020] In some optional implementation manners, the receiving end is specifically used for: For any logical channel, all media frames corresponding to the logical channel are sorted according to the sequence of the time information to generate a data stream corresponding to the logical channel.

[0021] In some optional implementation manners, the receiving end is further configured to: For any logical channel, the media frames of the logical channel are decoded and played through the application layer.

[0022] In a fourth aspect, an embodiment of the present application provides a first data transmission device, which is applied to a sending end, and the device includes: A cache module, used to obtain a media frame based on each data to be transmitted and the corresponding time information, and transmit the media frame to the corresponding logical channel; A transmission module is used to select media frames from all logical channels in sequence according to the order of the time information and transmit them to a target link, and send the media frames to a receiving end through the target link, so that after receiving the media frames, the receiving end can reconstruct the data streams corresponding to the logical channels based on the time information of the media frames and the corresponding logical channels.

[0023] Some optional implementations further include a first establishing module, configured to: Before the cache module obtains the media frame based on each data to be transmitted and the corresponding time information, in response to the link establishment request sent by the receiving end, establishes the target link with the receiving end, and maps the logical channel corresponding to the link establishment request to the target link; The link establishment request is triggered when the receiving end determines that the target link does not exist at the start of the media service.

[0024] Some optional implementations further include a first establishing module, configured to: Before the cache module obtains the media frame based on each data to be transmitted and the corresponding time information, in response to the mapping request sent by the receiving end, mapping the logical channel corresponding to the mapping request to the target link; The mapping request is triggered when the receiving end determines that the target link exists at the start of the media service.

[0025] Some optional implementations further include a first establishing module, configured to: In response to the channel modification request sent by the receiving end, the mapping between the logical channel and the target link is adjusted.

[0026] In some optional implementations, the cache module is further used to: If the number of media frames in all logical channels is greater than a preset number, a target media frame is selected from the logical channels based on the time information, and the target media frame is discarded.

[0027] In a fifth aspect, an embodiment of the present application provides a second data transmission device, which is applied to a receiving end, and the device includes: A receiving module, configured to receive a media frame from a target link; wherein the target link maps a plurality of logical channels, and the media frame in the target link is obtained by the transmitting end based on each data to be transmitted and the corresponding time information, and after the media frame is transmitted to the corresponding logical channel, the media frame is sequentially selected from all logical channels in the order of the time information and transmitted to the target link; The reconstruction module is used to reconstruct the data stream corresponding to each logical channel based on the time information of the media frame and the corresponding logical channel.

[0028] Some optional implementations further include a second establishing module, which is used to: Before the receiving module receives the media frame from the target link, at the start of the media service, determining whether the target link exists between the transmitting end and the receiving module; If yes, sending a mapping request to the receiving end, so that the sending end maps the corresponding logical channel to the target link based on the mapping request; Otherwise, a link establishment request is sent to the receiving end, so that the sending end establishes the target link with the receiving end based on the link establishment request, and maps the logical channel corresponding to the link establishment request to the target link.

[0029] In some optional implementation manners, the reconstruction module is specifically used to: For any logical channel, all media frames corresponding to the logical channel are sorted according to the sequence of the time information to generate a data stream corresponding to the logical channel.

[0030] Some optional implementations further include a second establishing module, which is used to: In response to the channel modification instruction, a channel modification request is sent to the receiving end, so that the sending end adjusts the mapping between the logical channel and the target link based on the channel modification request.

[0031] Some optional implementations further include a playback module for: After the reconstruction module reconstructs the data streams corresponding to the logical channels, for any logical channel, the media frames of the logical channel are decoded and played through the application layer.

[0032] In a sixth aspect, an embodiment of the present application provides a transmitting end, comprising at least one processor and at least one memory, wherein the memory stores a computer program, and when the program is executed by the processor, the processor executes any data transmission method described in the first aspect above.

[0033] In the seventh aspect, an embodiment of the present application provides a receiving end, comprising at least one processor and at least one memory, wherein the memory stores a computer program, and when the program is executed by the processor, the processor executes any data transmission method described in the second aspect above.

[0034] In an eighth aspect, an embodiment of the present application provides a computer-readable storage medium storing a computer program executable by a processor, wherein when the program runs on the processor, the processor executes the data transmission method described in any one of the first aspect or the second aspect.

[0035] In the embodiment of the present application, a target link is established through multi-channel grouping and chaining, and multiple logical channels are mapped, that is, multi-channel transmission shares the target link. Even if network fluctuations occur, the synchronization of media frames of different channels during transmission can be guaranteed, and the multi-channel outflow speed and outflow synchronization can be improved. By adding time information of the data to be transmitted at the sending end, the clock source is aligned to ensure the synchronization of transmitted picture data, improve the picture outflow speed, and improve the picture time synchronization. BRIEF DESCRIPTION OF THE DRAWINGS

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

[0037] Figure 1 A data transmission system architecture diagram provided in an embodiment of the present application; Figure 2 An interactive flow chart of the first data transmission method provided in an embodiment of the present application; Figure 3 A schematic diagram of data stream reconstruction provided in an embodiment of the present application; Figure 4 An interactive flow chart of a second data transmission method provided in an embodiment of the present application; Figure 5 An interactive flow chart of a third data transmission method provided in an embodiment of the present application; Figure 6A schematic diagram of a flow chart of a first data transmission method provided in an embodiment of the present application; Figure 7 A schematic diagram of a flow chart of a second data transmission method provided in an embodiment of the present application; Figure 8 A schematic diagram of the structure of a first data transmission device provided in an embodiment of the present application; Fig. 9 A schematic diagram of the structure of a second data transmission device provided in an embodiment of the present application; Fig.10 A schematic diagram of the structure of the transmitting end provided in an embodiment of the present application. DETAILED DESCRIPTION

[0038] In order to make the purpose, technical solutions and advantages of the present application clearer, the present application will be further described in detail below in conjunction with the accompanying drawings. Obviously, the described embodiments are only part of the embodiments of the present application, rather than all of the embodiments. Based on the embodiments in the present application, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present application.

[0039] The terms "first" and "second" are used for descriptive purposes only and should not be understood as indicating or implying relative importance or implicitly indicating the number of the indicated technical features. Thus, a feature defined as "first" or "second" may explicitly or implicitly include one or more of the features. In the description of this application, unless otherwise specified, "plurality" means two or more.

[0040] In the description of this application, it should be noted that, unless otherwise clearly specified and limited, the term "connection" should be understood in a broad sense, for example, it can be directly connected, or indirectly connected through an intermediate medium, or it can be the internal connection of two devices. For ordinary technicians in this field, the specific meanings of the above terms in this application can be understood according to specific circumstances.

[0041] With the development of the Internet of Things, more and more intelligent Internet of Things scenarios are being applied. Some scenarios involve multi-channel devices, such as multi-eye cameras that capture images through multiple cameras, simulate the binocular vision of the human eye, and integrate monitoring and intelligence around the three levels of perception, judgment, and action; NVR provides multiple network cameras. These application scenarios are inseparable from real-time audio and video, intelligent events, and streaming media transmission technology.

[0042] Home networks usually use Wi-Fi or cellular transmission. The wireless signal coverage is insufficient or there is signal interference. The transmission quality of multi-channel video transmission cannot be guaranteed, and outgoing streams are prone to being out of sync.

[0043] In the related art, the ability to resist network fluctuations is improved by increasing the cache. However, increasing the cache cannot increase the multi-channel outflow speed and will lead to an increase in data.

[0044] In some embodiments, multi-channel link building is used to transmit video frames for playback services. However, for real-time streaming services, when the network is insufficient, increased delay and frame loss will occur. If the multi-channel frame loss is not aligned, the picture will be out of sync.

[0045] In view of this, an embodiment of the present application proposes a data transmission method and system to improve the outbound flow speed and outbound flow synchronization of a multi-channel real-time streaming service.

[0046] See also Figure 1 As shown, an embodiment of the present application provides a data transmission system, which includes a transmitting end, a target link and a receiving end; wherein: A transmitting end, configured to obtain a media frame based on each data to be transmitted and the corresponding time information, and transmit the media frame to the corresponding logical channel; select media frames from all logical channels in sequence according to the order of the time information and transmit them to the target link, and send the media frame to the receiving end through the target link; The receiving end is used to reconstruct the data stream corresponding to each logical channel based on the time information of the media frame and the corresponding logical channel after receiving the media frame.

[0047] Through multi-channel grouping and chaining, one target link is built and multiple logical channels are mapped, that is, multi-channel transmission shares the target link. Even if there are network fluctuations, the synchronization of media frames of different channels during transmission can be guaranteed, and the multi-channel outflow speed and outflow synchronization can be improved. By adding time information of the data to be transmitted at the sending end and aligning the clock source, the synchronization of transmitted picture data can be guaranteed, the picture outflow speed can be increased, and the picture time synchronization can be improved.

[0048] The following will be combined with the accompanying drawings and specific embodiments to describe in detail the technical solution of the present application and how the technical solution of the present application solves the above technical problems. The following specific embodiments can be combined with each other, and the same or similar concepts or processes may not be repeated in some embodiments.

[0049] Figure 2 The interactive flow chart of the first data transmission method provided in the embodiment of the present application is as follows: Figure 2 As shown, the following steps are included: Step S201: The transmitting end obtains a media frame based on each data to be transmitted and the corresponding time information, and transmits the media frame to a corresponding logical channel.

[0050] In practice, the sending end has multiple real-time data streams, that is, each stream will generate data to be transmitted in real time. Since the data between different streams are independent of each other, based on this, multiple logical channels are mapped to the target link in this embodiment. For example, when host A (receiving end APP) previews the nine-split screen of host B (NVR device), the original bottom layer needs to create nine links to transmit the media data of the corresponding channels respectively; while this embodiment uses a shared target link at the bottom layer to establish a corresponding relationship between the bottom link (target link) of the transport layer protocol stack and the upper layer packet logical channel.

[0051] In other words, the bottom layer of the transport layer uses a shared link (shared target link), which only maps multiple channels at the logical level, and multiple channels are shared at one link. By sharing the target link, the target link link is completed, which means that all logical channels are completed, which improves the outflow speed and outflow synchronization of multiple channels; in addition, by sharing the target link, multi-channel transmission competition is resolved; at the same time, it also reduces the outflow speed asynchrony caused by different link completion times when multiple channels are linked separately.

[0052] This embodiment does not specifically limit the number of the above-mentioned logical channels, which may correspond to some or all channels that generate data on the sending end, and may be specifically determined according to the request of the receiving end.

[0053] Since real-time streaming data is easily affected by network fluctuations, based on this, in this embodiment, the sending end determines the time information corresponding to each data to be transmitted, and obtains a media frame by adding a corresponding timestamp to the data to be transmitted, thereby performing time alignment and reducing the phase difference between different logical channels.

[0054] In this embodiment, the media frame is transmitted to the corresponding logical channel, that is, when the media frame is sent, it is first sent to the corresponding queue for buffering.

[0055] Step S202: the sending end selects media frames from all logical channels in sequence according to the order of the time information and transmits them to the target link.

[0056] In implementation, when transmitting media data through a target link, media frames are first sent to the network from the packet buffers corresponding to the multiple logical channels in chronological order, and data is transmitted through the network protocol stack.

[0057] Step S203: The sending end sends the media frame to the receiving end through the target link.

[0058] In implementation, the sender sends media frames to the network in chronological order, and data is transmitted through the network protocol stack in the target link.

[0059] Exemplarily, the media frames are packaged to obtain data packets, which are then sent to a receiving end.

[0060] Since each data transmission channel has periodicity and time alignment between different channels is performed by adding time information, the number of media frames of each logical channel is usually the same in a time interval.

[0061] Step S204: after receiving the media frame, the receiving end reconstructs the data stream corresponding to each logical channel based on the time information of the media frame and the corresponding logical channel.

[0062] Since the media frames of multiple logical channels are all transmitted by one target link, what is received from the target link are the media frames of all logical channels arranged in time, that is, mixed multi-channel data. Therefore, the media frames received by the receiving end cannot be played directly.

[0063] Since each media frame has time information and logical channel information, the data stream corresponding to each logical channel can be reconstructed based on the time information of the media frame and the corresponding logical channel.

[0064] Exemplarily, the protocol stack receives transport layer message fragments from the network; the protocol stack ensures the reliability and integrity of the transport layer data according to the message sequence number in the fragment; the receiving end reassembles the service layer data according to the logical channel to which the media frame belongs.

[0065] In implementation, the media frames may be packaged in the target link, and the receiving end receives the data packets. The receiving end needs to parse the data packets to obtain the media frames before reconstruction.

[0066] The above scheme forms a chain through multi-channel grouping. One target link is used to complete the chain building and map multiple logical channels. That is, multi-channel transmission shares the target link. Even if there are network fluctuations, the synchronization of media frames of different channels during transmission can be guaranteed, thereby improving the multi-channel outflow speed and outflow synchronization. By adding the time information of the data to be transmitted at the sending end and aligning the clock source, the synchronization of the transmitted picture data can be guaranteed, the picture outflow speed can be improved, and the picture time synchronization can be improved.

[0067] In some optional implementation manners, the above step S204 may be implemented by but not limited to the following methods: For any logical channel, all media frames corresponding to the logical channel are sorted according to the sequence of the time information to generate a data stream corresponding to the logical channel.

[0068] As described above, since the media frames of multiple logical channels are all transmitted by one target link, what is received from the target link are the media frames of all logical channels arranged in time, that is, mixed multi-channel data; The receiving end first needs to separate the media frames of multiple logical channels; based on this, the receiving end processes the media frames corresponding to each logical channel separately; Furthermore, based on the sequence of time information, all media frames corresponding to each logical channel are formed into an ordered data stream.

[0069] See also Figure 3 As shown, there are N logical channels sharing the target link; t1, t2, t3, ... are time intervals respectively. As mentioned above, in a time interval, the number of media frames of each logical channel is usually the same; if a sending cycle is regarded as a time interval, there is usually a media frame corresponding to each logical channel in a time interval.

[0070] The sender transmits the media frames of logical channel 1 to logical channel 1, transmits the media frames of logical channel 2 to logical channel 2, and ... transmits the media frames of logical channel N to logical channel N.

[0071] According to the order of time information, the media frame of time period t1 is first transmitted to the target link, and then the media frame of time period t2 is transmitted to the target link... The media frame is sent to the receiving end through the target link; The receiving end receives media frames of different logical channels in different time periods and processes the media frames corresponding to each logical channel separately, that is, separates the media frames of multiple logical channels; Furthermore, based on the sequence of time information, all media frames corresponding to each logical channel are formed into an ordered data stream.

[0072] The above scheme avoids data interference between different logical channels by processing the media frames corresponding to each logical channel separately; based on the sequence of time information, all media frames corresponding to each logical channel are formed into an orderly data stream.

[0073] In some optional implementation manners, after the above step S204, the receiving end further performs the following steps: For any logical channel, the media frames of the logical channel are decoded and played through the application layer.

[0074] Exemplarily, the receiving end reconstructs the received media frames through the transport layer to form an ordered data stream; by submitting it to the application layer and decoding the ordered data stream, the audio and video stream with high stream speed and high stream synchronization can be played.

[0075] Figure 4 The interactive flow chart of the second data transmission method provided in the embodiment of the present application is as follows: Figure 4 As shown, the following steps are included: Step S401: When a media service starts, the receiving end determines whether the target link exists between the receiving end and the sending end.

[0076] In this embodiment, the target link is multiplexed, that is, as long as the target link between the transmitting end and the receiving end still exists, there is no need to create a new target link every time a media service starts; Based on this, in this embodiment, when a media service starts, the receiving end first determines whether there is a target link between the receiving end and the sending end.

[0077] Step S402: If yes, the receiving end sends a mapping request to the sending end.

[0078] In the implementation, if the target link exists, there is no need to create a new target link, and only mapping between the logical channel and the target link is required for subsequent transmission; Based on this, the receiving end sends a mapping request to the sending end to perform mapping between the logical channel and the target link.

[0079] This embodiment does not limit the specific implementation method of the mapping request, such as including the identifier of the logical channel corresponding to the data to be played.

[0080] Step S403: The sending end maps the logical channel corresponding to the mapping request to the target link.

[0081] In implementation, in the case where the target link exists, a new logical link is virtually mapped on the target link based on the mapping request, and subsequent transmission can be performed.

[0082] Step S404: the transmitting end obtains a media frame based on each data to be transmitted and the corresponding time information, and transmits the media frame to the corresponding logical channel.

[0083] Step S405: selecting media frames from all logical channels in sequence according to the order of the time information and transmitting them to the target link.

[0084] Step S406: Send the media frame to the receiving end through the target link.

[0085] Step S407: After receiving the media frame, the receiving end reconstructs the data stream corresponding to each logical channel based on the time information of the media frame and the corresponding logical channel.

[0086] The specific implementation of steps S404 to S407 can refer to the above embodiment and will not be described again here.

[0087] In the above scheme, when the target link exists, a new target link is not created, but mapping between the logical channel and the target link is performed to multiplex the target link and improve the outflow speed.

[0088] Figure 5 The interactive flow chart of the third data transmission method provided in the embodiment of the present application is as follows: Figure 5As shown, the following steps are included: Step S501: When a media service starts, the receiving end determines whether the target link exists between the receiving end and the sending end.

[0089] The specific implementation of step S501 can refer to the above embodiment and will not be described again here.

[0090] Step S502: Otherwise, the receiving end sends a link establishment request to the sending end.

[0091] In this embodiment, the target link is multiplexed, but when there is no target link between the transmitting ends, the target link needs to be established for this transmission and subsequent multiplexing; Based on this, the receiving end sends a link establishment request to the sending end to establish the target link and the mapping between the logical channel and the target link.

[0092] Step S503: The target link is established between the transmitting end and the receiving end, and the logical channel corresponding to the link establishment request is mapped to the target link.

[0093] Exemplarily, a handshake is performed between the receiving end and the transmitting end to establish a link based on a transport layer protocol, and after the target link is established, a mapping is performed between the logical channel and the target link.

[0094] Step S504: the transmitting end obtains a media frame based on each data to be transmitted and the corresponding time information, and transmits the media frame to the corresponding logical channel.

[0095] Step S505: selecting media frames from all logical channels in sequence according to the order of the time information and transmitting them to the target link.

[0096] Step S506: Send the media frame to the receiving end through the target link.

[0097] Step S507: After receiving the media frame, the receiving end reconstructs the data stream corresponding to each logical channel based on the time information of the media frame and the corresponding logical channel.

[0098] The specific implementation of steps S504 to S507 can refer to the above embodiment and will not be described again here.

[0099] In the above scheme, when the target link does not exist, a new target link is created to facilitate the current transmission and subsequent multiplexing.

[0100] In some optional implementation manners, based on any one of the embodiments, the receiving end performs the following steps: In response to the channel modification instruction, a channel modification request is sent to the receiving end Correspondingly, the sender performs the following steps: In response to the channel modification request sent by the receiving end, the mapping between the logical channel and the target link is adjusted.

[0101] In this embodiment, the target link is multiplexed, that is, as long as the target link between the transmitting end and the receiving end still exists, the target link can be used during data transmission; Based on this, in this embodiment, when channel modification is required, some logical channels are closed and / or added, and the existing target links are reused. There is no need to rebuild the link. Only the mapping relationship between the logical channels and the target links needs to be adjusted (adding and / or deleting the mapping between some logical channels and the target links), and the outflow speed is fast.

[0102] In some optional implementation manners, based on any embodiment, the sending end further performs the following steps: If the number of media frames in all logical channels is greater than a preset number, a target media frame is selected from the logical channels based on the time information, and the target media frame is discarded.

[0103] During implementation, data transmission is affected by the network. For example, when the network is insufficient, a large number of media frames will not be transmitted in the sender's cache queue. At this time, some media frames need to be discarded to ensure the real-time nature of the data.

[0104] Since the media frame in this embodiment carries time information, packet loss can be more targeted based on the time information.

[0105] Exemplarily, the media frame with the earliest time information in the logical channel is discarded; or, one or more media frames are discarded every preset time period.

[0106] In the embodiment of the present application, the data transmission method performed by the sending end is as follows: Figure 6 As shown, the following steps are included: Step S601: obtaining a media frame based on each data to be transmitted and the corresponding time information, and transmitting the media frame to a corresponding logical channel; Step S602: Select media frames from all logical channels in sequence according to the order of the time information and transmit them to the target link, and send the media frames to the receiving end through the target link, so that after receiving the media frames, the receiving end can reconstruct the data streams corresponding to the logical channels based on the time information of the media frames and the corresponding logical channels.

[0107] In some optional implementation manners, before obtaining the media frame based on each data to be transmitted and the corresponding time information, the method further includes: In response to the link establishment request sent by the receiving end, establish the target link with the receiving end, and map the logical channel corresponding to the link establishment request to the target link; The link establishment request is triggered when the receiving end determines that the target link does not exist at the start of the media service.

[0108] In some optional implementation manners, before obtaining the media frame based on each data to be transmitted and the corresponding time information, the method further includes: In response to the mapping request sent by the receiving end, mapping the logical channel corresponding to the mapping request to the target link; The mapping request is triggered when the receiving end determines that the target link exists at the start of the media service.

[0109] Some optional implementations also include: In response to the channel modification request sent by the receiving end, the mapping between the logical channel and the target link is adjusted.

[0110] Some optional implementations also include: If the number of media frames in all logical channels is greater than a preset number, a target media frame is selected from the logical channels based on the time information, and the target media frame is discarded.

[0111] In the embodiment of the present application, the data transmission method performed by the receiving end is as follows: Figure 7 As shown, the following steps are included: Step S701: receiving a media frame from a target link; wherein the target link maps a plurality of logical channels, and the media frame in the target link is obtained by the sender based on each data to be transmitted and the corresponding time information, and after the media frame is transmitted to the corresponding logical channel, it is sequentially selected from all logical channels in the order of the time information and transmitted to the target link; Step S702: reconstructing the data stream corresponding to each logical channel based on the time information of the media frame and the corresponding logical channel.

[0112] In some optional implementation manners, before receiving the media frame from the target link, the method further includes: When the media service starts, determining whether the target link exists between the transmitting end and the transmitting end; If yes, sending a mapping request to the receiving end, so that the sending end maps the corresponding logical channel to the target link based on the mapping request; Otherwise, a link establishment request is sent to the receiving end, so that the sending end establishes the target link with the receiving end based on the link establishment request, and maps the logical channel corresponding to the link establishment request to the target link.

[0113] In some optional implementations, reconstructing a data stream corresponding to each logical channel based on the time information of the media frame and the corresponding logical channel includes: For any logical channel, all media frames corresponding to the logical channel are sorted according to the sequence of the time information to generate a data stream corresponding to the logical channel.

[0114] Some optional implementations also include: In response to the channel modification instruction, a channel modification request is sent to the receiving end, so that the sending end adjusts the mapping between the logical channel and the target link based on the channel modification request.

[0115] In some optional implementation manners, after reconstructing the data streams corresponding to each logical channel, the method further includes: For any logical channel, the media frames of the logical channel are decoded and played through the application layer.

[0116] Figure 6~Figure 7 The specific implementation of the embodiment can refer to the implementation of the above-mentioned interaction method, and the repeated parts will not be repeated.

[0117] like Figure 8 As shown, based on Figure 6 The invention concept of the data transmission method shown in FIG. 1 is the same as that of the invention concept, and the embodiment of the present application provides a first data transmission device 800, which is applied to a sending end, and the device includes: The cache module 801 is used to obtain a media frame based on each data to be transmitted and the corresponding time information, and transmit the media frame to the corresponding logical channel; The transmission module 802 is used to select media frames from all logical channels in sequence according to the order of the time information and transmit them to the target link, and send the media frames to the receiving end through the target link, so that after receiving the media frames, the receiving end can reconstruct the data streams corresponding to each logical channel based on the time information of the media frames and the corresponding logical channels.

[0118] Some optional implementations further include a first establishing module 803, which is used to: Before the cache module 801 obtains the media frame based on each to-be-transmitted data and the corresponding time information, in response to the link establishment request sent by the receiving end, establishes the target link with the receiving end, and maps the logical channel corresponding to the link establishment request to the target link; The link establishment request is triggered when the receiving end determines that the target link does not exist at the start of the media service.

[0119] Some optional implementations further include a first establishing module 803, which is used to: Before the cache module 801 obtains the media frame based on each data to be transmitted and the corresponding time information, in response to the mapping request sent by the receiving end, the logical channel corresponding to the mapping request is mapped to the target link; The mapping request is triggered when the receiving end determines that the target link exists at the start of the media service.

[0120] Some optional implementations further include a first establishing module 803, which is used to: In response to the channel modification request sent by the receiving end, the mapping between the logical channel and the target link is adjusted.

[0121] In some optional implementations, the cache module 801 is further configured to: If the number of media frames in all logical channels is greater than a preset number, a target media frame is selected from the logical channels based on the time information, and the target media frame is discarded.

[0122] like Fig. 9 As shown, based on Figure 7 The invention concept of the data transmission method shown in FIG. 1 is the same as that of the invention concept, and the embodiment of the present application provides a second data transmission device 900, which is applied to a receiving end, and the device includes: The receiving module 901 is used to receive a media frame from a target link; wherein the target link maps multiple logical channels, and the media frame in the target link is obtained by the sending end based on each data to be transmitted and the corresponding time information. After the media frame is transmitted to the corresponding logical channel, it is selected from all logical channels in sequence according to the order of the time information and transmitted to the target link; The reconstruction module 902 is used to reconstruct the data stream corresponding to each logical channel based on the time information of the media frame and the corresponding logical channel.

[0123] Some optional implementations further include a second establishing module 903, which is used to: Before the receiving module 901 receives the media frame from the target link, at the start of the media service, it is determined whether the target link exists between the transmitting end and the receiving end; If yes, sending a mapping request to the receiving end, so that the sending end maps the corresponding logical channel to the target link based on the mapping request; Otherwise, a link establishment request is sent to the receiving end, so that the sending end establishes the target link with the receiving end based on the link establishment request, and maps the logical channel corresponding to the link establishment request to the target link.

[0124] In some optional implementations, the reconstruction module 902 is specifically configured to: For any logical channel, all media frames corresponding to the logical channel are sorted according to the sequence of the time information to generate a data stream corresponding to the logical channel.

[0125] Some optional implementations further include a second establishing module 903, which is used to: In response to the channel modification instruction, a channel modification request is sent to the receiving end, so that the sending end adjusts the mapping between the logical channel and the target link based on the channel modification request.

[0126] Some optional implementations further include a playback module 904, which is used to: After the reconstruction module 902 reconstructs the data stream corresponding to each logical channel, for any logical channel, the media frame of the logical channel is decoded and played through the application layer.

[0127] Figure 8~Figure 9 The specific implementation of the embodiment can refer to the implementation of the above-mentioned interaction method, and the repeated parts will not be repeated.

[0128] Based on the same technical concept, the embodiment of the present application also provides a sending end 1000, such as Fig.10 As shown, it includes at least one processor 1001 and a memory 1002 connected to the at least one processor. The specific connection medium between the processor 1001 and the memory 1002 is not limited in the embodiment of the present application. Fig.10 For example, the processor 1001 and the memory 1002 are connected via a bus 1003. The bus can be divided into a path bus, a data bus, a control bus, etc. For ease of representation, Fig.10 Only one thick line is used in the diagram, but this does not mean that there is only one bus or only one type of bus.

[0129] Among them, the processor 1001 is the control center of the transmitting end, and can use various interfaces and lines to connect various parts of the transmitting end, and realize data processing by running or executing instructions stored in the memory 1002 and calling data stored in the memory 1002. Optionally, the processor 1001 may include one or more processing units, and the processor 1001 may integrate an application processor and a modem processor, wherein the application processor mainly processes the operating system, user interface, and application program, etc., and the modem processor mainly processes the issued instructions. It can be understood that the above-mentioned modem processor may not be integrated into the processor 1001. In some embodiments, the processor 1001 and the memory 1002 may be implemented on the same chip, and in some embodiments, they may also be implemented separately on independent chips.

[0130] Processor 1001 may be a general-purpose processor, such as a central processing unit (CPU), a digital signal processor, an application-specific integrated circuit (ASIC), a field programmable gate array or other programmable logic device, a discrete gate or transistor logic device, or a discrete hardware component, and may implement or execute the methods, steps, and logic block diagrams disclosed in the embodiments of the present application. A general-purpose processor may be a microprocessor or any conventional processor, etc. The steps of the method disclosed in the embodiment of the data transmission method may be directly embodied as being executed by a hardware processor, or may be executed by a combination of hardware and software modules in the processor.

[0131] The memory 1002 is a non-volatile computer-readable storage medium that can be used to store non-volatile software programs, non-volatile computer executable programs and modules. The memory 1002 may include at least one type of storage medium, such as a flash memory, a hard disk, a multimedia card, a card-type memory, a random access memory (Random Access Memory, RAM), a static random access memory (Static Random Access Memory, SRAM), a programmable read-only memory (Programmable Read Only Memory, PROM), a read-only memory (Read Only Memory, ROM), an electrically erasable programmable read-only memory (Electrically Erasable Programmable Read-Only Memory, EEPROM), a magnetic memory, a disk, an optical disk, and the like. The memory 1002 is any other medium that can be used to carry or store the desired program code in the form of an instruction or data structure and can be accessed by a computer, but is not limited thereto. The memory 1002 in the embodiment of the present application can also be a circuit or any other device that can realize a storage function, for storing program instructions and / or data.

[0132] In the embodiment of the present application, the memory 1002 stores a computer program. When the program is executed by the processor 1001, the processor 1001 executes: Obtaining a media frame based on each data to be transmitted and the corresponding time information, and transmitting the media frame to the corresponding logical channel; According to the order of the time information, media frames are selected from all logical channels in turn and transmitted to the target link, and the media frames are sent to the receiving end through the target link, so that after receiving the media frames, the receiving end can reconstruct the data streams corresponding to the logical channels based on the time information of the media frames and the corresponding logical channels.

[0133] In some optional implementations, before obtaining the media frame based on each to-be-transmitted data and the corresponding time information, the processor 1001 further executes: In response to the link establishment request sent by the receiving end, establish the target link with the receiving end, and map the logical channel corresponding to the link establishment request to the target link; The link establishment request is triggered when the receiving end determines that the target link does not exist at the start of the media service.

[0134] In some optional implementations, before obtaining the media frame based on each to-be-transmitted data and the corresponding time information, the processor 1001 further executes: In response to the mapping request sent by the receiving end, mapping the logical channel corresponding to the mapping request to the target link; The mapping request is triggered when the receiving end determines that the target link exists at the start of the media service.

[0135] In some optional implementations, the processor 1001 further executes: In response to the channel modification request sent by the receiving end, the mapping between the logical channel and the target link is adjusted.

[0136] In some optional implementations, the processor 1001 further executes: If the number of media frames in all logical channels is greater than a preset number, a target media frame is selected from the logical channels based on the time information, and the target media frame is discarded.

[0137] Based on the same technical concept, an embodiment of the present application further provides a receiving end, comprising at least one processor and at least one memory, wherein the memory stores a computer program, and when the program is executed by the processor, the processor executes: Receive a media frame from a target link; wherein the target link maps a plurality of logical channels, and the media frame in the target link is obtained by the transmitter based on each data to be transmitted and the corresponding time information, and after the media frame is transmitted to the corresponding logical channel, the media frame is sequentially selected from all logical channels in the order of the time information and transmitted to the target link; Based on the time information of the media frame and the corresponding logical channel, the data stream corresponding to each logical channel is reconstructed.

[0138] In some optional implementations, before receiving the media frame from the target link, the processor further executes: When the media service starts, determining whether the target link exists between the transmitting end and the transmitting end; If yes, sending a mapping request to the receiving end, so that the sending end maps the corresponding logical channel to the target link based on the mapping request; Otherwise, a link establishment request is sent to the receiving end, so that the sending end establishes the target link with the receiving end based on the link establishment request, and maps the logical channel corresponding to the link establishment request to the target link.

[0139] In some optional implementations, the processor specifically performs: For any logical channel, all media frames corresponding to the logical channel are sorted according to the sequence of the time information to generate a data stream corresponding to the logical channel.

[0140] In some optional implementations, the processor further executes: In response to the channel modification instruction, a channel modification request is sent to the receiving end, so that the sending end adjusts the mapping between the logical channel and the target link based on the channel modification request.

[0141] In some optional implementation manners, after reconstructing the data streams corresponding to each logical channel, the processor further executes: For any logical channel, the media frames of the logical channel are decoded and played through the application layer.

[0142] Based on the same technical concept, an embodiment of the present application also provides a computer-readable storage medium, which stores a computer program executable by a processor. When the program runs on the processor, the processor executes the steps of the above-mentioned data transmission method.

[0143] Those skilled in the art will appreciate that the embodiments of the present application may be provided as methods, systems, or computer program products. Therefore, the present application may adopt the form of a complete hardware embodiment, a complete software embodiment, or an embodiment combining software and hardware. Moreover, the present application may adopt the form of a computer program product implemented on one or more computer-usable storage media (including but not limited to disk storage, CD-ROM, optical storage, etc.) containing computer-usable program codes.

[0144] The present application is described with reference to the flowcharts and / or block diagrams of the methods, devices (systems), and computer program products according to the present application. It should be understood that each process and / or block in the flowchart and / or block diagram, as well as the combination of processes and / or blocks in the flowchart and / or block diagram, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, a special-purpose computer, an embedded processor, or other programmable data processing device to produce a machine, so that the instructions executed by the processor of the computer or other programmable data processing device generate instructions for implementing the processes in the flowchart and / or block diagram. Figure 1 A process or multiple processes and / or boxes Figure 1 A device that provides the functions specified in a block or multiple blocks.

[0145] These computer program instructions may also be stored in a computer-readable memory capable of directing a computer or other programmable data processing device to operate in a specific manner, so that the instructions stored in the computer-readable memory produce an article of manufacture comprising an instruction device, which implements the process Figure 1 A process or multiple processes and / or boxes Figure 1 A function specified in one or more boxes.

[0146] These computer program instructions can also be loaded onto a computer or other programmable data processing device so that a series of operating steps are executed on the computer or other programmable device to produce a computer-implemented process, thereby providing instructions for implementing the process. Figure 1 A process or multiple processes and / or boxes Figure 1 The steps for the functions specified in one or more boxes.

[0147] Although the preferred embodiments of the present application have been described, those skilled in the art may make other changes and modifications to these embodiments once they have learned the basic creative concept. Therefore, the appended claims are intended to be interpreted as including the preferred embodiments and all changes and modifications falling within the scope of the present application.

[0148] Obviously, those skilled in the art can make various changes and modifications to the present application without departing from the spirit and scope of the present application. Thus, if these modifications and variations of the present application fall within the scope of the claims of the present application and their equivalents, the present application is also intended to include these modifications and variations.

Claims

1. A data transmission method, characterized in that: Applied to the sending end, the method includes: Obtaining a media frame based on each data to be transmitted and the corresponding time information, and transmitting the media frame to the corresponding logical channel; According to the order of the time information, media frames are selected from all logical channels in turn and transmitted to the target link, and the media frames are sent to the receiving end through the target link, so that after receiving the media frames, the receiving end can reconstruct the data streams corresponding to the logical channels based on the time information of the media frames and the corresponding logical channels.

2. The method according to claim 1, characterized in that Before obtaining a media frame based on each to-be-transmitted data and the corresponding time information, the method further includes: In response to the link establishment request sent by the receiving end, establish the target link with the receiving end, and map the logical channel corresponding to the link establishment request to the target link; The link establishment request is triggered when the receiving end determines that the target link does not exist at the start of the media service.

3. The method according to claim 1, characterized in that Before obtaining a media frame based on each to-be-transmitted data and the corresponding time information, the method further includes: In response to the mapping request sent by the receiving end, mapping the logical channel corresponding to the mapping request to the target link; The mapping request is triggered when the receiving end determines that the target link exists at the start of the media service.

4. The method according to claim 1, characterized in that Also includes: In response to the channel modification request sent by the receiving end, the mapping between the logical channel and the target link is adjusted.

5. The method according to any one of claims 1 to 4, characterized in that: Also includes: If the number of media frames in all logical channels is greater than a preset number, a target media frame is selected from the logical channels based on the time information, and the target media frame is discarded.

6. A data transmission method, characterized in that: Applied to the receiving end, the method includes: Receive a media frame from a target link; wherein the target link maps a plurality of logical channels, and the media frame in the target link is obtained by the transmitter based on each data to be transmitted and the corresponding time information, and after the media frame is transmitted to the corresponding logical channel, the media frame is sequentially selected from all logical channels in the order of the time information and transmitted to the target link; Based on the time information of the media frame and the corresponding logical channel, the data stream corresponding to each logical channel is reconstructed.

7. The method according to claim 6, characterized in that Before receiving a media frame from the target link, it also includes: When the media service starts, determining whether the target link exists between the transmitting end and the transmitting end; If yes, sending a mapping request to the receiving end, so that the sending end maps the corresponding logical channel to the target link based on the mapping request; Otherwise, a link establishment request is sent to the receiving end, so that the sending end establishes the target link with the receiving end based on the link establishment request, and maps the logical channel corresponding to the link establishment request to the target link.

8. The method according to claim 6, characterized in that Reconstructing data streams corresponding to the logical channels based on the time information of the media frame and the corresponding logical channels, including: For any logical channel, all media frames corresponding to the logical channel are sequenced according to the time information to generate a data stream corresponding to the logical channel.

9. The method according to claim 6, characterized in that Also includes: In response to the channel modification instruction, a channel modification request is sent to the receiving end, so that the sending end adjusts the mapping between the logical channel and the target link based on the channel modification request.

10. The method according to any one of claims 6 to 9, characterized in that: After reconstructing the data streams corresponding to each logical channel, it also includes: For any logical channel, the media frames of the logical channel are decoded and played through the application layer.

11. A data transmission system, characterized in that: The system includes a transmitting end, a target link and a receiving end; wherein: A transmitting end, configured to obtain a media frame based on each data to be transmitted and the corresponding time information, and transmit the media frame to a corresponding logical channel; The transmitting end is further used to select media frames from all logical channels in sequence according to the order of the time information and transmit them to the target link, and send the media frames to the receiving end through the target link; The receiving end is used to reconstruct the data stream corresponding to each logical channel based on the time information of the media frame and the corresponding logical channel.

Citation Information

Patent Citations

  • Network transmission method, CAN bus network, storage medium and electronic equipment

    CN111030905A

  • Video transmission method and device, server and storage medium

    CN118660191A

  • Data transmission method, device, system, equipment and medium

    CN118842769A

  • Improvement of multi-medium communication reliability by logic media

    CN1747435A

Cited By

  • Multi-eye tracker data processing method and device based on common port communication

    CN121774441A