bit manipulation - Retain Data from 27 bit to 19 bit conversion -


i have access control solution 27 bit format 13 bits facility code , 14 bits badge id. conversely, need convert 8 bits facility code , 16 bits badge id.

what largest number can convert on 27 bit side same result using 8 bit facility code size? meaning, if have 13 bits facility code, how many bits can chop off still same result , 8 bit size?

if facility code never greater 255, can chop off 5 significant bits (i.e. keep 8 least significant ones), without losing information.


Comments

Popular posts from this blog

windows - Why does Vista not allow creation of shortcuts to "Programs" on a NonAdmin account? Not supposed to install apps from NonAdmin account? -

c++ - How do I get a multi line tooltip in MFC -

unit testing - How to mock PreferenceManager in Android? -