08 Dec 2016
courses, documentation, pcomp
For the pcomp final, Jaycee and I building a multi-player version of the classic game snake, where each player's snake is moved by player's body around the table. The most challenging part of the project has been finding the right sensor. We were told to focus on the game design and that the sensors would be the easy part, but apparently indoor sub-meter position tracking is a very challenging problem, at least on a graduate student's budget.
We experiemented with various sensors but none of them solved all of the problems of our game design. I played with the Flora's magnetometer for a while, which seemed promising because it could track position and depth.
The above image is the magnetometer's x and y axis readings as a walked in a circle around the table. This seemed promising because it was detecting a clear pattern. However, after more teseting, the magnetometer was not reliable enough for our uses. For example, if you stand in one place and move the magnet (i.e. the attract and repel sides) then the magnetometer picks up significantly different data, as if you were jumping across the table.
After consulting with several people on and off the floor, we decided to try the Kinect. Fellow student Lisa Jamhoury created a great library for working with the Kinect 2 and helped us get started using Kinect for skeleton tracking. This seems to do everything we needs the sensor to do, although we still have some finess work to do to get cleaner data. Here's a recent version of play testing:
Since we're using the ER's Kinect instead an elaborate combination of sensors, our bill of materials has been greatly simplified
1 circular table, approx. 36" diameter (tables in commons area are perfect)
Projector with 12' HDMI cable (ER)
Windows laptop with p5 (ER)
Kinect 2 (ER)
2 projector arms, 1 for Kinect and 1 for projector (ER)
Our system diagram looks like: