Fir_tool 0.5 for 5D/30D/400D and for 1Dm3 -> 7D

  • 0 Replies
  • 4403 Views
Fir_tool 0.5 for 5D/30D/400D and for 1Dm3 -> 7D
« on: 10 / May / 2010, 14:57:09 »
Advertisements
Hi,

Please find attached a open source and free python utility, called 'ofir_tool.py', to parse .fir updates for 5D/30D/400D.

use -c to verify checksums...

Code: [Select]
$ python ofir_tool.py  -c 5d000111.fir
Fir_tool 0.5 for 5D/30D/400D (9May2010)

fileLen = 0x4f6424
---.fir header---
0x000: modelId = 0x80000213, (5D, VxWorks)
0x010: version = 1.1.1
---ciphered part (xor)---
 xor_decoding [0x20-0x4f6424]... OK (0213_111_firmware.bin)
0x020: checksum = 0xe1a7fb7b
 checksum computing [0x0-0x4f6424] is OK!
0x024: updater offset = 0x30
0x028: firmware pack offset = 0x16e4d0
0x02c:  = 0x0
0x030: ---updater---
0x16e4d0: ---firmware---
0x16e4d0: (+0x000) firmware checksum = 0xe9f97565
 checksum computing [0x16e4d4-0x4f6424] is OK!
0x16e4d4: 0x96e4d4 (only with 5D)
0x16e4d8: number of files in the pack = 6
0x16e4dc: offset to the file table = 0x20 (from 0x16e4d0)
0x16e4e0: header size = 0x140 (from 0x16e4d0). end of header = 0x16e610
0x16e4e4: size of file table = 0x120
0x16e4e8: size after table = 0x387e14
0x16e4cc: 0x1 (only with 5D)
0x16e4d0: (+0x020) files table
        +-flags--+-offset-+-length-+--name--------------------------+---??---
0x16e4f0: 0x0002  0x000140 0x000042 MPU_FIRMWARE                     0x0001f4
0x16e520: 0x0002  0x000182 0x0010a0 MPU_FIRMWARE                     0x00047e
0x16e550: 0x0002  0x001222 0x018098 MPU_FIRMWARE                     0x00ae4c
0x16e580: 0x0001  0x0192ba 0x35d8c0 --------                         0xf8010000 0x013880
0x16e5b0: 0x0001  0x376b7a 0x011398 --------                         0xf8780000 0x000172
0x16e5e0: 0x0002  0x387f12 0x000042 MPU_FIRMWARE                     0x0001f4
0x16e610: (+0x140) end of table, first file

other output examples are here:
- 400D 1.1.1 http://chdk.wikia.com/wiki/400D#Firmware_content
- 30D 1.0.6 http://chdk.wikia.com/wiki/30D

for lastest fir update format (from 1Dm3 to 7D), please see this other version 'fir_tool2.py', posted on the Magic Lantern mailing list
http://groups.google.com/group/ml-devel/browse_thread/thread/79f08172a021fae3

Credits (from CHDK among others) are in the code sources or in the companion document:
http://magiclantern.wikia.com/wiki/Firmware_file

Arm.Indy

 

Related Topics