# Smart Collection of Real-Time Vehicular Mobility Traces
## Implementation Details
### Adopted Infrastructure  
Based on the developed framework, the system generates an information which is used either to:  
* transmit recorded positions at regular intervals to the geo-localization platform, or
* warm the administrator framework about a system dysfunction.  
The system requires network access to transmit the produced updates from trackers to the processing server through any of the available communication networks (GSM and GPRS). The trackers are configured in a hybrid mode; in this mode, they detect an available network to send the collected data immediately, with higher precision and reliability, to the processing center which carries the main framework. These data are analyzed, providing a description of real-life vehicular behaviors.  
Figure 4: Flow chart describing the processes and procedures required for setting-up the system, its implementation and deployment.  
However, if no network is available in the deployment zone, the tracker stores the collected data until any network is available again and then delivers the data to the server. The chosen operation methods seem to be an appropriate solution given that it offers the major benefit of continuously collecting data during the experiment time without losses. The data set obtained contains a complete start-to-end trace of the vehicle route. The experiments were carried out during a continuous period of seven months (approximately 214 days). It is worth nothing that the adopted approach makes it possible to prevent deployment drawbacks, such as energy consumption, loss of devices, and possible hardware troubleshoots. The chosen solution considers three warning methods to release regulated conditions or triggered updates:  
* The main method permits continuous framework updates via GPRS. It allows changes to be displayed at the administrator's dashboard.
* If it is detected that the dashboard is in an inactive state, a warning is forwarded to the administrator by e-mail.
* Otherwise, to carry out permanent vehicle monitoring, these warnings are sent as a text message when specified as critical notifications (optional).  
The collection process is displayed in Figure 5. This shows that each vehicle is equipped with a GPS tracker, so that it can be located, and a GPRS modem to transmit current updates. The system computes accurate updates that are delivered to the processing server through an available network in order to provide localization data and all deployment incidents. This allows a smart collection with the aim to detect, correct and prevent losing of any part of mobility model collected. A set of graphs is displayed at the administrator's console in real time. All of the vehicle pathways are recorded in a global data set, making it possible to obtain a new and complete trace mobility model, entitled Morocco traces. The proposed framework monitors vehicle tracks, and additionally it can remotely and concurrently manage the activities of heterogeneous transport fleets in several assorted regions, such as excursions and maritime shipping, as well as carrying out truck localization. Analysis of the overall collected tracks and the current data allows the optimization of courses, for example, in a vehicular ad hoc network (VANET) [17]. Nowadays, these kinds of applications have attracted much attention in the case of smart cities, especially in the deployment of intelligent vehicles, where they can be interconnected in an IoT context [18].