IoT Based Logistics Vehicle Security Monitoring System

Speed, security and accuracy of a goods transportation play an important role in the logistics industry. This study proposes a logistics vehicle monitoring system that are consists of automated locking and tracking system to ensure the security and on-time arrival of the transported goods. Global Positioning System (GPS) combined with Global System for Mobile Communication/General Packet Radio Service (GSM/GPRS) internet connection method was utilized to provide real-time monitoring using an Android application display. The automatic locking command was successfully executed within 30.50 s delay. The logistics vehicle location accurate to 16.7 m was pinpointed within 28.72 s delay. The warning was successfully given when the logistic vehicle was moving away at minimum 500 m from the destination point to ensure the delivery route was exactly followed.


Introduction
The widespread use of the internet nowadays has increased public interest in electronic commerce activities or e-commerce. To support the e-commerce success, speed, security and accuracy in the delivery of goods play an important role. To achieve this, reliable and fast transportation, as well as efficient logistics services are required. This requirement can only be fulfilled by good and highly credible logistic companies.
Most logistics companies in Indonesia cover such a wide area throughout the nation. They offer a range of services, from simple transport services, through service forwarding, warehousing, palletizing, packing, packaging, to full service of supply chains [1]. The large numbers of logistics companies in Indonesia offer the customers the freedom to choose the companies that suit their need. However, the good performance and credibility of the logistics companies will decide whether the company will exist in the market at all [2].
The basic of a logistic company is not only sending parcels, documents and heavy freight, but also information about them. Hence, a well-developed operating system which consists of working people and infrastructure is required. To ensure a fast and correct flow of information and also to increase the efficiency, the logistics companies need to use the appropriate information technologies. Another objective of the application of information technology by logistics companies is to avoid problems and fulfil the expectations of potential and existing customers [3].
Many problems that arise in the logistics companies include the foul driver, delay of arrival, lost or broken goods, even the thievery of goods during travel [4]. These terrible things can occur due to lack of supervision, which can result in excessive costs for the company. Therefore, the logistics vehicle security monitoring system is required to avoid these problems.
Due to the security reason, the location monitoring of a vehicle or a vehicle tracking system has been commonly used in recent years. The utilization of Global Positioning System (GPS) combined with the latest technology of internet of things (IoT) has been widely implemented in the private cars, school buses and transport trucks [5]- [7]. The diverse connection methods were used such as GSM/GPRS (Global System for Mobile Communication/General Packet Radio Service) or Wi-Fi (Wireless Fidelity) [8]- [13]. However, a GSM/GPRS method was convinced to be more suitable for the usage of a moving vehicle [14].
In this study, the logistics vehicle security monitoring system consists of the automated locking system and tracking system was designed. The locking system is required to ensure the safety of the goods inside the logistics vehicle. Whereas the tracking system is required to locate the position of the logistics vehicle during goods transportation. Its objective is to ensure that the logistics vehicle always follow the pre-determined route so it will not delay the arrival of goods transportation. GPS technology combined with IoT with GSM/GPRS connection methods was used along with Thinkspeak as the IoT platform.

Methods
The safety monitoring system for logistics vehicle designed in this study consists of two parts,i.e. the automated locking system and tracking system. To give the user the convenience and simplicity, both systems can be accessed via an android application using IoT. The diagram block of the overall system is illustrated in Figure 1.

Automated Locking System
A real logistic vehicle box with a dimension of 261×170×150 cm 3 was simulated using a ratio of 1:7 prototype. The dimension of the prototype is 37.2×24.2×21.4 cm 3 as illustrated in Figure 2. The locking system designed in this study is a logistic vehicle box door security system using a servo motor as an IoT-based key slot drive. This system can lock and unlock the box door and can monitor the state of the door remotely to provide a sense of security for the user. The controlling and monitoring of the system can be carried out via an android application using IoT. The reed switch sensor installed on the box door was used to send the data to the android so that the door state can be monitored in real-time. If the box door is opened by force, the reed switch sensor will send a notification to the android application.  logic is 1 or High (the door is closed), otherwise, if the magnet and the switch are apart, the sensor logic is 0 or Low (the door is opened). In this prototype, the magnet and switch are placed adjacently as illustrated by Figure 2(b). Then, the servo motor was connected to the box door key. The microcontroller used in this system was Arduino ATMega2560 with a 12V Yuasa accumulator as the power supply.

