Table of Contents
DriveCR
Authors
- Aguilar Adrián
- Pérez David
- Sánchez Andrés
- Villalobos Willy
Introduction
People around the world need to move from one place to other for many reasons like work, study, hobbies, etc. There are several roads which they can take to move, and the interconnection between these, induces there are several different routes to reach the same point; sometimes with different conditions, which ultimately can generate significant changes in costs and time you need for traveling.
Following this situation, programmers from different countries have created applications (apps) which can suggest the most convenient roads to be chosen for the user. However these apps have been created based on the needs that these programmers have noticed in their own countries, but not in other regions such as Costa Rica.
That's why DriveCR was born. An app for Android systems1), focused in supplying the Costa Ricans' needs in these aspects, considering the characteristics of the Costa Rican road system.
DriveCR is an app which use Android as operative system (OS) and Python as programming language, creating a social web similar to others like Waze2), but specialized in offering this service to the Costa Rican people. The app uses OpenStreetMaps 3) and MySQL4) as fundamental tools; these are the base of the project.
Objectives
General Objective:
Develope a mobile GPS application for the Costa Rican society which solves the problems that other mobile programs capable of tracing routes, have had since their creation. Also make it with special conditions for its use in Costa Rica
Specific Objectives:
- To develop a data base which stores the information of each user (email address, preferences, level in the app)
- Allow the data base to save information in real time exactly as events happen on the road, and also erase unnecessary information at the same time.
- To develop specific algorithms which allow to optimize the time and the monetary expenditures, by choosing routes, considering each mishap the users report.
- To create an algorithm which regulate the particular cases, as “vehicule restriction” and vehicles' special conditions (for example 4×4 vehicles)
- To obtain connectivity between the terminals which use the app and the server.
- To generate a groupware5) between app's users, which gives them licenses to modify the maps from a specific report of mishaps as traffic jams, car crashes, structural damages; from a rate system based on this kind of reports.
- To generate a graphical user interface (GUI) friendly with the user, starting at PC and next for Android
- To implement a integrate voice system which permits better accessibility for the user
- To permit the report by comments, pictures and videos, encouraging its function as social web.
Implementation
The following flow chart describes the proyect's development process in the different stages. It is an useful way to organize the evolution of the proyect and the assignation of tasks. It also allows for an organized way of developing the app.
- GPS Read: This method give us the posibility of knowing the position according to the GPS in that moment.
- Server: It is in charge of managing the communication between the client and the databases, and the app itself. The code for its implementation can be viewed in the following link:
- Database information management methods: A series of basic methods for retrieving and saving information in the databases were needed in order to ensure the GUI was able to manage the user's information, for signing up, login, etc. The code is in the following link:
- GUI: This kind of apps require a decent graphic user interface, easy to learn how to use and navigate with. Aesthetic appeal is a good extra for making the app attractive to people, but it must be functional a efficient. The code for la GUI is in the next link:
- Route tracing: For this particular and important functionality exists several apps and tutorials, such as pyroute and rana. These programs allow the user to trace a route from current location A to destination B. Currently, rana is replacing pyroute, yet both alternatives work. Rana is particularly useful in mobile devices.
Pyroute documentation here
Rana documentation here
GUI Final aspect
For information on the libraries and programs needed to develop a GUI using Qt and python, check the next link:
Qt development libraries using python
We first have a welcome window or front page, displaying the name and logo of the app. We will have buttons for skipping from the current window to the next or the previous window, both located in the upper corners.
When we click on the arrow that leads us to the next window, the app shows the options of creating a new user or login.
If you already have an user, then you click on the “Iniciar Sesión” button, and displays the next window, where you can input your login information.
Otherwise, you may create a new user. You can input your information manually or register using your facebook, twitter or google+ accounts.
Once we login, the app displays a window with a map obtained from OpenStreetMaps, and below we have options for displaying the current location, mark destination point on the map, and an adjustments button, were you can input additional information like your car model, brand, number of submits, favorite destinations, etc.
The displayed menus for adjustments, navigation adjustments, event report, also have colapse buttons, and allow a simple navigation and access to features without fully blocking the map's visibility.
Manuals and Tutorials
- This manual is used to to establish a connection between your phone and computer, and read your position by GPS localization
- This is a tutorial for MySQL. Used for the data bases