William Chops Westfield wrote : > On Friday, Apr 23, 2004, at 03:22 US/Pacific, Jinx wrote: > > >> 1 << GIE = B'10000000' > >> 1 << T0IE= B'00100000' > >> IOR them B'10100000' > > > > Ah, gotcha. So T0IE is representing, in a user-friendly way, 5 > > Yep... > The (1 << bitnum) shift is a standard C hack for converting > bit numbers to masks. (You wouldn't want to do this at runtime, > multiple shifts being rather inefficient. > But there's not reason not to let the compiler do the math at > compile time.) Maybe lack of readability, if you (like me) are not familiar with those "standard C hacks"... Jan-Erik. -- http://www.piclist.com hint: The PICList is archived three different ways. See http://www.piclist.com/#archives for details.