CN104038307A - Data stream transmission system and method - Google Patents

Data stream transmission system and method Download PDF

Info

Publication number
CN104038307A
CN104038307A CN201310069360.2A CN201310069360A CN104038307A CN 104038307 A CN104038307 A CN 104038307A CN 201310069360 A CN201310069360 A CN 201310069360A CN 104038307 A CN104038307 A CN 104038307A
Authority
CN
China
Prior art keywords
data stream
serial data
compression algorithm
compression
electronic equipment
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.)
Pending
Application number
CN201310069360.2A
Other languages
Chinese (zh)
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.)
Hongfujin Precision Industry Shenzhen Co Ltd
Hon Hai Precision Industry Co Ltd
Original Assignee
Hongfujin Precision Industry Shenzhen Co Ltd
Hon Hai Precision Industry 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 Hongfujin Precision Industry Shenzhen Co Ltd, Hon Hai Precision Industry Co Ltd filed Critical Hongfujin Precision Industry Shenzhen Co Ltd
Priority to CN201310069360.2A priority Critical patent/CN104038307A/en
Priority to TW102108218A priority patent/TW201436533A/en
Publication of CN104038307A publication Critical patent/CN104038307A/en
Pending legal-status Critical Current

Links

Abstract

A data stream transmission method is applied to a piece of first electronic equipment used as a sending end. The method comprises the following steps: converting a to-be-transmitted original data stream into a serial data stream; determining whether or not to compress the serial data stream, and determining a compression algorithm when determining to compress the serial data stream; compressing the serial data stream by use of the determined compression algorithm; and adding a compression mark to the serial data stream and then sending the serial data stream to a piece of second electronic equipment used as a receiving end, wherein the compression mark records whether the serial data stream is compressed and the compression algorithm adopted. The invention further provides a data stream transmission system. The data stream transmission method and the data stream transmission system of the invention can be used in serial data stream transmission.

Description

