Driv3rs/Beginning.py

14 lines
288 B
Python
Raw Normal View History

2015-07-28 18:46:34 +00:00
import struct
import binascii
SOSfile = open('SOSCFFA.DRIVER', 'rb')
try:
SOS = SOSfile.read()
finally:
SOSfile.close()
2015-07-28 23:55:15 +00:00
# encode file as hexadecimal
SOSHex = SOS.encode('hex_codec')
print SOSHex[0x10:0x14]
SOSstruct = struct.unpack('< f', SOS[0x10:0x14])
print SOSstruct