Cemetery Navigation and Information Query System Based on Android and Java Web

. In view of the problems that cemetery location is difficult to find, as well as the congestion of parking lot, this paper design a cemetery navigation and information query system, which can facilitate people's life and strengthen the management of cemeteries. System is mainly composed of three parts: Java Web servers, Android App and acquisition terminal of parking data. The server relies on JFinal framework which can acquire data, handle data, and at the same time, returns a response to users. MAppWidget open source framework is the core of Android App, which is combined with Floyd shortest path algorithm to realize fast navigation. Parking data acquisition terminal’s core is STC12 single chip; it gets information of the parking node from ultrasonic sensor. These data will be post to server, meanwhile users can use Android App to make decisions of which place to park their car.


Introduction
In recent years, aging of the China population has become serious, by the end of 2015, the population of 60 years of age or older has reached 212 million, accounting for 15.5% of the total population.In order to deal with this trend, government department expand cemetery usable floor area, and at the same time strengthen the construction of cemeteries.But it also raises two main questions, the first is people using a lot of time in the process of looking for tomb, because of the bad navigation tips.The location of the tomb becomes more and more disorderly.The second, location of the cemetery is far away from the urban area, most of the people choose to drive there.Management of the parking lot has so much pressure.So many people gather together with cars.It is easy to cause irreversible loss of life and property [1].So a set of navigation, information query, information acquisition system of parking lots is particularly needed.
In addition, this article puts forward the congestion problem solution for parking lot, focuses on letting users know the current status of parking, to ensure that the vehicle does not gather together lead to congestion.

System Introduction
Cemetery navigation and information query system mainly consists of three parts, Java Web information acquisition terminal server, Android App, and parking lot.System structure diagram is shown in figure 1. Java Web server internal using JFinal lightweight framework, its main goal is to simplify the development process, reduce the amount of code, make its code powerful and easy to extend.
Android App uses MAppWidget map framework as its core, with GPS and WIFI technology for fast positioning.MAppWidget is an open source framework.It has so many useful methods that developers can quickly convert an image to an interactive map, especially for android developers.

Server Design
Java Web server is mainly used for receiving the request form the terminal server, after processing data by JFinal framework; server will act as a response is returned to the terminal device.

Server Requirements Analysis
As the data processing of the core of the whole system, server mainly completed the following functions： 1) Process the Android App's navigation request, calculate the shortest path and deal with the data that sent by terminal devices.2) Deal with Android App's requests for parking information.

Server Function Design
 Navigation requests are sent by App in the form of Json.After parsing these Json data, server can get the information of target tombs and current location information of users.Use this information to form a path matrix, and comply with Floyd shortest path algorithm to calculate the shortest path to targets.After that, processed data will be returned to Android terminal device. Android App sends requests for parking space information.After servers receive and check requests successfully, then load data of each node of terminals from database.All data should be checked by JFinal framework's Validator class, and if the data in time with the current server time is more than the required value, then server will mark this node with timeout flag.

Android App Design
Development of Android app depends on MAppWidget open-source map framework; developer can easily customize their own map using methods of this framework [2].

App Demand Analysis
App is a software application running on the user Android device, it mainly realize the following function: 1) Show navigation information.
2) Show parking space information.

App Function Design
 After App submits a navigation request to the server, server will return the shortest path data in the form of Json.Android App marks the route on the map using MAppWidget framework on the basis of the received data [3].Flow chart of the navigation display module is shown in figure 2.

Fig. 2 Navigation display module flow chart
 Parking space information acquisition does not require users to take the initiative to send request, but when user login successfully into the main interface, the App communicates with the server through the WebSocket protocol in real-time.WebSocket protocol is essentially based on TCP protocol, it first launches a special HTTP request after shaking hands to create a TCP connection to exchange data via HTTP or HTTPS, and then the server and the client communicate with each other through the real-time TCP connection [4].

Parking Space Data Acquisition Terminal Design
Parking space data acquisition terminal uses STC12 as its main control chip, and keep capturing ultrasonic sensor data in fixed time as well as uploading these data to the server.Acquisition terminal and server interaction diagram is shown in figure 3.

Fig. 3 Server interaction diagram
Parking space data acquisition module uses STC12A60S2 chip as its processor, running speed, low power consumption, strong anti-jamming capability [5].
Ultrasonic sensor has two parts, one is as transmitter ，another is as receiver.The transmitter launches ultrasonic with same amplitude to detection area, and receivers get the returned ultrasonic.Terminal devices adopted high integration USR -WIFI232 wireless module, and it communicates with the control chip via serial port.WIFI module internal integrates TCP/IP protocol, so the main control chip doesn't need to have TCP/IP protocol.All of parts simplify the design of program greatly and improve development efficiency.

Experimental Results
Experiment is performed in Nantong university innovation laboratory, meanwhile, the Java Web server is running on PC.User can be access to the server daemon through browser.After logining into the server backstage, it will present a map of cemetery.In the map, dot is on behalf of user's current position.Android App is running on the Meizu MX5 Android phone.The five digital identification tag mark paths in order of the sequence of five targets.The sequence is calculated by server using Floyd algorithm, figure 4 illustrates the shortest paths.The experimental chooses 24 nodes, and each module is checked carefully to ensure data accurately.The hasCar property in server database table is initialized to zero.Place hard wood randomly in front of ultrasonic sensors.

Conclusions
The actual test proves that the Android App, server and parking space data acquisition terminal cooperate with each other effectively, the server receives requests from App and data acquisition terminal successfully, in the same time, returns correct response.Ultrasonic sensor in acquisition terminal can capture parking information accurately, and upload data to server via WIFI module; User can query navigation and parking information query by using Android App with the aid of server and acquisition terminal.In view of that the cemetery is difficult to find, and cemetery parking space has problems of management, this article presents cemetery navigation and information query system based on Android and Java Web server, this system has high applied value.

Fig. 4
Fig. 4 Navigation interfaceParking space acquisition terminal connect laboratory internal WIFI network through WIFI module, meanwhile, set the IP address of PC that performs the experimental in lower position machine system.Acquisition terminal can access to server through internal WIFI network.The experimental chooses 24 nodes, and each module is checked carefully to ensure data accurately.The hasCar property in server database table is initialized to zero.Place hard wood randomly in front of ultrasonic sensors.