title: vb.net - hex, bitwise question
body: <p>I'm trying to figure out how to calculate the lower 7 bits and 7-13 bits of two hex numbers.</p>
  
  <p>Here is some example c code, just need this in vb.net:</p>
  
  <pre><code>serialBytes[2] = 0x64 &amp; 0x7F; // Second byte holds the lower 7 bits of target.
  serialBytes[3] = (0x64 &gt;&gt; 7) &amp; 0x7F;   // Third data byte holds the bits 7-13 of target
  </code></pre>
  
  <p>The 0x7F is a constant so the only number that changes based off input is the 0x64.</p>
  
  <p>Can someone help me out?</p>