Avoid magic numbers. Use the available defines to set up the bit mask to compare...