Hack 4 Colorado

I just got done with another great weekend of hacking!  This time it was for Hack4CO, which is part of the National Day for Civic Hacking.

I was part of team Peak Badger, which worked on a fun app that allows you to ‘check in’ to peaks at the summit, earning badges and bragging rights.  It was a great weekend with lots of great people, and we took home 3rd place!

Peak Badger Presenting

For this hackathon I worked as a solo programmer on the Android app.   We had a designer on our team, and it was great to collaborate with him to get this clean, polished look.

The main UI consists of 3 pages which can be accessed by swiping the pages or tapping on the tabs.  To achieve this, I created a custom FragmentStatePagerAdapter; each of these three screens is a fragment.  The actionable items on each screen launch new activities to show things like peak details, badge / achievements drill down, social leaderboards , etc.

Screenshot of Peak Badger 1

Screenshot of Peak Badger 2

Screenshot of Peak Badger 3

When you ‘get your badge,’ the app scans a local database of global peaks, to check if you are standing one one.  The data is local, because we wanted this app to work in airplane mode for 2 big reasons.  First off, if you are going on a long hike, it is always a good idea to turn your phone on airplane mode to conserve battery power.  Your phone will be working hard to find a signal, and could be dead when you need it most.  Second, you might not get any service at all in the mountains.  For a viable product it couldn’t be dependent on cell service.  (With airplane mode off, a phone still gets GPS data, so we can still verify a user’s location.)

If you really are standing on a peak, your data is saved and your badges and achievements are updated.    We built out the start of social integration via Facebook, but didn’t have enough time to finish that part.  I was able to pull down some dummy user data from our backend endpoint, and display that in the Android app leaderboards.  With a little time it wouldn’t be too much effort to get Facebook account integration on the Android side.

It was so much fun to work on this app, and I learned a lot, as usual!  Feel free to check out my code here:

https://github.com/peak-badger/android

Yay Hack 4 CO

This entry was posted in Android, Hackathons. Bookmark the permalink.

Leave a Reply

Your email address will not be published. Required fields are marked *