Video I frame transmission control method, device and equipment based on link equipment

By detecting and allocating idle time slices, the I-frame collision problem caused by the high peak of network traffic when multiple network cameras send video I-frames is solved, and the accurate control of I-frame time is achieved, which improves the stability of video transmission and efficiency.

CN114567808BActive Publication Date: 2025-01-03ZHEJIANG DAHUA TECH CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202210085071.0
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2022-01-25
Publication Date
2025-01-03
Estimated Expiration
2042-01-25

Smart Images

  • Figure CN114567808B_ABST
    Figure CN114567808B_ABST
Patent Text Reader

Abstract

The present application relates to a video I frame transmission control method, device and equipment based on a link device, wherein the method includes: obtaining video frame transmission information of video I frames in each terminal; detecting whether there is a collision within a unit time according to the video frame transmission information; when there is a collision within a unit time, allocating an idle time slice for the video I frame that has collided, and transmitting the idle time slice to each terminal, so that the terminal transmits the corresponding video I frame according to the standard time corresponding to the idle time slice. Through this application, the problem that there is an error in the received I frame time, thereby failing to accurately control the I frame, is solved, and the effect of being able to directly perform more accurate timing control on the video I frames sent by each terminal in the link device is achieved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the technical field of data transmission, and in particular to a video I frame transmission control method, device and equipment based on a link device. Background Art

[0002] With the development of IoT technology, the network platform can pull video streams from multiple network cameras (IPCamera, IPC) through link devices at the same time. When video frames are transmitted and encoded, the most frequently used ones are I frames and P frames. I frames are compressions of all data, so the data volume is relatively large, while P frames are differentially encoded on the previous I frames, and their data volume is relatively small. In this scenario, when multiple network cameras send I frames to the network platform at the same time, the instantaneous network traffic peak of the link device will exceed the forwarding capacity of the upstream port, resulting in delays, freezes, and packet loss in the video effect, which is the I frame collision effect.

[0003] In order to avoid the I frame collision effect during video frame transmission, the prior art usually controls the I frames sent by the network camera in the network platform. Since the sent video frames need to be forwarded through multiple layers of link devices before reaching the network platform, errors occur in the received I frame time, making it impossible to accurately control the I frames.

[0004] With regard to the problem in the related art that there is an error in the time of receiving the I frame, thereby failing to accurately control the I frame, no effective solution has been proposed yet. Summary of the invention

[0005] In this embodiment, a link device-based video I frame transmission control method, apparatus and device are provided to solve the problem in the related art that there is an error in the received I frame time, thereby failing to accurately control the I frame.

[0006] In a first aspect, a video I frame transmission control method based on a link device is provided in this embodiment, including:

[0007] Obtain video frame transmission information of video I frames in each terminal;

[0008] Transmitting information according to the video frame to detect whether there is a collision within a unit time;

[0009] When there is a collision within a unit time, an idle time slice is allocated to the video I frame where the collision occurs, and the idle time slice is transmitted to each terminal, so that the terminal transmits the corresponding video I frame according to the standard time corresponding to the idle time slice.

[0010] In some embodiments, obtaining the video frame transmission information of the video I frame in each terminal includes:

[0011] The I frame timestamp and device identification of the video I frame in each terminal are obtained by receiving.

[0012] In some embodiments, the receiving and obtaining the I frame timestamp and device identification of the video I frame in each terminal includes:

[0013] Receiving LLDP messages sent by each of the terminals based on the LLDP protocol;

[0014] The I frame timestamp and device identification are obtained by parsing the newly added fields in the LLDP message.

[0015] In some embodiments, obtaining the video frame transmission information of the video I frame in each terminal includes:

[0016] The traffic peak value and device identification of the video I frame in each terminal are collected.

[0017] In some of the embodiments, collecting the traffic peak value and device identification of the video I frame in each terminal includes:

[0018] By collecting message information of ports in the link device, flow data of each terminal corresponding to the port is obtained;

[0019] The flow peak value and device identification are obtained by analyzing the flow data.

[0020] In some embodiments, transmitting information according to the video frame to detect whether there is a collision within a unit time includes:

[0021] When the video frame transmission information is an I frame timestamp and a device identifier, the I frame timestamp and the corresponding device identifier are divided into corresponding unit times, and by monitoring the device identifier in the unit time, it is determined whether there is a collision within the unit time, or;

[0022] When the video frame transmission information is a traffic peak and a device identification, the time of the traffic peak is determined according to the acquisition time point, and the traffic peak and the corresponding device identification are divided into corresponding unit times. By monitoring the device identification in the unit time, it is determined whether there is a collision within the unit time.

[0023] In some embodiments, the monitoring of the device identification in the unit time to determine whether there is a collision in the unit time includes:

[0024] When the video frame transmission information includes the I frame timestamp and the device identifier, if the corresponding device identifier already exists in the unit time, then there is a video I frame collision in the unit time, or;

[0025] When the video frame transmission information includes the traffic peak value and the device identifier, if there are a number of device identifiers corresponding to the unit time, there is a video I frame collision within the unit time.

