Possible Duplicate:
How to write individual bits to a text file in python?
I have been searching, trying to find a way to simply read and write bits to/from a file. Most of the things I have found have just showed ways to convert characters to binary. such as:
>>> byte = 'a'
>>> byte = ord(byte)
>>> byte = bin(byte)
>>> print byte
'0b1100001'
This isn't what I want. I am looking to manipulate the actual binary in the file. I dont want to use extra modules, just standard python 2.7. Any help would be appreciated.