Pages: [1]
Author Topic: Universal Patcher - new open source tuning tool  (Read 11827 times)
kur4o
Newbie
*

Karma: +5/-7
Offline Offline

Posts: 13


« on: September 24, 2021, 04:36:09 AM »

Hi to all at Nefmoto

I present you some new tuning tool, developed as open source for all the tuning guys out there.
It is called

Universal Patcher

the name doesn`t represent the current capabilities, since it started as a simple patching utility and expand really fast to very comprehensive tuning tool with very advanced features.

The primary target of the tool is GM files, but I guess it can be easily adapted to anything out there.
Almost all features are user configurable and there is very good search engine, that can discover opcode patterns and checksum patterns with ease.


You can get  the latest zip folder from github.

https://github.com/joukoy/UniversalPatcher/blob/master/UniversalPatcher-Full.Zip

just unzip and run from folder.[It runs on windows from XP to 10]. Need some .net framework installed.

And also check the official site here

http://universalpatcher.net/


Some the features that needs to outlined is the ability to import xdf files.
There is written some external parser to import a2l files but is not yet implemented due to various reasons.
Also a support for any unencrypted definition files can be added if the demand is big enough.
It is still actively developed so any suggestions or request are welcomed.

Here are some GM files so you can explore the features and some screenshots.
Logged
kur4o
Newbie
*

Karma: +5/-7
Offline Offline

Posts: 13


« Reply #1 on: September 24, 2021, 04:42:13 AM »

some random bins.
Logged
_nameless
Hero Member
*****

Karma: +342/-466
Offline Offline

Posts: 2800



« Reply #2 on: September 24, 2021, 08:17:40 AM »

I think this would be better suited on gearhead-efi.com forum. Nice work
Logged

Giving your mom a tuneup
d3irb
Full Member
***

Karma: +134/-1
Offline Offline

Posts: 195


« Reply #3 on: September 24, 2021, 08:18:36 AM »

Great to see more open source tuning tools! Thanks for posting!

For those curious about what it actually does:

I read the source and it looks like the tool uses a variety of XML definition files and some currently GM-specific hard-coded opcode skeleton cross-correlation to locate segments and tables, and then has a map editor and an XDF generator built in as well.

While everything looks very GM specific, I think the conceptual approach is very similar to the older version of 360Trev's ME7 Swiss Army Knife https://github.com/360trev/ME7RomTool_Ferrari/ , before he added the actual opcode disassembler. Basically, look for known opcode sequences for specific map and table lookups, and then extract the address xrefs from inside of those functions to locate the maps and tables themselves.
Logged
kur4o
Newbie
*

Karma: +5/-7
Offline Offline

Posts: 13


« Reply #4 on: September 24, 2021, 02:14:46 PM »

I think this would be better suited on gearhead-efi.com forum. Nice work

It is already. I decided to share with nefmoto users, since it is another great open source platform for DYI heads.


Great to see more open source tuning tools! Thanks for posting!

For those curious about what it actually does:

I read the source and it looks like the tool uses a variety of XML definition files and some currently GM-specific hard-coded opcode skeleton cross-correlation to locate segments and tables, and then has a map editor and an XDF generator built in as well.

While everything looks very GM specific, I think the conceptual approach is very similar to the older version of 360Trev's ME7 Swiss Army Knife https://github.com/360trev/ME7RomTool_Ferrari/ , before he added the actual opcode disassembler. Basically, look for known opcode sequences for specific map and table lookups, and then extract the address xrefs from inside of those functions to locate the maps and tables themselves.


You are almost correct, unless that there is almost nothing GM hardcoded[some specific checksums of one type of files] and almost everything is user configurable.

The tableseek-xxxx.xml have the search strings patterns that find the tables addresses and offsets.
Not sure where I got inspirations for this. Maybe repeatable compilers patterns found in the disassemblies of different revisions. Maybe some net ideas. Who knows - might have stumbled upon swiss knife that tool at some point.

 
There is some example in the xml folder.

For example if this search string is unique in any revision you are working with

20 70 05 b0 @ @ @ @ 30 38 * * * * * * * * * * * * c0 f8 +D12

It can take an indexed lookup address.
@@@@ is the address of the lookup table`s addresses.
+D12 is the offset from @@@@ where the final addresses is read.
You can even find double or triple indexed stuff for example +d12 +156 and so on.


For research of unknown multiple tables, there is tablesearch-xxx.xml It will find all tables with the same table lookup opcodes, but you have to figure which one does what.


This is for the very advanced users so I can bring some basic stuff first, how it works.
The autodetect.xml contains rules or some specfic identifiers of the bin file, so it can be easily identified as a type upon opening.

The checksum xml files[open from settings->edit config(xml)] can set complex multiple checksums, where start-end addresses can be taken from bin if hardcoded in the file, or searched, or you can just hardcode them, add offsets and so on.

Also in that xml file you configure  how to take p/ns or other stored data as engine identifiers, Vin numbers and anything that is stored at specific address in ascii, integer or hex.

If a file have a p/n stored that can be retrieved when the file is opened, you can set some CVN calculation to check if the file have been altered or is completely stock. Just add the entry in CVN list.

As for the Tuner part. it can work with anything you throw at as long as you have a definition xml, or some xdf can be imported too.
Logged
kur4o
Newbie
*

Karma: +5/-7
Offline Offline

Posts: 13


« Reply #5 on: October 01, 2021, 08:28:04 AM »

Some initial beta support for me7.5 files[still testing not released yet].

Autodetect is working fine with all the files I have and detects p/n; engine type and ecu type.

Some initial definition file ripped from random a2l file.[still needs some more work and polishing].

Need to figure if checksums are possibility for external configuration or some hardcoding is required.


I am looking for some ideas about checksum calculation.
A translation list of abbreviation will be also very handy.

I think the thread is in the wrong section. If admins decide can move it to reverse eng section.
Logged
kur4o
Newbie
*

Karma: +5/-7
Offline Offline

Posts: 13


« Reply #6 on: October 30, 2021, 01:13:16 PM »

The program now supports some more stuff including detection of me7.5 and med9.1 files.

It also can find some dtc table on select med9.1 files.[still beta-needs some descriptions of status byte.Actually any info will be very beneficial here, how dtcs works on bosch stuff]

-Added support for bosch inversed word sum algorythm for checksums. It can also print all inversed pairs in checksum research tab.
-Added .hex and .s19 files import with some very nice features how to treat offsets[tuner->utilities->import]

A sample med9.1 file is attached. Place the .xml file in tuner folder and open the file in tuner.

All stuff works only on latest version in github. Get the full zip folder.

A2l import is still on beta testing and if someone needs some a2l converted for testing with the program, send me a note.

Logged
kur4o
Newbie
*

Karma: +5/-7
Offline Offline

Posts: 13


« Reply #7 on: August 16, 2022, 01:12:57 PM »

Some update on new features.

New logger, it can log 2 channels at the same time. A quality j-2534 tool is required.

New tools for finding tables` offset between different bins.

New data visualizer for even faster offset.

New a2l and winols files converting tool. Not published yet. If anyone needs some files converted, post them here or post to pm.
Logged
Pages: [1]
  Print  
 
Jump to:  

Powered by SMF 1.1.21 | SMF © 2015, Simple Machines Page created in 0.018 seconds with 17 queries. (Pretty URLs adds 0s, 0q)