[0026] In some embodiments, when there is a collision within a unit time, allocating an idle time slice for the video I frame where the collision occurs, and transmitting the idle time slice to each terminal so that the terminal transmits the corresponding video I frame according to the standard time corresponding to the idle time slice, including:

[0027] When there is a collision within a unit time, according to the unit time of the video I frame where the collision occurs, find the next unit time without the corresponding device identifier in time sequence, and use the unit time as the idle time slice;

[0028] Sending an I frame control instruction including the idle time slice information to each of the terminals;

[0029] In the terminal, the idle time slice is parsed to obtain the corresponding standard time, and the corresponding video I frame is transmitted according to the standard time.

[0030] In a second aspect, a video I frame transmission control device based on a link device is provided in this embodiment, comprising: an acquisition module, a monitoring module and a control module;

[0031] An acquisition module, used to acquire video frame transmission information of video I frames in each terminal;

[0032] A monitoring module, used for transmitting information according to the video frame to detect whether there is a collision within a unit time;

[0033] The control module is used to allocate idle time slices to the video I frames where the collision occurs when there is a collision within a unit time, and transmit the idle time slices to each terminal so that the corresponding video I frames are transmitted in the terminal according to the standard time corresponding to the idle time slice.

[0034] In a third aspect, a computer device is provided in this embodiment, comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein when the processor executes the computer program, the video I frame transmission control method based on the link device described in the first aspect is implemented.

[0035] In a fourth aspect, a storage medium is provided in this embodiment, on which a computer program is stored, and when the program is executed by a processor, the video I frame transmission control method based on the link device described in the first aspect is implemented.

[0036] Compared with the related art, the video I frame transmission control method, device and equipment based on the link device provided in this embodiment obtains the video frame transmission information of the video I frame in each terminal; detects whether there is a collision within a unit time according to the video frame transmission information; when there is a collision within a unit time, allocates an idle time slice to the video I frame that has collided, and transmits the idle time slice to each terminal, so that the terminal transmits the corresponding video I frame according to the standard time corresponding to the idle time slice, thereby solving the problem that there is an error in the received I frame time, thereby failing to accurately control the I frame, and achieving the effect of accurately controlling the received I frame directly in the link device.

[0037] Details of one or more embodiments of the present application are set forth in the following drawings and description to make other features, objects, and advantages of the present application more readily apparent. BRIEF DESCRIPTION OF THE DRAWINGS

[0038] The drawings described herein are used to provide a further understanding of the present application and constitute a part of the present application. The illustrative embodiments of the present application and their descriptions are used to explain the present application and do not constitute an improper limitation on the present application. In the drawings:

[0039] Figure 1 The hardware structure block diagram of a video I frame transmission control method based on a link device in one embodiment;

[0040] Figure 2 A schematic diagram of an I frame in a bitstream with a frame rate of 25 frames when encoding video frame transmission;

[0041] Figure 3 is a flow chart of a video I frame transmission control method based on a link device in one embodiment;

[0042] Figure 4 A flowchart of a video I frame transmission control method based on a link device in a preferred embodiment;

[0043] Figure 5 A flowchart of a video I frame transmission control method based on a link device in another preferred embodiment;

[0044] Figure 6 It is a structural block diagram of a video I frame transmission control device based on a link device in one embodiment;

[0045] Figure 7 It is a structural block diagram of a video I frame transmission control system based on a link device in one embodiment;

[0046] In the figure: 610, acquisition module; 620, monitoring module; 630, control module; 710, terminal; 720, link device; 730, network platform. DETAILED DESCRIPTION

[0047] In order to more clearly understand the purpose, technical solutions and advantages of the present application, the present application is described and illustrated below in conjunction with the accompanying drawings and embodiments.

[0048] Unless otherwise defined, the technical terms or scientific terms involved in this application shall have the general meaning understood by people with ordinary skills in the technical field to which this application belongs. The words "one", "a", "a", "the", "these" and the like in this application do not represent quantitative restrictions, and they can be singular or plural. The terms "include", "comprise", "have" and any variants thereof involved in this application are intended to cover non-exclusive inclusions; for example, a process, method and system, product or device comprising a series of steps or modules (units) is not limited to the listed steps or modules (units), but may include unlisted steps or modules (units), or may include other steps or modules (units) inherent to these processes, methods, products or devices. The words "connect", "connected", "coupled" and the like involved in this application are not limited to physical or mechanical connections, but may include electrical connections, whether directly or indirectly. The "multiple" involved in this application refers to two or more. "And / or" describes the association relationship of associated objects, indicating that there can be three relationships. For example, "A and / or B" can mean: A exists alone, A and B exist at the same time, and B exists alone. Usually, the character " / " indicates that the objects associated with each other are in an "or" relationship. The terms "first", "second", "third", etc. involved in this application are only used to distinguish similar objects and do not represent a specific ordering of the objects.

