Inspiration: The recent surge in criminal activity on university grounds inspired our team to develop a solution to tackle student concerns. We aimed to empower students with a tool that would allow them to quickly request for assistance from peers in case of an emergency, fostering a safer atmosphere on campus.

What it does: Our app, SafeSpace, equips users with an emergency button, which when pressed, sends out an SOS to other nearby users to request immediate assistance. In these life-or-death emergency situations, a quick response time is crucial in preventing escalation of the situation. Rather than having to wait for the arrival of 911 services or campus police, students in danger can get assistance promptly from nearby peers. The alert pins the location of the vulnerable student on a map, allowing other students to easily locate and respond to the threat. In addition, a future revision will allow students to see heat maps of criminal occurrences on campus, helping them avoid dangerous areas.

How we built it: We employed Google's Flutter development kit to create the application. Flutter provides developers with a variety of libraries, including the Firebase Messaging API, which we used to send push notifications. When the user launches the app for the first time, we make a POST request to the back-end server and store the device's token. If that user ever uses the button, we identify their location and we make another POST request to the server, providing data that can be used to locate that user. We then make an API call to the firebase messaging API and send a push notification to all nearby devices. These notifications will contain the location, which we then use to pin the location on a map (provided by the Google Maps API). The back-end was developed using Python and a Flask server to handle the POST requests and store the data.

Challenges we faced One of our greatest hurdles was the integration of the Firebase Cloud Messaging API with both our front and back ends. Firstly, sending push notifications to devices through the Firebase API was initially very sluggish, taking up to minutes to send. This rendered the app virtually useless, as users would not be able to get help quickly enough. Thus, we explored alternative means of sending HTTP requests to Firebase from Flutter and ultimately found a way to send alerts instantaneously. Next, ensuring that Flask & Python were well integrated with Firebase was another big hurdle. Despite using the default python requests library correctly and receiving successful codes, Firebase would simply refuse to send push notifications to the Flutter app. After meticulous debugging and exploring, we finally discovered and implemented the firebase_admin library which solved the issue completely.

Accomplishments that we're proud of: We are proud of our implementation of the Google Maps API to provide users with a pinned live location of the student in danger. Requesting students will now be provided with aid quickly and intuitively. This was a difficult and tedious task to undertake. Nevertheless, as one of our team values, we prioritized user safety and usability over all else. All in all, we take the greatest amount of pride in having developed a functional and impactful app that directly addresses the safety concerns of students. By fostering a peer-to-peer support system to fight crimes, we promote security and a sense of community on campus.

What's next for SafeSpace: Firstly, we plan to add a heat map to the app, which highlights the locations of past criminal occurrences. This will deter users from entering a dangerous area of the campus and give valuable insight to campus police, who can further investigate and improve these dangerous hotspots. Indeed, we will work with university authorities and campus security to add more features curated to their respective campus locations. Moreover, in addition to providing users with the victim's latitudinal and longitudinal positions, we will add altitude to better describe their location in buildings, where it may be difficult to discern which floor the victim is on.

Share this project:

Updates