Data streaming system and method
Technical field
The present invention relates to a kind of data streaming system and method, relate in particular to a kind of serial data flow transmission system and method.
Background technology
Serial ports is at industrial application prospers long always, and along with the development of wireless transmission, the application surface of serial transmission technology is in continuous expansion now.Yet due to the restriction of serial technology itself, the gap between its transmittability and parallel transmission exists all the time.Current, in order to shorten this gap, the most frequently used method is to transmitting after data stream compression.
Yet in data stream compression process, same compression algorithm, is different for different data streams compression ratio.For example, when the document having compressed compresses again, its compression stroke is very little, and common character document can be with very big ratio compression.Given this, in serial data stream transmission procedure, transmission speed with the transmission network of compression function is extremely unsettled, it is on the one hand the asynchronism(-nization) consuming while compressing due to different data streams is done, on the other hand, the data volume after the data stream compression under some extreme case is large all the better, and for example after null file compression, data volume can increase on the contrary, also after even all adopting certain compression algorithm of reservation to compress to various data flow, transmit again, also can have influence on transmission rate.
Summary of the invention
In view of above content, be necessary to provide a kind of data streaming system and method, can be used for serial data flow transmission.
Described data streaming system, runs on the first electronic equipment as transmitting terminal, and this system comprises: the first processing module, for original data stream waiting for transmission is converted to serial data stream; The first judge module, compresses this serial data stream for determining whether, and determines when this serial data stream is compressed, and determines compression algorithm; Compression module, for compressing serial data stream according to definite compression algorithm; And sending module, for send to the second electronic equipment as receiving terminal after serial data stream adds compressing mark, this compressing mark is recorded the compression algorithm whether described serial data stream adopts when overcompression and compression.
Described data streaming system, runs on the second electronic equipment as receiving terminal, and this system comprises: receiver module, for receiving the serial data stream sending over from the first electronic equipment as transmitting terminal; The second judge module, for judging whether to separate press operation according to the compressing mark of received serial data stream; Decompression module, carries out decompress(ion) for the compression algorithm of recording according to compressing mark to received serial data stream; And second processing module, for serial data stream is converted to original data stream.
Described data flow transmission method, is applied to the first electronic equipment as transmitting terminal, and the method comprises: the first treatment step, is converted to serial data stream by original data stream waiting for transmission; The first determining step, determines whether this serial data stream to compress, and determines when this serial data stream is compressed, and determines compression algorithm; Compression step, compresses serial data stream according to definite compression algorithm; And forwarding step, after adding compressing mark, serial data stream sends to the second electronic equipment as receiving terminal, and this compressing mark is recorded the compression algorithm whether described serial data stream adopts when overcompression and compression.
Described data flow transmission method, is applied to the second electronic equipment as receiving terminal, and the method comprises: receiving step, receives the serial data stream sending over from the first electronic equipment as transmitting terminal; The second determining step, judges whether to separate press operation according to the compressing mark of received serial data stream; Separate contracting step, the compression algorithm of recording according to compressing mark is carried out decompress(ion) to received serial data stream; And second treatment step, serial data stream is converted to original data stream.
Compared to prior art, described data streaming system and method, can be used for serial data flow transmission, and can determine whether serial data stream compression according to the concrete condition of serial data stream, thereby make the transmission speed of serial transmission network more stable.
Accompanying drawing explanation
Fig. 1 is the running environment figure of data streaming system of the present invention.
Fig. 2 is the functional block diagram of data streaming system of the present invention.
Fig. 3 is the data flow transmission flow figure of the preferred embodiment of data flow transmission method of the present invention.
Fig. 4 is that the data flow of the preferred embodiment of data flow transmission method of the present invention receives flow chart.
Main element symbol description
The first electronic equipment 1
The second electronic equipment 2
Data streaming system 10
First memory 20
First processor 30
The first communication module 40
The second communication module 41
Second memory 50
The second processor 60
The first processing module 11
The first judge module 12
Compression module 13
Sending module 14
Receiver module 15
The second judge module 16
Decompression module 17
The second processing module 18
Following embodiment further illustrates the present invention in connection with above-mentioned accompanying drawing.
Embodiment
As shown in Figure 1, be the running environment figure of data streaming system of the present invention.In the present embodiment, data streaming system 10 runs in the first electronic equipment 1 and the second electronic equipment 2.Described data streaming system 10 for carrying out data stream transmitting by the first communication module 40 and the second communication module 41 between described the first electronic equipment 1 and the second electronic equipment 2.Described data flow comprises data, order etc.Described the first communication module 40 and the second communication module 41 can be wired serial transmission cables, wireless-transmission network etc.It should be noted that, described the first electronic equipment 1 or the second electronic equipment 2 both can be used as transmitting terminal and also can be used as receiving terminal.
In the present embodiment, described the first electronic equipment 1 also comprises first memory 20 and first processor 30, and described the second electronic equipment 2 also comprises second memory 50 and the second processor 60.It should be noted that, the simple description that the present embodiment just carries out the structure of the first electronic equipment 1 and the second electronic equipment 2, this first electronic equipment 1 and the second electronic equipment 2 can also comprise other elements, as Circuits System, sound effect system, I/O interface, battery, operating system etc.
Described first memory 20 and second memory 50 can be for storing the data such as program code of described data streaming system 10.In the present embodiment, described data streaming system 10 can be divided into one or more modules, described one or more module is stored in described first memory 20 and second memory 50 and for example, by one or more processors (first processor in the present embodiment 30 and the second processor 60) and carries out, to complete the present invention.
In the present embodiment, described data streaming system 10 comprises that the first processing module 11, the first judge module 12, compression module 13, sending module 14, receiver module 15, the second judge module 16, decompression module 17 and the second processing module 18(consult shown in Fig. 2).
It should be noted that, when described data streaming system 10 runs on transmitting terminal, described data streaming system 10 is carried out described the first processing module 11, the first judge module 12, compression module 13 and sending module 14.When described data streaming system 10 runs on receiving terminal, described data streaming system 10 is carried out described receiver module 15, the second judge module 16, decompression module 17 and the second processing module 18.
The alleged module of the present invention has been the program segment of a specific function, than program, is more suitable in describing the implementation of software in the first electronic equipment 1 and the second electronic equipment 2, will be in following specific descriptions about the function of each module.
As shown in Figure 3, be the data flow transmission flow figure of the preferred embodiment of data flow transmission method of the present invention.Wherein, Fig. 3 is usingd the first electronic equipment 1 and is described as transmitting terminal, in other embodiments, also can the second electronic equipment 2 as transmitting terminal.Step S1, the first processing module 11 is converted to serial data stream by original data stream waiting for transmission.Described original data stream comprises data, order etc.
Step S2, the first judge module 12 determines whether this serial data stream to compress, and determines when this serial data stream is compressed, and determines compression algorithm.
Particularly, described the first judge module 12 can intercept a section in this serial data stream, utilize default multiple compression algorithm respectively the serial data stream of this intercepting to be compressed, which kind of compression algorithm compression ratio according to the serial data stream of this intercepting under each compression algorithm, determine whether described serial data stream waiting for transmission to be compressed and to adopt.
For example, for example, three kinds of compression algorithms have been preset, be respectively A, B, C, the compression ratio of the serial data stream of supposing described intercepting under compression algorithm A is 40%, and the compression ratio under compression algorithm B is 50%, compression ratio under compression algorithm C is 90%, obviously the compression ratio under compression algorithm C is maximum, so determines and adopts compression algorithm C, flow performing step S3.
And for example, suppose that the serial data stream of described intercepting is under described each default compression algorithm, the data volume after compression increases on the contrary, so determines described serial data stream waiting for transmission is not compressed, flow performing step S4.In other embodiments, also can be set to serial data stream when the described intercepting compression ratio under various compression algorithms all very little, for example, while being all less than 5%, determining described serial data stream waiting for transmission is not compressed to processing.
Step S3, compression module 13 compresses serial data stream according to definite compression algorithm.
Step S4, sending module 14 sends to the second electronic equipment 2 as receiving terminal by described the first communication module 40 after described serial data stream adds compressing mark.This compressing mark is recorded the compression algorithm whether described serial data stream adopts when overcompression and compression.
In the present embodiment, described sending module 14 can add described compressing mark at packet header or the bag tail of serial data stream place packet.
It should be noted that, if when step S2, determine and described serially-transmitted data stream is not compressed, 14 pairs of described serial data streams of described sending module add compressing mark, identify this serial data stream not through overcompression.
As shown in Figure 4, be the flow chart of data flow transmission method preferred embodiment data flow receiving course of the present invention.Wherein, Fig. 4 is usingd the first electronic equipment 1 and is described as receiving terminal.As mentioned above, in other embodiments, also can be using the second electronic equipment 2 as receiving terminal.
Step S11, receiver module 15 receives from the second communication module 41 serial data stream sending over from the first electronic equipment 1 as transmitting terminal.
Step S12, the second judge module 16 judges whether to separate press operation according to the compressing mark of received serial data stream.If compressing mark is recorded this serial data stream through overcompression, perform step S13.If compressing mark is recorded the serial data stream receiving, do not have through overcompression, perform step S14.
Step S13, the compression algorithm that decompression module 17 is recorded according to compressing mark is carried out decompress(ion) to received serial data stream.
Step S14, the second processing module 18 is converted to original data stream by serial data stream.It should be noted that, in this step, when received described serial data stream need be separated press operation, what described the second processing module 18 was processed is the serial data stream through decompress(ion) gained.
Finally it should be noted that, above embodiment is only unrestricted in order to technical scheme of the present invention to be described, although the present invention is had been described in detail with reference to preferred embodiment, those of ordinary skill in the art is to be understood that, can modify or be equal to replacement technical scheme of the present invention, and not depart from the spirit and scope of technical solution of the present invention.

