Pages: 1 ... 3 4 [5]
Author Topic: New open source tuning software  (Read 8722 times)
Artemisia
Full Member
***

Karma: +18/-0
Offline Offline

Posts: 83



« Reply #60 on: March 09, 2025, 04:10:56 PM »

I'm fine with that, it's not a runtime dependency. Although it would be cool to write that tooling myself. I have time, and half a year is not much.

If you want to make something like ME7Info, I can provide some insight on finding and parsing the signal table. I fiddled with it for the ST10 after prj mentioned that. There is a lot of work involved depending on how many variables you would like to support, it would be a good addition to your software based on your end goal.

Personally, I looked into the signal table parsing for R&D in hopes to save time in the long run, I was 100% wrong. Might be simpler on older C167, but prj's approach totally makes more sense in all aspects for finding measurments / variables


You are wrong. It's how NefMoto verifies flash checksums. I am already using it.

It uses a pre-supported routine (0xC5), but if you want to write a custom function and then call it on runtime, it won't work with StartRoutineByLocalIdentifier

Prj has shared detailed information about his RCE exploit on his repo: https://github.com/prj/me7log
« Last Edit: March 09, 2025, 04:13:03 PM by Artemisia » Logged
willemml
Full Member
***

Karma: +10/-0
Offline Offline

Posts: 50


« Reply #61 on: March 09, 2025, 06:40:28 PM »

If you want to make something like ME7Info, I can provide some insight on finding and parsing the signal table. I fiddled with it for the ST10 after prj mentioned that. There is a lot of work involved depending on how many variables you would like to support, it would be a good addition to your software based on your end goal.

Definitely curious.

Personally, I looked into the signal table parsing for R&D in hopes to save time in the long run, I was 100% wrong. Might be simpler on older C167, but prj's approach totally makes more sense in all aspects for finding measurments / variables

This is definitely the route I am most interested in, I have been idly poking at it every now and then.

It uses a pre-supported routine (0xC5), but if you want to write a custom function and then call it on runtime, it won't work with StartRoutineByLocalIdentifier

Ah I see, so it does exist, it just won't be useful to me.
Logged
willemml
Full Member
***

Karma: +10/-0
Offline Offline

Posts: 50


« Reply #62 on: March 09, 2025, 07:28:39 PM »

Prj has shared detailed information about his RCE exploit on his repo: https://github.com/prj/me7log

I am considering giving that a shot, but it would be nice to have the satisfaction of figuring it out myself.
Logged
prj
Hero Member
*****

Karma: +1089/-512
Online Online

Posts: 6158


« Reply #63 on: March 10, 2025, 12:51:28 AM »

Ah I see, so it does exist, it just won't be useful to me.

No, you thought that you can just write random code into RAM in ASW and execute it via those commands.
So for all intents and purposes what you described does not exist.

One step ahead of you, have been doing this for a while too, you know? Wink

WriteMemoryByAddress works on earlier ECU's, and you need to make the ECU jump to your code by using that.
On newer ECU's that's closed as well, but on those DDLI and WBLI works. Some need security access, especially for speed switching, sometimes that access is blocked on a huge timer, which you have to bypass with another exploit. Or you can call the set baud directly from your code... etc...
As I said, more difficult than all the shit you've done until now combined. I know because I've done it all.
Logged

PM's will not be answered, so don't even try.
Log your car properly - WinOLS database - Tools/patches
Artemisia
Full Member
***

Karma: +18/-0
Offline Offline

Posts: 83



« Reply #64 on: March 11, 2025, 07:15:31 PM »

Definitely curious.

The signal table refer to the %TKMWL Testerkommunikation; Meßwerte lesen



To create your initial signature / pattern to find the table, I look where TKMWLMW is being used. Then I can see the function that push the measurement value to the table



I named it for PUSH_TO_TABLE. By looking at the first reference to this function, you can find the function that compute this table.



That function looks very similar for all ME7 and even the MED9 (of course different instruction set). You can now identify NA_nr, NORMWERT and the variable that hold the value of the measurement

Under the Jump indirect, you can find your signal table



I added some comments, but it is self-explanatory. When a Nr get skipped, it is being processed in the same location (dual-bank system, etc)


If you work on one engine or very similar controller, you could make a script that identify the location of your signal table, then parse it and use signatures to identify your RAM locations. I think this would be the shortest path to achieve what you want

There are surely other ideas out there. Personally, I was looking into making an interpreter for C166 instructions that would go through the function to properly find variables and their RAM location. This way it would support all ME7

This code is also stored into the AM29F800 on the ST10 ECUs which make it convenient as no readout of the processor is required

Those are rough explanations, I am not that great to explain stuff. I hope this helps

Unrelated, but it might also interest you. For reading ECU that are "locked", you can use the checksum routine to map the whole file. There are clever ways to optimize it and have quick readouts as well
Logged
prj
Hero Member
*****

Karma: +1089/-512
Online Online

Posts: 6158


« Reply #65 on: March 12, 2025, 03:44:51 AM »

Unrelated, but it might also interest you. For reading ECU that are "locked", you can use the checksum routine to map the whole file. There are clever ways to optimize it and have quick readouts as well
As long as WMBA/DDLI/WBLI are not locked you can just inject the RCE payload and read whatever you want.
Logged

PM's will not be answered, so don't even try.
Log your car properly - WinOLS database - Tools/patches
Pages: 1 ... 3 4 [5]
  Print  
 
Jump to:  

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