Skip to Main Content

New to Java

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

Extract bits from byte array

807598Jun 26 2006 — edited Jun 26 2006
Hello,

I have an array of 48 byte that will correspond to 48 different registers. Each register has different fields (eg. register1 has 1 field of 2 bits, and another field of 6 bits, register2 is composed of 1 2-bit field and 6 1-bit fields.)

How can I parse the byte array and extract the bits corresponding to the different fields (and field lengths)

Any suggestions are greatly appreciated.
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Jul 24 2006
Added on Jun 26 2006
4 comments
443 views