Short Paper—Smartphone-Based Sensing for Intelligent Inland Waterway Transportation Smartphone-Based Sensing for Intelligent Inland Waterway Transportation

In this paper, we present an Android application, namely BoatSafe, which offers easy and effective navigation of waterways. The data were collected directly from both GPS and the accelerometer sensor, and then these data were processed to determine the user's "Sailing on Water" status through the motions and the position. The software offers some essential features such as: provide the positions, velocities, and heading angle of vehicles at present; save the route for a specific period time; identify the outage of GPS signal; collision warning feature, identify a collision, and call a pre-selected phone number in the event of a collision. Keywords—Inland Waterway Transport (IWT), Global Positioning System (GPS), Android


Introduction
Vietnam has about 2,360 rivers and canals with a total length of 220,000 km. The State of Vietnam manages 65 waterways in the North, 21 waterways in the Central, and 101 waterways in the South. Inland waterway transport plays an essential role in the operation of Vietnam's economy, which is endowed with two large deltas [1].
In Vietnam, actual water transport is mixed, overlapping traffic between maritime, inland waterways, and many types of vehicles circulating on the river. While domestic and foreign ships are always fully equipped with support systems as prescribed by the Vietnam Maritime Code and the International Maritime Organization (IMO) etc, most types of Inland waterway facilities of Vietnam are not yet fully equipped. Notably, the small type of experimental vehicles mainly operates the ship using the traditional method, based on the operator's experience. If weather factors are taken into account, for Inland Waterway Transport (IWT) vehicles operating along the coast, the route to the island and the routes connecting the islands will still have a high risk of accidents without support systems.
Currently, to locate ships/boats, the device is mainly satellite (GPS is the most popular) [2]. In adverse weather conditions, the GPS signal is often weak, and even the loss of GPS signal causes the navigation process to be interrupted. One more of the solutions is to use the inertial navigation system (INS). The INS have two outstanding advantages compared to other navigation systems: 1) its ability to operate autonomously and 2) high accuracy in a short period. The combination of GPS and INS is best because the INS will support GPS very effectively [6].
Smartphones have become very popular in recent years. Initially, smartphones included the features of conventional mobile phones combined with other popular devices such as GPS, magnetic compass sensor, and inertial sensor already built into the machine. In Vietnam, the monitoring of waterways is mostly based on commercial GPS devices [2][3][4]. Position monitoring of the IWT boat/vessel is essential for the management and administration. Large boats/vessels nowadays have to have electric or magnetic compasses, or both, to show the direction of the train. For phone development, there are Google Maps (for all applications -not just inland waterways) and some other applications (primarily using GPS and magnetic sensors). In this paper, we proposed to use smartphones as a device that integrates navigation, journey monitoring, velocity determination, driving directions for inland watercraft, serving the management of these boats/vessels.

Signal acquisition and status classification
The characteristics of moving on waterways are much different from moving on land. Therefore, for users' convenience, we proposed an algorithm to classify the status of equipment users whether they are on waterway transport or not. The flow chart of the algorithm is shown in Figure 1. It is a type of Supervised Machine Learning [8] where the data is continuously split according to a specific parameter. Firstly, we use the Elevation service, which provides elevation information for locations on the surface of the earth, including depth locations on the ocean floor. In the cases that Google cannot possess exact elevation measurements at the precise location, which is requested, the Elevation service will interpolate and provide an average value using the four nearest locations. The Elevation Service object communicates with the Google Maps API Elevation Service, which receives elevation requests and returns elevation data.
The raw data stream from the accelerometers is the acceleration of each axis X, Y, Z in the units of g-force [10]. After that, we pre-process these data before performing any further statistical computations. One purpose of the data pre-processing is to reduce the noise from the sensors. The root mean square (RMS) of the acceleration Ad is an excellent candidate to discriminate between behaviors with high dynamic and low dynamic movements. If the value of Ad is higher than a threshold (denoted by Thresh-old_Ad), the user's status is assigned as "Sailing on Water". Consequently, a series of tasks will be executed, such as provide the positions, velocities, and heading angle of vehicles at present. It also saves the route for a specific period, identifies the outage of GPS signal, collision warning feature, identifies a collision, and calls a pre-selected phone number in the event of a collision. Fig. 1. Flow chart of recognizing the status "Sailing on Water". In case that the user is in water (i.e., on boat, ship, vessel, etc.), the acceleration data are needed.

Collision warning
In this work, the phone's acceleration data will be collected and processed to identify collisions that occur when compared to a preset threshold Threshold_Bd. Acceleration is known to represent a change of velocity. When there is a collision, the velocity will decrease rapidly to zero. When the acceleration information notifies the state of the collision of the ship, the software will check previous states to see whether it is on sailing to avoid false alarms. False alarms can be the cases when the phone is on the table suddenly dropped to the ground, or the phone is in the user's pocket while jogging, falling, etc. When detecting signs of an accident, a warning dialogue box will appear for users to confirm the actual situation. After 60 seconds, if there is no confirmation from the user, the software will treat it as an accident and will automatically call relatives to be able to support promptly. In the future, anti-collision algorithms should be concerned to integrate into our application [12].

Results
Currently, our software is available on the Google Play store (see Fig. 2). Users need to allow the software to access the phone book, built-in sensors, GPS, etc. (see Fig. 3).

Fig. 2.
Our software can be downloaded from Google Play store at https://play.google.com/store/apps/details?id=vnu.uet.boatsafe Fig. 3. Our software needs to access some resources.
As shown in Fig. 1, our application was able to use the location information and vibration data to determine whether the vehicle circulates on the waterway, as shown in Fig. 4.  The information of positions and velocities of the ship on the smartphone screen is shown in Figure 5. If the user saves the sailing history, he or she can draw the previous trajectory of the ship (shown in Figure 6). It would be useful for management.
In case of an accident, the absolute acceleration excessed the collision threshold. Consequently, a warning message will appear in the confirmation from the user. If the "I'm OK" button is pressed, the warning message will disappear. After 60 seconds, if there is no confirmation from the user, the software will treat it as an accident and will automatically call relatives to be able to support promptly.

Conclusion
Even though the BoatSafe application is made public, it is still in the development phase. There some features that need to be improved and added in future such as: 1) improve the accuracy of estimation algorithms of positions and velocities; 2) develop on other operating systems such as iOS, Window Phone, etc; 3) empirically verify collision warning; 4) predict the trajectory when the GPS connection lost in a certain of time. BoatSafe is a good example of cutting-edge mobile technologies that can be implemented in almost every aspect of our lives [13]. and conference proceedings. He served as a TPC member, session chair and reviewer of international conferences and journals.
Duc-Tan Tran is an Associate professor and Vice Dean of Faculty of Electrical and Electronic Engineering, Phenikaa University. He has published over 150 research papers. His publications received the "Best Paper Award" at the 9th International Conference on Multimedia and Ubiquitous Engineering (MUE-15), and International Conference on Green and Human Information Technology (ICGHIT-2015). He was the recipient of the award for the excellent young researcher from Vietnam National University in 2008, Hanoi and the third prize in the contest "Vietnamese Talents" in 2008. His main research interests include the representation, processing, analysis, and communication of information embedded in signals and datasets. He serves as a TP Co-chair, technical committee program member, track chair, session chair and reviewer of many international conferences and journals.