CN110445578A - A kind of SPI data transmission method and device - Google Patents

A kind of SPI data transmission method and device Download PDF

Info

Publication number
CN110445578A
CN110445578A CN201910698023.7A CN201910698023A CN110445578A CN 110445578 A CN110445578 A CN 110445578A CN 201910698023 A CN201910698023 A CN 201910698023A CN 110445578 A CN110445578 A CN 110445578A
Authority
CN
China
Prior art keywords
data
buffer area
sent
frame
receiver buffer
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.)
Granted
Application number
CN201910698023.7A
Other languages
Chinese (zh)
Other versions
CN110445578B (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.)
Guangxin Microelectronics (guangzhou) Co Ltd
Original Assignee
Guangxin Microelectronics (guangzhou) 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 Guangxin Microelectronics (guangzhou) Co Ltd filed Critical Guangxin Microelectronics (guangzhou) Co Ltd
Priority to CN201910698023.7A priority Critical patent/CN110445578B/en
Publication of CN110445578A publication Critical patent/CN110445578A/en
Application granted granted Critical
Publication of CN110445578B publication Critical patent/CN110445578B/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/0015Systems modifying transmission characteristics according to link quality, e.g. power backoff characterised by the adaptation strategy
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L1/00Arrangements for detecting or preventing errors in the information received
    • H04L1/22Arrangements for detecting or preventing errors in the information received using redundant apparatus to increase reliability
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/50Network services
    • H04L67/56Provisioning of proxy services
    • H04L67/568Storing data temporarily at an intermediate stage, e.g. caching

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Quality & Reliability (AREA)
  • Communication Control (AREA)
  • Data Exchanges In Wide-Area Networks (AREA)

Abstract

The invention discloses a kind of SPI data transmission method and devices.In one embodiment: data distribution to be sent being sent into buffer area to N number of data, wherein N is the integer greater than 1;The data to be sent that each data are sent to buffer area, are sent to corresponding data receiver buffer area, so that receiving end garbled data from least one data receiver buffer area, to obtain a and consistent partial data of data to be sent;Wherein, the data send buffer area and the data receiver buffer area is cyclic buffer.Introduction based on the above embodiment, implementing technical solution of the present invention can be under the premise of guaranteeing the integrality of data transmission, improve data transfer efficiency.

Description

