Key Takeaways
- Location-based services (LBS) determine a mobile device’s geographical location via mobile networks for multiple uses, including for social networking. LBS is a common class of computer program that uses data location to develop different service features.
- Finding someone’s location can be challenging during an emergency. Moreover, it is difficult to determine the location of an object such as a car in a parking lot if you forget where you’ve parked it. The Danger Notification and User Navigation (DNUN) mobile application lets users effectively locate a human or object.
- The DNUN application allows users to add, delete, or update contacts who, in the event of an emergency, could track their location in Google Maps using geo-finder APIs. Contacts can also track a user’s route and total distance away, and hence navigate to that user. Another essential feature, Finding an Object, is available via the geo-finder APIs in Google Maps; this feature can store the latitudinal and longitudinal positions of an object, such as a parked car, for future use.
- DNUN can be used for commercial LBS, including locating patients in a hospital, locating soldiers, policemen, and fire fighters in case of an emergency, etc.
This article first appeared in IEEE IT Professional magazine. IEEE IT Professional offers solid, peer-reviewed information about today's strategic technology issues. To meet the challenges of running reliable, flexible enterprises, IT managers and technical leads rely on IT Pro for state-of-the-art solutions.
Geolocation is the process of identifying a person or object's geographical position1,2. Location-based services (LBS) determine a mobile device's geographical location via mobile networks for multiple uses, including for social networking. LBS is a common class of computer program that uses data location to develop different service features.
Throughout history, humans have developed technologies for determining location and for navigation. "Smoke signals" are an old method that ancient Chinese, Greeks, and Native Americans used to communicate over long distances and to navigate through wide deserts and across the sea3. Early navigation aids, such as the magnetic compass and the kamal4, were used on ships to determine directions while traveling not only through small rivers but also over entire oceans. However, for several centuries, such devices were costly and were available only to those who held economic power. Today, many different types of technologies let us obtain location information, including GPS5, IP addressing, the Global System for Mobile Communications (GSM) and code division multiple access (CDMA) cell phone IDs6, Wi-Fi and Bluetooth MAC addresses7,8, and user input.
Mobile applications are growing in quantity and quality; for example, the Yelp mobile application was an early location-aware communication technology9. Network providers such as T-Mobile, Verizon Wireless, and AT&T offer geolocation application services for their devices. Furthermore, these devices' operating systems (iOS, Android, RIM, and so on) enable software designers to develop various applications using software development kits (SDKs). This has led to an obvious evolution in LBS, with applications such as Foursquare, Yelp, Glympse, and so on.
However, finding someone's location can be challenging during an emergency. Moreover, it is difficult to determine the location of an object such as a car in a parking lot if you forget where you've parked it. Our Danger Notification and User Navigation (DNUN) mobile application lets users effectively locate a human or object.
Methodology
The DNUN application opens on a login page with fields such as log in, sign up for new users, and forgot password. Once logged in, users are redirected to the application's homepage. To enable better security, all emergency notification services are available via the DNUN homepage. Users can add, delete, or update contacts who, in the event of an emergency, could track their location in Google Maps using geo-finder APIs. Contacts can also track a user's route and total distance away, and hence navigate to that user. Another essential feature, Finding an Object, is available via the geo-finder APIs in Google Maps; this feature can store the latitudinal and longitudinal positions of an object, such as a parked car, for future use.
The software design process starts with the analysis phase and ends at the product testing phase for further development. This design process specifies how applications will interact with their environment and users. During architectural design, application development might need to be based on particular design models, including dataflow diagrams (DFD), model-view-controller (MVC), and UML.
A DFD, sometimes known as a bubble chart, is implemented as a graphical representation. It illustrates various stages of the development process, from data input, to the execution of different processing elements on the data, to the data output the system produces10. To respond to user requests, DNUN is associated with a database that stores user data such as contacts and danger notifications. Depending on the user request, the application communicates with the database.
UML is well-known to software designers; it is used for object modeling, and documenting class diagrams and other diagrams. Native applications are coded using Android and iOS SDKs. Mobile web applications are accessed using Internet browsers such as Safari on iOS or Chrome on Android. Projects such as Apache Cordova11 contribute to application building using web technologies that are compiled into a wrapper, creating a hybrid application such as DNUN.
Mobile application development can also be done with Ruby on Rails12,13, which DNUN uses for backend processing along with the PostgreSQL database. Ruby on Rails is an open source web application framework coded in Ruby. It employs the MVC pattern to organize application programming. Ruby creates DNUN with all required resources and available libraries, called Ruby Gems. These Gems are well-built, and developing a mobile application such as DNUN using Ruby on Rails is efficient and easier than using other web application frameworks.
A class diagram shows a set of classes, interfaces, and collaborations and their relationships in DNUN. The class diagram is the key building block of object-oriented modeling. We mainly use it for detailed modeling to translate models into our application programming code. The DNUN application has four main classes: EmergencyDetail
, User
, DangerNotification
, and MyLocation
.
The EmergencyDetail
class gives users the option to save some contacts to whom they can send a danger notification if they are in an emergency situation. This class has attributes such as name, email, phone_no_1, and phone_no_2, and methods such as addContact() to add a new contact, updateContact() to update previously added contacts, deleteContact() to delete the selected contact, and showContacts() to view a list of all contacts added by the user.
The User
class represents the application's user. Each object in this class will be associated with all the other classes. User has attributes such as first_name, last_name, contact_number, email, password, and so on, and methods such as addUser() to create a new user, addPassword() to create a secure password for the newly created user, createSession() to maintain the user's sessions once he or she logs into the application, and destroySession() to destroy the session once the user logs out of the application.
The DangerNotification
class does the work of creating a danger notification and sending it to one or more selected contacts through email. This class has attributes such as user_id, receiver_id, message, address, latitude, and longitude. Methods include addNotification() to create a new notification, updateNotification() to update an added notification, deleteNotification() to delete a selected notification, showNotifications() to view the list of all the user's notifications, navigate() to navigate to a location in the notification, and sendNotification() to send a notification to one or more contacts through email.
The MyLocation
class is useful for saving user locations. It is associated with the User class, and has attributes such as user_id, name, desc (description), latitude, and longitude to represent location. Methods include addLocation() to add a new location (the user's current one), updateLocation(), which updates previously added locations when users enter them again, deleteLocation() to delete a saved location, showLocations() to show the list of all locations that the user has saved, and navigate() to navigate from the current location to a selected saved location.
We next look more closely at the DangerNotification
and MyLocation
classes as the two primary features the DNUN application provides.
DangerNotification Page
Danger notification is one of the main relevant features of DNUN; it allows users to send their current location with just a single click of a button to one or more added contacts registered during the EmergencyDetail
phase. When the user clicks send, geolocation will track his or her current position and send the notification along with an email to other users, who can then respond to the help request.
When an individual is in danger, he or she can click on the Locations tab, shown in Figure 1, to detect and display his or her position via Google Maps. The user can then send a danger notification, as shown in Figure 1. The user can send this notification through either broadcast or multicast communications, as shown in Figure 2. Users can tick separate selected contacts (multicast) or all of them (broadcast). Once the user clicks the send button, an email will be sent to the intended contacts notifying them that a friend (user) is in danger. This email is accompanied by the user's exact location.
Figure 1. Creating danger notifications. The user's location is displayed via Google Maps, and the message is sent to the user's emergency contacts.
Figure 2. Sending notifications. Users can send notifications to select individual contacts (multicast) or choose all contacts (broadcast).
MyLocation Page
Object positioning is the second main function of the DNUN application; it allows a user to store the location of a particular object and thus save that location for later navigation. Whenever needed, the user can find the object with just a single click using Google Maps.
Users can add and store their current location or the position of one or more objects, such as a vehicle in a parking lot, by clicking on the Add Location button. Figure 3 depicts the application's Add Location feature. The user's current location is determined, and a page is displayed so that the user can save his or her location using the following fields: Name the Location lets the user name the location of the stored object, and Note for Your Location lets the user make notes about the object and its location. Later, when the user needs to retrieve the object location, he or she clicks View Map, and DNUN will open the location in Google Maps, as shown in Figure 4. Moreover, to navigate to a saved location or object, users can click Navigate (see Figure 4) and the map will show the route along with navigation directions.
Figure 3. The My Locations page. Users can add and store their own location as well as that of objects, such as a car in a parking lot.
Figure 4. The Open Location in Map page. When users need to retrieve an object location, they can click View Map, and the application will show the object's location via Google Maps. By clicking Navigate, the user can receive a route and directions.
Discussion and Analysis
It's well known that smartphones have altered our daily lives, most likely in a positive way. Geolocation is one of the most beneficial application areas for smartphone technology. Most of today's smartphones come with hardware and software geolocation components, allowing for location tracking. LBS assists the GPS component in locating devices with different operating systems, such as Android or iOS. Geolocation technologies are gaining importance in wireless products for many reasons, in particular, the US Federal Communication Commission's mandate requiring that all wireless cellular carriers be able to provide the location of emergency 911 callers to a public safety answering point (PSAP).
However, geolocation technology has also proved to be significant for both military and commercial applications in general beyond emergency location14; this, in turn, is the motivation for our DNUN application. The use of wireless devices such as cell phones, PDAs, and laptops has enabled viable LBS and applications that need position location information. DNUN can be used for commercial LBS, including
- locating patients in a timely fashion in hospitals;
- locating individuals for personal and residential applications; and
- concierge and location-aware services (such as locating the nearest coffee shop; helping those new to a city to find a stored location, such as a library; finding a vehicle in a crowded mall or university parking lot; helping new students locate classrooms; and providing information about exhibits in museums based on the customer's location).
In the military and public sectors, enabling soldiers, policemen, and fire fighters with location-based knowledge-both their own and that of other personnel, victims, individuals in danger, and so on-could prove to be invaluable. GPS has been the most significant and successful positioning technique for outdoor areas, and it is generally understood that the GPS receiver is an inexpensive, commonplace gadget13.
One key feature of DNUN is its ability to allow an individual in danger to send a notification to more than one helper through selected contacts (multicast) or all contacts (broadcast) depending on the case and need. This gives the individual more flexibility to move within the danger area because multiple helpers can respond over a wider range. Further, having several contacts would clearly be useful in case only a few rescuers are available at any given time. Those rescuers who are geographically closer could respond quicker than others.
On the other hand, rescuers who are far away could contact people not on the notification list or contact those on the notification list but away from email via phone or pager. An individual who moves substantially from his or her current location might need to send a location update notification. However, to minimize effort for the person in danger, DNUN can be paired with a mobile application that runs in the background, such as GPS Phone Tracker Pro or Mobile Location Tracker on Google Play, which enables location tracking in case the individual moves but cannot send a notification update. Having a function to help users filter informed people by location or even skills is an option that can be added to DNUN.
The DNUN mobile application can help rescue a user by sending an email with a danger notification to intended contacts. These contacts can be added, updated, or deleted by DNUN as part of the user's social network. Consequently, DNUN integrates mobile sensors and social networks as a rescue plan that can be used in military and commercial applications. Combining social media, geographic location services, and a mapping system like DNUN is a useful application for smartphone users. DNUN also provides another function in helping the user navigate to a previously saved location from anywhere.
This kind of software solution eliminates the cost of hardware installation. DNUN can successfully incorporate all the requirements specified for creating a mobile application using Apache Cordova and Ruby on Rails.
References
1. D. Ionescu, "Geolocation 101: How It Works, the Apps, and Your Privacy", PC World, 29 Mar. 2010.
2. K.F. King, "Geolocation and Federalism on the Internet: Cutting Internet Gambling's Gordian Knot", Columbia Science and Tech. Law Rev., July 2010.
3. M.H. Ammar and G.C. Polyzos, "Guest Editorial: Network Support for Multipoint Communication", IEEE J. Selected Areas in Comm., vol. 15, no. 3, 1997, pp. 273-276.
4. J.M.M. Pereira, "The Stellar Compass and the Kamal-An Interpretation of Its Practical Use", Proc. Int'l Seminar Marine Archaeology, 2003, pp. 21-29.
5. J. Parthasarathy, "Positioning and Navigation System Using GPS", Int'l Archives of Photogrammetry, Remote Sensing, and Spatial Information Science, vol. XXXVI, part 6, 2006.
6. S. Hara and R. Prasad, "Overview of Multicarrier CDMA", IEEE Comm. Magazine, 1997, pp. 126–129.
7. I. Koeppel, What Are Location Services? From a GIS Perspective, white paper, ESRI, 2000.
8. K. Pahlaven and P. Krishna Murthy, Principles of Wireless Networks: A Unified Approach, Prentice Hall, 2001.
9. R. Want, "iPhone: Smarter than the Average Phone", IEEE Pervasive Computing, vol. 9, no. 3, 2010, pp. 6–9.
10. "Lesson 10: Data Flow Diagrams (DFDs)", Module 5: Function-Oriented Software Design, Version 2 CSE IIT, Kharagpur.
11. J.M. Wargo, Apache Cordova 3 Programming, Addison-Wesley Professional, 2013.
12. B.A. Tate and C. Hibbs, Ruby on Rails: Up and Running, O'Reilly Media, 2006.
13. R. Borup, "An Introduction to Ruby on Rails", Proc. Southwest Fox Conf., 2010, pp. 50–55.
14. K. Pahlavan and P. Krishnamurthy, Networking Fundamentals: Wide, Local, and Personal Area Communications, Wiley, 2009.
About the Authors
Karthik Reddy Nalla received an MSc in computer science from Lakehead University, Canada. His interests are in software applications and data analysis (big data). Contact him here.
Hosam El-Ocla is an associate professor in the computer science department at Lakehead University, Canada. His research interests include computer communications, networks, and mobile applications development. El-Ocla was previously a technical committee member on telecommunications for the International Association of Science and Technology for Development (IASTED) and is currently a technical committee member on antennas, radar, and wave propagation for IASTED. He received a PhD in computer science and communication engineering from Kyushu University. He is a senior member of IEEE. Contact him here.
This article first appeared in IEEE IT Professional magazine. IEEE IT Professional offers solid, peer-reviewed information about today's strategic technology issues. To meet the challenges of running reliable, flexible enterprises, IT managers and technical leads rely on IT Pro for state-of-the-art solutions.