A great example exists in [this thread](http://forums.parallax.com/discussion/162603/bit-priority-in-c)