# Receiver-Initiated Handshaking MAC Based on Traffic Estimation for Underwater Sensor Networks +
## 5 TERI-MAC Design
### Description of TERI-MAC  
TERI-MAC employs a receiver-initiated _three-way_ handshake. Specifically, it involves four phases, as shown in Figure 4.  
Figure 3: Distribution of the average number of packets on the link layer. The average data generation rate is 0.4. Figure 2: Data gathering network scenario. **Phase 1:** The receiver \(R\) starts a handshake process by sending out a Request-to-Receive (\(RTR\)) message when it intends to poll data from its neighbors. Here, the \(RTR\) message has two functions: to help the receiver request data from neighborhoods and to arrange the transmissions of Available-to-Send (\(ATS\)) packets from neighboring senders. It consists of the receiver's ID, the next-hop receiver's ID, the surrounding senders' IDs, the transmission time of \(ATS\) in sequence, and the number of requested packets from each sender for the data transmission, as shown in Figure 5. By overhearing the \(RTR\) message, all the senders and potential interference nodes within the communication range are immediately notified of the upcoming data transmissions. No matter whether the neighboring node is scheduled to transmit the data or not, it will not interfere with the following data reception at the receiver. In this way, TERI-MAC is more effective at preventing the packet collisions caused by the hidden terminal phenomenon. _RTR loss:_ If the \(RTR\) message is not successfully decoded at the intended sender or potential interference node, we call it the \(RTR\) loss. Taking sender \(S_{3}\) as an example, if the \(RTR\) is lost on \(S_{3}\), the node will not be able to respond with \(ATS\) and thus, the handshake between \(R\) and \(S_{3}\) will not be established. The time slots that have been assigned to sender \(S_{3}\) will be wasted, degrading the channel's utilization. However, the handshake process and data transmissions continue on other senders that have successfully received the \(RTR\) message, as shown in Figure 6. Another negative effect of \(RTR\) loss is on the collision avoidance mechanism in TERI-MAC. Without the interpretation of the transmission scheduling carried on \(RTR\), the node may not be aware of the following data receptions on the receiver \(R\). Collisions are likely to happen if the node attempts to access a channel at the same time. In this case, overhearing the \(ATS\) message from other senders within the transmission range (i.e., \(S_{1}\) and \(S_{4}\) in Figure 4) can help mitigate the collisions caused by \(RTR\) loss. **Phase 2:** The senders need to respond to the receiver with \(ATS\) messages to establish the data transmission sessions. In order to avoid collisions among \(ATS\) packets, the transmission time of the \(ATS\) packets should be staggered and follow the order scheduled in the \(RTR\) packet, which will be introduced in detail in Section 5.2. The \(ATS\) message includes the sender's ID and the number of available packets during the time interval since the last round of data transmission, as shown in Figure 7. This information, as the input of the traffic estimation algorithm to be discussed in Section 7, helps the receiver to update the traffic distribution of each sender. _ATS loss_: When the \(ATS\) message cannot be decoded, we call it \(ATS\) loss. Different from \(RTR\) loss, \(ATS\) loss does not affect the handshake process or the scheduled data transmissions, since the transmission is arranged in advance in the \(RTR\) packet. Figure 6 illustrates an example when the \(ATS\) from \(S_{2}\) is lost on the receiver, \(R\). The loss of the information about the number of available data packets on \(S_{2}\) affects the traffic estimation to be performed on the receiver, \(R\). Figure 4: Four phases in traffic estimation-based receiver-initiated medium access control (TERI-MAC). Figure 5: Format of the Request-to-Receive (\(RTR\)) message. **Phase 3:** After establishing the handshakes between the receiver and the senders, the data transmission process begins.