]> cvs.zerfleddert.de Git - proxmark3-svn/blame - tools/merge-srec.pl
part of readmem function
[proxmark3-svn] / tools / merge-srec.pl
CommitLineData
30f2a7d3 1# merge the code that initially executes out of flash with the RAM image\r
2\r
3($flashFile, $ramFile) = @ARGV;\r
4\r
5open(FLASH, $flashFile) or die "$flashFile: $!\n";\r
6\r
7while(<FLASH>) {\r
8 print if /^S3/;\r
9}\r
10\r
11open(RAM, $ramFile) or die "$ramFile: $!\n";\r
12\r
13while(<RAM>) {\r
14 if(/^S3(..)(........)(.*)/) {\r
15 $addr = sprintf('%08X', hex($2) - 0x00200000 + 0x200);\r
16 print "S3$1$addr$3\n";\r
17 }\r
18}\r
Impressum, Datenschutz