A kind of SPI data transmission method and device
Technical field
The present invention relates to technical field of data transmission more particularly to a kind of SPI data transmission methods and device.
Background technique
In SPI (Serial Peripheral Interface, Serial Peripheral Interface (SPI)) data transmission procedure, usually can There is the phenomenon that data packetloss.To solve this problem, data transmission procedure of the prior art based on SPI connection, by specified Flow control, i.e. acknowledgement mechanism are confirmed whether to have correctly received data frame.Although this way ensure that data to a certain extent Integrality, a certain frame data check errors can once occur, then need the request repeat frame data, so recycle, until complete Portion's data send complete, to transmit so as to cause SPI data inefficiency.
Summary of the invention
The object of the present invention is to provide a kind of SPI data transmission method and devices, can guarantee the complete of data transmission Under the premise of whole property, improve data transfer efficiency.
In order to solve the above-mentioned technical problem, the embodiment of the invention provides a kind of SPI data transmission methods, comprising:
Data distribution to be sent is sent into buffer area to N number of data, wherein N is the integer greater than 1;
The data to be sent that each data are sent to buffer area, are sent to corresponding data receiver buffer area, so that Receiving end garbled data from least one data receiver buffer area, to obtain a consistent complete with the data to be sent Entire data;Wherein, the data send buffer area and the data receiver buffer area is cyclic buffer.
It is described by data distribution to be sent to N number of data send buffer area before, further includes:
Check code is generated to each frame data of data to be sent, and adds frame number to each frame data, wherein described Frame number indicates that M is the integer greater than 0 with M;
In the data to be sent that each data are sent to buffer area, it is sent to corresponding data receiver buffer area Later, further includes:
So that receiving end to each data receiver buffer area the check codes of received each frame data verify, and will The data frame of verification failure abandons.
It is described so that receiving end garbled data from least one data receiver buffer area, comprising: so that receiving end is from The data frame cached is taken out in one data receiver buffer area, then according to taking out from n-th data receiver buffer area The mode garbled data of the data frame lacked in N-1 data receiver buffer area.
Described so that receiving end garbled data from least one data receiver buffer area, further includes: so that receiving end When last data receives buffer area and takes out data and jump latter data reception buffer area, by previous data receiver buffer area All data dumps;When so that receiving end is sequentially sieved from first data receiver buffer area to n-th data receiver buffer area After selecting data, when cannot still obtain a partial data consistent with the data to be sent, then above-mentioned steps are repeated, directly To acquisition portion and the consistent partial data of data to be sent.
The data send buffer area and each frame data of the data receiver buffer area are arranged according to frame number ascending order Column.
To solve identical technical problem, the embodiment of the present invention separately provides a kind of SPI data transmission method, comprising: connects The N number of data for receiving and dispatching sending end send the data to be sent that buffer area is sent, and are cached in corresponding with each data transmission buffer area Data receiver buffer area;
The garbled data from least one data receiver buffer area, to obtain a consistent with the data to be sent Partial data;Wherein, the data send buffer area and the data receiver buffer area is cyclic buffer.
To each data receiver buffer area the check codes of received each frame data verify, and will verification failure Data frame abandons.
The garbled data from least one data receiver buffer area, comprising: from first data receiver buffer area The data frame cached is taken out, is then taken out in the N-1 data receiver buffer area according to from n-th data receiver buffer area The mode garbled data of the data frame of missing.
In the garbled data from least one data receiver buffer area, further includes: receive buffer area in last data When taking out data and jumping latter data reception buffer area, by all data dumps of previous data receiver buffer area;When according to Sequence from first data receiver buffer area to n-th data receiver buffer area after garbled data, cannot still obtain it is a with it is described When the consistent partial data of data to be sent, then above-mentioned steps are repeated, until obtaining a with the data one to be sent The partial data of cause.
As an improvement of the above scheme, another embodiment of the present invention correspondence provides a kind of SPI data transmission device, wraps It includes:
File distributing unit, for data distribution to be sent to be sent buffer area to N number of data, wherein N is whole greater than 1 Number;
Data transmission unit is sent to corresponding number for each data to be sent to the data to be sent of buffer area According to buffer area is received so that receiving end garbled data from least one data receiver buffer area, thus obtain it is a with it is described The consistent partial data of data to be sent;Wherein, the data send buffer area and the data receiver buffer area is circulation Buffer area.
Pretreatment unit generates check code for each frame data to data to be sent, and adds to each frame data Frame number, wherein the frame number is indicated with M, M is the integer greater than 0;
The data transmission unit is also used to make receiving end to the received each frame data of each data receiver buffer area institute Check code verified, and will verification failure data frame abandon.
As an improvement of the above scheme, another embodiment of the present invention correspondence provides a kind of SPI data transmission device, wraps It includes:
Data receipt unit, N number of data for receiving transmitting terminal send the data to be sent that buffer area is sent, and cache In data receiver buffer area corresponding with each data transmission buffer area;
Data screening unit, for the garbled data from least one data receiver buffer area, to obtain a and institute State the consistent partial data of data to be sent;Wherein, the data send buffer area and the data receiver buffer area is to follow Ring buffer area.
Data check unit, for each data receiver buffer area the check codes of received each frame data carry out school It tests, and the data frame of verification failure is abandoned.
Compared with the prior art, the beneficial effect of the embodiment of the present invention is, SPI data provided in an embodiment of the present invention pass Transmission method and device send buffer area and data receiver buffer area by using N number of data to realize double buffers, and make to connect Receiving end garbled data from least one data receiver buffer area is a consistent complete with the data to be sent up to obtaining Data, to guarantee the integrality of data transmission;When there is data packetloss situation, it can be used from preliminary data and receive buffer area Middle screening institute packet loss data, to solve asking using acknowledgement mechanism caused by inefficiency of the prior art under packet drop Topic, and then improve the efficiency of data transmission.
Another embodiment of the present invention provides a kind of terminal device, including processor, memory and it is stored in described deposit In reservoir and it is configured as the computer program executed by the processor, the processor executes real when the computer program Existing SPI data transmission method as described in any one of the above embodiments.
Another embodiment of the present invention provides a kind of servers, comprising:
One or more processors;
Storage device, for storing one or more programs;
When one or more of programs are executed by one or more of processors, so that one or more of processing Device realizes SPI data transmission method as described in any one of the above embodiments.
Another embodiment of the present invention provides a kind of computer readable storage medium, the computer readable storage medium packet Include the computer program of storage, wherein where controlling the computer readable storage medium in computer program operation Equipment executes SPI data transmission method as described in any one of the above embodiments.
Detailed description of the invention
Fig. 1 is a kind of flow diagram for SPI data transmission method that one embodiment of the invention provides;
Fig. 2 be another embodiment of the present invention provides a kind of SPI data transmission method flow diagram;
Fig. 3 is an a kind of flow diagram of SPI data transmission method provided in an embodiment of the present invention;
Fig. 4 is a kind of another flow diagram of SPI data transmission method provided in an embodiment of the present invention;
Fig. 5 is a kind of another flow diagram of SPI data transmission method provided in an embodiment of the present invention;
Fig. 6 is a kind of flow diagram for SPI data transmission device that one embodiment of the invention provides;
Fig. 7 be another embodiment of the present invention provides a kind of SPI data transmission device flow diagram;
Specific embodiment
Following will be combined with the drawings in the embodiments of the present invention, and technical solution in the embodiment of the present invention carries out clear, complete Site preparation description, it is clear that described embodiments are only a part of the embodiments of the present invention, instead of all the embodiments.It is based on Embodiment in the present invention, it is obtained by those of ordinary skill in the art without making creative efforts every other Embodiment shall fall within the protection scope of the present invention.
Referring to Fig. 1,3 and 4, which comprises
S001: data distribution to be sent is sent into buffer area to N number of data, wherein N is the integer greater than 1;
Each data: being sent the data to be sent of buffer area, is sent to corresponding data receiver buffer area by S002, So that receiving end garbled data from least one data receiver buffer area, to obtain a consistent with the data to be sent Partial data;Wherein, the data send buffer area and the data receiver buffer area is cyclic buffer, wherein recycling Buffering carries out the transmission, reception, verification etc. of data in the way of data first in first out.
In the present embodiment, before step S001, check code is generated to each frame data of data to be sent, so as to connect Receiving end according to the identifying code carry out verification received data it is whether correct;And frame number, wherein institute are added to each frame data State frame number is indicated with M, and M is the integer greater than 0.
In the present embodiment, the step S002 further include: in the number to be sent that each data are sent to buffer area According to being sent to after corresponding data receiver buffer area, so that receiving end is received to each data receiver buffer area institute The check code of each frame data is verified according to frame number ascending order, and the data frame of verification failure is abandoned.
In the present embodiment, the step S002 further include: so that receiving end takes from first data receiver buffer area The data frame cached out, it is then scarce in the N-1 data receiver buffer area according to being taken out from n-th data receiver buffer area The mode garbled data of the data frame of mistake can screen when there is packet drop to realize in next data receiver buffer area Institute's packet loss data, thus the data transmission realizing the integrality of data transmission, and without carrying out acknowledgement mechanism, and then improving Efficiency.
In the present embodiment, the step S002 further include: so that receiving end, which receives buffer area in last data, takes out number According to and when jumping latter data and receiving buffer area, by all data dumps of previous data receiver buffer area, to realize circulation Caching, to guarantee data transfer integrity;When so that receiving end sequentially from first data receiver buffer area to n-th data After receiving buffer area garbled data, when cannot still obtain a partial data consistent with the data to be sent, then repeat to hold Row above-mentioned steps, until a and consistent partial data of data to be sent is obtained, to ensure that the complete of data transmission Whole property, and double buffers are utilized, further improve the efficiency of data transmission.
In the present embodiment, the data send each frame data of buffer area and the data receiver buffer area according to The arrangement of frame number ascending order, to realize that data transmission procedure orderly carries out, thus improve the efficiency of transmission.
A kind of SPI data transmission method provided in an embodiment of the present invention has the following beneficial effects: by by number to be sent Buffer area is sent according to N number of data are distributed to, in a manner of realizing that N paths carry out the transmission of SPI data, and the data are sent Buffer function is played in buffer area, thus the efficiency of improve data transfer;Meanwhile by making receiving end from least one data receiver Garbled data in buffer area, to obtain a and consistent partial data of data to be sent, to ensure that data are transmitted Integrality further improve the effect of data transmission and by the way that N number of data receiver buffer area is arranged to realize buffer function Rate.
Referring to fig. 2,3 and 5, which comprises
S011: the N number of data for receiving transmitting terminal send the data to be sent that buffer area is sent, and are cached in and each data Send the corresponding data receiver buffer area in buffer area;
S012: the garbled data from least one data receiver buffer area, to obtain a and data to be sent Consistent partial data;Wherein, the data send buffer area and the data receiver buffer area is cyclic buffer.
In the present embodiment, buffer area and data receiver buffer area are sent by data and realizes double buffers, to realize Buffer function, to improve the efficiency of data transmission procedure;And pass through at least one sieve from N number of data receiver buffer area Data are selected, to obtain a and consistent partial data of the outgoing data, to guarantee the integrality of data transmission, and then can Under the premise of guaranteeing data transfer integrity, the efficiency of improve data transfer.
In the present embodiment, to each data receiver buffer area the check codes of received each frame data verify, And abandon the data frame of verification failure, to ensure that received data is consistent with the data to be sent.
In the present embodiment, the step S012 further include: take out from first data receiver buffer area and to have cached Then data frame takes out the data frame lacked in the N-1 data receiver buffer area according to from n-th data receiver buffer area Mode garbled data;When there is packet drop to realize, institute's packet loss data can be screened in next data receiver buffer area, To realize the integrality of data transmission, and without carrying out acknowledgement mechanism, and then the efficiency of the data transmission improved.
In the present embodiment, the step S012 further include: after last data receives buffer area taking-up data and jumps When one data receiver buffer area, by all data dumps of previous data receiver buffer area;It is connect when sequentially from first data After receiving buffer area to n-th data receiver buffer area garbled data, cannot still it obtain a consistent with the data to be sent When partial data, then above-mentioned steps are repeated, until a and consistent partial data of data to be sent is obtained, thus It ensure that the integrality of data transmission, and utilize double buffers, further improve the efficiency of data transmission.
A kind of SPI data transmission method provided in an embodiment of the present invention has the following beneficial effects: by receiving transmitting terminal N number of data send buffer area send outgoing data, by realize by mulitpath carry out the transmission of SPI data in a manner of, when When packet loss occurs in main road path in mulitpath, general's choosing to packet loss data can be carried out from backup path, thus guaranteeing number Under the premise of transmission completely, the efficiency of improve data transfer;And the data send buffer area and play buffer function, into one The efficiency of step ground improve data transfer.
Referring to Fig. 6, a kind of flow diagram for SPI data transmission device that one embodiment of the invention provides, comprising:
Pretreatment unit 61 generates check code for each frame data to data to be sent, and adds to each frame data Add frame number, wherein the frame number is indicated with M, M is the integer greater than 0.
File distributing unit 62, for data distribution to be sent to be sent buffer area to N number of data, wherein N is greater than 1 Integer.
Data transmission unit 63 is sent to corresponding for each data to be sent to the data to be sent of buffer area Data receiver buffer area, so that receiving end garbled data from least one data receiver buffer area, to obtain a and institute State the consistent partial data of data to be sent;Wherein, the data send buffer area and the data receiver buffer area is to follow Ring buffer area.
Wherein, the data transmission unit 63 is also used to keep receiving end received every to each data receiver buffer area institute The check code of one frame data is verified, and the data frame of verification failure is abandoned.
A kind of SPI data transmission device provided in an embodiment of the present invention has the following beneficial effects: through the processing unit 61 Check code is generated to each frame of outgoing data and adds frame number, so that receiving end is according to frame number sequence to received number According to sequentially being verified, received data is consistent with outgoing data to verify, to guarantee the accuracy of data and complete Whole property;Say that data distribution sends buffer area to N number of data by file distributing unit simultaneously, to realize that the data of multipath pass It is defeated, and by data transmission unit from the data receiver buffer area garbled data at least one path, when there is packet loss Packet loss data can be screened from the data receiver buffer area in other path, retransmit packet loss data without feeding back to sender, To improve the efficiency of data transmission, and the data transmission unit verifies received data, until obtaining A and consistent partial data of data to be sent, and then ensure that the integrality of data transmission.
Referring to Fig. 7, another embodiment of the present invention provides a kind of SPI data transmission device, comprising:
Data receipt unit 71, N number of data for receiving transmitting terminal send the data to be sent that buffer area is sent, and delay It is stored in data receiver buffer area corresponding with each data transmission buffer area;
Data screening unit 72, for the garbled data from least one data receiver buffer area, thus obtain it is a with The consistent partial data of data to be sent;Wherein, the data send buffer area and the data receiver buffer area is Cyclic buffer.
Data check unit 73, for each data receiver buffer area received each frame data check code carry out Verification, and the data frame of verification failure is abandoned.
A kind of SPI data transmission device provided in an embodiment of the present invention, has the following beneficial effects: through data receiver list N number of data that member receives transmitting terminal send the data that buffer area is sent, to realize the data transfer mode of multichannel, and by slow There are the data to send in buffer area and the data receiver buffer area, to realize buffer function, to improve data biography Defeated efficiency;Simultaneously by data screening unit carry out to the data receiver buffer area at least one channel in multichannel into Row data screening with obtain it is a send the consistent partial data of data with the band, can be from it when occurring under packet drop Packet loss data are screened in his data receiver buffer area, reduce acknowledgement mechanism, and then can guarantee data transfer integrity Under the premise of, the efficiency of improve data transfer.
The embodiment of the invention also provides a kind of terminal device, including processor, memory and it is stored in the storage In device and it is configured as the computer program executed by the processor, the processor is realized when executing the computer program SPI data transmission method as described in any one of the above embodiments.Such as step S001 shown in FIG. 1.Alternatively, the processor executes institute The function of each module/unit in above-mentioned each Installation practice, such as data transmission unit are realized when stating computer program.
Illustratively, the computer program can be divided into one or more module/units, one or more A module/unit is stored in the memory, and is executed by the processor, to complete the present invention.It is one or more A module/unit can be the series of computation machine program instruction section that can complete specific function, and the instruction segment is for describing institute State implementation procedure of the computer program in SPI data transmission terminal equipment.
The SPI data transmission terminal equipment can be desktop PC, notebook, palm PC and Intelligent flat etc. Calculate equipment.The SPI data transmission terminal equipment may include, but be not limited only to, processor, memory.Those skilled in the art Member is appreciated that above-mentioned component is only the example of SPI data transmission terminal equipment, does not constitute to SPI data transmission terminal The restriction of equipment may include perhaps combining certain components or different components, example than above-mentioned more or fewer components Such as described SPI data transmission terminal equipment can also include input-output equipment, network access equipment, bus.
The embodiment of the invention also provides a kind of servers, comprising:
One or more processors;
Storage device, for storing one or more programs;
When one or more of programs are executed by one or more of processors, so that one or more of processing Device realizes SPI data transmission method as described in any one of the above embodiments.
Alleged processor can be central processing unit (Central Processing Unit, CPU), can also be it His general processor, digital signal processor (Digital Signal Processor, DSP), specific integrated circuit (Application Specific Integrated Circuit, ASIC), ready-made programmable gate array (Field- Programmable Gate Array, FPGA) either other programmable logic device, discrete gate or transistor logic, Discrete hardware components etc..General processor can be microprocessor or the processor is also possible to any conventional processor Deng the processor is the control centre of the SPI data transmission terminal equipment, entire using various interfaces and connection The various pieces of SPI data transmission set.
The storage device can be used for storing the computer program and/or module, and the processor is by operation or holds Row stores computer program and/or module in the memory, and calls the data being stored in memory, realizes institute The various functions of predicate voice endpoint detection device.The storage device can mainly include storing program area and storage data area, In, storing program area can application program needed for storage program area, at least one function (such as sound-playing function, image Playing function etc.) etc.;Storage data area, which can be stored, uses created data (such as audio data, phone directory according to mobile phone Deng) etc..In addition, memory may include high-speed random access memory, it can also include nonvolatile memory, such as firmly Disk, memory, plug-in type hard disk, intelligent memory card (Smart Media Card, SMC), secure digital (Secure Digital, SD) block, flash card (Flash Card), at least one disk memory, flush memory device or other volatile solid-states Part.
Wherein, if the SPI data transmission terminal equipment it is integrated module/unit it is real in the form of SFU software functional unit Now and when sold or used as an independent product, it can store in a computer readable storage medium.Based in this way Understanding, the present invention realize above-described embodiment method in all or part of the process, can also be instructed by computer program Relevant hardware is completed, and the computer program can be stored in a computer readable storage medium, the computer program When being executed by processor, it can be achieved that the step of above-mentioned each embodiment of the method.Wherein, the computer program includes computer Program code, the computer program code can be source code form, object identification code form, executable file or certain centres Form etc..The computer-readable medium may include: can carry the computer program code any entity or device, Recording medium, USB flash disk, mobile hard disk, magnetic disk, CD, computer storage, read-only memory (ROM, Read-Only Memory), random access memory (RAM, Random Access Memory), electric carrier signal, telecommunication signal and software Distribution medium etc..It should be noted that the content that the computer-readable medium includes can be according to making laws in jurisdiction Requirement with patent practice carries out increase and decrease appropriate, such as in certain jurisdictions, according to legislation and patent practice, computer Readable medium does not include electric carrier signal and telecommunication signal.
It should be noted that the apparatus embodiments described above are merely exemplary, wherein described be used as separation unit The unit of explanation may or may not be physically separated, and component shown as a unit can be or can also be with It is not physical unit, it can it is in one place, or may be distributed over multiple network units.It can be according to actual It needs that some or all of the modules therein is selected to achieve the purpose of the solution of this embodiment.In addition, device provided by the invention In embodiment attached drawing, the connection relationship between module indicate between them have communication connection, specifically can be implemented as one or A plurality of communication bus or signal wire.Those of ordinary skill in the art are without creative efforts, it can understand And implement.
The above is a preferred embodiment of the present invention, it is noted that for those skilled in the art For, various improvements and modifications may be made without departing from the principle of the present invention, these improvements and modifications are also considered as Protection scope of the present invention.