[0049] The method embodiment provided in this embodiment can be executed in a terminal, a computer or a similar computing device. For example, running on a terminal, Figure 1 is a hardware structure block diagram of a terminal of the video I frame transmission control method based on a link device in this embodiment. Figure 1 As shown, the terminal may include one or more ( Figure 1 Only one is shown in the figure) processor 102 and memory 104 for storing data, wherein processor 102 may include but is not limited to a processing device such as a microprocessor MCU or a programmable logic device FPGA. The above terminal may also include a transmission device 106 and an input and output device 108 for communication functions. It can be understood by those skilled in the art that Figure 1 The structure shown is only for illustration and does not limit the structure of the above terminal. Figure 1 More or fewer components as shown, or with Figure 1 Different configurations shown.

[0050] The memory 104 can be used to store computer programs, for example, software programs and modules of application software, such as the computer program corresponding to the video I frame transmission control method based on the link device in this embodiment. The processor 102 executes various functional applications and data processing by running the computer program stored in the memory 104, that is, to implement the above method. The memory 104 may include a high-speed random access memory, and may also include a non-volatile memory, such as one or more magnetic storage devices, flash memory, or other non-volatile solid-state memory. In some examples, the memory 104 may further include a memory remotely arranged relative to the processor 102, and these remote memories may be connected to the terminal via a network. Examples of the above-mentioned network include, but are not limited to, the Internet, an intranet, a local area network, a mobile communication network, and combinations thereof.

[0051] The transmission device 106 is used to receive or send data via a network. The above network includes a wireless network provided by the communication provider of the terminal. In one example, the transmission device 106 includes a network adapter (Network Interface Controller, referred to as NIC), which can be connected to other network devices through a base station so as to communicate with the Internet. In one example, the transmission device 106 can be a radio frequency (Radio Frequency, referred to as RF) module, which is used to communicate with the Internet wirelessly.

[0052] When encoding video frames for transmission, the most frequently used are I-frames and P-frames. I-frames compress all data, so the data volume is relatively large, while P-frames are differentially encoded on the previous I-frames, and the data volume is relatively small. Therefore, if a collision occurs when transmitting an I-frame, a huge amount of data will be generated. Figure 2 A schematic diagram of I frames in a bitstream with a frame rate of 25 frames when encoding video frame transmission, where the top three bars represent I frames.

[0053] In this embodiment, a video I frame transmission control method based on a link device is provided. Figure 3 is the corresponding flow chart of this method, such as Figure 3 As shown, the method comprises the following steps:

[0054] Step S310, obtaining video frame transmission information of video I frames in each terminal.

[0055] Specifically, the link device obtains the transmission information of the I frame during the video frame transmission from each terminal by receiving or collecting the information. The link device refers to a device with forwarding function such as a switch, a wireless repeater, and a wireless router; the terminal refers to a front-end video device such as an IP Camera (IP Camera, IPC). The transmission information of the video I frame includes but is not limited to the timestamp of the video I frame, the traffic peak value, and the device identification of each terminal.

[0056] Step S320: Transmitting information based on the video frame to detect whether there is a collision within a unit time.

[0057] Specifically, the I frame timestamp or traffic peak in the video frame transmission information is divided according to unit time, and the time when each terminal sends the I frame can be corresponded to the corresponding time unit. Then, based on the terminal device identifier corresponding to the I frame timestamp or traffic peak in each time unit, it is detected whether there is a collision of the video I frame within the unit time.

[0058] Step S330, when there is a collision within a unit time, an idle time slice is allocated to the video I frame where the collision occurs, and the idle time slice is transmitted to each terminal, so that the terminal transmits the corresponding video I frame according to the standard time corresponding to the idle time slice.

[0059] Specifically, if a collision of multiple video I frames within a unit time is detected, one video I frame is retained without controlling its sending timing, and idle time slices are searched for the remaining video I frames according to the terminal device identifier corresponding to the I frame timestamp or traffic peak in each unit time, and the idle time slices are transmitted to each terminal through a control instruction, and the idle time slices are re-encoded in each terminal to transmit the video I frame at the corresponding standard time after encoding, where the standard time can be local time or Coordinated Universal Time (UTC).

[0060] In the prior art, in order to avoid the frame collision effect when multiple terminals send I frames to the network platform at the same time, when the terminal transmits video frame data to the network platform through the link device, the network platform performs timing control on the video I frames sent by each terminal. Since the video frame needs to be forwarded through multiple layers of link devices before it can reach the network platform, the video I frame time received by the network platform has errors, so that the I frame cannot be accurately controlled. This embodiment is an effective supplement to the prior art. The above steps are performed by judging whether there is a collision within a unit time in the link device according to the video frame transmission information of the video I frame obtained from each terminal, and sending an idle time slice to the terminal corresponding to the video I frame that has collided, and controlling each terminal to transmit the video I frame with the idle time slice as the standard time. In the link device, a more accurate video I frame time can be obtained than the network platform, which solves the problem that the received I frame time has errors, so that the I frame cannot be accurately controlled, and achieves the effect of being able to directly perform more accurate timing control on the video I frame sent by each terminal in the link device.