Claims (6)

1. a data streaming system, runs on the first electronic equipment as transmitting terminal, it is characterized in that, this system comprises:
The first processing module, for being converted to serial data stream by original data stream waiting for transmission;
The first judge module, compresses this serial data stream for determining whether, and determines when this serial data stream is compressed, and determines compression algorithm;
Compression module, for compressing serial data stream according to definite compression algorithm; And
Sending module, for send to the second electronic equipment as receiving terminal after serial data stream adds compressing mark, this compressing mark is recorded the compression algorithm whether described serial data stream adopts when overcompression and compression.
2. data streaming system as claimed in claim 1, it is characterized in that, described the first judge module intercepts a section of described serial data stream, utilize default multiple compression algorithm respectively the serial data stream of this intercepting to be compressed, which kind of compression algorithm compression ratio according to the serial data stream of this intercepting under each compression algorithm, determine whether described serial data stream waiting for transmission to be compressed and to adopt.
3. a data streaming system, runs on the second electronic equipment as receiving terminal, it is characterized in that, this system comprises:
Receiver module, for receiving the serial data stream sending over from the first electronic equipment as transmitting terminal;
The second judge module, for judging whether to separate press operation according to the compressing mark of received serial data stream;
Decompression module, carries out decompress(ion) for the compression algorithm of recording according to compressing mark to received serial data stream; And
The second processing module, for being converted to original data stream by serial data stream.
4. a data flow transmission method, is applied to the first electronic equipment as transmitting terminal, it is characterized in that, the method comprises:
The first treatment step, is converted to serial data stream by original data stream waiting for transmission;
The first determining step, determines whether this serial data stream to compress, and determines when this serial data stream is compressed, and determines compression algorithm;
Compression step, compresses serial data stream according to definite compression algorithm; And
Forwarding step sends to the second electronic equipment as receiving terminal after serial data stream adds compressing mark, and this compressing mark is recorded the compression algorithm whether described serial data stream adopts when overcompression and compression.
5. data flow transmission method as claimed in claim 4, it is characterized in that, in described the first determining step, from one section of described serial data stream intercepting, utilize default multiple compression algorithm respectively the serial data stream of this intercepting to be compressed, which kind of compression algorithm compression ratio according to the serial data stream of this intercepting under each compression algorithm, determine whether described serial data stream waiting for transmission to be compressed and to adopt.
6. a data flow transmission method, is applied to the second electronic equipment as receiving terminal, it is characterized in that, the method comprises:
Receiving step, receives the serial data stream sending over from the first electronic equipment as transmitting terminal;
The second determining step, judges whether to separate press operation according to the compressing mark of received serial data stream;
Separate contracting step, the compression algorithm of recording according to compressing mark is carried out decompress(ion) to received serial data stream; And
The second treatment step, is converted to original data stream by serial data stream.
CN201310069360.2A 2013-03-05 2013-03-05 Data stream transmission system and method Pending CN104038307A (en)

