More "fun"

This commit is contained in:
ultramagnus_tcv 2015-07-28 18:55:15 -05:00
parent 157569bb20
commit 186b4f40cf
1 changed files with 5 additions and 3 deletions

View File

@ -6,6 +6,8 @@ try:
finally:
SOSfile.close()
#Slice two bytes
SOSSlice = SOS[0x10:0x11]
SOSstruct = struct.unpack('< H', SOSSlice[0])
# encode file as hexadecimal
SOSHex = SOS.encode('hex_codec')
print SOSHex[0x10:0x14]
SOSstruct = struct.unpack('< f', SOS[0x10:0x14])
print SOSstruct