Summary of the invention
There is delay inequality to solve existing magnetic resonance imaging multi-channel data transmission, each channel data synchronously can not arrive the problem of receiver, the invention provides a kind of multi-channel data transmission method and system.
A kind of multi-channel data transmission method, comprises the steps:
At transmitting terminal, by data head embedding data, and by the transfer of data with data head to receiving terminal, described data head comprises frame number, symbol, channel number;
At described receiving terminal, the described data with data head are resolved, parses the frame number of data and correspondence, symbol, channel number;
Described receiving terminal comprises several forms, according to the frame number parsed, symbol, channel number, the data of correspondence is inserted the relevant position of corresponding forms.
Preferably, described forms are the data structure body of memory space definition, comprise the memory space storing N number of passage * M symbol data.
Preferably, the frame number one_to_one corresponding of described forms number and described data head, the Width of described forms addition of the channel number attribute of data head, and the depth direction of described forms addition of the symbol attribute of data head.
Preferably, if the passage of forms Width fills up data, the data of having filled up described in reading.
Preferably, the frame number parsed, symbol, channel number are sent into controller, according to the frame number parsed, symbol, channel number, data corresponding for described data head is inserted the relevant position of corresponding forms by described controller.
Preferably, the data header information of described data obtains in the following way: transmitting terminal includes the multichannel data being no more than port number N, every circuit-switched data counts through M system Counter, symbolic number is M, described M system Counter often counts M number, once, described device for carrying-bit records described frame number to described device for carrying-bit record from 0, increases successively afterwards.
Preferably, the transmission cycle T of described data, degree of depth M, the forms number L of forms and interchannel maximum delay difference need meet the following conditions: T*M* (L-1) > Δ T.。
Present invention also offers a kind of multi-channel Transmission System, comprising: transmitting terminal, receiving terminal;
Described transmitting terminal comprises: group bag module, at transmitting terminal by data head embedding data, described data head comprises frame number, symbol, channel number; Described receiving terminal comprises: data resolution module, for resolving the data with data head, parses the frame number of data and correspondence, channel number, symbol; Forms, for storing described frame number, channel number, data that symbol is corresponding.
Preferably, described forms are the data structure body of memory space definition, comprise the memory space storing N number of passage * M symbol data.
Preferably, the frame number one_to_one corresponding of described forms number and described data head, the Width of described forms addition of the channel number attribute of data head, and the depth direction of described forms addition of the symbol attribute of data head.
Preferably, described system also comprises controller, for the data of described correspondence being inserted according to the frame number parsed, symbol, channel number the relevant position of corresponding forms.
Preferably, described transmitting terminal also comprises transmitter module, for the described data with data head are sent to receiving terminal; Described receiving terminal also comprises receiver module, for the data with data head described in receiving end/sending end transmission.
Preferably, described multi-channel Transmission System also comprises: read module, the data that the passage for reading forms Width has filled up.
Preferably, described transmitting terminal also comprises M system Counter and device for carrying-bit, transmitting terminal includes the multichannel data being no more than port number N, every circuit-switched data counts through M system Counter, symbolic number is M, and described M system Counter often counts M number, described device for carrying-bit record frame number, described device for carrying-bit records described frame number from 0, increases successively afterwards.
Compared with prior art, the multi-channel data transmission method that the technical program provides and system, at transmitting terminal, by data head embedding data, and by the transfer of data with data head to receiving terminal, described data head comprises frame number, symbol, channel number, described receiving terminal is provided with several forms, at receiving terminal, the data with data head received are resolved, parse the frame number of data and correspondence, symbol, channel number, according to the frame number parsed, symbol, channel number, data corresponding for described data head are inserted the relevant position of corresponding forms.The technical program reduces the requirement of synchronous transmission to sequential, the transfer of data of different passage does not need to consider the delay inequality between passage, does not need identical transmission medium, does not need many passage close alignment, can be even nonsynchronous multiple transmitter, improve the efficiency of transmission of data.
Embodiment
Set forth a lot of detail in the following description so that fully understand the present invention.But the present invention can be much different from alternate manner described here to implement, those skilled in the art can when without prejudice to doing similar popularization when intension of the present invention, therefore the present invention is by the restriction of following public concrete enforcement.Secondly, the present invention utilizes schematic diagram to be described in detail, and when describing the embodiment of the present invention in detail, for ease of illustrating, described schematic diagram is example, and it should not limit the scope of protection of the invention at this.
As stated in the Background Art, the appearance based on the parallel MR imaging of multichannel collecting technology creates fundamental change to magnetic resonance imaging, the feasibility also making researcher see image taking speed again to improve further.This technology increases substantially supper-fast level, has widened clinical practice further.In multichannel collecting technology application process, also there is many problem demanding prompt solutions, as the difference due to transmission path or transmission medium between different passage, there is certain delay inequality, make each channel data synchronously can not arrive receiver.In magnetic resonance embody rule scene, comprise two synchrodata makers at transmitting terminal, comprise 4 passages, when having 4 parameters respectively from 4 channel transfer to receiving terminal, and these four parameters need when receiving terminal is synchronously resolved, and just occur problem as above.Prior art has measured the path delay of time usually in advance, inserting fixed delay, ensure that the time of data when accepting is identical at receiving terminal.Then this technical scheme also exist to transmission path and latency measurement required precision very high, and the problem on environmental condition sensitivity (as temperature, humidity etc. can affect transmission path delay); Another problem is that transmission time delay difference is not fixing each time, and in practical application, also need the scheme taking to insert dynamic delay, this requirement for system is higher.Therefore the solution proposing new Solving Multichannel transmission time delay difference problem is needed.
As shown in Figure 1, a kind of multi-channel data transmission method, comprising:
Step S10, at transmitting terminal, by data head embedding data, and by the transfer of data with data head to receiving terminal, described data head comprises frame number, symbol, channel number.
As shown in Figure 2, described data (data after embedding data head) comprise data head and data volume, and described data head comprises frame number, symbol, channel number.
The information of the data head of described data obtains in the following way: transmitting terminal includes the multichannel data being no more than port number N, every circuit-switched data counts through M system Counter, symbolic number is M, described M system Counter often counts M number, described device for carrying-bit record once, device for carrying-bit records described frame number from 0, once increases afterwards.
For 4 passages, the counter adopting 8 systems, data are divided into 4 tunnels, every circuit-switched data counts through 8 system Counters, then symbol number is 8, symbol is respectively 0,1,2,3,4,5,6,7, simultaneously frame number described in device for carrying-bit record, when described 8 system Counters complete first time 8 countings, described device for carrying-bit record frame number is 0, increases successively afterwards.
Above-mentioned multichannel data, for needing synchronous multichannel data of resolving at receiving terminal, the such as different parameters of same algorithm, these parameters are obtained by multiplexer channel collection; Or split by a circuit-switched data, the bit wide of a circuit-switched data is too large, having exceeded the maximum bit wide of passage, has needed to split this circuit-switched data, therefore when arriving receiving terminal, having been needed to be resolved by the data split simultaneously.
Step S20, at described receiving terminal, resolves the described data with data head, parses the frame number of data and correspondence, symbol, channel number.
Described forms are the data structure body of memory space definition, comprise the memory space storing N number of passage * M symbol, described forms have forms number, symbol and channel number attribute, the frame number one_to_one corresponding of described forms number and described data head, the Width of described forms addition of the channel number attribute of data head, and the depth direction of described forms addition of the symbol attribute of data head.
As shown in Figure 3, the width of described forms is 4 port numbers, and the degree of depth of described forms is 8 symbolic numbers, and in one embodiment, described forms number is 2, then correspondingly forms number are respectively 0,1.
The data of correspondence are inserted the relevant position of corresponding forms by step S30 according to the frame number parsed, symbol, channel number.
Step S40, if the channel data in described forms direction fills up, reads and fills up data.
In one embodiment, the data head of each data received is resolved, the frame number parsed, symbol, channel number are sent into controller, according to the frame number parsed, symbol, channel number, data corresponding for described data head are inserted the relevant position of corresponding forms by described controller, and the data that forms Width has filled up are read in control.
As shown in Figure 3, be 0 by controller by frame number, symbol be 0, position that the data of channel number corresponding to the data head of 0 insert forms number 0, forms depth direction symbol 0, forms Width channel number 0, after the data of 4 passages of the correspondence of symbol 0 in forms 0 are all filled up, controller control RAM reads data.
In one embodiment, forms quantity is 2, when the passage 0 of forms 1 fills up, then continue to insert data from the passage 0 of forms 0, if when the delay inequality between 1 or the passage 2 of passage 0 and passage or passage 3 is greater than 8 clock cycle, then the data of 4 passages that forms 0 symbol is now corresponding are not also filled up, therefore RAM is not also by digital independent, if the data of inserting, then will cause data corruption, therefore whether forms quantity arranges reasonable is also very important in the technical program.In practice, the transmission cycle T(data cycle of forms number L, data is the equal of inverse and the 1/V of transmission rate), the degree of depth M of forms and interchannel maximum delay difference Δ T need meet: T × M × (L-1) > Δ T; Namely if data transfer cycle (transmission rate) is fixing, then can according to the quantity of maximum delay difference adjustment forms, as forms quantity is fixed, then can adjust data transfer cycle (transmission rate), in order to taking into account of efficiency and cost, suitable forms quantity and data transfer cycle can be set.
As shown in Figure 4, present invention also offers a kind of multi-channel Transmission System, described multi-channel Transmission System comprises: transmitting terminal 10, receiving terminal 20.
Described transmitting terminal 10 comprises: group bag module 101, described group of bag module 101 at transmitting terminal 10 by data head embedding data, described data head comprises frame number, symbol, channel number.
Described receiving terminal 20 comprises: data resolution module 201, for resolving the described data with data head, parses the frame number of data and correspondence, channel number, symbol.
Described receiving terminal 20 also comprises: forms 202, for the frame number, channel number, the data that symbol is corresponding that parse described in storing.In one embodiment, described forms comprise the memory space storing N number of passage * M symbol data, described forms have forms number, symbol and channel number attribute, the frame number one_to_one corresponding of described forms number and described data head, the Width of described forms addition of the channel number attribute of data head, and the depth direction of described forms addition of the symbol attribute of data head.
In one embodiment, described multi-channel Transmission System also comprises controller 304, for data corresponding for described data head being inserted respectively according to the frame number parsed, symbol, channel number the relevant position of corresponding forms.
In one embodiment, described multi-channel Transmission System also comprises read module 40, the data that described read module 40 has filled up for the passage reading forms Width.
As shown in Figure 5, described transmitting terminal 10 also comprises transmitter module 102, for the data with data head are sent to receiving terminal 20; Described receiving terminal 20 also comprises receiver module 203, for receiving the data with data head described in transmitting terminal 10 transmission.
As shown in Figure 6, described transmitting terminal 10 also comprises M system Counter 103 and device for carrying-bit 104.As shown in the figure, transmitting terminal includes the multichannel data being no more than port number N, and every circuit-switched data counts through described M system Counter 103, described M system Counter 103 often counts M number, and described device for carrying-bit 104 records once, and described device for carrying-bit 104 records described frame number from 0, increase successively afterwards.
In practical application, transmission channel can be optical fiber, SATA, netting twine etc., only needs in conjunction with corresponding interface protocol.As shown in Figure 7, be external SERDES(HSSI High-Speed Serial Interface) afterwards by the schematic diagram of Optical Fiber Transmission data, wherein transmitter has two modules and asynchronous, and fiber lengths is different.
The realization of the technical program can realize based on FPGA, also can use ARM, DSP, FPGA and ARM/DSP can also be used mutual, as long as meet message transmission rate.Multiple passage can build with multiple transmitter, and transmitter signal does not need homology, only needs to distinguish channel number, and port number can add according to actual transmission port number.
The multi-channel data transmission method that the technical program provides and system, at transmitting terminal, by data head embedding data, and by the transfer of data with data head to receiving terminal, described data head comprises frame number, symbol, channel number, described receiving terminal is provided with several forms, at receiving terminal, the data with data head received are resolved, parse the frame number of data and correspondence, symbol, channel number, according to the frame number parsed, symbol, channel number, data corresponding for described data head are inserted the relevant position of corresponding forms.The technical program reduces the requirement of synchronous transmission to sequential, the transfer of data of different passage does not need to consider the time delay between passage, does not need identical transmission medium, does not need many passage close alignment, can be even nonsynchronous multiple transmitter, improve the efficiency of transmission of data.
Although the present invention discloses as above, the present invention is not defined in this.Any those skilled in the art, without departing from the spirit and scope of the present invention, all can make various changes or modifications, and therefore protection scope of the present invention should be as the criterion with claim limited range.