Summary of the invention
At there being the shortcoming that user data traffic of application is not optimized distribution in the existing flow control methods, the purpose of this invention is to provide the self-adapting flow control method that a kind of forward direction inserts transmission channel (FACH), this method can be applicable among the MAC-c/sh of WCDMA communication system, this method according to the data traffic of MAC-d application in real time with and the priority of corresponding logic channel, data source (MAC-d) the self adaptation distribute data flow to being applied in a dispatching cycle.
In order to achieve the above object, the present invention has used following technical scheme,
The implementation method of self-adapting flow control method of the present invention is as follows:
A. determine MAC-c/sh a Secondary Common Control Physical Channel congestion threshold and can distribute thresholding c11, and as the input parameter of step c;
B. monitor buffer area (comprise the logic channel buffer area and receive buffer area) the capacity c12 of the Secondary Common Control Physical Channel of MAC-c/sh, average cache district occupation rate (BUFFER OCCUPANCY:BO) in the statistic logic channel buffer in N times of scheduling time and the situation of change of BO, the buffering area of roughly predicting (measurement period) in the future a certain short time according to the situation of change of BO takies situation, obtains the BO of logic channel buffering area after current and a period of time
Logic_aver, new, constantly add up in planning then and receive data volume in the buffering area, obtain the situation that takies of this of buffer area dispatching cycle; And the input of this result as step c;
C. calculate the total capacity c13 that can distribute to MAC-d: whether the monitoring result of judging earlier described step b is above the congestion threshold among the described step a, if surpass congestion threshold, dispense flow rate no longer then, otherwise the monitoring result of step b and can to distribute the difference between the thresholding be exactly to distribute to the Buffer capacity of the MAC-d of all applications-Allowed Assign Buffer size; This result outputs to steps d and step e respectively;
D. the total capacity that can distribute to MAC-d according to current MAC-c/sh is determined the pairing weight of priority: use weights to embody priority, the weights (PriorityWeight of the correspondence that priority level is high
i) big.And a variable R is set in order to write down the request number of times that is not assigned with data volume, be these request number of times configuration weights R then
Weight(be 〉=1 value), the number of times that is not assigned with is many more, and its corresponding weights are big more, the work that MAC-c/sh need do: MAC-c is the weight R+1 of the request number of times R of zero request record with the data volume that is assigned in each dispatching cycle, to the data volume of having distributed, this value is set to 1 again.The determined weights of steps d output to step e;
E. in planning constantly, according to data volume and the priority that each MAC-d applied for, utilize the output result of step c and steps d: assignable total capacity and weights calculate the data volume that can distribute to each MAC-d, and formula is:
Wherein:
AllocationSizeMacd
i: distribute to each MAC-d data volume, unit is byte
PriorityWeight
j: the weights size of each priority correspondence of j=0....15
UserBufferSizeMacd
i: the USER BUFFER SIZE of each MAC-d application of i=1...N (N is the MAC-d number of application);
Allowed_Allocation_Size: be the total data flow that allows to distribute to all MAC-d
N: the MAC-d number that is all application partition capacities in scheduling time
Rweight: the pairing weights of number of times that are not assigned with data traffic
Be down to round, remove fractional part
After calculating finishes then MAC-c/sh to the MAC-d echo reply control frame of being applied for.
Because the present invention has adopted above technical scheme, the size of buffer area of the priority of the MAC-d logic channel of application, the data traffic of application, current MAC-c/sh and the influence that is not assigned with four kinds of factors of request number of times of flow have been taken all factors into consideration, just can effectively monitor the data flow, guarantee the integrality of transmission data, improve the communication quality of system.
Embodiment
Further describe implementation step of the present invention below in conjunction with accompanying drawing:
FACH self-adapting flow control method of the present invention is based on that 3GPP (2001.3) MAC-c/sh that agreement provided and the Signalling exchange between the MAC-d and MAC-c/sh realize the flow monitoring of buffer area.Basic conception is as follows,
The common logical buffer area: this buffer area is deposited data SDU (the ServiceData Unit: service data unit) of common logical;
Receive buffer area: this buffer area is deposited the data that send over from MAC-d;
The common logical buffer area and receive the position of buffer area can be with reference to the accompanying drawings 1, the common logical buffer area with to receive buffer area be because the data volume in next dispatching cycle (data are in Uu mouth protocol layer (except the physical layer) processing time) common logical is uncontrollable in the come reason considered of statistic flow time-division, and be unknown, need do a prediction to it according to current dispatching cycle and former dispatching cycle; And the data volume that receives buffering area is controlled, and at current this dispatching cycle, need not predict, what have just what add.Common logical buffer area and reception buffer area are actually a big buffer area, just logically it has been separated now for Data Source and the statistical method of distinguishing both, the buffer size of both data occupancies is dynamic equalizations, that is to say that if the data volume of common logical is fewer the data volume that receives the receivable MAC-d of buffer area so is just many.
Fig. 2 is the schematic diagram that forward direction of the present invention inserts the transmission channel self-adapting flow control method, as shown in Figure 2:
A. determine MAC-c/sh a Secondary Common Control Physical Channel congestion threshold and can distribute thresholding c11, described congestion threshold (BO
Congestion_thresholdBut) be meant the threshold value of MAC-c/sh buffer area store data capacity; Described thresholding (the BO that distributes
Alloction_threshold) be meant that MAC-c/sh current cache district capacity can not distribute to the threshold value that MAC-d uses; These two thresholdings are made as the input parameter of step c.
B. monitor buffer area (comprise logic channel buffer area and receive buffer area) the capacity c12 of the Secondary Common Control Physical Channel of MAC-c/sh: the size that the statistic logic channel buffer takies data volume is to carry out before the data of logic channel in a dispatching cycle send to FP, the data that receive in the buffering area that add up are carried out after data are issued FP, indicate and receive the data volume that does not send out in the buffering area in this dispatching cycle; Consider that the data volume that in next dispatching cycle RLC is put into MAC-c/sh logic channel buffering area is unknown, therefore need in the statistic logic channel buffer average cache district occupation rate (BUFFER OCCUPANCY:BO) in N times of scheduling time and the situation of change of BO, so just can predict that roughly the buffering area of (measurement period) in a certain short time in the future takies situation according to the situation of change of BO, thereby obtain the BOlogic_aver of logic channel buffering area after current and a period of time, new (=BOaver+BO is in the situation of change of measurement period in the time); Constantly the data volume that receives in the buffering area is added up in planning then, obtain the situation that takies of this of buffer area dispatching cycle; And the input of this result as step c;
C. calculate the total capacity c13 that can distribute to MAC-d: the monitoring result according to step b compares with distributing thresholding, and the difference between these two values is exactly to distribute to the Buffer capacity one Allowed Assign Buffer size of the MAC-d of all applications; This result outputs to steps d and step e respectively;
D. the total capacity that can distribute to MAC-d according to current MAC-c/sh is determined the pairing weight of priority: owing to should consider the priority of logic channel in minute timing, the size of the data traffic of considering MAC-d again and being applied for, therefore consider here to embody priority with weights, and the weights of the correspondence that priority level is high (PriorityWeighti) are big.Also to consider the request (in this case might such data always exist in the dedicated logical channel buffer area) of and those data that data volume especially little lower simultaneously in addition for some priority ratio, therefore a variable R being set in order to write down the request number of times (if interior same request dispatching cycle occurs repeatedly all being considered to once ask) that is not assigned with data volume here, is these request number of times configuration weights R then
Weight(be 〉=1 value), the number of times that is not assigned with is many more, and its corresponding weights are big more, and the initial value of She Zhiing all is 1 at the beginning, and as long as certain application has distributed flow, then this value is put 1.Consideration for the request number of times that is not assigned with data volume, the work that MAC-c/sh need do: MAC-C is the weight R+1 of the request number of times R of zero request record with the data volume that is assigned in each dispatching cycle, to the data volume of having distributed, this value is set to 1 again.
The corresponding weights R of request number of times
WeightDetermine: R
WeightBe relevant with the number of times that is not assigned with, number of times is many more, R
WeightBig more, the value example:
R | 0 | 1 | 2 | … | 4 |
R
weight | 1 | 5 | 10 | … | 40 |
Definite can making for this value is the function of R, as R
Weight=A*B
[C (R-1)+D]+E(except R=0, R
Weight=1), A, B, C, D, E are constants, can adjust, in order to adjust the degree of crook of curve.
Can divide following five kinds of situations for the definite of the corresponding weights of priority:
1) (MacdBufferSize is the data traffic sum that will send of all MAC-d applications to Allowed_Allocation_Size≤1/4*MacdBufferSize, and Allowed_Allocation_Size is total buffer memory capacity that MAC-c/sh allows to distribute to MAC-d
In this situation, because assignable Capacity Ratio is less, this moment is just main to be considered the high data of priority to be sent priority as far as possible, therefore this moment low priority and high priority weights just differ greatly; Determine that through emulation (results of more several groups of parameters) weights of this kind situation are:
Priority={0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15};
PriorityWeigth={0.10,0.20,0.30,0.40,0.50,0.60,0.70,0.80,0.9,1.00,1.10,1.20,1.30,1.40,1.50,1.60};
Two arrays are directly corresponding, represent lowest priority for 0 grade, and 15 represent limit priority.
2)1/4*MacdBufferSize<Allowed_Allocation_Size<1/2*MacdBufferSize
In this situation, if the weights setting of low priority and high priority differed bigger, the capacity that just may cause high priority channel to be distributed a lot (BUFFER that has surpassed application is a lot), and low priority channel is distributed seldom, causes the waste of capacity; Therefore occur for fear of this situation, establish one group of weights here in addition, it is a little bit smaller to make that the weights of low priority and high priority differ; The weights of determining are:
Priority={0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15};
PriorityWeight={0.25,0.30,0.35,0.40,0.45,0.50,0.55,0.60,0.65,0.70,0.75,0.80,0.85,0.90,0.95,1.0};
3)1/2*MacdBufferSize≤Allowed_Allocation_Size<3/4*MacdBufferSize
Because this situation assignable Capacity Ratio with respect to second kind of situation is bigger, if the low priority and the weights of high priority are provided with mutually residual quantity as second kind, the capacity that just may cause high priority to distribute a lot (BUFFER that has surpassed application is a lot), and the distribution of low priority seldom, causes the waste of capacity; Therefore occur for fear of this situation, establish one group of weights here in addition, it is more a little bit smaller to make that the weights of low priority and high priority differ;
Priority={0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15};
PriorityWeigth={0.50,0.53,0.56,0.59,0.62,0.65,0.68,0.71,0.74,0.77,0.80,0.83,0.86,0.89,0.92,0.95};
4)3/4*MacdBufferSize≤Allowed_Allocation_Size<MacdBufferSize
In this situation, the Capacity Ratio that can distribute to MAC-d is more, so at this time just can the weights difference between high priority and the low priority be provided with a little bit smaller, make data traffic that each MAC-d applied for as the main foundation of distributing, but still will consider the difference of priority this moment, just the weight of considering will be hanged down a bit:
Priority={0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15};
PriorityWeigth={0.60,0.62,0.64,0.66,0.68,0.70,0.72,0.74,0.76,0.78,0.80,0.82,0.84,0.86,0.88,0.90};
5)MacdBufferSize≤Allowed_Allocation_Size
In this situation, because the capacity that the Capacity Ratio application that allow to distribute distributes is big, so at this time just need not consider priority, only need distribute just passable according to the user's of each application capacity; The weights that establish this moment all are 1;
Priority={0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15};
PriorityWeigth={1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1};
Here weights are that the information that BUFFER according to MAC-c takies situation and MAC-d application is divided, and when the buffer area duty ratio of MAC-c/sh is higher, then distributes to the size of the capacity of MAC-d and consider that the factor of priority height is just more.The determined weights of steps d output to step e;
E. constantly, according to data volume and the priority that each MAC-d applied for, utilize the output result in the 3rd step and the 4th step then: assignable total capacity and weights calculate the data volume that can distribute to each MAC-d in planning:
The formula that calculates the data volume that each MAC-d should distribute is:
AllocationSizeMacd
i: distribute to each MAC-d data volume, unit is byte
PriorityWeight
j: the weights size of each priority correspondence of j=0....15
UserBufferSizeMacd
i: the USER BUFFER SIZE of each MAC-d application of i=1...N (N is the MAC-d number of application);
Allowed_Allocation_Size: be the total data flow N that allows to distribute to all MAC-d: the MAC-d number Rweight that is all application partition capacities in scheduling time: the pairing weights of number of times that are not assigned with data traffic
Be down to round (removing fractional part)
After calculating finishes then MAC-c/sh to the MAC-d echo reply control frame of being applied for.
The method has been taken all factors into consideration the size of buffer area of the priority of the MAC-d logic channel of application, the data traffic of application, current MAC-c/sh and the influence that is not assigned with four kinds of factors of request number of times of flow, can effectively monitor the data flow, guarantee the integrality of transmission data, improve the communication quality of system.
Fig. 3 is the planning time chart that distributes the buffer memory capacity of application MAC-d, because the application of MAC-d is at random, for the MAC-d that is applied for being carried out flow control in following period of time, designed a kind of planning sequential chart, as shown in Figure 3, that is to say and be not that MAC-d is when MAC-c/sh one sends request, MAC-c/sh just gives the MAC-d partition capacity immediately, but all MAC-d requests that will receive in a time period (dispatching cycle-when first MAC-d send the shared time of scheduling time-capacity allocation that when request crossed) begins section between at this moment afterwards do data volume and distribute, then to MAC-d echo reply control frame; If when carrying out the capacity allocation processing procedure, receive the request that MAC-d sends again, then the capacity allocation process of this request is put into next scheduling time this moment and carries out.That is to say that each capacity allocation all is to handle at the MAC-d that is applied in the scheduling time, just the scheduling time started and the termination of zero-time and termination time and reality have a difference.
According in 3GPP TS 25.425 agreements about the content of the Signalling exchange of application between MAC-d and the MAC-c/sh and distribution in the WCDMA system, in order making the flow control procedure among the MAC-c/sh of WCDMA system there is further understanding in time with on the method, is described in further detail below in conjunction with the specific implementation of 4 pairs of the technical program of accompanying drawing in the WCDMA system:
1) at first to determine the congestion threshold of logic channel buffer area and can distribute thresholding according to the TFS Transport Format Set that high level disposed at MAC-c/sh;
2) the data volume BOlogic_new_aver (not being dealt into the data volume that FP goes) in the MAC_c/sh cycle monitoring logic channel buffer area, on the basis of planning moment BOlogic_new_aver, add the data volume that receives buffer area then, obtain BOtotal_new_aver, this work is all will do each dispatching cycle;
3) BOlogic_new_aver that calculates according to second step judges whether the data volume in the current cache district has surpassed the congestion threshold of buffer area (BOcongestion_threshold), if surpass then execution in step 10); Otherwise execution in step 4);
4) BOtotal_new_aver that calculates according to second step judges whether the data volume in the current cache district surpasses the distributed thresholding (BOallocation_threshold) of buffer area, if surpass then execution in step 5); Otherwise execution in step 11);
5) calculate the total Buffer capacity that to distribute to MAC-d, continue step 6);
6) in a dispatching cycle, may receive the application of a plurality of MAC-d, so MAC-c/sh when the application that receives MAC-d, all need to the application in information preserve, so that use when giving optimized distribution, for being optimized partition capacity after and the request that receives before finishing this dispatching cycle all be put into the next one and distribute dispatching cycle; Continue step 7);
7) judge whether to arrive the moment of optimized distribution, if arrive then execution in step 8), otherwise get back to the application that step 6) continues monitoring MAC-d;
8) call the method for optimized distribution capacity: determine the number of times of the unallocated flow of request of every kind of pairing weights of priority and current record according to the application information of the MAC-d of all application partition capacities of preserving, Buffer Size and the priority according to application is optimized distribution then; Continue step 9);
9) send the capacity allocation control frame respectively for all MAC-d of application in the current dispatching cycle, to step 12);
10) chain of command will be notified this moment so that chain of command reference when doing new radio bearer and reshuffle, to step 11);
11) do not do the work of optimized distribution capacity this moment, the MAC-d of all applications is returned to distribute control frame, continue step 12);
12) the wait measurement period is then got back to step 2 again).
Because without any mechanism the data of losing because buffer area is congested are carried out record at the MAC of WCDMA system layer, if especially the data that MAC-d is sended over do not impose any restrictions, just very likely cause the data in the buffer area to be overflowed, thereby cause loss of data, and do not report which loss of data after the loss of data to high level, so also at high level the data of losing are done some and remedy, finally cause the decline of the quality of reception with regard to having no idea; Therefore the flow control among the MAC-c/sh sends for the high-rise data of restriction, guarantees that it is very important that data are not lost at the MAC layer; And the self-adapting flow control method about the FACH of WCDMA system proposed by the invention be according to the data traffic among the current MAC-c/sh with and the priority of corresponding logic channel, data source (MAC-d) the self adaptation distribute data flow to being applied in a dispatching cycle; The method has been taken all factors into consideration the priority of the MAC-d logic channel of application, the data traffic of application, the size of current MAC-c/sh buffer area and the influence that is not assigned with four kinds of factors of request number of times of flow, can so that this distribution method the MAC-d of all applications is compared fair, only can not occur having distributed the traffic assignments that may give the small data quantity high priority that causes according to priority hows a lot than the data that will transmit, and give big data quantity low priority traffic assignments data volume seldom, thereby cause the situation of the waste that buffer pool size distributes.Utilize this method effectively to monitor, also can effectively guarantee to transmit the integrality of data, improve the communication quality of system the data flow.