# UAV-Assisted Dynamic Clustering of Wireless Sensor Networks for Crop Health Monitoring
## 3 Proposed UAV Assisted Dynamic Clustering Architecture
### Sensor Node  
Field sensors installed in the field to monitor a specific parameters about crop, soil or the environment have the following properties:  
* Location-unaware, cheap in cost and left unattended.
* Support for multiple frequencies (at least two frequencies--433 MHz and 2.4 GHz--for localization and data transmission.
* By default, 433 MHz is switched on to hear the beacon from the UAV, afterward it will be used for localization and synchronization, while the 2.4 GHz transceiver will be activated on demand for communication only.
* Can hear the UAV if in range, but all might not be able to connect with it because of their internal parameters.
* Maximum communication range = 500 m.
* Processing and memory enabled.  
All sensor nodes are considered to have a unique ID of the format given below:  
* _Type_: We consider three basic types: crop, soil and environment, but we allocate 1 byte for further and future extensions.
* _Subtype_: Leaf, stem, root and any combination.
* _Purpose_: Temperature, humidity, thickness, flow and all possible combinations.
* _Unique ID_: Unique number of each sensor node.  
The field sensor nodes will have 6 bytes of unique ID as shown in Table 2. The UAV will select any particular type or combination with the help of this ID, also called prefix. Sensor nodes will also use it to send beacon acknowledgement/reply messages.  
In our proposed system, initially all sensor nodes are considered as undistinguishable (no special CH). A sensor node has to maintain five parameter values about its health:  
\begin{table}
\begin{tabular}{c c c c} \hline Type (6 bytes) & Height (2 bytes) & Threshold (1 byte) & Other (2 bytes) \\ \hline Ifestor & 150 bytes & Traffic \\ \hline \end{tabular}
\end{table}
Table 1: UAV beacon message.  
\begin{table}
\begin{tabular}{c c c c c} \hline Circle No. & Type & Sub Type & Purpose & Unique No. & 1001 Size \\ \hline
1 byte & 1 byte & 1 byte & 1 byte & 2 bytes & 6 bytes \\ \hline \end{tabular}
\end{table}
Table 2: Sensor node unique ID.  
1. _Energy:_ How much energy is remaining,
2. _Consumption rate:_ The consumption rate of energy to perform its job,
3. _Renewable energy:_ Whether renewable energy is available or not,
4. _Antenna size:_ Antenna size to estimate its communication range,
5. _Data size:_ How much data should be transmitted.  
All activated sensor nodes will calculate a probability value to become a CH based on these health indicators. The sensor nodes' reply to the UAV will consist of 9 Bytes containing a prefix (node ID) in the packet header, a probability value (the probability to be selected as a CH, calculated by the Bayesian formula by putting its entire health indicator's values) in payload and trailer. The 1 trailer byte is allocated for Cyclic Redundancy Check (CRC) and future use. A sensor node activated in response to an UAV beacon will send a reply shown in Table 3:  
The most important component of our developed system is the sensor node. The whole system is developed in such a way to facilitate the tasks of this component and let it optimize its resources to monitor the crop parameters for a longer time. In our developed system, the daily routine working of sensor node is limited to sense and sleep. It becomes only active for communication after receiving a beacon message from the UAV. The sensor node working process is expressed in an algorithmic form as shown in Figure 3. The process starts when the node receives a beacon then it calculates its Bayesian probability to be a CH and informs the UAV about it. The UAV then selects one of the activated nodes as CH, which should collect data from the whole cluster, aggregate and forward it to the UAV. The list of variables used in the rest of this article is given in Table 4.  
\begin{table}
\begin{tabular}{c c} \hline \hline ID (6 bytes) & Probability (2 bytes) & Trailer (1 byte) \\ \hline
**T**odule: & Beyond & Traffic \\ \hline \hline \end{tabular}
\end{table}
Table 3: Sensor node reply.