CN111555842B - Method and device for transmitting data frame - Google Patents

Method and device for transmitting data frame Download PDF

Info

Publication number
CN111555842B
CN111555842B CN202010336283.2A CN202010336283A CN111555842B CN 111555842 B CN111555842 B CN 111555842B CN 202010336283 A CN202010336283 A CN 202010336283A CN 111555842 B CN111555842 B CN 111555842B
Authority
CN
China
Prior art keywords
data
transmitted
data frame
filled
filling
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN202010336283.2A
Other languages
Chinese (zh)
Other versions
CN111555842A (en
Inventor
马迈周
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Beijing Yutai Tongde Investment Management Co ltd
Original Assignee
Beijing Yutai Tongde Investment Management Co ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Beijing Yutai Tongde Investment Management Co ltd filed Critical Beijing Yutai Tongde Investment Management Co ltd
Publication of CN111555842A publication Critical patent/CN111555842A/en
Application granted granted Critical
Publication of CN111555842B publication Critical patent/CN111555842B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L1/00Arrangements for detecting or preventing errors in the information received
    • H04L1/0001Systems modifying transmission characteristics according to link quality, e.g. power backoff
    • H04L1/0006Systems modifying transmission characteristics according to link quality, e.g. power backoff by adapting the transmission format
    • H04L1/0007Systems modifying transmission characteristics according to link quality, e.g. power backoff by adapting the transmission format by modifying the frame length
    • H04L1/0008Systems modifying transmission characteristics according to link quality, e.g. power backoff by adapting the transmission format by modifying the frame length by supplementing frame payload, e.g. with padding bits

Abstract

The embodiment of the invention provides a method and a device for transmitting a data frame, wherein the method comprises the following steps: acquiring a data frame to be transmitted, analyzing the data frame to be transmitted, and determining the transmission type of the data frame to be transmitted; determining a transmission instruction matched with the transmission type, and transmitting the data frame to be transmitted to a data buffer area through the transmission instruction based on a preset transmission frequency; determining each data packet to be filled in each data frame to be transmitted in the data buffer area, and filtering each data packet to be filled according to a preset filtering rule; filling each data packet to be filled after the filtering processing, and transmitting at least one data frame to be transmitted after filling the data packet to be filled. The invention realizes the great utilization of bandwidth to improve the quality of data transmission, and further realizes the efficient packet loss recovery capability when the packet loss occurs.

Description

Method and device for transmitting data frame
Technical Field
The present invention relates to the field of internet technologies, and in particular, to a method and an apparatus for transmitting a data frame.
Background
With the development of technology, the real-time transmission technology is also mature. The transmitting end can continuously shoot the environment video through the video shooting device, and after the environment video is processed such as coding, compressing and packaging, the data packet is transmitted to the receiving end based on a transmission protocol. However, the existing transmission protocol cannot guarantee that each data packet is sent to the receiving end, and the packet loss phenomenon exists. The traditional packet loss recovery technology comprises retransmission and error correction, wherein the retransmission is that a receiving end feeds back to a transmitting end to request retransmission after detecting packet loss, the efficiency is not very high in an environment with larger inherent delay of a network, larger recovery delay is introduced, and the error correction recovery is that a certain amount of redundant data is added during transmission to realize packet loss recovery. The recovery capacity of the redundant data is related to the size of the redundant data, the larger the redundancy is, the stronger the packet loss resistance is, the redundant data can increase extra bandwidth consumption, and the effective utilization rate of the bandwidth is reduced, in the prior art, on one hand, the redundancy is generally self-adaptive according to the packet loss condition fed back by a receiving end, but the bandwidth consumption is still unavoidable to be increased; on the other hand, when video is encoded by CBR (Constant Bit Rate, fixed bit rate) encoding and VBR (Variable Bit Rate, dynamic bit rate) encoding, if the bit rate is wrong, more bandwidth will be free, which is not beneficial to network transmission, and in addition, in that way, efficient and stable transmission cannot be performed according to the service requirements. Therefore, the encoding processing is carried out on the data, and the realization of efficient packet loss recovery is a problem to be solved in the data network transmission process.
Disclosure of Invention
The embodiment of the invention provides a method and a device for transmitting a data frame, which are used for carrying out coding processing on data and realizing efficient packet loss recovery.
In one aspect, an embodiment of the present invention provides a method for transmitting a data frame, including:
acquiring a data frame to be transmitted, analyzing the data frame to be transmitted, and determining the transmission type of the data frame to be transmitted;
determining a transmission instruction matched with the transmission type, and transmitting the data frame to be transmitted to a data buffer area through the transmission instruction based on a preset transmission frequency;
determining each data packet to be filled in each data frame to be transmitted in the data buffer area, and filtering each data packet to be filled according to a preset filtering rule;
filling each data packet to be filled after the filtering processing, and transmitting at least one data frame to be transmitted after filling the data packet to be filled.
In another aspect, an embodiment of the present invention provides an apparatus for transmitting a data frame, including:
the analyzing and determining module is used for acquiring the data frame to be transmitted, analyzing the data frame to be transmitted and determining the transmission type of the data frame to be transmitted;
the transmission module is used for determining a transmission instruction matched with the transmission type and transmitting the data frame to be transmitted to a data buffer area through the transmission instruction based on a preset transmission frequency;
the filtering module is used for determining each data packet to be filled in each data frame to be sent in the data buffer area and filtering each data packet to be filled according to a preset filtering rule;
and the filling module is used for filling each data packet to be filled after the filtering processing and transmitting at least one data frame to be transmitted after filling the data packet to be filled.
The technical scheme has the following beneficial effects: the invention can filter the data packets according to different network data transmission conditions and then fill the data packets, thereby avoiding the occurrence of additional bandwidth consumption when packet loss recovery is performed through redundant data, avoiding the occurrence of more idle bandwidth due to error of code rate, realizing the improvement of the data transmission quality by greatly utilizing the bandwidth, improving the data filling efficiency while meeting the stable data transmission, and providing important precondition guarantee for ensuring the accuracy of data recovery when the packet loss recovery occurs later; further, when packet loss occurs in the data packet, the filling data packet can be used for replacing the data packet with the packet loss, so that the filling data packet can be effectively utilized to improve the quality of data transmission, and the efficient packet loss recovery capability is realized.
Drawings
In order to more clearly illustrate the embodiments of the invention or the technical solutions in the prior art, the drawings that are required in the embodiments or the description of the prior art will be briefly described, it being obvious that the drawings in the following description are only some embodiments of the invention, and that other drawings may be obtained according to these drawings without inventive effort for a person skilled in the art.
FIG. 1 is a flow chart of a method for transmitting a data frame according to an embodiment of the present invention;
fig. 2 is a schematic diagram of an apparatus for transmitting a data frame according to an embodiment of the present invention.
Detailed Description
The following description of the embodiments of the present invention will be made clearly and completely with reference to the accompanying drawings, in which it is apparent that the embodiments described are only some embodiments of the present invention, but not all embodiments. All other embodiments, which can be made by those skilled in the art based on the embodiments of the invention without making any inventive effort, are intended to be within the scope of the invention.
As shown in fig. 1, a flowchart of a method for transmitting a data frame according to an embodiment of the present invention includes:
101. acquiring a data frame to be transmitted, analyzing the data frame to be transmitted, and determining the transmission type of the data frame to be transmitted;
102. determining a transmission instruction matched with the transmission type, and transmitting the data frame to be transmitted to a data buffer area through the transmission instruction based on a preset transmission frequency;
103. determining each data packet to be filled in each data frame to be transmitted in the data buffer area, and filtering each data packet to be filled according to a preset filtering rule;
104. filling each data packet to be filled after the filtering processing, and transmitting at least one data frame to be transmitted after filling the data packet to be filled.
Further, before the step of transmitting the data frame to be transmitted to a data buffer by the transmission instruction based on a predetermined transmission frequency, the method includes:
creating a data buffer area for storing data frames, and creating a first buffer queue in the data buffer area;
the method comprises the steps of transmitting the data frame to be transmitted to a data buffer area through the transmission instruction based on a preset transmission frequency, wherein the step of transmitting the data frame to be transmitted to the data buffer area comprises the following steps of;
and transmitting the data frame to be transmitted to a first buffer queue of a data buffer area through the transmission instruction based on a preset transmission frequency.
Further, the determining each data packet to be filled in each data frame to be sent of the data buffer area includes:
judging whether each data packet in the current data frame to be transmitted needs to be filled or not according to each data frame to be transmitted in a first buffer queue of the data buffer area;
if necessary, each data packet to be filled in the current data frame to be sent is determined.
Further, the filtering processing for each data packet to be filled according to the predetermined filtering rule includes:
discarding data packets to be filled which do not meet a preset filtering rule in the data frame to be sent currently according to the preset filtering parameter information and the data information of the data frame to be sent currently obtained by analysis;
wherein the filtering parameter comprises at least one of data packet size, data packet number and data packet type;
wherein the data information includes at least one of a transmission type, a data packet size, a data packet number, and a data packet type.
Further, before the step of filling each data packet to be filled after the filtering process and transmitting at least one data frame to be transmitted after filling the data packet to be filled, the method includes:
determining the task type of each data frame to be transmitted;
determining filling priority matched with the task type according to the task type, and creating a second buffer queue for temporarily storing data frames in the data buffer area;
wherein a predetermined storage number of data frames temporarily stored in the second buffer queue is set.
Further, each data packet to be filled after the filling filtering processing specifically includes:
reordering each data frame to be transmitted based on the filling priority of each data frame to be transmitted;
based on the ordered data frames to be sent, sequentially storing the data frames to be sent in the preset storage quantity into the second buffer queue;
and traversing and filling each data packet to be filled of each data frame to be transmitted in the second buffer queue in turn according to each determined data packet to be filled in each data frame to be transmitted.
Further, the traversing each data packet to be filled of each data frame to be sent in the second buffer queue sequentially includes:
and accumulating the filling times of each data packet to be filled.
Optionally, after the step of sequentially traversing each data packet to be filled of each data frame to be sent in the second buffer queue, the method further includes:
step a, determining whether the data frame to be transmitted currently has data packets to be filled with the filling times less than the preset maximum filling times or not based on the filling times of each data packet to be filled of each data frame to be transmitted;
if the data packet to be filled exists, determining the data packet to be filled with the minimum filling frequency among the data packets to be filled with the filling frequency less than the preset maximum filling frequency, and filling the data packet to be filled with the minimum filling frequency;
and if the data frame does not exist, and the preset storage quantity is at least two, determining a last data frame of the data frame to be sent currently in the second buffer queue, and jumping to execute the step a until the data frame to be sent currently in the second buffer queue does not exist in the last data frame.
As shown in fig. 2, an apparatus for transmitting a data frame is shown, which includes:
the analyzing and determining module 21 is configured to obtain a data frame to be sent, analyze the data frame to be sent, and determine a transmission type of the data frame to be sent;
a transmitting module 22, configured to determine a transmission instruction matched with the transmission type, and transmit, based on a predetermined transmission frequency, the data frame to be transmitted to a data buffer through the transmission instruction;
a filtering module 23, configured to determine each data packet to be filled in each data frame to be sent in the data buffer, and perform filtering processing on each data packet to be filled according to a predetermined filtering rule;
and the filling module 24 is used for filling each data packet to be filled after the filtering processing and transmitting at least one data frame to be transmitted after filling the data packet to be filled.
Further, the method comprises the steps of:
a first creating module, configured to create a data buffer area for storing data frames, and create a first buffer queue in the data buffer area;
wherein the sending module is specifically configured to
And transmitting the data frame to be transmitted to a first buffer queue of a data buffer area through the transmission instruction based on a preset transmission frequency.
Further, the filtration module comprises:
the judging unit is used for judging whether each data packet in the current data frame to be transmitted needs to be filled or not according to each data frame to be transmitted in the first buffer queue of the data buffer area;
and the determining unit is used for determining each data packet to be filled in the current data frame to be transmitted if required.
Further, the filtration module comprises:
the discarding unit is used for discarding the data packets to be filled which do not meet the preset filtering rule in the current data frame to be sent according to the preset filtering parameter information and the data information of the current data frame to be sent obtained by analysis;
wherein the filtering parameter comprises at least one of data packet size, data packet number and data packet type;
wherein the data information includes at least one of a transmission type, a data packet size, a data packet number, and a data packet type.
Further, the method comprises the steps of:
the first determining module is used for determining the task type of each data frame to be transmitted;
a second creating module, configured to determine, according to the task type, a filling priority that matches the task type, and create a second buffer queue in the data buffer for temporarily storing data frames;
wherein a predetermined storage number of data frames temporarily stored in the second buffer queue is set.
Further, the filling module includes:
a transmitting unit for reordering each data frame to be transmitted based on a filling priority of each data frame to be transmitted;
the storage unit is used for sequentially storing the preset storage quantity of the data frames to be sent into the second buffer queue based on the ordered data frames to be sent;
and the filling unit is used for sequentially traversing and filling each data packet to be filled of each data frame to be transmitted in the second buffer queue according to each determined data packet to be filled in each data frame to be transmitted.
Further, the filling unit includes:
and the accumulation subunit is used for accumulating the filling times of each data packet to be filled.
Optionally, the method further comprises:
the second determining module is used for determining whether the data frame to be transmitted currently has the data packet to be filled with the filling frequency less than the preset maximum filling frequency or not based on the filling frequency of each data packet to be filled of each data frame to be transmitted;
the determining and filling module is used for determining the data packet to be filled with the minimum filling frequency among the data packets to be filled with the filling frequency less than the preset maximum filling frequency if the data packet to be filled with the minimum filling frequency exists, and filling the data packet to be filled with the minimum filling frequency;
and the jump module is used for determining the last data frame of the data frame to be sent currently in the second buffer queue if the data frame to be sent does not exist and the preset storage quantity is at least two, and executing the second determination module in a jumping manner until the data frame to be sent currently in the second buffer queue does not exist.
The technical scheme provided by the embodiment of the invention has the following beneficial effects: the invention can filter the data packets according to different network data transmission conditions and then fill the data packets, thereby avoiding the occurrence of additional bandwidth consumption when packet loss recovery is performed through redundant data, avoiding the occurrence of more idle bandwidth due to error of code rate, realizing the improvement of the data transmission quality by greatly utilizing the bandwidth, improving the data filling efficiency while meeting the stable data transmission, and providing important precondition guarantee for ensuring the accuracy of data recovery when the packet loss recovery occurs later; further, when packet loss occurs in the data packet, the filling data packet can be used for replacing the data packet with the packet loss, so that the filling data packet can be effectively utilized to improve the quality of data transmission, and the efficient packet loss recovery capability is realized.
The following describes the above technical solution of the embodiment of the present invention in detail with reference to an application example:
the application example aims at carrying out coding processing on the data, and realizes efficient packet loss recovery.
As shown in fig. 1, for example, in a data transmission system, firstly, a data frame to be transmitted is acquired, and the data information of the current data frame to be transmitted is obtained by analyzing the data frame to be transmitted, and the transmission type of the data frame to be transmitted is determined according to the data information; determining a transmission instruction matched with the transmission type, and transmitting the data frame to be transmitted to a data buffer area through the transmission instruction based on a preset transmission frequency; the data buffer area stores a plurality of data frames to be transmitted, then, each data packet to be filled in each data frame to be transmitted in the data buffer area is determined, and each data packet to be filled is filtered according to a preset filtering rule; filling each data packet to be filled after the filtering processing, and transmitting at least one data frame to be transmitted after filling the data packet to be filled. Wherein the data information includes at least one of a transmission type, a data packet size, a data packet number, and a data packet type.
It should be noted that, as will be understood by those skilled in the art, the network data transmission may be performed by using different transmission protocols, where the protocols include RTP (Real-time Transport Protocol, real-time transmission protocol), UDP (User Datagram Protocol ), TCP (Transmission Control Protocol, transmission control protocol), etc., the related protocols matched to RTP are RTCP (Real-time Transport Control Protocol, real-time transmission control protocol), where RTP is used to provide end-to-end Real-time transmission services for multiple multimedia data needing Real-time transmission, such as voice, image, fax, etc., on the network, and RTP provides time information and stream synchronization for end-to-end Real-time transmission on the network, but the quality of service is not guaranteed, and is provided by RTCP; UDP is mainly used to support those network applications that need to transfer data between computers, and many client/server mode network applications, including network video conferencing systems, all need to use the UDP protocol, which is mainly used to compress network data traffic into datagram form; TCP works in the OSI transmission layer to provide reliable connection-oriented transmission service, the TCP mainly works by establishing connection, then receiving data from application layer program and transmitting, TCP works in virtual circuit connection mode, before transmitting data, it needs to establish a connection between sender and receiver, after transmitting data, sender waits for receiver to give a confirmatory response, otherwise sender considers the data to be lost, and retransmits the data. Therefore, different network transmission modes will determine different data transmission types, and thus, the transmitted instructions will also be different. In order to better explain the data transmission mode of the present invention, the transmission type in the embodiment of the present invention is illustrated by RTP.
In a possible implementation manner, before the step of sending the data frame to be sent to the data buffer area through the transmission instruction based on the predetermined sending frequency, the method includes: a data buffer is created for storing data frames and a first buffer queue is created in the data buffer.
Wherein the sending the data frame to be sent to the data buffer area through the transmission instruction based on the preset sending frequency includes: and transmitting the data frame to be transmitted to a first buffer queue of a data buffer area through the transmission instruction based on a preset transmission frequency.
Wherein the determining each data packet to be filled in each data frame to be sent of the data buffer zone includes: judging whether each data packet in the current data frame to be transmitted needs to be filled or not according to each data frame to be transmitted in a first buffer queue of the data buffer area; if necessary, each data packet to be filled in the current data frame to be sent is determined.
For example, in a data transmission system, a data buffer for storing data frames is created, and a first buffer queue is created in the data buffer; acquiring a data frame to be transmitted, analyzing the data frame to be transmitted to obtain data information of the current data frame to be transmitted, and determining the transmission type of the data frame to be transmitted according to the data information; determining a transmission instruction matched with the transmission type, and transmitting the data frame to be transmitted to a first buffer queue of a data buffer area through the transmission instruction based on a preset transmission frequency; then, for each data frame to be transmitted in the first buffer queue of the data buffer area, judging whether each data packet in the current data frame to be transmitted needs to be filled, if so, storing the data frame to be transmitted F001 and the data frame to be transmitted F002 in the first buffer queue, respectively judging whether each data packet in the data frame to be transmitted F001 and the data frame to be transmitted F002 needs to be filled, and if so, determining that the data packet to be filled in the data frame to be transmitted F002 is D01 and D02.
By the embodiment, the data packet to be filled can be determined rapidly and efficiently, so that an important precondition guarantee is provided for rapid filling of the data packet in the follow-up process, and the situation that more bandwidth is free due to error of code rate is avoided.
In a possible implementation manner, the filtering processing for each data packet to be filled according to a predetermined filtering rule includes: discarding data packets to be filled which do not meet a preset filtering rule in the data frame to be sent currently according to the preset filtering parameter information and the data information of the data frame to be sent currently obtained by analysis;
wherein the filtering parameter comprises at least one of data packet size, data packet number and data packet type.
For example, in a data transmission system, a predetermined filtering rule is preconfigured, such as discarding a data packet which satisfies a predetermined data type and whose size is larger than a predetermined value, etc., according to the data type; in the above example, it is determined that the data packets to be filled in the data frame F002 to be transmitted are D01, D02 and D03, and the data packet to be filled in the data frame F002 to be transmitted, which does not satisfy the predetermined filtering rule, is discarded according to the preconfigured filtering parameter information and the data information of the current data frame F002 to be transmitted obtained by parsing, for example, D03.
According to the embodiment, the data packet to be filled can be accurately and efficiently determined according to different conditions, the filling efficiency of the data packet is greatly improved, and meanwhile, when packet loss recovery occurs, the situation that extra bandwidth consumption is increased when the packet loss recovery is performed through redundant data can be avoided.
In a possible implementation manner, before the step of filling each data packet to be filled after the filtering process and transmitting at least one data frame to be transmitted after filling the data packet to be filled, the method includes: determining the task type of each data frame to be transmitted; and determining filling priority matched with the task type according to the task type, and creating a second buffer queue for temporarily storing data frames in the data buffer area.
Wherein a predetermined storage number of data frames temporarily stored in the second buffer queue is set.
Each data packet to be filled after the filling and filtering processing specifically comprises: reordering each data frame to be transmitted based on the filling priority of each data frame to be transmitted; based on the ordered data frames to be sent, sequentially storing the data frames to be sent in the preset storage quantity into the second buffer queue; and traversing and filling each data packet to be filled of each data frame to be transmitted in the second buffer queue in turn according to each determined data packet to be filled in each data frame to be transmitted.
For example, in a data transmission system, a data buffer for storing data frames is created, a first buffer queue is created in the data buffer, and a second buffer queue for temporarily storing data frames is created in the data buffer, and a predetermined storage number, such as a predetermined storage number of 2, of data frames temporarily stored in the second buffer queue is set; establishing filling priorities corresponding to different task types of the data frame; acquiring a data frame to be transmitted, analyzing the data frame to be transmitted to obtain data information of the current data frame to be transmitted, and determining the transmission type of the data frame to be transmitted according to the data information; determining a transmission instruction matched with the transmission type, and transmitting the data frame to be transmitted to a data buffer area through the transmission instruction based on a preset transmission frequency; the method comprises the steps that a plurality of data frames to be transmitted are stored in a data buffer area, then, each data packet to be filled in each data frame to be transmitted in the data buffer area is determined, filtering processing is carried out on each data packet to be filled according to a preset filtering rule, each data frame to be transmitted after filtering processing is obtained, each data packet to be filled in each data frame to be transmitted can be determined, if the data packets to be filled in each data frame to be transmitted in F001 are D02 and D03, the data packets to be filled in each data frame to be transmitted in F002 are D01 and D02, the data packets to be filled in each data frame to be transmitted in F003 are D01 and D02, then, according to the filling priority corresponding to each task type of each data frame to be transmitted in F001, F002 and F003, if the filling priority of each data frame to be transmitted in F001 is determined to be lower than that of each data frame to be transmitted in F002, the filling priority of each data frame to be transmitted in F002 is determined to be lower than that of each data frame to be transmitted in F003, and then, the data frames to be transmitted in F002 are reordered according to the high priority; based on the ordered data frames to be sent, if the preset storage number is 2, firstly storing the data frames to be sent F003 and F002 into a second buffer queue, and traversing each data packet to be filled of each data frame to be sent in the second buffer queue in turn according to each determined data packet to be filled in each data frame to be sent. After the data frames F003 and F002 to be sent are sent, the data in the second buffer queue is emptied, the data frame F001 to be sent is stored in the second buffer queue, and each data packet to be filled of the data frame F001 to be sent in the second buffer queue is traversed.
According to the embodiment, the data to be filled is determined according to different data transmission types and requirements and according to the filling priority, the data filling efficiency is improved while stable data transmission is met, meanwhile, when packet loss recovery occurs, the accuracy of data recovery is greatly guaranteed, and the quality of data transmission is improved by efficiently utilizing filling data packets.
In a possible implementation manner, the traversing each to-be-filled data packet of each to-be-sent data frame in the second buffer queue sequentially includes:
and accumulating the filling times of each data packet to be filled.
After the step of sequentially traversing each data packet to be filled of each data frame to be sent in the second buffer queue, the method further includes: step a, determining whether the data frame to be transmitted currently has data packets to be filled with the filling times less than the preset maximum filling times or not based on the filling times of each data packet to be filled of each data frame to be transmitted; if the data packet to be filled exists, determining the data packet to be filled with the minimum filling frequency among the data packets to be filled with the filling frequency less than the preset maximum filling frequency, and filling the data packet to be filled with the minimum filling frequency; and if the data frame does not exist, and the preset storage quantity is at least two, determining a last data frame of the data frame to be sent currently in the second buffer queue, and jumping to execute the step a until the data frame to be sent currently in the second buffer queue does not exist in the last data frame.
For example, the previous example is followed, each data packet to be filled of the data frames F003 and F002 to be sent in the second buffer queue is sequentially traversed and filled, and when filling of each data packet is completed, the filling times of the current data packet to be filled are accumulated; then, executing the step a, and determining whether the data frame to be transmitted currently, such as the data frame F003 to be transmitted, has the data packet to be filled with the filling frequency less than the preset maximum filling frequency or not based on the filling frequency of each data packet to be filled of the data frames F003 and F002 to be transmitted; if the data packet to be filled exists, determining the data packet to be filled with the minimum filling frequency among the data packets to be filled with the filling frequency less than the preset maximum filling frequency, and filling the data packet to be filled with the minimum filling frequency; and then, changing the current data frame to be transmitted into a data frame to be transmitted F002, executing the step a, if no data packet to be filled with the filling frequency less than the preset maximum filling frequency exists in the data frame to be transmitted F003, and when the preset storage number is at least two, determining the last data frame of the current data frame to be transmitted in the second buffer queue, and jumping to execute the step a, if no data packet to be filled with the filling frequency less than the preset maximum filling frequency exists in the data frame to be transmitted F001 at this time, and the preset storage number is at least two, but the data frames to be transmitted F001 in the second buffer queue do not exist in the last data frame, and ending the data packet filling processing of the data frames to be transmitted F003 and F002 in the second buffer queue.
Through the embodiment, the data filling efficiency is further improved, and meanwhile, when packet loss recovery occurs, the accuracy of data recovery is greatly ensured; in the delay of obtaining the lost packet recovery, the delay is controlled within a preset frame number according to different network transmission requirements, and in addition, the recovery probability of each filling data packet is similar, so that the lost packet recovery capability is exerted to the greatest extent; meanwhile, the maximum filling times of the data frames with preset storage quantity in the second buffer queue are differentiated, so that the filling proportion of the current data frame to be filled is larger than that of the previous frame, and the packet loss resistance is further improved.
The embodiment of the present invention provides a device for transmitting a data frame, which can implement the above-provided method embodiment, and specific function implementation is referred to the description in the method embodiment, and is not repeated herein.
It should be understood that the specific order or hierarchy of steps in the processes disclosed are examples of exemplary approaches. Based on design preferences, it is understood that the specific order or hierarchy of steps in the processes may be rearranged without departing from the scope of the present disclosure. The accompanying method claims present elements of the various steps in a sample order, and are not meant to be limited to the specific order or hierarchy presented.
In the foregoing detailed description, various features are grouped together in a single embodiment for the purpose of streamlining the disclosure. This method of disclosure is not to be interpreted as reflecting an intention that the claimed embodiments of the subject matter require more features than are expressly recited in each claim. Rather, as the following claims reflect, invention lies in less than all features of a single disclosed embodiment. Thus the following claims are hereby expressly incorporated into this detailed description, with each claim standing on its own as a separate preferred embodiment of this invention.
The previous description of the disclosed embodiments is provided to enable any person skilled in the art to make or use the present invention. As will be apparent to those skilled in the art; various modifications to these embodiments will be readily apparent, and the generic principles defined herein may be applied to other embodiments without departing from the spirit or scope of the disclosure. Thus, the present disclosure is not intended to be limited to the embodiments shown herein but is to be accorded the widest scope consistent with the principles and novel features disclosed herein.
The foregoing description includes examples of one or more embodiments. It is, of course, not possible to describe every conceivable combination of components or methodologies for purposes of describing the aforementioned embodiments, but one of ordinary skill in the art may recognize that many further combinations and permutations of various embodiments are possible. Accordingly, the embodiments described herein are intended to embrace all such alterations, modifications and variations that fall within the scope of the appended claims. Furthermore, as used in the specification or claims, the term "comprising" is intended to be inclusive in a manner similar to the term "comprising," as interpreted when employed as a transitional word in a claim. Furthermore, any use of the term "or" in the specification of the claims is intended to mean "non-exclusive or".
Those of skill in the art will further appreciate that the various illustrative logical blocks (illustrative logical block), units, and steps described in connection with the embodiments of the invention may be implemented by electronic hardware, computer software, or combinations of both. To clearly illustrate this interchangeability of hardware and software, various illustrative components (illustrative components), elements, and steps have been described above generally in terms of their functionality. Whether such functionality is implemented as hardware or software depends upon the particular application and design requirements of the overall system. Those skilled in the art may implement the described functionality in varying ways for each particular application, but such implementation is not to be understood as beyond the scope of the embodiments of the present invention.
The various illustrative logical blocks or units described in the embodiments of the invention may be implemented or performed with a general purpose processor, a digital signal processor, an Application Specific Integrated Circuit (ASIC), a field programmable gate array or other programmable logic device, discrete gate or transistor logic, discrete hardware components, or any combination thereof designed to perform the functions described. A general purpose processor may be a microprocessor, but in the alternative, the general purpose processor may be any conventional processor, controller, microcontroller, or state machine. A processor may also be implemented as a combination of computing devices, e.g., a digital signal processor and a microprocessor, a plurality of microprocessors, one or more microprocessors in conjunction with a digital signal processor core, or any other similar configuration.
The steps of a method or algorithm described in connection with the embodiments disclosed herein may be embodied directly in hardware, in a software module executed by a processor, or in a combination of the two. A software module may be stored in RAM memory, flash memory, ROM memory, EPROM memory, EEPROM memory, registers, hard disk, a removable disk, a CD-ROM, or any other form of storage medium known in the art. In an example, a storage medium may be coupled to the processor such that the processor can read information from, and write information to, the storage medium. In the alternative, the storage medium may be integral to the processor. The processor and the storage medium may reside in an ASIC, which may reside in a user terminal. In the alternative, the processor and the storage medium may reside as distinct components in a user terminal.
In one or more exemplary designs, the above-described functions of embodiments of the present invention may be implemented in hardware, software, firmware, or any combination of the three. If implemented in software, the functions may be stored on a computer-readable medium or transmitted as one or more instructions or code on the computer-readable medium. Computer readable media includes both computer storage media and communication media that facilitate transfer of computer programs from one place to another. A storage media may be any available media that can be accessed by a general purpose or special purpose computer. For example, such computer-readable media may include, but is not limited to, RAM, ROM, EEPROM, CD-ROM or other optical disk storage, magnetic disk storage or other magnetic storage devices, or any other medium that may be used to carry or store program code in the form of instructions or data structures and other data structures that may be read by a general or special purpose computer, or a general or special purpose processor. Further, any connection is properly termed a computer-readable medium, e.g., if the software is transmitted from a website, server, or other remote source via a coaxial cable, fiber optic cable, twisted pair, digital Subscriber Line (DSL), or wireless such as infrared, radio, and microwave, and is also included in the definition of computer-readable medium. The disks (disks) and disks (disks) include compact disks, laser disks, optical disks, DVDs, floppy disks, and blu-ray discs where disks usually reproduce data magnetically, while disks usually reproduce data optically with lasers. Combinations of the above may also be included within the computer-readable media.
The foregoing description of the embodiments has been provided for the purpose of illustrating the general principles of the invention, and is not meant to limit the scope of the invention, but to limit the invention to the particular embodiments, and any modifications, equivalents, improvements, etc. that fall within the spirit and principles of the invention are intended to be included within the scope of the invention.

Claims (10)

1. A method of transmitting a data frame, comprising:
acquiring a data frame to be transmitted, analyzing the data frame to be transmitted, and determining the transmission type of the data frame to be transmitted;
determining a transmission instruction matched with the transmission type, and transmitting the data frame to be transmitted to a data buffer area through the transmission instruction based on a preset transmission frequency;
determining each data packet to be filled in each data frame to be transmitted in the data buffer area, and filtering each data packet to be filled according to a preset filtering rule;
filling each data packet to be filled after the filtering processing, and transmitting at least one data frame to be transmitted after filling the data packet to be filled.
2. The method according to claim 1, characterized by, before the step of transmitting the data frame to be transmitted to a data buffer by the transmission instruction based on a predetermined transmission frequency, comprising:
creating a data buffer area for storing data frames, and creating a first buffer queue in the data buffer area;
wherein the sending the data frame to be sent to the data buffer area through the transmission instruction based on the preset sending frequency includes:
transmitting the data frame to be transmitted to a first buffer queue of a data buffer area through the transmission instruction based on a preset transmission frequency;
wherein the determining each data packet to be filled in each data frame to be sent of the data buffer zone includes:
judging whether each data packet in the current data frame to be transmitted needs to be filled or not according to each data frame to be transmitted in a first buffer queue of the data buffer area;
if necessary, each data packet to be filled in the current data frame to be sent is determined.
3. The method according to claim 1 or 2, wherein the filtering each data packet to be filled according to a predetermined filtering rule comprises:
discarding data packets to be filled which do not meet a preset filtering rule in the data frame to be sent currently according to the preset filtering parameter information and the data information of the data frame to be sent currently obtained by analysis;
wherein the filtering parameter comprises at least one of data packet size, data packet number and data packet type;
wherein the data information includes at least one of a transmission type, a data packet size, a data packet number, and a data packet type.
4. A method according to claim 3, wherein, before the step of padding each data packet to be padded after the padding filtering process and transmitting at least one data frame to be transmitted after padding the data packet to be padded, the method comprises:
determining the task type of each data frame to be transmitted;
determining filling priority matched with the task type according to the task type, and creating a second buffer queue for temporarily storing data frames in the data buffer area;
wherein a predetermined storage number of data frames temporarily stored in the second buffer queue is set.
5. The method according to claim 4, wherein each data packet to be filled after the filling filtering process specifically comprises:
reordering each data frame to be transmitted based on the filling priority of each data frame to be transmitted;
based on the ordered data frames to be sent, sequentially storing the data frames to be sent in the preset storage quantity into the second buffer queue;
traversing each data packet to be filled of each data frame to be transmitted in the second buffer queue in turn according to each determined data packet to be filled in each data frame to be transmitted;
wherein the sequentially traversing filling each data packet to be filled of each data frame to be transmitted in the second buffer queue includes:
and accumulating the filling times of each data packet to be filled.
6. The method of claim 5, further comprising, after the step of sequentially traversing each of the data packets to be filled that fill each of the data frames to be transmitted in the second buffer queue:
step a, determining whether the data frame to be transmitted currently has data packets to be filled with the filling times less than the preset maximum filling times or not based on the filling times of each data packet to be filled of each data frame to be transmitted;
if the data packet to be filled exists, determining the data packet to be filled with the minimum filling frequency among the data packets to be filled with the filling frequency less than the preset maximum filling frequency, and filling the data packet to be filled with the minimum filling frequency;
and if the data frame does not exist, and the preset storage quantity is at least two, determining a last data frame of the data frame to be sent currently in the second buffer queue, and jumping to execute the step a until the data frame to be sent currently in the second buffer queue does not exist in the last data frame.
7. An apparatus for transmitting a data frame, comprising:
the analyzing and determining module is used for acquiring the data frame to be transmitted, analyzing the data frame to be transmitted and determining the transmission type of the data frame to be transmitted;
the transmission module is used for determining a transmission instruction matched with the transmission type and transmitting the data frame to be transmitted to a data buffer area through the transmission instruction based on a preset transmission frequency;
the filtering module is used for determining each data packet to be filled in each data frame to be sent in the data buffer area and filtering each data packet to be filled according to a preset filtering rule;
and the filling module is used for filling each data packet to be filled after the filtering processing and transmitting at least one data frame to be transmitted after filling the data packet to be filled.
8. The apparatus according to claim 7, comprising:
a first creating module, configured to create a data buffer area for storing data frames, and create a first buffer queue in the data buffer area;
wherein the sending module is specifically configured to
Transmitting the data frame to be transmitted to a first buffer queue of a data buffer area through the transmission instruction based on a preset transmission frequency;
wherein, the filtration module includes:
the judging unit is used for judging whether each data packet in the current data frame to be transmitted needs to be filled or not according to each data frame to be transmitted in the first buffer queue of the data buffer area;
and the determining unit is used for determining each data packet to be filled in the current data frame to be transmitted if required.
9. The apparatus of claim 7 or 8, wherein the filtration module comprises:
the discarding unit is used for discarding the data packets to be filled which do not meet the preset filtering rule in the current data frame to be sent according to the preset filtering parameter information and the data information of the current data frame to be sent obtained by analysis;
wherein the filtering parameter comprises at least one of data packet size, data packet number and data packet type;
wherein the data information includes at least one of a transmission type, a data packet size, a data packet number, and a data packet type.
10. The apparatus as claimed in claim 9, comprising:
the first determining module is used for determining the task type of each data frame to be transmitted;
a second creating module, configured to determine, according to the task type, a filling priority that matches the task type, and create a second buffer queue in the data buffer for temporarily storing data frames;
wherein a predetermined storage number of data frames temporarily stored in the second buffer queue is set;
wherein, the filling module includes:
a transmitting unit for reordering each data frame to be transmitted based on a filling priority of each data frame to be transmitted;
the storage unit is used for sequentially storing the preset storage quantity of the data frames to be sent into the second buffer queue based on the ordered data frames to be sent;
the filling unit is used for sequentially traversing and filling each data packet to be filled of each data frame to be transmitted in the second buffer queue according to each determined data packet to be filled in each data frame to be transmitted;
wherein, the filling unit includes:
the accumulation subunit is used for accumulating the filling times of each data packet to be filled;
wherein, still include:
the second determining module is used for determining whether the data frame to be transmitted currently has the data packet to be filled with the filling frequency less than the preset maximum filling frequency or not based on the filling frequency of each data packet to be filled of each data frame to be transmitted;
the determining and filling module is used for determining the data packet to be filled with the minimum filling frequency among the data packets to be filled with the filling frequency less than the preset maximum filling frequency if the data packet to be filled with the minimum filling frequency exists, and filling the data packet to be filled with the minimum filling frequency;
and the jump module is used for determining the last data frame of the data frame to be sent currently in the second buffer queue if the data frame to be sent does not exist and the preset storage quantity is at least two, and executing the second determination module in a jumping manner until the data frame to be sent currently in the second buffer queue does not exist.
CN202010336283.2A 2020-01-14 2020-04-23 Method and device for transmitting data frame Active CN111555842B (en)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN202010034961 2020-01-14
CN202010034961X 2020-01-14

Publications (2)

Publication Number Publication Date
CN111555842A CN111555842A (en) 2020-08-18
CN111555842B true CN111555842B (en) 2024-01-16

Family

ID=72003117

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202010336283.2A Active CN111555842B (en) 2020-01-14 2020-04-23 Method and device for transmitting data frame

Country Status (1)

Country Link
CN (1) CN111555842B (en)

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103685243A (en) * 2013-11-28 2014-03-26 许继电气股份有限公司 Fault recording data transmission method based on UDP
CN103929681A (en) * 2014-04-09 2014-07-16 安徽超远信息技术有限公司 Method for improving RTP video streaming treatment efficiency in low-speed network
CN104243103A (en) * 2014-10-13 2014-12-24 福州瑞芯微电子有限公司 Method, system, transmitting terminal and receiving terminal for disconnected WIFI (wireless fidelity) data transmission

Family Cites Families (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
EP1730899B1 (en) * 2004-01-30 2010-12-08 TELEFONAKTIEBOLAGET LM ERICSSON (publ) Packet scheduling for data stream transmission

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103685243A (en) * 2013-11-28 2014-03-26 许继电气股份有限公司 Fault recording data transmission method based on UDP
CN103929681A (en) * 2014-04-09 2014-07-16 安徽超远信息技术有限公司 Method for improving RTP video streaming treatment efficiency in low-speed network
CN104243103A (en) * 2014-10-13 2014-12-24 福州瑞芯微电子有限公司 Method, system, transmitting terminal and receiving terminal for disconnected WIFI (wireless fidelity) data transmission

Also Published As

Publication number Publication date
CN111555842A (en) 2020-08-18

Similar Documents

Publication Publication Date Title
JP4414311B2 (en) Multimedia streaming service system and method
JP6067378B2 (en) Method and apparatus for determining retransmission
EP2529528B1 (en) A method and apparatus for parsing a network abstraction-layer for reliable data communication
KR100657314B1 (en) Apparatus and method for transmitting multimedia streaming
US20040098748A1 (en) MPEG-4 live unicast video streaming system in wireless network with end-to-end bitrate-based congestion control
US7733913B1 (en) Striping data over transmission channels
EP1701506B1 (en) Method and system for transmission control protocol (TCP) traffic smoothing
WO2019154221A1 (en) Method for sending streaming data and data sending device
US20110085602A1 (en) Video Communication System, Device and Method Based on Feedback Reference Frames
CN107231328A (en) Method for real-time video transmission, device, equipment and system
US8347189B2 (en) Data transmission system, program and method
CN109862440A (en) Audio video transmission forward error correction, device, computer equipment and storage medium
CN106105141A (en) Realize the delivery acceleration device of extension transmission control function
EP3120521A1 (en) Transport accelerator implementing request manager and connection manager functionality
JP2024509728A (en) Data retransmission processing method, device, computer equipment and computer program
EP2710778B1 (en) Method for dynamic adaptation of the reception bitrate and associated receiver
CN110113662A (en) A kind of video monitor client system adapting to multiple network situation
CN114640886A (en) Bandwidth-adaptive audio and video transmission method and device, computer equipment and medium
KR20230002784A (en) Methods and servers for transmitting audio and/or video content
US9866350B2 (en) Streaming media packet processing method, WiFi chip, and mobile terminal
KR100589725B1 (en) Multimedia streaming system for wireless handheld devices
CN114051173B (en) RTP extension header-based video frame reliable transmission method, device and equipment
CN113573003B (en) Audio and video real-time communication method, device and equipment based on weak network
CN111555842B (en) Method and device for transmitting data frame
CN114979793A (en) Live broadcast data transmission method, device, system, equipment and medium

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant