title: Convert binary string representation of a byte to actual binary value in Python
body: <p>I have a binary string representation of a byte, such as</p>
  
  <pre><code>01010101
  </code></pre>
  
  <p>How can I convert it to a real binary value and write it to a binary file?</p>