## 4 Partition Aware-RPL Protocol Overview
### Parent Selection Algorithm
(ii) _P2 MP_ data-streams such as control messages from the sink to the field, including: electro-vanes, air conditioners, milking machines, gates, agriculture robots, drones, etc. (iii) _P2P_ communication such as exchange between local (parcel level) decision system and local instruments (air conditioner, local alert system, fertilizing machines with nodes in the same parcels, communication and coordination between two automated tractors, etc.). Based on the latter example, it becomes clear that there are mainly three data stream patterns in the smart farm network:

* [rightmargin=*]
* [leftmargin=*

+++ ==WARNING: Truncated because of repetitions==



++

(e.g., tractor, drone, and robot). Likewise, PA-RPL can be adapted to support these dynamic scenarios. Nevertheless, we can expect this adaptation to be relatively easier compared to RPL. In fact, with PA-RPL, all the parcel nodes are assembled in the same DODAG branch (sub-DODAG) allowing to easily gather information about a parcel at the Parcel Head node, reducing the effort needed to make the mobile node collect this data. Additionally, if we assume One-to-One communication scenarios (where the communication needs to go _UP_ then _DOWN_) covering situations where a node exchanges data with the mobile node, PA-RPL turns out to be more suited than RPL as illustrated in Figures 18 and 19. Indeed, the mobile node can easily integrate the built DODAG by simply acquiring the color of the parcel. As such, the mobile node simply needs to move from one parcel to the other while adopting each time the color of the visited parcel. Moreover, the One-to-One communication can be easily performed by going Up to the Parcel Head (no need to go up to the sink), then Down to the target node. This makes the whole exchange process run locally (involving the mobile node and nodes in the parcel solely), which makes it possible to support more than one mobile node in the network simultaneously. Figure 5:5 Spatial queries dissemination with RPL. Figure 5:6 Spatial queries dissemination with PA-RPL. Figure 5:7 Intra-parcel message exchange with RPL. From the above, it becomes clear how important to take into account the partition of the farm into the DODAG building process in order to optimize the whole communication system. Indeed, when the built DODAG allows an easy gathering of all the data messages of a parcel, in the same node (Parcel Head), it enables efficient in-network aggregation. Moreover, when a selected (or elected) node to collect data, is a common parent for all the parcel nodes, it allows more efficient intra-parcel (or partition) communications. In addition, when the common parent selection process is based on the path reliability, between this node and the sink, all the sink-to-parcel messages will follow the same way. On the other hand, the fact that farm partitions are usually very autonomous and/or independent motivates the need to local decision making processes, in contrast to all-centralized systems. One of the main attractive features of the proposed PA-RPL [14] is the fact that the built DODAG straightforwardly enables parcel-level information processing. However, it is mandatory to pay attention to the fact that this PA-RPL DODAG, will potentially drain the energy of the nodes located between the Parcel Head (PH) and the sink. This is usually referred as Hot-Spot problem [44], leading to a decrease in the LLN lifetime. This is an attractive topic of research that requires specific careful investigation and countermeasure solutions. In principle, lifetime improvement solutions, inspired from similar literature situations, are very feasible and applicable to our algorithm. In fact, the objective function of the PA-RPL can be extended, in order to take into account the node residual energy, in the parent selection process. For instance, a potential solution can be based on the frequent change of the Parcel Head and other end nodes, upon reaching a threshold of residual energy.