OpenCores
URL https://opencores.org/ocsvn/6809_6309_compatible_core/6809_6309_compatible_core/trunk

Subversion Repositories 6809_6309_compatible_core

[/] [6809_6309_compatible_core/] [trunk/] [sim/] [conv_bin_hexlist.py] - Rev 17

Go to most recent revision | Compare with Previous | Blame | View Log

#!/usr/bin/python
import struct
import sys
 
fi = open(sys.argv[1], 'rb')
fo = open(sys.argv[2], 'wt')
fibyte = fi.read()
for i in range(len(fibyte)):
	u = struct.unpack('B', fibyte[i])
	fo.write('{0:02x}\n'.format(u[0]))
 
#close(fi)
#close(fo)
 
 

Go to most recent revision | Compare with Previous | Blame | View Log

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.