833339e1c6
Some compiler is brain-damaged that it will yeild a warning for headers not ended with a newline. Yes, I mean you, Keil.
15 lines
225 B
Python
15 lines
225 B
Python
#!/bin/env python
|
|
|
|
import sys
|
|
|
|
fi = open(sys.argv[1], 'rb')
|
|
fo = open(sys.argv[2], 'wb')
|
|
|
|
idx = 0
|
|
for i in fi.read():
|
|
idx += 1
|
|
fo.write('0x%02x, ' % ord(i))
|
|
if idx % 16 == 0:
|
|
fo.write('\n')
|
|
fo.write('\n')
|