Inspiration

Lockyroad is inspired by the critical issue of accidents caused by distracted driving, especially those that are a result of texting or calling while driving. In the United States, nine people are killed every day, and one in every four accidents involve the use of a cell phone. We realized that with today's technology making it easier to make sense of the physical world with software, these deaths can be prevented with an app for phones.

What it does

Lockyroad is an app that solves the epidemic of distracted driving by using existing or aftermarket Bluetooth accessories to determine if the vehicle is in motion and whether or not the user of the phone is the driver. Rather than disabling touch for any passenger of a vehicle, the app is able to sense how close the user is to the driving console or another Bluetooth-enabled accessory to determine if it is in fact the driver. When both of these conditions are fulfilled, the app disables touch for the user until the app recognizes that the user is no longer in vehicular motion.

How I built it

We built Lockyroad for both iOS and Android to connect with a Myo armband to simulate a Bluetooth car console or a Bluetooth-enabled keychain on the keys of the vehicle. It uses new Bluetooth 4.0 technologies to get a measurement from the Myo called RSSI, or received signal strength indication. To determine whether the vehicle was in motion or not on Android, we used geolocation API's to calculate the velocity of the user's position over an interval of time. On iOS, we tapped into CoreMotion and the newer iPhone motion co-processors that analyze the user's speed and gyroscope data to differentiate vehicular motion from other motion (like walking, running, etc).

Challenges I ran into

In order to make Lockyroad compatible with as much technology we could, we developed the iOS version as a framework that allows developers to drag-and-drop car safety into their app. The implementation is only two lines of code for app developers, and we were able to test this with open source apps such as Wikipedia. When we initially thought of this, we did not realize how difficult it would be to adapt to every situation of view controllers, such as game layers or custom views. We were able to in the end work out a number of hacky but creative solutions that enabled us to make it compatible with a game, a utility, and a messaging app. It also proved to be a challenge to connect to the Myo and obtain the statistics we needed with the precision and rate that we required, especially with our limited resources. We pulled it off with an iPhone 5s (bare minimum hardware requirement for the project) and an MLH Amazon Fire Phone (which is now running Cyanogen Mod 11).

What I learned

Being a prolific JavaScript developer most recently, "re-teaching" myself Objective-C was an excellent exercise for me and has made me excited to pursue native projects in the near future. As for Albert, he took an AP Computer Science-level understanding of Java and in just 36 hours taught himself how to create Android applications and connect them to a number of high-level native API's - for a phone with relatively scarce documentation.

What's next for Lockyroad

Lockyroad was originally meant to be an Arduino-powered hack, and we have ambitions to create hardware for it in the future to make it a custom solution that can be attached to keychains and even sold in the future. We also are actively looking into ways of authenticating different users and managing different driving situations and use cases.

Built With

Share this project:

Updates