Debounce buffer, data storage method and device, data reading method and device
A data storage and buffer technology, applied in the direction of data exchange network, digital transmission system, electrical components, etc., can solve the problems of low data storage and reading efficiency, slow traversal of linked lists, etc., to speed up storage and improve data reading Efficiency, the effect of improving buffer efficiency
- Summary
- Abstract
- Description
- Claims
- Application Information
AI Technical Summary
Problems solved by technology
Method used
Image
Examples
Embodiment 1
[0065] Such as figure 1 As shown, this embodiment provides a debounce buffer, including:
[0066] One or more data linked lists 1 for storing data;
[0067] The ring data index includes a plurality of data indexes 2 arranged sequentially in a ring, the starting position 21 of the ring data index can be set, and each data linked list 1 corresponds to a data index 2 .
[0068] The above-mentioned debounce buffer adds a ring data index on the basis of the linked list structure buffer, so that the data can be inserted into the data linked list corresponding to the corresponding data index according to its timestamp, without the need to sort by one-to-one comparison. When the data is read It is also to read data in the corresponding data index according to the timestamp, without viewing them one by one. Therefore, the traversal speed can be accelerated, the data insertion and reading time can be reduced, and the buffering efficiency can be improved. In addition, each data index ...
Embodiment 2
[0072] Such as figure 2 and 3 As shown, the present embodiment provides a data storage method, which is applicable to the debounce buffer based on the RTP / UDP protocol, including the following steps:
[0073] S11: Determine whether the data linked list in the debounce buffer is empty, that is, whether there is real-time data stream data in the data linked list in the current buffer;
[0074] S12: If it is empty, store the data to be inserted in a data linked list, use the timestamp of the data as the minimum timestamp, and set the data index corresponding to the data linked list as the starting position, because the data in the current buffer When there is no real-time data stream data in the data linked list, the data to be inserted is the earliest real-time data stored in it;
[0075] S13: If not empty, calculate the difference between the timestamp of the data to be inserted and the minimum timestamp;
[0076] S14: Determine the data index corresponding to the data to b...
Embodiment 3
[0086] This embodiment provides a data reading method, which is applicable to the debounce buffer based on the RTP / UDP protocol, such as Figure 4 shown, including the following steps:
[0087] S21: judging whether the data linked list in the debounce buffer is empty;
[0088] S22: When it is not empty, divide the interval between the current time and the last read time by the time interval between two adjacent data indexes in the ring data index to obtain the quotient T2;
[0089] S23: Take sequentially the data stored in the data linked list corresponding to the data index corresponding to the starting position to the T2th array index;
[0090] S24: Set the data index corresponding to the data with the smallest time stamp in the remaining data as the starting position.
[0091] In addition, when it is judged that the data link list in the debounce buffer is empty, it means that there is no real-time data available for reading, and then exit directly.
[0092] The data rea...
PUM
Abstract
Description
Claims
Application Information
- R&D Engineer
- R&D Manager
- IP Professional
- Industry Leading Data Capabilities
- Powerful AI technology
- Patent DNA Extraction
Browse by: Latest US Patents, China's latest patents, Technical Efficacy Thesaurus, Application Domain, Technology Topic, Popular Technical Reports.
© 2024 PatSnap. All rights reserved.Legal|Privacy policy|Modern Slavery Act Transparency Statement|Sitemap|About US| Contact US: help@patsnap.com