This is the most fun coding I've done in years. Lesson 4 of the Baking Pi ARM OS series has you write your own system wait function based on the Pi's microsecond-precise timer. Such a buzz seeing the LED flash on and off at the right time!
I showed it to my 7 year old who's been playing with and enjoying Scratch programming, and she said 'that is cool!'. This makes me happy.