Thursday, April 19, 2012

I forgot to mention, our hockey team (the Rockets) won our division! We're champions of Thursday D2 Men's 30+ hockey! The summer season starts today, but we also get to continue the winter season in the facility championships next weekend. (They should come up with a more exciting name than "facility championships"). There's four D league teams from the various nights that play at York, and we're all in a playoff to go onto the regional playoffs. Every team plays each other, so next week we'll have our regular summer season game on Thursday, then the facility championship games which includes one game on Friday evening, two on Saturday, and then Sunday if we are in the top two teams. Five games in four days! I'll be in good shape after that.

Well I figured out the math for my app. The iPhone accelerometer provides the acceleration along the x-, y- and z-axis. If the iPhone is laying flat, the x- and y- values are 0, and the z- value is 1 (because gravity is pushing down with a force of 1). If the iPhone is static but tilted in various directions, the accelerometer returns the appropriate x- y- and z- co-ordinates. I use the following formula to figure out the angle of the iPhone's plane relative to a world frame:

radians = atanf(z/sqrtf(pow(x, 2) + pow(y, 2)))

The next step is applying a low-pass filter to the readings, there's a lot of noise that I need to average out.

Yesterday MC and Robin dropped by before dinner, they were out taking Corben (their 4-week-old) for a short walk. They looked really rested for new parents. Corben is very cute, with a full head of hair. We chatted for a few minutes, it was good to see them.