Claims (13)

1. a kind of SPI data transmission method characterized by comprising
Data distribution to be sent is sent into buffer area to N number of data, wherein N is the integer greater than 1;
The data to be sent that each data are sent to buffer area, are sent to corresponding data receiver buffer area, so as to receive End garbled data from least one data receiver buffer area, to obtain a and consistent complete number of data to be sent According to;Wherein, the data send buffer area and the data receiver buffer area is cyclic buffer.
2. SPI data transmission method as described in claim 1, which is characterized in that it is described by data distribution to be sent to N number of Data are sent before buffer area, further includes:
Check code is generated to each frame data of data to be sent, and adds frame number to each frame data, wherein the frame sequence It number is indicated with M, M is the integer greater than 0;
It is described by each data send buffer area data to be sent, be sent to corresponding data receiver buffer area it Afterwards, further includes:
So that receiving end to each data receiver buffer area the check codes of received each frame data verify, and will verification The data frame of failure abandons.
3. SPI data transmission method as claimed in claim 2, which is characterized in that described so that receiving end is counted from least one According to garbled data in reception buffer area, comprising: so that the number cached is taken out from first data receiver buffer area in receiving end According to frame, the data frame lacked in the N-1 data receiver buffer area then is taken out according to from n-th data receiver buffer area Mode garbled data.
4. SPI data transmission method as claimed in claim 3, which is characterized in that it is described so that receiving end from least one Garbled data in data receiver buffer area, further includes: so that receiving end receives buffer area taking-up data in last data and jumps When latter data receives buffer area, by all data dumps of previous data receiver buffer area;When so that receiving end sequentially from After the garbled data of first data receiver buffer area to n-th data receiver buffer area, cannot still obtain it is a with it is described pending When sending the consistent partial data of data, then above-mentioned steps are repeated, until obtaining a consistent with the data to be sent Partial data.
5. SPI data transmission method as claimed in claim 4, which is characterized in that the data send buffer area and the number It is arranged according to frame number ascending order according to each frame data for receiving buffer area.
6. a kind of SPI data transmission method characterized by comprising
The N number of data for receiving transmitting terminal send the data to be sent that buffer area is sent, and are cached in send with each data and buffer The corresponding data receiver buffer area in area;
The garbled data from least one data receiver buffer area, to obtain a consistent complete with the data to be sent Data;Wherein, the data send buffer area and the data receiver buffer area is cyclic buffer.
7. SPI data transmission method as claimed in claim 6, which is characterized in that further include:
To each data receiver buffer area the check codes of received each frame data verify, and will verification failure data Frame abandons.
8. SPI data transmission method as claimed in claim 7, which is characterized in that described to be buffered from least one data receiver Garbled data in area, comprising: the data frame cached is taken out from first data receiver buffer area, then according to from n-th The mode garbled data of the data frame lacked in the N-1 data receiver buffer area is taken out in data receiver buffer area.
9. SPI data transmission method as claimed in claim 8, which is characterized in that described slow from least one data receiver Rush garbled data in area, further includes: when last data receives buffer area and takes out data and jump latter data reception buffer area, By all data dumps of previous data receiver buffer area;When sequentially from first data receiver buffer area to n-th data After receiving buffer area garbled data, when cannot still obtain a partial data consistent with the data to be sent, then repeat to hold Row above-mentioned steps, until obtaining a and consistent partial data of data to be sent.
10. a kind of SPI data transmission device characterized by comprising
File distributing unit, for data distribution to be sent to be sent buffer area to N number of data, wherein N is the integer greater than 1;
Data transmission unit is sent to corresponding data and connects for each data to be sent to the data to be sent of buffer area Receive buffer area so that receiving end garbled data from least one data receiver buffer area, thus obtain it is a with it is described pending Send data consistent partial data;Wherein, the data send buffer area and the data receiver buffer area is circular buffering Area.
11. SPI data transmission device as claimed in claim 10, which is characterized in that further include:
Pretreatment unit generates check code for each frame data to data to be sent, and adds frame sequence to each frame data Number, wherein the frame number is indicated with M, M is the integer greater than 0;
The data transmission unit, be also used to make receiving end to each data receiver buffer area received each frame data inspection It tests code to be verified, and the data frame of verification failure is abandoned.
12. a kind of SPI data transmission device characterized by comprising
Data receipt unit, for receive transmitting terminal N number of data send buffer area send data to be sent, and be cached in Each data send the corresponding data receiver buffer area in buffer area;
Data screening unit, for the garbled data from least one data receiver buffer area, thus obtain it is a with it is described to Send the consistent partial data of data;Wherein, the data send buffer area and the data receiver buffer area is that circulation is slow Rush area.
13. SPI data transmission device as claimed in claim 12, which is characterized in that further include:
Data check unit, for each data receiver buffer area the check codes of received each frame data verify, And the data frame of verification failure is abandoned.
CN201910698023.7A 2019-07-29 2019-07-29 SPI data transmission method and device Active CN110445578B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201910698023.7A CN110445578B (en) 2019-07-29 2019-07-29 SPI data transmission method and device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201910698023.7A CN110445578B (en) 2019-07-29 2019-07-29 SPI data transmission method and device

