grasshopper
03-20-2009, 09:58 PM
If I have 8 bytes and all I am interested in is the last bit of each how would I put that all the bits in another byte. For example
Var
Byte X1,X2,X3,X4,X5,X6,X7,X8 ,Total
X1 := %0001
x2 := %0000
x3 := %0001
X4 := %0001
x5 := %0000
x6 := %0001
X7 := %0001
x8 := %0001
Total would equal %10110111
Could I bit shift and OR them some how?
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Visit my site -> www.rawcircuits.com (Http://www.rawcircuits.com)
Post Edited (grasshopper) : 3/20/2009 4:24:07 PM GMT
Var
Byte X1,X2,X3,X4,X5,X6,X7,X8 ,Total
X1 := %0001
x2 := %0000
x3 := %0001
X4 := %0001
x5 := %0000
x6 := %0001
X7 := %0001
x8 := %0001
Total would equal %10110111
Could I bit shift and OR them some how?
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Visit my site -> www.rawcircuits.com (Http://www.rawcircuits.com)
Post Edited (grasshopper) : 3/20/2009 4:24:07 PM GMT