## 5 Integration of EOLSR and SERENA
### Application to the OCARI Project  
In the OCARI project, devoted to wireless sensor networks in an industrial environment, SERENA and EOLSR belong to the network layer of the OCARI stack illustrated in Figure 19.  
This OCARI stack refines this published in [7]. EOLSR and SERENA interact with MaCARI layer via two service access points: MDE-SAP for MaCARI data and MME-SAP for MaCARI management. In OCARI, the medium access is scheduled in three periods:  
* \([T0,T1]\) for the synchronization: the beacon generated by the PAN coordinator is propagated multihop in the network;
* \([T1,T2]\) for the intra-cell communications: a cell consists of a coordinator and its attached nodes with reduced functionality. In this period, constrained and unconstrained traffic sent by a reduced functionality device is received by its coordinator and vice-versa;
* \([T2,T3]\) for the inter-cell communications: coordinators route unconstrained traffic using EOLSR. It is possible to have an inactivity period \([T3,T0]\) during which all nodes sleep. More precisely, the EOLSR routing protocol is used to route unconstrained traffic in the \([T2,T3]\) period devoted to inter-cell communications. As said in Section 3, EOLSR builds a routing table according to the information exchanged in the \(Hello\) and \(TC\) messages. This routing table is read by the network layer to find the next hop for the final destination of unconstrained traffic. EOLSR is able to find the path consuming the least energy from a source to a destination, even in case of mobility  
Figure 18: Comparison of the energy consumption in OLSR, EOLSR, OLSR+SERENA, EOLSR+SERENA. of some nodes. The periodic exchange of \(Hellos\) will detect the appearance of new links as well as the breakage of existing ones. \(TC\) will propagate the topology changes in the network and routes are updated accordingly. SERENA is also used in this \([T2,T3]\) period to schedule coordinators activity. Coordinators run the SERENA coloring algorithm. The MaCARI layer of the PAN coordinator is informed of the number of colors used. It dimensions the frame accordingly and assigns time slots per color. Hence, the MaCARI layer of each coordinator is in charge of awaking it in the slot assigned to its color as well as in the slots assigned to its one-hop neighbors. In a perfect environment without mobility and late node arrivals, all transmissions would be collision free and then energy is saved. The medium access is perfectly deterministic. However, in a real industrial environment, color conflicts can occur. Two nodes with the same color transmitting simultaneously can cause collision because of a modified neighborhood due to late arrivals, mobility. Thus, these two nodes that were neither one-hop, nor two-hop nor three-hop neighbors can become neighbors and then prevent the intended destination of a message to correctly receive it. In OCARI, cross-layering between MaCARI and SERENA allows the detection/resolution of such conflicts. MaCARI will detect the conflict and notify SERENA of the conflicting nodes. SERENA  
Figure 19: The OCARI stack. will solve the conflict by obliging the conflicting node with the smallest priority to change its color. For more details, see the paper by [PERSON] _et al_. in this issue. In a further step, SERENA will also be used in the \([T0,T1]\) period to reduce the time needed for beacon dissemination following the association tree. That is because nodes sharing the same color can transmit simultaneously without interfering and each node has a color strictly higher than the color of its parent in the tree. Hence, assigning time slots in the increasing order of colors reduces the end-to-end delay of downstream communications like beacon dissemination. Whereas the reverse order favors upstream communications. This assignment can change to alternatively favor upstream or downstream communications depending on the application requirements. Furthermore, the use of SERENA in the \([T1,T2]\) period will allow several cells to be simultaneously active without interfering.