views:

23

answers:

1

I have an access control solution where the 27 bit format is 13 bits for the facility code and 14 bits for the badge ID. Conversely, I need to convert it into 8 bits for the facility code and 16 bits for the badge ID.

What is the largest number I can convert from on the 27 bit side to get the same result using the 8 bit facility code size? Meaning, if I have 13 bits for the facility code, how many bits can I chop off to still get the same result and an 8 bit size?

+1  A: 

If the facility code is never greater than 255, you can chop off the 5 most significant bits (i.e. keep the 8 least significant ones), without losing information.

cypheon