CHAPTER 3 Energy-aware Grouping Design
3.3 Energy-aware Grouping (EG) Design
國
立 政 治 大 學
‧
N a tio na
l C h engchi U ni ve rs it y
3.3 Energy-aware Grouping (EG) Design
Figure 4 is an overview of our design: Energy-aware Grouping (EG). Since nodes are equipped GPS device, a leader node will record the waypoints of its moving path which are predefined in the preinstall navigation system. A beacon message contains with its group identity (GID), the record of historical waypoints, the next waypoint, and the destinations of messages. Once a leader node gets it, it will check the path information first to recognize if they are suit to form a group or not. If the “join” event won’t happen, they will go to the step of “message relay”.
Figure 4:Overview of Energy-aware Grouping (EG)
‧
When the sleeping duration timed-out, all nodes are checking their status and transmit a message of it to their leader node to make the decision of leader selection for next round. After the selection, the original leader node will alert all other nodes who will be the new leader node in next round. A member node goes to sleeping mode after received the alert and the new leader node charges with group’s contact and messages’ transmission.
3.3.1 Methods choose when contact between method 1 (M1) and method 2 (M2)
Our design contains with two methods for different scenarios. The first method, called M1, is designed for less changing situation like scenario 1 and the other method, called M2, is for others.
A single node uses M2 as its default grouping policy for more opportunities to form a group. When a contact occurs, leader nodes will check the other one’s group identity (GID) and the record of historical and next waypoints.
If they have a same GID and same waypoints in the last three (or more) waypoints, they will use M1 to form a group. This is also the only chance for a node to change its grouping method from M2 to M1. Once a node chooses M1, it will not change the group method until it becomes a group contains with only single node, such as the situation of can’t find its leader node after sleeping duration timed-out. Choosing M1 is the highest priority if the conditions are satisfied.
When the conditions for M1 are dissatisfied, they will choose M2 as their grouping method if they have same records of next waypoints. Otherwise, they will go to message relay policy checking.
‧ 國
立 政 治 大 學
‧
N a tio na
l C h engchi U ni ve rs it y
3.3.2 Method 1 (M1) for less variation
When a group formed by M1 method, it will only check the group identity (GID) as the main condition any time. Even if a node has same moving path in the future approaches, it is not allowed to join the M1 group if its GID is not match. Each GID is an unique code with a group table in the system. Every node has its group table to realize which node can be grouping with and which one is the leader node of the group. The first leader node is set by default with randomly chosen. Once the M1 group is formed, nodes will only check GID and group table to maintain it. The flow shows on Figure 5 and the detail shows below.
Figure 5:The flow of method 1 (M1)
‧ 國
立 政 治 大 學
‧
N a tio na
l C h engchi U ni ve rs it y
At the beginning of the round, nodes check its group table to recognize its GID and the role of the group. If it is a member node, it broadcasts a beacon message contains with its GID and energy level. If it gets leader’s acknowledgement, it will wait the message contains with next leader node information until time-out. If it gets nothing but time-out, it will turn to be a leader node itself and change the grouping method to M2. On the other side, a leader node tries to collect all information of its group members until time-out. When it gets all
information, it chooses a new leader which has the highest power in the whole group. Then it transmits a message to notify which one is the new leader node at next round to all member messages but the new leader node. After all, member nodes turn to sleeping mode and the old leader exchange the buffered messages to new leader and then change its role to member node and turn to sleeping mode.
‧ 國
立 政 治 大 學
‧
N a tio na
l C h engchi U ni ve rs it y
3.3.3 Method 2 (M2) for the environment with groups will change
In order to be more flexible for nodes’ mobility, we purpose another method, called M2, to improve M1. A group contains with only leader node is setting to use M2 as its grouping method. Figure 6 is the flow of M2 and the detail shows below.
Figure 6:The flow of method 2 (M2)
The main concept of M2 which is different to M1 is the grouping policy. M1 uses GID to make the grouping decision. In the M2 method, nodes will check their future routing path.
When they have same path in nearly future, they are allowed to form a M2 group. If they don’t, they will check only the message relay policy. The leader node’s selection of the group is still considering the energy level of nodes. The higher one will be the leader node and the
‧ 國
立 政 治 大 學
‧
N a tio na
l C h engchi U ni ve rs it y
other one will be the member node and then turns to sleeping mode after buffered messages have been exchanged. The sleeping interval of a node is calculating by itself. Since it can recognize the same path when grouping, it can estimate how much time will take to reach the location that is the end of the same path. When a member node wakes up and cannot find its leader node, it will change its role to be a leader node itself.
The rest part of the design M2 is similar to the design in M1. A group has only one awake node, called leader node, to charge with messages’ transmission and others turn to sleeping mode.