Embodiment
As shown in Figure 1: group system network of the present invention has increased new network element PTT Server (PTT service device) with respect to the networking of CDMA 1X, is responsible for management and group, location management and the voice calls exchange of cluster user.In this programme, PTT Server also will be responsible for initiating the cluster test call as the triggering person of test call.
Based on above-mentioned group system network, call testing method of the present invention comprises the steps:
Step 1: increase the PTT service device at network side, portable terminal or network side are initiated the cluster test call;
Step 2: trunked call is competed right of speech after setting up and finishing between portable terminal;
Step 3, apply for that the portable terminal of right of speech begins to generate Frame, described Frame is to send the cluster portable terminal of data by using pseudo-random process, dynamically generate the GPS absolute time when being filled with assembled data frame in the described Frame according to the model of typical voice call;
The processing mode that step 4, described Frame are pressed speech frame transmits, and all the other portable terminals receive described Frame and add up, and to PTT service device (PTT Server) report statistics;
The portable terminal of original right of speech discharges right of speech behind step 5, the certain hour, triggers the right of speech competition of a new round.
Further, as shown in Figure 2, in the step 1, the flow process that portable terminal is initiated the cluster test call comprises the steps:
A, cluster portable terminal signalling of bouquet are called out initial call message, and the cluster test call is carried out in request, and the business option that carries in the message is " cluster test call-individual calling " or " cluster test call-group calling ";
B, PTT Server are according to the called number in the portable terminal initial call message, to other portable terminal signalling of bouquet call page message that belongs to this group, the business option that carries in the message is " cluster test call-individual calling " or " cluster test call-group calling ";
Connect between c, PTT Server and the calling mobile terminal, be used for transmit data frames.Whenever step c can take place after step a;
After other portable terminal in d, the group received the trunked call beep-page message, the signalling of bouquet call page responded, and connected with PTTServer.If PTT Server still has subscriber paging not have response after waiting for certain hour in the group, then PTT Server directly forwards step e to, only sends the right of speech idle message to the portable terminal that has inserted;
After e, all users inserted, PTT Server sent the right of speech idle message to all portable terminals that inserted, represented that present right of speech, can be for application for idle;
As shown in Figure 3: the flow process of network side initiation cluster test call comprises the steps: in the step 1
A, operator operate on PTT Server, by the cluster test call of group's group number triggering to this group, PTT Server all portable terminal signalling of bouquet call page message in group, the business option that carries in the message is " cluster test call-individual calling " or " cluster test call-group calling "
After b, each portable terminal received the trunked call beep-page message, the response of signalling of bouquet call page connected with PTT Server.If PTT Server still has subscriber paging not have response after waiting for certain hour in the group, then PTT Server directly forwards step c to, only sends the right of speech idle message to the portable terminal that has inserted
After c, all users inserted, PTT Server sent the right of speech idle message to all portable terminals that inserted, represented that present right of speech, can be for application for idle;
Described application process is as follows: when right of speech is idle, PTT Server notifies each portable terminal by the right of speech idle message, after portable terminal receives this message, and the initializing pseudo random factor, carry out right of speech and rob power, (specifically, get the number between 0 to 255 at random, if less than 50, then apply for right of speech, the probability of application right of speech is 50/255 like this, general 20%), flow process is as follows:
{
a=7
5=16807
m=2
31-1=2147483647
The RNG=Current GPS time (is unit with the frame)
RNG=(RNG^ESN)&0x7FFFFFFF
RNG=(RNG*a)mod m
RNG=(RNG*a)mod m
RNG=(RNG*a)mod m
RNG=(RNG*a)mod m
yn=(RNG>>7)&0xFF
if(yn≤50)
Application sending the right words message
endif
}
In the above algorithm, ESN (Electronic Serial Number) is the Electronic Serial Number of portable terminal.
If the condition of application sending the right words message does not satisfy, perhaps PTT Server refuses the application of this right of speech, and portable terminal is (500ms is to the random value between the 1000ms) at set intervals, once adjudicates again, and decision method is as follows:
{
a=7
5=16807
m=2
31-1=2147483647
RNG=(RNG*a)mod m
yn=(RNG>>7)&0xFF
if(yn≤50)
Application sending the right words message
endif
}
After the application sending the right words message, if portable terminal receives the right of speech grant message that PTT Server sends, then portable terminal log-on data frame generates and transmission flow.
If in the right to apply for words process, portable terminal receives the right of speech notification message that PTT Server sends, and represents that other portable terminal applied for right of speech, then terminating mobile terminal the right to apply for words judgement, and the log-on data frame receives and the statistics flow process.
The portable terminal application is after right of speech, and the longest air time is 1 minute, and after promptly the longest 3000 frames, portable terminal sends the right of speech release message, discharges right of speech.
As shown in Figure 4: the flow process of portable terminal competition right of speech comprises the steps: in the step 2
Under a, the connected state, portable terminal is to PTT Server application sending the right words message
If the current right of speech free time of b, PTT Server sends the right of speech grant message to this portable terminal, and this moment, this mobile terminal backward passage was opened, and can upwards send Frame, otherwise PTT Server sends the right of speech refuse information to this portable terminal;
Other has inserted portable terminal transmission right of speech notification message in group for c, PTT Server, notifies its terminal iidentification of having applied for right of speech at present, receive the right of speech notification message after, portable terminal begins receiving data frames and adds up.
As shown in Figure 5, the flow process of portable terminal release right of speech comprises the steps: in the step 5
Under a, the connected state, the portable terminal that has right of speech sends the right of speech release message to PTT Server;
B, PTT Server regain right of speech, and all have inserted portable terminal and have sent the right of speech idle message in group; If desired, PTTServer can initiatively send the right of speech idle message, reclaims right of speech, does not need message a in this case;
C, portable terminal send the test result report message to PTT Server, report that this takes turns the statistics of test.
Further, the feature of Frame is as follows in the described step 3:
1, Multiplex Option
The cluster test call is supported Multiplex Option MO (Multiplex Options) 0x01 and 0x02, the every 20ms of portable terminal generates a frame data frame, the Frame that generates can be a kind of in full rate, 1/2 speed, 1/4 speed, 1/8 speed, and the bit number that every kind of Frame comprised is as shown in the table:
| Data frame type | MO=1 | MO=2 |
| Full rate | 171 | 266 |
| 1/2 speed | 80 | 124 |
| 1/4 speed | 40 | 54 |
2, Frame is filled
In the cluster test call, the portable terminal transmit leg uses gps time to come the padding data frame, and gps time is be the Current GPS absolute time of unit with millisecond (ms), and the gps time significance bit is long, so only get low 16 or low 24 information as fillings.For the foundation that judges whether the mistake frame is provided to the recipient, gps time is repeated to send twice at least in same frame, according to different speed, and the filling mode of Frame such as following table.
Multiplex Option is 0x01, the filling mode of Frame:
| Data frame type | Information bit length | Gps time length | The gps time number of repetition | Filling bit length | The filling bit content |
| Full rate | 171 | 24 | 7 | 3 | ‘101’B |
| 1/2 speed | 80 | 24 | 3 | 8 | 0xAB |
| 1/4 speed | 40 | 16 | 2 | 8 | 0xAB |
| 1/8 speed | 16 | 0 | 0 | 16 | 0xABAB |
Multiplex Option is 0x02, the filling mode of Frame:
| Data frame type | Information bit length | Gps time length | The gps time number of repetition | Filling bit length | The filling bit content |
| Full rate | 266 | 24 | 11 | 2 | ‘10’B |
| 1/2 speed | 124 | 24 | 5 | 4 | ‘1010’B |
| 1/4 speed | 54 | 16 | 3 | 6 | ‘101010’B |
| 1/8 speed | 20 | 0 | 0 | 20 | 0xABABA |
If when sending Frame, in a certain 20ms moment, portable terminal upper-layer protocol stack requires to send other layer 3 signalings, and then portable terminal stops the transmission of epicycle Frame.
3, speed decision
In the cluster test call, the portable terminal transmit leg uses pseudo random sequence to decide the type of Frame, promptly adopts full rate, 1/2 speed, 1/4 speed or 1/8 speed to send Frame.
According to the speed R (n-1) of portable terminal present rate R (n) and last data frame, portable terminal can be divided into 16 states as shown in the table.Each state can only be moved in certain one of four states, as, state 0 can only be moved to state 0,1, and 2 and 3, state 1 can only be moved to state 4,5, and 6 and 7.If the state S (n-1) of n-1 Frame is k, the state S (n) of n Frame satisfies following formula so:
S(n)∈{(4×k)mod 16,(4×k+1)mod 16,(4×k+2)mod 16,(4×k+3)mod 16}
If state S (n) determines that rate corresponding is so:
| S(n) |
R(n-1) |
R(n) |
| 0 |
1 |
1 |
| 1 |
1 |
1/2 |
| 2 |
1 |
1/4 |
| 3 |
1 |
1/8 |
| 4 |
1/2 |
1 |
| 5 |
1/2 |
1/2 |
| 6 |
1/2 |
1/4 |
| 7 |
1/2 |
1/8 |
| 8 |
1/4 |
1 |
| 9 |
1/4 |
1/2 |
| 10 |
1/4 |
1/4 |
| 11 |
1/4 |
1/8 |
| 12 |
1/8 |
1 |
| 13 |
1/8 |
1/2 |
| 14 |
1/8 |
1/4 |
| 15 |
1/8 |
1/8 |
After portable terminal receives the right of speech grant message, the initializing pseudo random factor (RND, Random Number Generator), method is as follows:
{
a=7
5=16807
m=2
31-1=2147483647
The RNG=Current GPS time (is unit with the frame)
RNG=(RNG^0x2AAAAAAA)&0x7FFFFFFF
RNG=(RNG*a)mod m
RNG=(RNG*a)mod m
RNG=(RNG*a)mod m
RNG=(RNG*a)mod m
S(0)=15
}
The every 20ms of portable terminal uses current RNG afterwards, once calculate by following method, and decision speed, and the padding data frame sends.
{
a=7
5=16807
m=2
31-1=2147483647
RNG=(RNG*a)mod m
zn=(RNG>>7)&0x7FFF
if(zn<A1)
S(n)=(4*s(n-1)+3)mod 16
elseif(A1≤zn<B1)
S(n)=(4*s(n-1)+2)mod 16
elseif(B1≤zn<C1)
S(n)=(4*s(n-1)+1)mod 16
elseif(zn≥C1)
S(n)=(4*s(n-1))mod 16
endif
}
Following table is the probability distribution of mobile terminal state migration, and S (n-1) be a current state, and A1, A2 and A3 are the boundary values of state transition probability, the typical case that these migration probabilities energy approximate simulations go out the people model of conversing.
| S(n-1) |
A1 |
B1 |
C1 |
| 0 |
0 |
0 |
2916 |
| 1 |
0 |
20906 |
25264 |
| 2 |
0 |
0 |
0 |
| 3 |
0 |
0 |
0 |
| 4 |
0 |
0 |
4915 |
| 5 |
0 |
17170 |
24969 |
| 6 |
21856 |
25887 |
27099 |
| 7 |
0 |
0 |
0 |
| 8 |
0 |
0 |
4522 |
| 9 |
0 |
5472 |
16384 |
| 10 |
21856 |
21856 |
24576 |
| 11 |
28246 |
29622 |
30802 |
| 12 |
0 |
0 |
5472 |
| 13 |
0 |
6554 |
6554 |
| 14 |
28377 |
28934 |
29491 |
| 15 |
29753 |
32473 |
32571 |
Further, in the described step 4: the method that portable terminal is added up described Frame is as follows:
1, transmit leg Frame statistics
After portable terminal received the right of speech grant message, beginning log-on data frame product process was added up the Frame that generates simultaneously.
| Data frame type | Correspondence adds 1 counter |
| Full rate | CT_T1 |
| 1/2 speed | CT_T2 |
| 1/4 speed | CT_T4 |
| 1/8 speed | CT_T8 |
Wherein, CT_T1 is the number of the full rate data frame of transmit leg transmission; CT_T2 is the number of 1/2 speed data frame of transmit leg transmission; CT_T4 is the number of 1/4 speed data frame of transmit leg transmission; CT_T8 is the number of 1/8 speed data frame of transmit leg transmission.
2, receiving side data frame statistics
After portable terminal received the right of speech notification message, the beginning receiving data frames was added up the Frame that receives simultaneously.Except the Frame of 1/8 speed, gps time sends twice to I haven't seen you for ages in Frame, and the recipient solves the value of these fields, if content is all identical, and the value (if there is) of filling bit is also correct, can think that then Frame is correct, otherwise is the mistake frame.
| Data frame type | Frame is correct | Correspondence adds 1 counter |
| Full rate | Y | CT_R1 |
| Full rate | N | CT_R1_ERR |
| 1/2 speed | Y | CT_TR2 |
| 1/2 speed | N | CT_R2_ERR |
| 1/4 speed | Y | CT_R4 |
| 1/4 speed | N | CT_R4_ERR |
| 1/8 speed | Y | CT_R8 |
| 1/8 speed | N | CT_R8_ERR |
Wherein, CT_R1 is the number of the correct frame of full rate of recipient's reception; CT_R1_ERR is the number of the full rate error code frame of recipient's reception; CT_R2 is the number of the correct frame of 1/2 speed of recipient's reception; CT_R2_ERR is the number of 1/2 speed error code frame of recipient's reception; CT_R4 is the number of the correct frame of 1/4 speed of recipient's reception; CT_R4_ERR is the number of 1/4 speed error code frame of recipient's reception; CT_R8 is the number of the correct frame of 1/8 speed of recipient's reception; CT_R8_ERR is the number of 1/8 speed error code frame of recipient's reception.
If the Frame that receives is full rate, 1/2 speed or 1/4 speed, after the recipient confirms that Frame is correct, solve the gps time that comprises in this Frame, use current GPS absolute time (GPScur), deducting the transmission gps time (GPSsnd) of this Frame, is the propagation delay time of this frame just.
The time-delay calculation formula of 1/4 rate frame:
{
if(GPScur≤GPSsnd)
Delay(n)=GPScur+2
16-GPSsnd
elseif
Delay(n)=GPScur-GPSsnd
endif
}
The time-delay calculation formula of 1/2 speed and full-rate vocoding:
{
if(GPScur≤GPSsnd)
Delay(n)=GPScur+2
24-GPSsnd
elseif
Delay(n)=GPScur-GPSsnd
endif
}
In the communication process (being that some portable terminal applications discharge the process of right of speech to right of speech to it), the recipient adds up the propagation delay time of each Frame, and according to following formula, calculates the average delay and the shake of various speed data frames:
Described PTT Server is responsible for carrying out the collection and the demonstration of the test data of each time communication process.
After right of speech discharged, PTT Server sent the right of speech release message to each portable terminal; After receiving this message, each portable terminal reports the statistics of this communication process by the test result report message.
Further, if desired, the PTT service device can be initiatively to the mobile terminal enquiry statistics, method is: PTTServer sends the test result request message to portable terminal, (right of speech ID: the portable terminal application is after right of speech to carry ID number of the communication process of inquiring about in the message, PTT Server distributes an ID for this conversation, notify each portable terminal, this ID is used to identify this communication process afterwards), portable terminal reports the statistics of this communication process according to right of speech ID by the test result report message.If the test result of portable terminal is lost, perhaps the right of speech ID in right of speech release message or the test result request message is illegal, and portable terminal sends the test result error message.
As shown in Figure 6, its message interaction process comprises the steps:
A, PTT Server send the test result request message to portable terminal;
The statistics of b, portable terminal report test.
Message format of the present invention is as follows:
1, the right of speech free time
| Field |
Length(bits) |
| MSG_TYPE |
8 |
MSG_TYPE: type of message ID
2, the right to apply for words
| Field | Length(bits) |
| MSG_TYPE | 8 |
MSG_TYPE: type of message ID
3, right of speech is authorized
| Field | Length(bits) |
| MSG_TYPE | 8 |
| FLOOR_ID | 8 |
MSG_TYPE: type of message ID
FLOOR_ID: right of speech ID is distributed by PTT Server, the process that identifies a right to apply for words and converse
4, right of speech notice
| Field | Length(bits) |
| MSG_TYPE | 8 |
| FLOOR_ID | 8 |
| GRANTED_NUM_LEN | 4 |
| GRANTED_NUM | GRANTED_NUM_LEN*4 |
MSG_TYPE: type of message ID
FLOOR_ID: right of speech ID is distributed by PTT Server, the process that identifies a right to apply for words and converse
GRANTED_NUM_LEN: the length of obtaining right of speech user's number mark
GRANTED_NUM: the number mark that obtains the right of speech user
5, right of speech discharges
| Field | Length(bits) |
| MSG_TYPE | 8 |
| FLOOR_ID | 8 |
MSG_TYPE: type of message ID
FLOOR_ID: right of speech ID, with this conversation in right of speech authorize or the right of speech notification message in FLOOR_ID consistent
6, test result request
| Field | Length(bits) |
| MSG_TYPE | 8 |
| FLOOR_ID | 8 |
MSG_TYPE: type of message ID
FLOOR_ID: right of speech ID, authorize with right of speech or the right of speech notification message in FLOOR_ID consistent, expression is to this speaking test result's inquiry
7, test result report
| Field | Length(bits) |
| MSG_TYPE | 8 |
| FLOOR_ID | 8 |
| CONV_MODE | 2 |
If CONV_MODE=0
| CT_T1 | 16 |
| CT_T2 | 16 |
| CT_T4 | 16 |
| CT_T8 | 16 |
If CONV_MODE=1
| CT_R1 | 16 |
| CT_R1_ERR | 16 |
| CT_R1_DELAY | 16 |
| CT_R1_JITTER | 16 |
| CT_TR2 | 16 |
| CT_R2_ERR | 16 |
| CT_R2_DELAY | 16 |
| CT_R2_JITTER | 16 |
| CT_R4 | 16 |
| CT_R4_ERR | 16 |
| CT_R4_DELAY | 16 |
| CT_R4_JITTER | 16 |
| CT_R8 | 16 |
| CT_R8_ERR | 16 |
| CT_RALL_DELAY | 16 |
| CT_RALL_JITTER | 16 |
MSG_TYPE: type of message ID
FLOOR_ID: right of speech ID, consistent with the FLOOR_ID in right of speech free time or the test result request message, expression is to this speaking test result's report
CONV_MODE: call mode, 0 expression transmit leg, 1 expression recipient
CT_T1: the number of the full rate data frame that transmit leg sends
CT_T2: the number of the 1/2 speed data frame that transmit leg sends
CT_T4: the number of the 1/4 speed data frame that transmit leg sends
CT_T8: the number of the 1/8 speed data frame that transmit leg sends
CT_R1: the number of the correct frame of full rate that the recipient receives
CT_R1_ERR: the number of the full rate error code frame that the recipient receives
CT_R1_DELAY: the time delay of full-rate vocoding, unit is a millisecond
CT_R1_JITTER: the shake of full-rate vocoding, unit is a millisecond
CT_R2: the number of the correct frame of 1/2 speed that the recipient receives
CT_R2_ERR: the number of the 1/2 speed error code frame that the recipient receives
The time delay of CT_R2_DELAY:1/2 rate frame, unit is a millisecond
The shake of CT_R2_JITTER:1/2 rate frame, unit is a millisecond
CT_R4: the number of the correct frame of 1/4 speed that the recipient receives
CT_R4_ERR: the number of the 1/4 speed error code frame that the recipient receives
The time delay of CT_R4_DELAY:1/4 rate frame, unit is a millisecond
The shake of CT_4_JITTER:1/4 rate frame, unit is a millisecond
CT_R8: the number of the correct frame of 1/8 speed that the recipient receives
CT_R8_ERR: the number of the 1/8 speed error code frame that the recipient receives
CT_RALL_DELAY: the time delay of all full-rate vocodings, 1/2 rate frame and 1/4 rate frame, unit is a millisecond
CT_RALL_JITTER: the shake of all full-rate vocodings, 1/2 rate frame and 1/4 rate frame, unit is a millisecond
8, test result mistake
| Field | Length(bits) |
| MSG_TYPE | 8 |
| FLOOR_ID | 8 |
MSG_TYPE: type of message ID
FLOOR_ID: right of speech ID, consistent with the FLOOR_ID in right of speech free time or the test result request message.