Hi All,, How can i declare constant bit fields in a struct ?? struct mystruct{ unsigned char xx:6; unsigned char yy:2; }mystruct; Let us say i want mystruct.yy to be a constant 00, how can i do that ?? mystruct must be a 8-bit datatype. which of its two components xx and yy would be at MSB ?? If anyone can tell how to figure that out it would be great. Thankzz && Bye -Rocknmoon
"Which of the structure members are MSB or LSB you can find out by testing the code." Or you can read the manual You might also want to check these articles: http://www.keil.com/support/docs/928.htm http://www.keil.com/support/docs/1279.htm And this thread: http://www.keil.com/forum/docs/thread1530.asp