[0061] In some embodiments, the step of obtaining the video frame transmission information of the video I frame in each terminal includes obtaining the I frame timestamp and device identifier of the video I frame in each terminal by receiving, and specifically includes the following steps:

[0062] Receive LLDP packets sent by each terminal based on the LLDP protocol.

[0063] LLDP (Link Layer Discovery Protocol) provides a standard link layer discovery method, which can organize the main capabilities, management address, device identification, interface identification and other information of the local device into different TLVs (Type / Length / Value), and encapsulate them in LLDPDU (Link Layer Discovery Protocol Data Unit) and publish them to the neighbors directly connected to it. After receiving this information, the neighbors save it in the form of standard MIB (Management Information Base) for the network management system to query and judge the communication status of the link. Among them, in addition to the required TLV fields, the LLDP protocol also includes some TLV fields that can be extended and defined.

[0064] Specifically, in this embodiment, before sending the video I frame, each terminal transmits the I frame timestamp and device identification of the video I frame by adding a TLV field in the LLDP protocol, and encapsulates it in the LLDPDU for sending, and receives the LLDP message LLDPDU sent by each terminal based on the LLDP protocol in the link device.

[0065] The format of the newly added TLV field is shown in the following table:

[0066] Table 1:

[0067] TLV Type TLV name TLV Value Usage In LLDPDU 9 Iframe timestamp IframeTS UTC time Optional

[0068] By parsing the newly added fields in the LLDP message, the I frame timestamp and device identification are obtained.

[0069] Specifically, the link device learns the LLDP message, parses the newly added TLV field in the LLDP message, and obtains the I frame timestamp IframeTS and the device identifier Chassis ID.

[0070] By receiving and obtaining the video frame transmission information of each terminal video I frame based on the LLDP protocol in this embodiment, the I frame timestamp and device identification of the video I frame can be obtained by receiving in the link device, so as to facilitate subsequent judgment on whether a collision occurs based on the received I frame timestamp and device identification.

[0071] In some embodiments, the step of obtaining the video frame transmission information of the video I frame in each terminal includes collecting the traffic peak value and device identification of the video I frame in each terminal, and specifically includes the following steps:

[0072] By collecting the message information of the port in the link device, the flow data of each terminal corresponding to the port is obtained.

[0073] Specifically, the number of TCP message bytes is read from the register of the link device. When the link device is a switch, the number of message bytes is read from the port of the switch. When the link device is a wireless repeater, the number of message bytes is read from the corresponding STA (Station) under the AP (Access Point) of the wireless repeater. The flow data of the terminal corresponding to the port can be calculated based on the number of message bytes of each port. The principles of collecting message information by other link devices are the same and will not be repeated here.

[0074] By analyzing the traffic data, the traffic peak value and device identification are obtained.

[0075] Specifically, the flow data of multiple unit times is collected continuously. By calculating the difference DeltaBytes of the flow data per unit time between two adjacent collection time points and the historical value LastBytes of the last collection time point, a two-dimensional data structure Obeject[t][Device ID] is established to analyze the flow data, where Obeject represents the flow data object, and its structure is<LastBytes,DeltaBytes> , t represents the time point, Device ID represents the device identification, that is, the Flag value in each terminal traffic data, and the obtained traffic peak is used as the basis for video I frame transmission. The Flag value corresponding to the traffic peak is the device identification of the terminal that transmits the video I frame. The above two-dimensional data structure Obeject[t][Device ID] is shown in the following table:

[0076] Table 2:

[0077] Device ID1 Device ID2 …… Device IDm t1 Object11 Object12 …… Object1m t2 Object21 Object22 …… Object2m …… …… …… …… …… tn Objectn1 Objectn2 …… Objectnm

[0078] In this embodiment, traffic data of each terminal is collected, and the basis for video I frame transmission and the corresponding device identification are obtained by analyzing the traffic peak in the traffic data, so as to facilitate subsequent judgment on whether a collision occurs based on the received I frame timestamp and device identification.

[0079] It should be noted that the above two embodiments are two possible implementation methods for obtaining video I frame transmission information from each terminal. If there are other embodiments that are improved and deformed on the basis of the above two embodiments and can achieve the above effects, they also fall within the scope of protection of this application.

[0080] In some embodiments, the above-mentioned information transmission based on the video frame to detect whether there is a collision within a unit time includes the following steps:

[0081] When the video frame is transmitted as an I frame timestamp and a device identifier, the I frame timestamp and the corresponding device identifier are divided into corresponding unit times, or;

[0082] When the video frame transmission information is a traffic peak value and a device identification, the time of the traffic peak value is determined according to the acquisition time point, and the traffic peak value and the corresponding device identification are divided into corresponding unit times.

[0083] Specifically, the I frame timestamp and traffic peak value can both indicate the basis for sending the video I frame. By dividing the I frame timestamp or traffic peak value into corresponding unit times respectively, the unit time of the sending time of each video I frame can be obtained, and the device identifier of the corresponding sending terminal of each video I frame is also corresponded to the unit time respectively.