Publications (2)

Publication Number Publication Date
CN110445578A true CN110445578A (en) 2019-11-12
CN110445578B CN110445578B (en) 2020-06-23

Family

ID=68432464

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201910698023.7A Active CN110445578B (en) 2019-07-29 2019-07-29 SPI data transmission method and device

Country Status (1)

Country Link
CN (1) CN110445578B (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN114942900A (en) * 2021-09-29 2022-08-26 太初(无锡)电子科技有限公司 Double-buffer data serial sending method for embedded system

Citations (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1761237A (en) * 2005-11-04 2006-04-19 清华大学 System for transmitting data frame of Etheent based on insertion between frames
CN101072087A (en) * 2007-06-15 2007-11-14 南京恩瑞特实业有限公司 Method for realizing multi-link redundancy based on buffer management
US20090103364A1 (en) * 2007-10-17 2009-04-23 Micron Technology, Inc. Serial interface nand
CN101667451A (en) * 2009-09-11 2010-03-10 西安电子科技大学 Data buffer of high-speed data exchange interface and data buffer control method thereof
CN101719809A (en) * 2009-11-25 2010-06-02 中兴通讯股份有限公司 Method and system for recovering lost media data packet
CN102118434A (en) * 2010-12-28 2011-07-06 华为技术有限公司 Data packet transmission method and device
CN103312606A (en) * 2013-05-23 2013-09-18 杭州卓沃电子商务有限公司 Wireless Mesh network routing based on multi-path concurrence and method thereof
CN104462008A (en) * 2014-12-05 2015-03-25 三星半导体(中国)研究开发有限公司 Physical-memory-shared multi-processor communication system and communication method thereof

Patent Citations (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1761237A (en) * 2005-11-04 2006-04-19 清华大学 System for transmitting data frame of Etheent based on insertion between frames
CN101072087A (en) * 2007-06-15 2007-11-14 南京恩瑞特实业有限公司 Method for realizing multi-link redundancy based on buffer management
US20090103364A1 (en) * 2007-10-17 2009-04-23 Micron Technology, Inc. Serial interface nand
CN101667451A (en) * 2009-09-11 2010-03-10 西安电子科技大学 Data buffer of high-speed data exchange interface and data buffer control method thereof
CN101719809A (en) * 2009-11-25 2010-06-02 中兴通讯股份有限公司 Method and system for recovering lost media data packet
CN102118434A (en) * 2010-12-28 2011-07-06 华为技术有限公司 Data packet transmission method and device
CN103312606A (en) * 2013-05-23 2013-09-18 杭州卓沃电子商务有限公司 Wireless Mesh network routing based on multi-path concurrence and method thereof
CN104462008A (en) * 2014-12-05 2015-03-25 三星半导体(中国)研究开发有限公司 Physical-memory-shared multi-processor communication system and communication method thereof

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN114942900A (en) * 2021-09-29 2022-08-26 太初(无锡)电子科技有限公司 Double-buffer data serial sending method for embedded system

Also Published As

Publication number Publication date
CN110445578B (en) 2020-06-23

Similar Documents

Publication Publication Date Title
CN106254202B (en) A kind of multidiameter delay transmission method and device based on fountain codes
US7995624B2 (en) Systems and methods for multiplexing digital data
KR101223950B1 (en) Remote transmission system
CN110312147B (en) Method, system and storage medium for service data transmission
US10476528B2 (en) Data packet processing method and device
CN110061816B (en) Mobile communication system, network equipment, terminal equipment and data scheduling method
CN106603209B (en) Data transmission method and device for time domain and frequency domain resource joint binding
CN107104782B (en) Data transmission method and device
CN106416179A (en) Transport accelerator implementing extended transmission control functionality
CN103023813A (en) Jitter buffer
CN110831010B (en) Multichannel data sending and receiving method and device and data transmission system
EP3342075A1 (en) Random linear network encoded data transmission from user equipment
CN111082896A (en) Data transmission method and transmitting and receiving device
CN1270466C (en) Radio system and stations for, and method of, multicast communication
CN1452830A (en) Data transmission protocol
CN110445578A (en) A kind of SPI data transmission method and device
CN107222848B (en) WiFi frame encoding method, transmitting end, storage medium and wireless access equipment
CN101001132A (en) Data radio transmission system
CN113573003B (en) Audio and video real-time communication method, device and equipment based on weak network
CN104683262A (en) Processing method and equipment for data packet
CN106230554A (en) Wireless communications method and system
CN113473532A (en) Method and system for optimally transmitting radio link control state report
KR100927980B1 (en) Method and apparatus for processing packet deletion in wireless communication system
CN110958084B (en) Method and communication equipment for transmitting acknowledgement message
WO2021012662A1 (en) Multipoint transmitting method and device for hybrid automatic repeat request

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
PE01 Entry into force of the registration of the contract for pledge of patent right
PE01 Entry into force of the registration of the contract for pledge of patent right

Denomination of invention: A method and device of SPI data transmission

Effective date of registration: 20201010

Granted publication date: 20200623

Pledgee: Bank of China Limited Guangzhou Pearl River Branch

Pledgor: UNICMICRO (GUANGZHOU) Co.,Ltd.

Registration number: Y2020440000309

PC01 Cancellation of the registration of the contract for pledge of patent right
PC01 Cancellation of the registration of the contract for pledge of patent right

Date of cancellation: 20211221

Granted publication date: 20200623

Pledgee: Bank of China Limited Guangzhou Pearl River Branch

Pledgor: UNICMICRO (GUANGZHOU) Co.,Ltd.

Registration number: Y2020440000309