|
Algorithm 1 Proposed new channel access mechanism. |
| Require:
, average packet duration time . |
| Ensure: Transmission success/failure. |
-
1:
if Beacon is not received in the control channel then
-
2:
Wait for the beacon in the control channel;
-
3:
else
-
4:
Switch to data channel and generate a random backoff = (0, CW) duration;
-
5:
if
then
-
6:
Wait for next superframe and go to step 1;
-
7:
else
-
8:
Performs CCA after duration and receives signal Y during this CCA;
-
9:
if Channel found busy then
-
10:
if
then
-
11:
Switch to sleep state for duration;
-
12:
else if
then
-
13:
Switch to sleep state for duration;
-
14:
else if
then
-
15:
Switch to sleep state for duration;
-
16:
else
-
17:
Switch to sleep state for ;
-
18:
end if
-
19:
, ;
-
20:
if
then
-
21:
Channel access failure;
-
22:
else
-
23:
Go to step 4;
-
24:
end if
-
25:
else
-
26:
Start transmission in the data channel;
-
27:
if ACK is not received then
-
28:
;
-
29:
if
then
-
30:
Go to step 4;
-
31:
else
-
32:
Transmission failure;
-
33:
end if
-
34:
end if
-
35:
end if
-
36:
end if
-
37:
end if
|