[0084] By monitoring the device identifications in a unit time, it is determined whether there is a collision in the unit time.

[0085] Furthermore, when the video frame transmission information includes an I frame timestamp and a device identifier, if a corresponding device identifier already exists in a unit time, a video I frame collision exists in the unit time.

[0086] Specifically, when the video frame transmission is an I frame timestamp and a device identifier, the device identifier in each unit time is monitored by establishing a first multi-mapping table in the monitoring cycle, wherein the data structure of the first multi-mapping table is MulMAP1.<T,Chassis ID> , T represents the unit time slice, n represents the number of unit time slices, usually n≥50, which means there are at least 50 unit times, and usually 50 unit times are taken for monitoring. During the entire video frame transmission process, the monitoring period is continuously turned on, and the monitoring data is cleared regularly, usually set to 2s. It should be noted that the monitoring period and the number of unit times can also be set to 1s, 3s or 120 unit times respectively, and there is no restriction on this. Chassis ID represents the device identification, usually the MAC address of the terminal. During initialization, its data structure is shown in the following table:

[0087] Table 3:

[0088] T T1 T2 …… Ti …… Tn Chassis ID NULL NULL NULL NULL NULL NULL

[0089] In the monitoring cycle, the device identification of each video I frame is added to the Chassis ID corresponding to each unit time slice in the table. Assuming that the Chassis ID to be added corresponds to the time slice Ti, if the Chassis ID in Ti in MulMAP1 is empty, the Chassis ID is directly added to MulMAP1, and the video I frame sending time of the terminal corresponding to the Chassis ID is not controlled. At this time, the data in MulMAP1 is shown in the following table:

[0090] Table 4:

[0091]

[0092] If the corresponding Chassis ID in Ti in MulMAP1 is not empty, it means that there is a video I frame collision within a unit time.

[0093] Furthermore, when the video frame transmission information includes a traffic peak value and a device identifier, if there are several device identifiers corresponding to a unit time, there is a video I frame collision within the unit time.

[0094] Specifically, when the video frame transmission information contains traffic peaks and device identifiers, the traffic data of multiple unit times are continuously collected for monitoring in the above embodiments, and the traffic peaks and device identifiers are mapped to the corresponding unit times. After the collection is completed, the monitoring results are counted, and the number of device identifiers corresponding to each unit time slice in the monitoring results is used to determine whether a collision of video I frames occurs. Usually, MAC is used as the device identifier. Usually, 50 unit times are collected continuously for monitoring, each unit time is 40ms, and the monitoring time is 2s. Only one implementation is given here. The number of time units, each unit time, and monitoring time can be adaptively adjusted without limitation. Among them, the monitoring results can be in the second multiple data table MulMAP2<T,Device ID> It is expressed in the form of , where T represents the unit time slice and Device ID represents the device identifier:

[0095] Table 5:

[0096]

[0097] As shown in Table 5, for example, if there are multiple device identifiers in the unit time T2, it means that multiple terminals send video I frames in the unit time T2, so there is a collision of video I frames in the unit time.

[0098] By monitoring the video frame transmission information per unit time in this embodiment, it is possible to determine whether there is a collision of video I frames within the unit time according to the presence of the device identifier in each unit time.

[0099] In some of the embodiments, when there is a collision within a unit time, allocating an idle time slice for the video I frame in which the collision occurs, and transmitting the idle time slice to each terminal so that the terminal transmits the corresponding video I frame according to the standard time corresponding to the idle time slice, including the following steps:

[0100] When there is a collision within a unit time, the next unit time without a corresponding device identifier is found in time sequence according to the unit time of the video I frame where the collision occurs, and the unit time is used as an idle time slice.

[0101] Specifically, in the above embodiments, the collision of the I frame timestamp and the traffic peak in the unit time can indicate that the video I frame has collided. According to the unit time where the collision occurs, the next unit time without an empty device ID is searched in the order of the unit time slices. Take MulMAP1 as an example when the video frame transmission information is the I frame timestamp and the device ID, and search for the next time slice with an empty Chassis ID. Assuming that the idle time slice is Tj, the device ID ChassisID is added to the unit time slice corresponding to Tj in MulMAP1. At this time, the data in MulMAP1 is shown in the following table:

[0102] Table 6:

[0103]

[0104] When the video frame transmission information is the traffic peak value and the device identification, the traffic peak value also searches for the next unit time in which the device identification bit is empty in the monitored unit time in a similar manner as described above as the idle time slice.

[0105] Send an I frame control instruction containing idle time slice information to each terminal.

[0106] Specifically, the instruction for controlling the video I frame is sent to each terminal where the video I frame collision occurs, including the allocated idle time slice. Further, when the video frame transmission information is the I frame timestamp and the device identifier, the idle time slice can be sent to each terminal through the LLDPDU unit based on the LLDP protocol. It should be noted that in other embodiments, the I frame control instruction can also be sent through other protocols, and the specific protocol is not limited here.

