I stumbled on the idea when I was sleep deprived and had a Pebble in my hand. How cool would it be to be able to score and track arm wrestling games? The once I finished the watch code I realized that this could be a great social game. By adding the online component it can be competitive with friends and fun for onlookers.

What it does

Wrastle is a score keeper and referee for arm wrestling matches and can additionally display this to an online score board!

The watch component of Wrastle tracks the angle of the player's wrist to track the progress of an arm wrestling match. When either player's arm goes down to the table for at least a second it counts a win for either red or blue, with red being the player wearing the watch if it on their right hand. During the match a progress bar will actively show the how close each player is to a victory with the display shifting colors to red or blue.

The online scoreboard displays the same information as the watch app, namely score and game progress, in a much larger format suitable for onlookers to see a live update of the game progress. This would be fantastic for an event where there are many people watching the match, such as professional tournaments, and not everyone has a clear view of the action itself. The online scoreboard is designed to look good at any size whether it is a friend checking in on their phone, or a projector on the wall.

How I built it

The watch app was built using Pebble's C API, as well as an integrated Javascript component which provides the internet connectivity. When programming I used the CloudPebble editor which is designed specifically for writing watch apps in a constant integration fashion. The Javascript component runs on the users phone if connected over bluetooth and receives information about game progress and score from the watch, which is then forwards to the web server hosting the online scoreboard.

The web application was written with Javascript, using AngularJS and bootstrap for the front end, and to enable the client to recieve score and progress updates from the web server in real time.

Challenges I ran into

  • The first hurdle was to learn the Pebble C API, which is admittedly a little obtuse. It is designed from the ground up to be maximally efficient with the watches resources, so compared to modern GUI frameworks, it provides very little to the user. Things like shapes, position calculations, and brushes all have to be managed by the user.
  • The second challenge was getting a well tuned system of reading an interpreting the accelerometer readings which would accurately tell the progress of the game. I focused on creating a system which would be direct and intuitive while eliminating false positives and negatives.
  • Communication between the web server and client was a new challenge for me, but luckily my friends were able to point me toward, which made it fairly straightforward task.

Accomplishments that I'm proud of

The application was fun a challenging the make, but I am most proud of bringing a little bit of laughter to TAMU Hack. Once I completed the watch app, I had to test it, which meant going around and arm wrestling anyone and everyone. When the judges can by, I would say "I'll show you my app, but we are going to have to arm wrestle" and they would always get a kick out of that. I lost nearly every single match, but I felt like a winner at heart.

What I learned

  • I learned about making graphical interfaces which the fancy frameworks
  • I learned how to integrate applications across components running different languages. In this case it was Javascript and C.
  • I learned about the challenges and solutions to real time web application requiring server to client communication.
  • I learned how to read and filter data from a hardware sensor

What's next for Wrastle

  • Make Wrastle available on the Pebble app store.
  • Make the online application work with many watches at once
  • Host the web application publically
Share this project: