Email: Password: Remember Me | Create Account (Free)

Back to Subject List

Old thread has been locked -- no new posts accepted in this thread
???
08/31/04 22:37
Read: times


 
#76706 - RE: how to manipulate 10 bits on 8 bits
Responding to: ???'s previous message
Adolfo Gonzalez Rodriguez said:
how to manipulate a 11 bits into 8 bits registers ... in C ...?

Obviously, you cannot squeeze 11 bits into an 8-bit register; if they won't fit into one register, the next step is, obviously, to use two:

Craig Steiner said:
writing it in 'C' why don't you just declare the variable as an integer (2 bytes) and let the compiler take care of it?

You might have to handle the sign-extension yourself when you first load the 11-bit value into your 'C' signed int, but thereafter the compiler will do it all for you.


List of 6 messages in thread
TopicAuthorDate
how to manipulate 10 bits on 8 bits            01/01/70 00:00      
   RE: how to manipulate 10 bits on 8 bits            01/01/70 00:00      
   RE: how to manipulate 10 bits on 8 bits            01/01/70 00:00      
      RE: how to manipulate 10 bits on 8 bits            01/01/70 00:00      
   RE: how to manipulate 10 bits on 8 bits            01/01/70 00:00      
      RE: how to manipulate 10 bits on 8 bits            01/01/70 00:00      

Back to Subject List