[0107] In the terminal, the idle time slice is parsed to obtain the corresponding standard time, and the corresponding video I frame is transmitted according to the standard time.

[0108] Specifically, after receiving the control instruction including the idle time slice, each terminal parses and obtains the idle time slice, and re-encodes the video I frame with the idle time slice to obtain the corresponding standard time, and transmits the video I frame with the standard time. The standard time can be expressed as local time or Coordinated Universal Time (UTC).

[0109] In this embodiment, idle time slices are allocated to the video I frames that collide in the link device, and the idle time slices are sent to the terminals that collide through control instructions. This allows the transmission of the video I frames of each terminal to be controlled in the link device, so that each terminal can transmit the video I frames in a way that does not cause collision.

[0110] The present embodiment is described and illustrated below through preferred embodiments.

[0111] Figure 4 FIG. 1 is a flow chart of the video I frame transmission control method based on the link device of the preferred embodiment. Figure 4 As shown, the method comprises the following steps:

[0112] Step S410: Add a TLV field to the LLDP protocol between the link device and each terminal, and receive an LLDP message sent by each terminal based on the LLDP protocol.

[0113] Step S420: In the link device, the newly added TLV field in the LLDP message is parsed to obtain the I frame timestamp and device identification of the video I frame sent by the terminal.

[0114] Step S430: divide the I frame timestamp into corresponding unit times, and add the device identifier corresponding to the I frame timestamp into the corresponding unit time for monitoring.

[0115] Specifically, each unit time is 40 ms, the monitoring cycle is reset every 2 seconds, there are 50 unit time slices in total, and the monitoring is performed in the form of Table 3 in the above embodiment.

[0116] Step S440, if the device identification bit corresponding to the unit time is empty, directly add the corresponding device identification; if the device identification bit corresponding to the unit time is not empty, it means that a collision occurs, and execute step S450.

[0117] Step S450, find the next unit time without a corresponding device identifier in time sequence, and use the unit time as an idle time slice.

[0118] Step S460: Based on the LLDP protocol, the idle time slice is sent to each terminal through the LLDPDU unit. Each terminal re-encodes the video I frame according to the idle time slice obtained by parsing, and transmits the video I frame at the corresponding standard time.

[0119] Figure 5 FIG. 1 is a flowchart of a video I frame transmission control method based on a link device according to another preferred embodiment. Figure 5 As shown, the method comprises the following steps:

[0120] Step S510, collecting and obtaining the number of TCP message bytes of each port in the link device.

[0121] Step S520, calculating the flow data of the terminal corresponding to each port according to the number of message bytes.

[0122] Step S530, analyzing the flow data per unit time, and obtaining the flow peak value and the corresponding device identification according to the flow difference and historical flow within the unit time.

[0123] Specifically, the flow data is analyzed in the form of Table 2 in the above embodiment to obtain the flow difference and historical flow per unit time.

[0124] Step S540: divide the traffic peak value into corresponding unit times according to the collection time points, and add the device identifier corresponding to the traffic peak value into the corresponding unit time for monitoring.

[0125] Specifically, each unit time is 40 ms, and there are 50 unit time slices in total. The flow data within 2 seconds is monitored, and after the monitoring is completed, the monitoring results are statistically calculated in the form of Table 5 in the above embodiment.

[0126] Step S550: If the unit time corresponds to two or more device identifiers, it indicates that a collision occurs.

[0127] Step S560: Find the next unit time without a corresponding device identifier in time sequence, and use the unit time as an idle time slice.

[0128] Step S570: Send the idle time slice to each terminal through a control instruction. Each terminal re-encodes the video I frame according to the idle time slice obtained by parsing, and transmits the video I frame at a corresponding standard time.

[0129] It should be noted that the steps shown in the above process or the flowchart in the accompanying drawings can be executed in a computer system such as a set of computer executable instructions, and although a logical order is shown in the flowchart, in some cases, the steps shown or described can be executed in an order different from that shown here.

[0130] In this embodiment, a video I frame transmission control device based on a link device is also provided, and the device is used to implement the above-mentioned embodiments and preferred implementation modes, and the descriptions that have been made will not be repeated. The terms "module", "unit", "subunit", etc. used below can implement a combination of software and / or hardware for a predetermined function. Although the devices described in the following embodiments are preferably implemented in software, the implementation of hardware, or a combination of software and hardware, is also possible and conceivable.

[0131] Figure 6 : is a structural block diagram of the video I frame transmission control device based on the link device of this embodiment, such as Figure 6 As shown, the device includes: an acquisition module 610, a monitoring module 620 and a control module 630;

[0132] An acquisition module 610 is used to acquire video frame transmission information of a video I frame in each terminal;

[0133] A monitoring module 620, for detecting whether there is a collision within a unit time according to the video frame transmission information;

[0134] The control module 630 is used to allocate idle time slices for the video I frames that collide when there is a collision within a unit time, and transmit the idle time slices to each terminal so that the terminal transmits the corresponding video I frame according to the standard time corresponding to the idle time slice.