Tracking System
The tracking system designed in this study utilized a GPS module based on an Android application. This system can locate the longitude and latitude position of a logistic vehicle and display it on the maps of android application. GPS Modul Ublox Neo-7M was connected to Arduino Mega ATMega2560 microcontroller to get the location of the logistic vehicle. That location was then sent to the webserver using GPRS (General Packet Radio Service) Modul SIM800C and displayed on the android application in real-time.
The objective of this system is to monitor the current position, the route needs to be taken, and the distance needs to be travelled by a logistic vehicle. If the vehicle is not moving, or if it travels outside the determined route, the system will give a warning to the user (administrator), so the user can contact the vehicle driver.

Data Transfer and Display
Thinkspeak was used in this study as an open-source of IoT cloud platform application. This application can retrieves and stores the data from the reed switch sensor and GPS through the internet that uses hypertext transfer protocol (HTTP). The data from the sensor and GPS were uploaded from the Arduino board connected to a GPRS module to the cloud. It updates all the data logs received from the sensor and giving the status application to the registered users. With internet-based monitoring, the data would be easily accessible through an online interface (computer or smartphone). An Android application was designed to facilitate users. The aims of this application is to give the users the convenience in the monitoring of logistics vehicle state of door and location to ensure its safety. The application was made using MIT App Inventor with a display shown in Figure 3.

Reed Switch Sensor Calibration
The calibration was carried out to determine the sensitivity of the sensor. The method was to measure the farthest distance between the switch and the magnet when the door was opened. Illustration of the calibration is shown in Figure 4. The distance covered in the calibration was in the range of 0 -6 cm. The data were taken 30 times with a 0.2 cm distance for each data. The results show that the reed switch sensor was only active at a distance below 2.2 cm. Above that, the sensor was inactive or could not give any response.

GPS Ublox NEO-7M Module Calibration
The purpose of this calibration was to find out the reading of the coordinates (latitude and longitude) by the GPS Ublox NEO-7M GPS module. The readings were then compared to the GPS Garmin 62s as the standard measurement instrument. The results from 30 readings show that the mean distance discrepancy between GPS Ublox NEO-7M and GPS Garmin 62s is 16.97 m.

Data Transfer Test
This test was carried out to measured the duration of data transfer from: (a) microcontroller (MC) to Thinkspeak and (b) Thinkspeak to Android application (APP). Each measurement was carried out 30 times in two conditions: (i) open space (simulating the open-free road) and (ii) closed spaced (simulating the road surround by high buildings). The results of these measures are given in Table 1.

Android Warning Test
This test aims to determine the capability of Android application warning system if the logistic vehicle moving further away from the intended route with a distance of more than 500 meters. This test was carried out by first routing the Android application and determined the destination point. Then the Android application will calculate the distance that will be travelled from the initial location to the destination location. After routing, the vehicle travels to the point of destination by taking a route that was located away from the destination location. The results are given in Table 2.  5 The results show that the Android application could only give a warning if the logistic vehicle was located inside 1500 meters away from the destination point. Beyond that point, the warning was not triggered or could not give any response. It may be caused by the faulty distance measurement of the Android application so the warning system became inactive. To overcome this problem, the distance measurement of the Android application should be checked regularly to ensure an accurate reading.

Conclusions
The logistics vehicles security monitoring system consists of an automated locking and tracking system was proposed in this study. GPS system combined with GSM/GPR internet connection method was utilized to provide real-time monitoring using an Android application display. The application was successfully able to execute the automatic locking command within 30.50 s delay. The logistics vehicles location accurate to 16.7 m was pinpointed within 28.72 s delay. To ensure the delivery route was exactly followed, the warning was successfully given when the logistic vehicle was moving away at minimum 500 m from the destination point. Based on these results, the proposed system was considered promising to ensure the safety of the goods inside the logistics vehicle and to locate the position of the logistics vehicle during goods transportation.