Introduction
This article describes a procedure for comparing two ECU images. This may be useful to identify differences between a standard ECU and an ECU that that has remapped/tuned. Perhaps you simply want assurance of the changes either you or someone else has made to your ECU image.
RomRaider version 0.5.6 RC1 introduced a graphical image compare option (Image compare updates yet to be released expected in version 0.5.7 RC3 or 0.5.8). This compare tool offers a comparison between two images and works best if these images are of the same vehicle and model year. The RomRaider compare should be used to identify possible differences and is designed to supplement the Hex compare method described below.
The following procedure using three OpenSource or free tools provides a workable hex compare alternative.
In summary the following procedure involves using a command line tool called 'od' to convert your two ECU images to a human readable hex dump ASCII text files. These text files can be colourfully compared using WinMerge to identify differences and then ecuECU can be used for a graphical visualisation.
Prerequisites
You need the following software installed:
- 'od' command line tool available for any platform you require. For Microsoft Windows users the author has packaged cygwin's version of the 'od' tool along with the required dlls: Attach:standalone_od_tool.zip. Extract this archive anywhere e.g. C:\od_tool
- download and install WinMerge
- download and install ecuEdit
Produce HEX dump
Convert your two ECU images to a human readable hex dump ASCII text files as follows:
- Bring up a DOS Command Window
- Change directory to the place you installed the 'od' tools e.g.
cd c:\od_tool
- In the following two commands replace 'my_ecu_file' with the name of your ECU image files:
- Run
od -A x -t x1 -v M my_ecu_file1.hex > my_ecu_file1_hex_dump.txt
- Run
od -A x -t x1 -v M my_ecu_file2.hex > my_ecu_file2_hex_dump.txt
You now have two text files which look something like this:
000000 02 20 02 20 08 f6 00 00 02 40 02 40 02 52 02 40
000010 02 64 02 40 02 40 02 40 02 40 02 40 02 40 02 40
000020 02 40 02 76 02 88 02 9a 02 ac 02 be 02 d0 02 e2
000030 02 40 02 40 02 40 02 40 02 40 02 40 02 40 02 40
000040 02 40 02 40 02 40 02 40 02 40 02 40 02 40 02 40
000050 02 40 02 40 02 40 02 40 02 40 02 40 02 40 02 40
000060 02 40 02 40 02 40 02 40 02 40 02 40 02 40 02 40
000070 02 40 02 40 02 40 02 40 03 9e 03 b0 03 c2 02 40
In the above example the hex bytes are shown in human readable text, the first column is the address of the remaining elements on each row.
Compare text files
These text files can be colourfully compared using WinMerge to identify differences. An example is illustrated below:
Comparing ECU dumps using WinMerge
Use the 'Next Diff' button on the toolbar to step through each difference found.
Graphical Visualisation
This section assumes you are already familiar with the ecuEdit tool and have configured it to identify your ECU maps. By loading both ECU images in to the ecuEdit tool, you can navigate to the hex address of a difference, identified above, using the HEX Viewer tool. ecuEdit will then illustrate what software map has been changed, which can be subsequently graphically visualised as in the illustration below.
Graphical Comparison of Desired Boost Maps Using ecuEdit
Related Articles