[0135] Through the device provided by this embodiment, it is determined whether there is a collision within a unit time according to the video frame transmission information of the video I frame obtained from each terminal, and an idle time slice is sent to the terminal corresponding to the video I frame where the collision occurs, and each terminal is controlled to transmit the video I frame with the idle time slice as the standard time. In the link device, a more accurate video I frame time can be obtained than the network platform, which solves the problem that there is an error in the received I frame time, thereby failing to accurately control the I frame, and achieves the effect of being able to directly perform more accurate timing control on the video I frames sent by each terminal in the link device.

[0136] It should be noted that the above modules can be functional modules or program modules, and can be implemented by software or hardware. For modules implemented by hardware, the above modules can be located in the same processor; or the above modules can be located in different processors in any combination.

[0137] This embodiment also provides a video I frame transmission control system based on a link device, such as Figure 7 As shown, the system includes: a terminal 710, a link device 720 and a network platform 730;

[0138] The terminal 710 is used to transmit the video frame data to the network platform through the link device, and transmit the video I frame at the corresponding standard time according to the idle time slice sent by the link device.

[0139] Specifically, the terminal 710 refers to a front-end video device such as an IP Camera (IP Camera, IPC).

[0140] The link device 720 is used to obtain the video frame transmission information of the video I frame in each terminal; and detect whether there is a collision within a unit time according to the video frame transmission information;

[0141] When there is a collision within a unit time, an idle time slice is allocated to the video I frame where the collision occurs, and the idle time slice is transmitted to each terminal.

[0142] Specifically, link devices refer to devices with forwarding functions such as switches, wireless repeaters, and wireless routers.

[0143] The network platform 730 is used to obtain video frame data from the terminal through the link device.

[0144] Specifically, the network platform refers to a network platform with certain business functions, such as a decoder, an NVR (Network Video Recorder), and a platform management controller DSS.

[0145] Taking the data interaction of a video I frame when the link device in the system is a switch and the terminal is an IPC as an example, the application of the above method embodiment in the system is described:

[0146] In the switch, the LLDP message sent by each IPC based on the LLDP protocol is received through the LLDP message transceiver module therein, and the video frame transmission information of the video I frame in each IPC is obtained. Then, the collision monitoring module is used to detect whether there is a collision within a unit time, and an idle time slice is allocated for the video I frame in which the collision occurs. The idle time slice is sent to each IPC based on the LLDP protocol through the LLDP message transceiver module.

[0147] In the IPC, the LLDP message transceiver module sends and receives LLDP messages to the switch, and the audio and video module encodes the video I frame at the standard time corresponding to the idle time slice.

[0148] In another system corresponding to the method embodiment, the switch reads the message information of each port of the switch through the traffic monitoring module, and calculates the traffic data of the IPC corresponding to each port, and then determines whether a collision occurs within a unit time according to the traffic data in the collision monitoring module, and allocates an idle time slice for the video I frame where the collision occurs, and finally sends the idle time slice to each IPC through a control instruction in the IPC control module;

[0149] In the IPC, the control instructions sent by the switch are received through the controlled module, the idle time slices contained therein are parsed, and the idle time slices are called back to the audio and video encoding module in the IPC, and the video I frame is encoded in the audio and video encoding module with the standard time corresponding to the idle time slice.

[0150] Through the system provided by this embodiment, it is possible to determine whether there is a collision within a unit time based on the video frame transmission information of the video I frame obtained from each terminal in the link device, and send an idle time slice to the terminal corresponding to the video I frame where the collision occurred, so as to control each terminal to transmit the video I frame to the network platform with the idle time slice as the standard time, thereby solving the problem that the I frame cannot be accurately controlled due to the error in the received I frame time in the network platform, and achieving the effect of more accurate timing control of the video I frame sent by each terminal directly in the link device.

[0151] In this embodiment, a computer device is further provided, including a memory and a processor, wherein a computer program is stored in the memory, and the processor is configured to run the computer program to execute the steps in any one of the above method embodiments.

[0152] Optionally, the computer device may further include a transmission device and an input / output device, wherein the transmission device is connected to the processor, and the input / output device is connected to the processor.

[0153] It should be noted that the specific examples in this embodiment can refer to the examples described in the above embodiments and optional implementation modes, and will not be repeated in this embodiment.

[0154] In addition, in combination with the video I frame transmission control method based on the link device provided in the above embodiment, a storage medium can also be provided in this embodiment to implement. The storage medium stores a computer program; when the computer program is executed by the processor, any one of the video I frame transmission control methods based on the link device in the above embodiment is implemented.

[0155] It should be understood that the specific embodiments described herein are only used to explain the application, rather than to limit it. Based on the embodiments provided in this application, all other embodiments obtained by ordinary technicians in this field without creative work are within the protection scope of this application.

[0156] Obviously, the drawings are only some examples or embodiments of the present application. For ordinary technicians in the field, the present application can also be applied to other similar situations based on these drawings without creative work. In addition, it is understandable that although the work done in this development process may be complicated and lengthy, for ordinary technicians in the field, certain changes in design, manufacturing or production based on the technical content disclosed in this application are only conventional technical means and should not be regarded as insufficient content disclosed in this application.