Priority Applications (2)

Application Number Priority Date Filing Date Title
CN201310069360.2A CN104038307A (en) 2013-03-05 2013-03-05 Data stream transmission system and method
TW102108218A TW201436533A (en) 2013-03-05 2013-03-08 System and method of transmitting data stream

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201310069360.2A CN104038307A (en) 2013-03-05 2013-03-05 Data stream transmission system and method

Publications (1)

Publication Number Publication Date
CN104038307A true CN104038307A (en) 2014-09-10

Family

ID=51468914

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201310069360.2A Pending CN104038307A (en) 2013-03-05 2013-03-05 Data stream transmission system and method

Country Status (2)

Country Link
CN (1) CN104038307A (en)
TW (1) TW201436533A (en)

Cited By (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN106776663A (en) * 2015-11-25 2017-05-31 腾讯科技(深圳)有限公司 The compression method and device of audio file
CN107015817A (en) * 2017-05-25 2017-08-04 孙文现 A kind of method of equipment firmware aerial upgrade
WO2017156684A1 (en) * 2016-03-14 2017-09-21 华为技术有限公司 Method, apparatus, and system for transmitting data
CN110430168A (en) * 2019-07-05 2019-11-08 视联动力信息技术股份有限公司 A kind of method and apparatus of data compression

Cited By (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN106776663A (en) * 2015-11-25 2017-05-31 腾讯科技(深圳)有限公司 The compression method and device of audio file
WO2017156684A1 (en) * 2016-03-14 2017-09-21 华为技术有限公司 Method, apparatus, and system for transmitting data
US11375047B2 (en) 2016-03-14 2022-06-28 Huawei Technologies Co., Ltd. Data transmission method, apparatus, and system
CN107015817A (en) * 2017-05-25 2017-08-04 孙文现 A kind of method of equipment firmware aerial upgrade
CN107015817B (en) * 2017-05-25 2021-06-01 北京君泊网络科技有限责任公司 Method for upgrading equipment firmware in air
CN110430168A (en) * 2019-07-05 2019-11-08 视联动力信息技术股份有限公司 A kind of method and apparatus of data compression

Also Published As

Publication number Publication date
TW201436533A (en) 2014-09-16

Similar Documents

Publication Publication Date Title
JP7029471B2 (en) Uplink data decompression, compression method and equipment
CN107295036B (en) Data sending method and data merging equipment
CN109756536A (en) A kind of method, apparatus and system of data transmission
CN104412601A (en) System and method for single KVM client accommodating multiple different video compression technologies
CN104978319A (en) Method and equipment used for classified transmission of files
US20150071307A1 (en) Communication interface and method for robust header compression of data flows
CN104038307A (en) Data stream transmission system and method
US11671678B2 (en) Method and device, equipment, and storage medium for data processing
CN106851733A (en) A kind of adaptive H TTP message compression methods for mobile network's application
CN107154835B (en) Data sending method and device
CN114039973A (en) File transmission method, device and storage medium
US10326677B2 (en) Communication device, available band calculation system, available band calculation method, and program
CN113138969A (en) Data transmission method and device, electronic equipment and computer readable storage medium
CN105262491A (en) Data compression method, data compression system, data decompression method, data decompression system and communication equipment
CN107615810B (en) Packet header compression system and method for online network code
CN110798865B (en) Data compression method, data compression device, computer equipment and computer-readable storage medium
JP2012039198A (en) Data compression transmission system, transmission apparatus, and data compression transmission method for use therein
CN109584889B (en) Audio transmission method and device and storage medium
CN117014379A (en) Code rate control method, device, electronic equipment and storage medium
CN110401604B (en) Information transmission method, device and computer readable storage medium
CN108289165B (en) Method and device for realizing camera control based on mobile phone and terminal equipment
CN114666776A (en) Data transmission method, device, equipment and readable storage medium
CN109379376B (en) Radio monitoring equipment and system based on data compression and data compression method
CN112335203B (en) Processing local area network diagnostic data
WO2021036189A1 (en) Rdma data sending and receiving methods, electronic device and readable storage medium

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
C02 Deemed withdrawal of patent application after publication (patent law 2001)
WD01 Invention patent application deemed withdrawn after publication

Application publication date: 20140910