[0157] The term "embodiment" in this application refers to a specific feature, structure or characteristic described in conjunction with the embodiment that can be included in at least one embodiment of the present application. The appearance of this phrase in various locations in the specification does not necessarily mean the same embodiment, nor does it mean that it is mutually exclusive with other embodiments and is independent or optional. It is clearly or implicitly understood by those of ordinary skill in the art that the embodiments described in this application can be combined with other embodiments without conflict.

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

Claims

1. A video I frame transmission control method based on a link device, characterized in that: include: Obtain video frame transmission information of video I frames in each terminal; The video frame transmission information includes the timestamp of the video I frame, the traffic peak value and the device identification of each terminal; Transmitting information according to the video frame to detect whether there is a collision within a unit time; When there is a collision within a unit time, one of the video I frames that collided is retained without controlling its sending timing, and idle time slices are allocated to the remaining video I frames that collided, and the idle time slices are transmitted to each terminal, so that the corresponding video I frame is transmitted in the terminal according to the standard time corresponding to the idle time slice.

2. The video I frame transmission control method based on link equipment according to claim 1 is characterized in that: The obtaining of video frame transmission information of video I frames in each terminal includes: The I frame timestamp and device identification of the video I frame in each terminal are obtained by receiving.

3. The video I frame transmission control method based on link equipment according to claim 2 is characterized in that: The receiving and obtaining the I frame timestamp and device identification of the video I frame in each terminal includes: Receiving LLDP messages sent by each of the terminals based on the LLDP protocol; The I frame timestamp and device identification are obtained by parsing the newly added fields in the LLDP message.

4. The video I frame transmission control method based on link equipment according to claim 1, characterized in that: The obtaining of video frame transmission information of video I frames in each terminal includes: The traffic peak value and device identification of the video I frame in each terminal are collected.

5. The video I frame transmission control method based on link device according to claim 4 is characterized in that: The collecting of the traffic peak value and device identification of the video I frame in each terminal includes: By collecting message information of ports in the link device, flow data of each terminal corresponding to the port is obtained; The flow peak value and device identification are obtained by analyzing the flow data.

6. The video I frame transmission control method based on link device according to any one of claims 1 to 5, characterized in that: The transmitting information according to the video frame to detect whether there is a collision within a unit time includes: When the video frame transmission information is an I frame timestamp and a device identifier, the I frame timestamp and the corresponding device identifier are divided into corresponding unit times, and by monitoring the device identifier in the unit time, it is determined whether there is a collision within the unit time, or; When the video frame transmission information is a traffic peak and a device identification, the time of the traffic peak is determined according to the acquisition time point, and the traffic peak and the corresponding device identification are divided into corresponding unit times. By monitoring the device identification in the unit time, it is determined whether there is a collision within the unit time.

7. The video I frame transmission control method based on link equipment according to claim 6 is characterized in that: The step of monitoring the device identification in the unit time to determine whether there is a collision in the unit time includes: When the video frame transmission information includes the I frame timestamp and the device identifier, if the corresponding device identifier already exists in the unit time, then there is a video I frame collision in the unit time, or; When the video frame transmission information includes the traffic peak value and the device identifier, if there are a number of device identifiers corresponding to the unit time, there is a video I frame collision within the unit time.

8. The video I frame transmission control method based on link equipment according to claim 1, characterized in that: When there is a collision within a unit time, allocating an idle time slice to the video I frame where the collision occurs, and transmitting the idle time slice to each terminal, so that the terminal transmits the corresponding video I frame according to the standard time corresponding to the idle time slice, including: When there is a collision within a unit time, according to the unit time of the video I frame where the collision occurs, find the next unit time without the corresponding device identifier in time sequence, and use the unit time as the idle time slice; Sending an I frame control instruction including the idle time slice information to each of the terminals; In the terminal, the idle time slice is parsed to obtain the corresponding standard time, and the corresponding video I frame is transmitted according to the standard time.

9. A video I frame transmission control device based on a link device, characterized in that: include: Acquisition module, monitoring module and control module; An acquisition module, used to acquire video frame transmission information of video I frames in each terminal; The video frame transmission information includes the timestamp of the video I frame, the traffic peak value and the device identification of each terminal; A monitoring module, used for transmitting information according to the video frame to detect whether there is a collision within a unit time; The control module is used to retain one of the video I frames that has collided without controlling its sending timing when there is a collision within a unit time, allocate idle time slices to the remaining video I frames that have collided, and transmit the idle time slices to each terminal, so that the terminal transmits the corresponding video I frame according to the standard time corresponding to the idle time slice.

10. A computer device comprising a memory and a processor, characterized in that: A computer program is stored in the memory, and the processor is configured to run the computer program to execute the link device-based video I frame transmission control method according to any one of claims 1 to 8.

11. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by a processor, the steps of the link device-based video I frame transmission control method according to any one of claims 1 to 8 are implemented.